' Display an OpenFileDialog so the user can select a Cursor.
Dim openFileDialog1 As New OpenFileDialog()

openFileDialog1.Filter = "VMware Configuration files (*.txt)|*.txt|All files (*.*)|*.*"
openFileDialog1.Title = "Selecteer een bestand"

' Show the Dialog.
' If the user clicked OK in the dialog and
' a .XML file was selected, open it.

If openFileDialog1.ShowDialog() = Windows.Forms.DialogResult.OK Then


I gote a problem whit this code
you can open a txt file but when
I click an the button cancel he gives error
Ik know that with this it to do has


If openFileDialog1.ShowDialog() = Windows.Forms.DialogResult.OK Then
I can just open it but i wanne cancel to how do i do that