Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Back to basics! 1

Status
Not open for further replies.

ebuBekir

Technical User
Sep 6, 2001
22
0
0
DE
I have big problems with structures!

typedef struct {WORD pixel;
int i;
int j;
int iStart;
int iMax_i;
int iMin_i;
double dAngle;
double dDistance;
CString csDecision;
int n;
} MfContour2D;

MfContour2D* Funct();

MfContour2D* pTmp = 0;

The function returns a pointer on some kind of a list of structure.
pTmp =Funct();

I want to point at places immediately after that ‘list’
pTmp += pTmp->n;
But I get problems, as at that place pTmp->n is not evaluable.
(Error: Expression cannot be evaluated!)

Can you please help me?

agurcan@hotmail.com
 
MfContour2D data[10]
MfContour2D* pTmp = data;
pTmp++;//dont increment the address but go to the next
//structure in the array Ion Filipski
1c.bmp


filipski@excite.com
 
Thanks Ion!
It works the way you wrote it!

ebuBekir :cool:
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top