Go Back   Computer Forums > General Computing > Programming
Join Computer forums Today

Thread Tools Search this Thread Display Modes
Old 05-04-2005, 12:06 PM   #1
Solid State Member
Join Date: Jun 2004
Posts: 11
Question VB6 click to bring explorer

Hi everyone,

I am creating a CD that would run a form on of the button when click it should bring explorer but I want to show what is on the CD. Right now when I clicked on it, it opens explorer but it shows what is in My Documents folder. this is the code I have right now:

Dim fsoX As Scripting.FileSystemObject
Dim strX As String
Set fsoX = New Scripting.FileSystemObject
strX = fsoX.GetSpecialFolder(0).Path
strX = fsoX.BuildPath(strX, "\Explorer.exe")
Shell strX, vbNormalFocus

Again thanks for the help

Access2mex is offline   Reply With Quote
Old 05-04-2005, 01:38 PM   #2
Fully Optimized
UK31337's Avatar
Join Date: Feb 2005
Posts: 2,776

How about

Shell("C:\Windows\explorer.exe DRIVELETTER:")?

Swap DRIVELETTER for your CD Drive e.g. E:

Hope that helps, if I've misunderstood the question please ask again.
Master of common sense. If you don't like it, stop reading.
UK31337 is offline   Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

All times are GMT -5. The time now is 07:16 AM.

Powered by vBulletin® Version 3.8.8 Beta 4
Copyright ©2000 - 2016, vBulletin Solutions, Inc.
Search Engine Friendly URLs by vBSEO 3.6.0