Solved

Launching a File

Posted on 2002-05-25
4
150 Views
Last Modified: 2010-05-18
Hi all,

In function I need to run a file outside of my app, just as if the user had clicked on the filename.  It could be a Word document, Zip file, *.Htm, *.exe, etc.  I used to do this in batch files by using: Start("Path/Filname") or similar syntax in Win98.

In application the user will double-click on a filename to be found in some text displayed in link format in my app window.

The platform would be any Windows 98/Me/NT5. I'm using VB6.

Any ideas are appreciated.

Jim
0
Comment
Question by:syntel
  • 2
4 Comments
 
LVL 44

Accepted Solution

by:
bruintje earned 200 total points
ID: 7034257
Hi syntel,

you can use the shellexecute function to do this

for a complete sample implementation
http://www.planet-source-code.com/vb/scripts/ShowCode.asp?txtCodeId=34188&lngWId=1

HTH:O)Bruintje
0
 
LVL 20

Expert Comment

by:hes
ID: 7034259
Here are a couple of other options

http://www.freevbcode.com/ShowCode.Asp?ID=525
0
 

Author Comment

by:syntel
ID: 7036517
Thanks for all responses.  I will be working on this next week, but it looks good.
0
 
LVL 44

Expert Comment

by:bruintje
ID: 7036522
thanks for the grade
0

Featured Post

ScreenConnect 6.0 Free Trial

At ScreenConnect, partner feedback doesn't fall on deaf ears. We collected partner suggestions off of their virtual wish list and transformed them into one game-changing release: ScreenConnect 6.0. Explore all of the extras and enhancements for yourself!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Link a textbox in excel to a cell with more than 255 characters. 5 95
VBA open file from excel cell 4 42
Hide vba in gp 7 96
Child Form in front 4 47
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question