Expand|Select|Wrap|Line Numbers
- EventLogEntryStruct EventLogEntry[100];
- for(int i=1;;i++)
- {
- EventLogEntry[i].logName = "log-";
- EventLogEntry[i].eventString = "event-";
- EventLogEntry[i].bufPos = i;
- EventLogEntry[i].logIdx = i+1;
- logName.append(i);//= "log-";
- EventLogEntry[i].dateTime = i+4;
- EventLogEntry[i].systemTick = i;
- EventLogEntry[i].resetCount = 1;
- EventLogEntry[i].inAir = 1;
- EventLogEntry[i].appSpec1 = i+2;
- EventLogEntry[i].appSpec2 = i+3;
- EventLogEntry[i].appSpec3 = i+1;
- EventLogEntry[i].timeStampLSW = 12;
- EventLogEntry[i].timeStampMSW = 24;
- EventLogEntry[i].timeStamp = 22;
- EventLogEntry[i].timeDelta = 12;
- EventLogEntry[i].windowID = i+2;
- eventString.append(i);// = "event-1";
here EventLogEntryStruct is a structure defined in my header file and i have created an instance of it as EventLogEntry. now i have to run an infinite loop as its a code in the server side which will be continuously sending data to the client ... now i want to change the logName and eventString everytime in the loop so what i did is at line no 4& 5 i ve declared it and used the append function at line no. 10 & 23 but its throwing error of:
[HTML]D:\trial\serverTrial.cpp(175) : error C2065: 'logName' : undeclared identifier
D:\trial\serverTrial.cpp(175) : error C2228: left of '.append' must have class/struct/union type
D:\trial\serverTrial.cpp(188) : error C2065: 'eventString' : undeclared identifier
D:\trial\serverTrial.cpp(188) : error C2228: left of '.append' must have class/struct/union type[/HTML]
so can any one plz help me ut in sorting this error..