ads

Saturday, November 25, 2006

VB: Open Save File

Public Function SaveFile(File2Save As String, txtContent As String)

'Variable Declaration
Dim fLen As Integer

'Get the free file number
fLen = FreeFile

'Create Specified File
Open File2Save For Output As #fLen
Print #fLen, txtContent 'save the txtContent to the created file
Close #fLen 'Close the opened

End Function

No comments:

Google Search