RE: w32engin

new topic     » goto parent     » topic index » view thread      » older message » newer message

Tyler Southwick wrote:
> I am trying to define the structure "LV_COLUMN" with w32engin, but can't 
> 
> use the c type "LPTSTR".  From the win32 docs the structure is defined:
> 
> typedef struct _LV_COLUMN { 
>     UINT mask; 
>     int fmt; 
>     int cx; 
>     LPTSTR pszText; 
>     int cchTextMax; 
>     int iSubItem; 
> } LV_COLUMN; 
> 
> I defined it as:
> StList &= { {0,"LV_COLUMN",
>     "mask        : UINT   : 4 "& 
>     "fmt         : int    : 4 "&
>     "cx          : int    : 4 "&
>     "pszText     : LPTSTR : 4 "&
>     "cchTextMax  : int    : 4 "&
>     "iSubItem    : int    : 4 "} }
> 
> but i get the message that LPTSTR is an invalid C type.  how do i make 
> it work?
> 
> 

StList &= { {0,"LV_COLUMN",
 "mask        : uint    : 1 "& 
 "fmt         : int     : 1 "&
 "cx          : int     : 1 "&
 "pszText     : pointer : 1 "&
 "cchTextMax  : int     : 1 "&
 "iSubItem    : int     : 1 "} }

  pszText is a pointer to a zero terminated string.

  The last numbers should be 1 for each member of the
  structure because it is the number of units or ints or pointers.
  If you were describing for example 20 bytes you
  would use something like "data : byte : 20"

Bernie

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu