Design :
1) Make a "Rich Textbox" and make it fill everything, but make a place for at toolstrip in the top.
2) Add a "Toolstrip Menu"
3) Press "Make New" (Also known as "Arrow down")
4) Choose "DropDown Button"
5) Right-Click the DropDown Button, choose "Display Style" and say Text.
6) now call it file, and make the following dropdown buttons :
Open
Save
Exit
7) Now do the same again, but call the new dropdown menu "Edit" and add the following dropdown buttons:
Undo
Redo
Copy
Paste
Cut
8) now to the coding.
Code :
1) For the "Undo" button use this code :
Code:
RichTextBox1.Undo()
2) For the "Redo" button use this code :
Code:
RichTextBox1.Redo()
3) For the "Copy" button use this code :
Code:
RichTextBox1.Copy()
4) For The "Paste" button use this code :
Code:
RichTextBox1.Paste()
5) For the "Cut" button use this code :
These codes are also called "Drag and Drop codes" becourse their so easy. its just "Element.Function" so its not hard

6) For "Open" button use this code:
(This code is a bit bigger)
Code:
Dim Open As New OpenFileDialog()
Dim myStreamReader As System.IO.StreamReader
Open.Filter = "All Files[*.*]|*.*"
Open.CheckFileExists = True
Open.Title = "Open File"
Open.ShowDialog(Me)
Try
Open.OpenFile()
myStreamReader = System.IO.File.OpenText(Open.FileName)
Document.Text = myStreamReader.ReadToEnd()
Catch ex As Exception
End Try
let me explain how this works, Stream Writer & Stream Reader is like "Save & Load" becourse "Stream Writer" writes text (Same as SAVE) and Stream Reader says itself in the name xD
"Dim" mean Make A New Code As [System File]
lets get to the next code, shall we ?
7) For the "Save" button use this code :
Code:
Dim Save As New SaveFileDialog()
Dim myStreamWriter As System.IO.StreamWriter
Save.Filter = "All Files[*.*]|*.*"
Save.CheckPathExists = True
Save.Title = "Save File"
Save.ShowDialog(Me)
Try
myStreamWriter = System.IO.File.AppendText(Save.FileName)
myStreamWriter.Write(Document.Text)
myStreamWriter.Flush()
Catch ex As Exception
'Do nothing on Exception'
End Try
i just told how Stream Reader and Stream Writer works, so u can easily figure this cod out.
8) For "Exit" button use this code :
Remember the "Exit" code, u can use this in al programs as a "Close Button" or something. "Me" means [This Form] so if ur in form 2 and wanna close form 1 use "Form1.Close()
Thanks for Looking, Enjoy
