TSFLLC
asked on
OpenFileDialog Issue - How to get file like (.doc, .xls) to open outside VB
I have the basic structure of an openfiledialog.
My filter is "All Files|*.*"
The folder could contain multiple file types. txt, doc, pdf, xls.
What is required to mirror the execution of one of these file types when double-clicking the file as occurs with Windows Explorer?
I don't seem be be getting there.
My filter is "All Files|*.*"
The folder could contain multiple file types. txt, doc, pdf, xls.
What is required to mirror the execution of one of these file types when double-clicking the file as occurs with Windows Explorer?
I don't seem be be getting there.
Dim pathToFolder As String = glRootDirectory & "\OtherWarrantyInfo"
OpenFileDialog1.InitialDirectory = pathToFolder
OpenFileDialog1.FileName = ""
OpenFileDialog1.Filter = "All Files|*.*"
OpenFileDialog1.RestoreDirectory = True
OpenFileDialog1.Multiselect = False
OpenFileDialog1.ShowDialog()
If OpenFileDialog1.FileName = "" Then
Exit Sub
Else
OpenFileDialog1.OpenFile()
End If
SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
ASKER CERTIFIED SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
ASKER
Thanks to both. 400 for full coding.