need help..
- From: bng_s@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx (slickn_sly)
- Date: 31 Mar 2005 03:55:11 -0600
<code>
line = 1;
while( !feof( infile ) )
{
if( line = 2 )
{
fgets( name, 25, infile );
}
else if( line = 3 )
{
fgets( address, 80, infile );
strcat( tempaddress, address );
if( strcmp( address, "?" ) == 0 )
{
line = 4;
}
}
else if( line = 4 )
{
fgets( yearofbirth, 5, infile );
}
else if( line = 5 )
{
fgets( telno, 15, infile );
}
line++;
printf( "%s%s%s%s", name, address, yearofbirth, telno );
addRecord( rptrp , name, address, atoi(yearofbirth), telno
);
}
</code>
I wonder if someone can help me out. For some reason, this while loop
doesn't update. line is always set to 1. i'm trying to get each line
and store it in each array.
Posted at: http://www.groupsrv.com
Posted Via Usenet.com Premium Usenet Newsgroup Services
----------------------------------------------------------
** SPEED ** RETENTION ** COMPLETION ** ANONYMITY **
----------------------------------------------------------
http://www.usenet.com
.
- Follow-Ups:
- Re: need help..
- From: Martin Ambuhl
- Re: need help..
- Prev by Date: What is memory pool
- Next by Date: Re: need help..
- Previous by thread: What is memory pool
- Next by thread: Re: need help..
- Index(es):
Relevant Pages
|