Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Create and save file in diffrent directory bt command.

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
Dear all,
I want to create a file and save the file with VB command, as it is required to do this when some information is to be stored dynamecally. Sipmly speaking if I want to create file name test.txt in c:\ then what shoul I do?
Hiren
 
What application do you want to run the Command from?
What is going to be in test.txt?
 
dear darksun,
let me tell you in simple language. suppose i am putting one CommandButton on one Form then after clicking that button one file, say test.txt should be created in c:\, how can we write the code???thanks for reply....

Hiren
 
Open "C:\test.txt" For Output As #1
Print #1, "This will be saved to the file"
Close #1 Ruairi

Could your manufacturing facility benefit from real time process monitoring? Would you like your employees to be able to see up to the minute goal and actual production?
For innovative, low cost solutions check out my website.
 
Dear Ruairi,
Thanks a lot finally I have got solution from you, thanks again.

Hiren
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top