I do actually have it as "!=", I must have made a typo when I wrote the
email..
but the if (var1[i] != *x) works..!!!

thanks alot guys!!
:)
Rania


----- Original Message -----
From: Max Bian <[EMAIL PROTECTED]>
To: Palm Developer Forum <[EMAIL PROTECTED]>
Sent: Tuesday, November 27, 2001 12:01 PM
Subject: Re: ChrPtr


> If x is another ChrPtr and you want to compare two characters, you need to
do :
> if (var1[i] != *x)
>
> Max
> --- Max Bian <[EMAIL PROTECTED]> wrote:
> > I believe ChrPtr is just Char *.  It makes no difference then.
> >
> > So if you have ChrPtr s="blah....", It will be the same as Char *s =
> > "blah...".
> > you should be able to use s[0], s[1]...to get the individual chars.
> >
> > Is "=!" what you wanted there?
> >
> > Max
> >
> > --- Rania Saymeh <[EMAIL PROTECTED]> wrote:
> > > if a string is defined as a ChrPtr, is that still equivelent to a
string
> > > where I can still access the character elements seperatly as an array?
> > > I have my ChrPtr var1 which is always going to be the size of 5 chars
> > > I would like to access the chars seperatly..how do I do that..?
> > > if I try something like, where X is another ChrPtr, it keeps
complaining
> > > that it's an illegal operand..
> > >
> > >
> > > for (i=0; i<5; i++){
> > >   if (var1[i] =! x){
> > >  ...}
> > > ..
> > > }
> > >
> > > thanx
> > >
> > > Rania
> > >
> > >
> > > --
> > > For information on using the Palm Developer Forums, or to unsubscribe,
> > please
> > > see http://www.palmos.com/dev/tech/support/forums/
> >
> >
> > __________________________________________________
> > Do You Yahoo!?
> > Yahoo! GeoCities - quick and easy web site hosting, just $8.95/month.
> > http://geocities.yahoo.com/ps/info1
> >
> > --
> > For information on using the Palm Developer Forums, or to unsubscribe,
please
> > see http://www.palmos.com/dev/tech/support/forums/
>
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! GeoCities - quick and easy web site hosting, just $8.95/month.
> http://geocities.yahoo.com/ps/info1
>
> --
> 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/

Reply via email to