>>SET CENTURY on >>SET DELETED on >>SET EXCLUSIVE off >>SET safety off >> >>SELECT 2 >>USE main2 >>GO TOP IN main2 >>IF NOT EOF("main2") >> >> gcDelimName = ALIAS( ) + '.xls' >> gcPath = [w:\Quality Test 01\mtest\] >> gcDelimName = gcPath + DTOS(file_date) + ".XLS" >> lcFile=gcDelimName >> >> if adir(dummy,lcFile)>0 >> MESSAGEBOX(" file exists") >> else >> COPY TO (gcDelimName) XL5 >> endif >> >>******* >> >>SET DEFAULT TO [z:\smd\INFORMATIONTECHNOLOGYFOLDER\Programs\New Folder\] >>DROP table main1 >>insert INTO mstr ; >> SELECT * FROM main2 WHERE file_date NOT IN (SELECT file_date FROM mstr) >>DROP table main2 >>endif >> >>****** >> >>SET DEFAULT TO [w:\Quality Test 01\Source Data] >>GETFILE('xls') >>thisform.text9.Value=GETFILE('xls') >> >> >>CREATE TABLE [\\Cctfil01\HRD-SpData\smd\INFORMATIONTECHNOLOGYFOLDER\Programs\New Folder\main1.dbf]; >>(msisdn n(15),num n(8),date d(8) ,flag n(2) ) >>APPEND FROM (thisform.text9.Value) TYPE xl5 >>Replace Date with thisform.text1.value ; >> flag with 0 ; >> num with RecNo() ALL >> >>********************************************* >> >> >> >>CREATE TABLE [\\Cctfil01\HRD-SpData\smd\INFORMATIONTECHNOLOGYFOLDER\Programs\New Folder\main2.dbf]; >>(num n(8),survey_num n(2),msisdn n(15),file_date d(8) ,intervdate d(8),status n(2),othersst c(100),con_type c(20) ) >>************************************************* >>*****SET DEFAULT to [z:\smd\INFORMATIONTECHNOLOGYFOLDER\Programs\New Folder\] >>SET DEFAULT TO [w:\Quality Test 01\Source Data] >>COPY FILE thisform.text9.Value.xls TO [w:\Quality Test 01\MTEST\(thisform.text9.Value).xls] >>ERASE (thisform.text9.Value).xls >>>>another form at..