On Error Goto Start SaveFile.ShowDialog() b = SaveFile.FileName If Not System.IO.File.Exists(b) = True Then Dim file As System.IO.FileStream file = System.IO.File.Create(b) file.Close() End If My.Computer.FileSystem.WriteAllText(b, RichText.Text, False) TabControl1.SelectedTab.Text = b Start: MsgBox(Err.Description)
This Works on Error with problem is that if there is no error But still it excute the messagebox