.PJ Posted September 13, 2004 Share Posted September 13, 2004 Hello, Im working in VB and Im trying to make a File tool bar (can make one) But I add Save to the File section, does anyone have the code that when they click save it will save a text box called Text1 (default) Thanks PJ :D Link to comment Share on other sites More sharing options...
0 hash Posted September 14, 2004 Share Posted September 14, 2004 you mean save the contents of text1 to a file when the save button is pressed? private sub SaveFile(TextBox as Control, FileName as string) if len(trim(textbox.text)) = 0 then exit sub ' nothing to save if filename = "" then exit sub ' no file name open filename for output as #1 print #1, textbox.text close #1 end sub this is a very basic example........... Link to comment Share on other sites More sharing options...
Question
.PJ
Hello,
Im working in VB and Im trying to make a File tool bar (can make one) But I add Save to the File section, does anyone have the code that when they click save it will save a text box called Text1 (default)
Thanks
PJ :D
Link to comment
Share on other sites
1 answer to this question
Recommended Posts