Clyde Level: Graduate
 Registered: 07-08-2005 Posts: 9
|
edit text file running shell batch script
Is there a way to directly edit a .txt file using the shell command, Now I have a button pointing to a certian batch file to edit the .txt file. What I am looking to do is to skip the batch file.
Here is the shell command I am using on a button called EDIT is...
Private Sub Command4_Click()
Dim RetVal
intpress = MsgBox("Are you sure you want to edit the SOURCE data?", vbQuestion + vbYesNo, "Source File")
If intpress = vbNo Then
Else
RetVal = Shell("c:\Data.bat", 1)
End If
End Sub
The Batch file is....
@echo off
edit c:\data.TXT
exit";
Thanks...
Clyde
|