V
Vijay
Hi,
Can anybody help me in below code? I am not sure how it is happing.
After fgetc(pB), position_B should be 1 but i am getting 0.
but I am getting right value for position_A.
.....
FILE *pA=NULL, *pB=NULL,
.....
fpos_t position_A,position_B;
while(!feof(pA)&& !feof(pB))
{
fgetpos (pA, &position_A); // position_A-> 0
fgetpos (pB, &position_B); //position_B-> 0
a=fgetc(pA);
b=fgetc(pB);
fgetpos (pA, &position_A); // position_A-> 1
fgetpos (pB, &position_B); //position_B-> 0
.....
I am using Visual Studio 2003 and 2008
Thanks,
Vijay
Can anybody help me in below code? I am not sure how it is happing.
After fgetc(pB), position_B should be 1 but i am getting 0.
but I am getting right value for position_A.
.....
FILE *pA=NULL, *pB=NULL,
.....
fpos_t position_A,position_B;
while(!feof(pA)&& !feof(pB))
{
fgetpos (pA, &position_A); // position_A-> 0
fgetpos (pB, &position_B); //position_B-> 0
a=fgetc(pA);
b=fgetc(pB);
fgetpos (pA, &position_A); // position_A-> 1
fgetpos (pB, &position_B); //position_B-> 0
.....
I am using Visual Studio 2003 and 2008
Thanks,
Vijay