Your array should be of size 5 (4 characters plus the end of file
character). Also, you cannot assign strings, use StrCopy. Hope that helps!
Regards,
Steve
-----Original Message-----
From: Patrick Ouellet [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, July 12, 2000 12:48 PM
To: Palm Developer Forum
Subject: Newbie to Palm question about using variable
Ok I tried something really easy.
// Regular C of what I want to do.
char TempCode[4] = "0000\0";
int CurChar = 0;
if( // the button #2 is pressed )
{
TempCode[CurChar] = '2';
CurChar++;
}
if( //the button #3 is pressed )
{
TempCode[CurChar] = '3';
CurChar++;
}
if( // the '#' button is pressed )
{
*TempCode = "0000\0";
CurChar = 0;
}
But no matter what I do TempCode never change.
Is there something I don't know I really should
Or am I just a id10t
--
Patrick Ouellet, Programmeur/Analyste
Département: Recherche & Développement
Les Entreprises Microtec Inc.
4780 rue St-Félix, St-Augustin, Qc, G3A-2J9
(418) 864-7644 poste 130
[EMAIL PROTECTED]
http://www.microtecsecurite.com/
--
For information on using the Palm Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/tech/support/forums/
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/