I think, the segment has nothing to to with this. Did you declare the struct
in the second file? You should place the declaration in a header file and
include it into both files:
<include-file>
typedef struct{
UInt8 lastHighScore;
} GamePreferenceType
<first file>
#include "headerfile.h"
GamePreferenceType Prefs;
<second file>
#include "headerfile.h"
extern GamePreferenceType Prefs;
If you just say "extern .." without declaring the structure, the compiler
does not know it.
Thomas
"Giorgos Sarris" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
news:[EMAIL PROTECTED]
>
> Hi to all,
>
> I use CW9, C++.
>
> I make a multi-segment program.
> In the main segment I have (eg):
>
> typedef struct
> {
> UInt8 lastHighScore;
> } GamePreferenceType;
>
> GamePreferenceType Prefs;
>
> How can I call that from the second segment???
> I tried:
> extern GamePreferenceType Prefs;
>
> but it doesn't work!!
>
> Thanks a lot.
> Giorgos
>
>
> ____________________________________________________________
> Do You Yahoo!?
> ��������� �� ������ @yahoo.gr ��������� ��� ��� http://www.otenet.gr
>
>
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/support/forums/