VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



Lauches an application based on file extension

by T-REX Software (14 Submissions)
Category: Files/File Controls/Input/Output
Compatability: Visual Basic 4.0 (32-bit)
Difficulty: Unknown Difficulty
Originally Published: Wed 24th March 1999
Date Added: Mon 8th February 2021
Rating: (1 Votes)

Lauches an application based on file extension

API Declarations


Private Declare Function GetDesktopWindow Lib "user32" Alias "GetDesktopWindow" () As Long


Rate Lauches an application based on file extension



Scr_hDC = GetDesktopWindow ()
'change "Open" to "Explore" to bring up file explorer
StartDoc = ShellExecute (Scr_hDC, "Open", DocName, "", "C:\", 1) 
'end function

'Place the following code in under a command button or in a menu, etc...

dim r as long
r = startdoc ("C:\windows\arcade.bmp")

Download this snippet    Add to My Saved Code

Lauches an application based on file extension Comments

No comments have been posted about Lauches an application based on file extension. Why not be the first to post a comment about Lauches an application based on file extension.

Post your comment

Subject:
Message:
0/1000 characters