Thanks Zyrenthian,
I tried your code with my program but got few errors, i tried help in VC++ on _tolower and still cannot get it to work.
There what i have so far..
#include <stdio.h>
#include <afx.h>
#include <Ctype.h>
#include <String.h>
#include <conio.h>
int main()
{
struct KeepCapital
{
CString lower;
CString upper;
};
KeepCapital kc[]={ {"tv","TV"},{"cid","CID"}};
FILE *fp, *fp1; // file pointer
int nTimeFlag=0; // time flag
float nTmpTime=0.00; // ref time.
char fname[80];
printf("File name to convert: "

;
scanf("%s",fname);
/* Open file for reading (fail if data does not exist) */
if( (fp = fopen(fname, "rt" )) == NULL )
printf( "error opening file \n" );
else
printf( "file opened \n" );
fp1 = fopen("pec.txt","wt"

;
// store original time in array time
while (!feof(fp))
{
float nTime;
char szBuf[10];
int nRet = fscanf(fp,"%f",&nTime);
if (nRet == -1) break;
fgets(szBuf,10,fp);
_tolower(szBuf );
*/ // write converted time(2dp) and text to new file
fprintf(fp1,"%.2f %s\n",nTmpTime,szBuf);
}
fclose(fp);
fclose(fp1);
return 0;
}
i am getting error on initialize KeepCapital ( cannot conver fromchar[3] /[4])
Help..