|
-
Dec 11th, 2001, 10:57 AM
#1
Thread Starter
Member
executing a shortcut?
How do you open a folder from vb to view its contents outside of a project?
i.e. C:\My Documents\New Folder
Thanks
Jim
Under the Bam
Under the Boo
Under the Bamboo tree
-
Dec 11th, 2001, 11:21 AM
#2
Hyperactive Member
dosen't Shell excecute work?
-
Dec 11th, 2001, 11:29 AM
#3
Thread Starter
Member
Nope it doesn't!
Shell "C:\My Documents\NewFolder"
if it were NewFolder.exe ...then yeah it would work!
Under the Bam
Under the Boo
Under the Bamboo tree
-
Dec 11th, 2001, 11:50 AM
#4
New Member
Use ShellExecute and the code
Dim lngret As Long
lngret = ShellExecute(Me.hwnd, vbNullString, _
"C:\My Documents\New Folder", vbNullString, "C:\", SW_SHOWNORMAL)
on your control
Eliza
-
Dec 11th, 2001, 12:09 PM
#5
Thread Starter
Member
Never heard of ShellExecute!
Just Shell
This works:
Reference "Microsoft Shell Controls and Automation"
Dim oFolder As Shell
Set oFolder = New Shell
oFolder.Open "C:\My Documents"
Thanks anyways
Under the Bam
Under the Boo
Under the Bamboo tree
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
|