2013-08-03 42 views
-1

我想選擇一個打開文件對話框的程序孤男寡女選擇一個程序,然後啓動它

我想要做的是選擇該文件,並打開它時,我的第二個按鈕點擊

而且我也想知道是否有可能將互聯網優先權添加到此程序?

Public Class Form1 

Private Sub PictureBox1_Click(sender As Object, e As EventArgs) 

End Sub 


Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click 

End Sub 

Private Sub OpenFileDialog1_FileOk(sender As Object, e As System.ComponentModel.CancelEventArgs) Handles OpenFileDialog1.FileOk 

End Sub 

Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click 

End Sub 

End Class 

回答

0

嘗試使用此

Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click 
    Try 
     OpenFileDialog1.ShowDialog() 
     System.Diagnostics.Process.Start(OpenFileDialog1.FileName) 
    Catch ex as Exception 
    End Try 
End Sub 
+0

謝謝你,它的工作 –

+0

現在是有可能使這一計劃有互聯網優先 –

相關問題