|
-
Nov 20th, 2008, 10:19 AM
#1
Thread Starter
Fanatic Member
[RESOLVED] [2008] Open With, in Vista
I've been using this in an XP environment without any problems to get the Open With dialog:
Dim sei As New SHELLEXECUTEINFO
Dim strFileName As String
sei.cbSize = Len(sei)
sei.hwnd = Me.Handle.ToInt32
sei.lpVerb = "openas"
sei.lpFile = strFileName
sei.nShow = 2
ShellExecuteEx(sei)
But, when I try it in Vista Business with any file extension I get this:
This file does not have a program associated with it for performing this action. Create an association in the Set Associations control panel.
I went to that control panel, and gifs, for instance, definitely have a program associated.
Has anyone encountered this problem? Does anyone know how to fix it?
Thanks
VB.Net 2008
.Net Framework 2.0
"Must you breathe? 'Cause I need heaven..."
-
Nov 20th, 2008, 11:27 AM
#2
Re: [2008] Open With, in Vista
try this:
vb Code:
Private Sub OpenWith(ByVal fileName As String)
Process.Start("RUNDLL32.EXE", "shell32.dll,OpenAs_RunDLL " & fileName)
End Sub
- Coding Examples:
- Features:
- Online Games:
- Compiled Games:
-
Nov 20th, 2008, 12:54 PM
#3
Thread Starter
Fanatic Member
Re: [2008] Open With, in Vista
VB.Net 2008
.Net Framework 2.0
"Must you breathe? 'Cause I need heaven..."
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|