Well im wondering how to make my text editor ask to save the changes before closing, what i mean is if you changed the document it will have a message box if it has been saved after changens, i know i can do:
Is there a better way of doing this?
Visual Basic:
Dim SaveSts as String = "Saved"
'Under TextBox1_TextChanged:
SaveSts = "Unsaved"
'Under Savebtn_Click:
SaveSts = "Saved"
'Under Form1_FormClosing:
'use e.cancel = true and a msgbox
Last edited by a moderator: