【发布时间】:2014-12-31 14:09:10
【问题描述】:
我有以下代码:
for(int iY=0;iY<(Height-YRemainder);iY=iY+16);
{
for(int iX=0;iX<(Width-XRemainder);iX=iX+16);
{
if(Operation==BLACKNESS)
{
Operation = WHITENESS;
PatBlt(DeviceContext, iX, iY, 16, 16, Operation);
}
else
{
Operation = BLACKNESS;
PatBlt(DeviceContext, iX, iY, 16, 16, Operation);
}
}
if(Operation == BLACKNESS)
{
Operation = WHITENESS;
PatBlt(DeviceContext, Width-XRemainder,iY,16,16,Operation);
}
else
{
Operation = BLACKNESS;
PatBlt(DeviceContext, Width-XRemainder, iY, 16, 16, Operation);
}
}
编译时,我收到针对 iX 和 iY 的每个 PatBlt 报告的未声明标识符。我是否误解了每个变量的范围是如何在这里工作的,或者我错过了什么?
提前致谢
【问题讨论】: