PureSc0pe Posted March 24, 2004 Posted March 24, 2004 I am trying to make it to where i can just click a button and a whole text file is erased. How would I go about doing this? Starting me with off with some coding would be great...Thanks.. Quote It's not impossible, it's Inevitable.
*Experts* mutant Posted March 24, 2004 *Experts* Posted March 24, 2004 Did you consider deleting the file and then recreating it? But if you still wanna do it like that here is how you can. Open the file using StreamWriter and specify the append argument as false which will clear the file. Dim wr As New IO.StreamWriter("file path", False) 'dont forget to close the stream wr.Close() Quote
PureSc0pe Posted March 24, 2004 Author Posted March 24, 2004 Did you consider deleting the file and then recreating it? But if you still wanna do it like that here is how you can. Open the file using StreamWriter and specify the append argument as false which will clear the file. Dim wr As New IO.StreamWriter("file path", False) 'dont forget to close the stream wr.Close() Thanks, I'm starting to figure this thing out :) Quote It's not impossible, it's Inevitable.
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.