Skip to main content
gamedev.net
🔒 Locked

VB prob again

Started by Malachi 9 replies 500+ views
Original Post
Malachi
Malachi
Hi again, Im half way creating my menu through VB but I came across an other problem. I have created a text box and I want it, so if the user clicks on the text box it will open the folder it has linked to in Windows Explorer. Does anyone know how to do ths?
TPH
TPH
From what I understand of your problem description you want to run explorer, and specify which folder to open?

Try the following:

Call Shell("explorer /c /e," & strFolder, vbNormal)

Remove the /c argument if you want the folder pane on the left side of Explorer.
Malachi
Malachi
Hey, thanks.
1.how can I make my form change the screen resolution? As I dont want the user to change it manually everytime they want to load my menu.
2.Im try to load a movie clip using this command,
Shell "C:\menu\clips\1.mpg"
But I get the error "Invalid procedure call or argument (Error 5)" How can I get this to work, do I have to add an Windows Media Player component?



Edited by - malachi on November 15, 2001 11:31:27 AM
anjee
anjee
Try the ShellExecute API instead, check planetsourcecode.com for help on your other question..
Malachi
Malachi
Where/how would I put ShellExecute API into my source?
Tszafran
Tszafran
Malachi take some time to look into it and try to solve your problems. Dont ask tons of questions like that, you are asking us to practically write your whole code.
MSN Messenger: Thomas_Szafran@hotmail.com
Malachi
Malachi
I have,Ive spent 5 days writing this menu. I came arcoss loads of probs and get them sorted, these are the ones which are bothering me. I was ment to get this done by Friday. Even the VB teachers at my college are clueless.
Malachi
Malachi
No....your not funny. But thanks anyway, yes we do have VB teachers at my college, I have no idea how my college managed to get hold of them as its so rubbish.
TPH
TPH
In VB there is an add-in called "API Viewer" that is essentially a user-interface for retrieving the majority of the API calls, constants and structures used in Windows programming. Start the add-in and load the win32api.txt file. In the declarations, look for ShellExecute, copy and paste. Simple!

For information about the API just look it up on the Microsoft MSDN.


Edited by - tph on November 16, 2001 11:26:49 AM
Malachi
Malachi
Tried it and it worked. You really helped me out alot, thank you.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.