I am novice in C programming.
i have to read a record from file which looks like
c|string1|string2$c|string1|string2$
I am trying to read using fscanf like
fscanf(fp,"%c|%[^|]s%[^$]s",&ch,string1,string2);
but im not getting c ,string1,string2
after playing around for some time I changed my fscanf to
fscanf(fp,"%c|%[^|]%c[^$]s",&ch,string1,string2);
which read successfully
can anybody help me out what's happening
Thanks in advance
--
comp.lang.c.moderated - moderation address: clcm@[EMAIL PROTECTED]
-- you must
have an appropriate newsgroups line in your header for your mail to be
seen,
or the newsgroup name in square brackets in the subject line. Sorry.


|