Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Your opinion
Message
From
30/11/2005 17:02:51
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Your opinion
Miscellaneous
Thread ID:
01073478
Message ID:
01073478
Views:
40
Hello,

What is the purpose of this following codes, your opinion ?

Tia
Parameters tcOpenFile, tcFileName
Local lcFileName, lnHandle, lnOHandle, lcFileIn, lnI

lcFileIn = ""
lnI 	 = 1
lnOHandle = FOpen( tcOpenFile )

If File( tcFileName )
	Erase ( tcFileName )
Endif
lnHandle = Fcreate( tcFileName )

Do While Not FEof( lnOHandle )
	lcFileIn = lcFileIn + FGets( lnOHandle)

	If !Empty(lcFileIn)
		lcFileIn = Left(lcFileIn, Len(lcFileIn) - 1 )
	Endif

	If lnI % 2 = 0
		If Len(lcFileIn) > 152
			lcFileIn = Left(lcFileIn, 151) + Chr(13)
		Endif
		=Fwrite( lnHandle, lcFileIn )
		lcFileIn = ""
	Endif
	lnI = lnI + 1
Enddo
=FClose( lnOHandle )
=FClose( lnHandle )
Next
Reply
Map
View

Click here to load this message in the networking platform