[RESOLVED] Programmatically Open VB Project
I have a form-based application that is still in the testing phase. As a convenience while the project is in test phase, I would like to be able to open its VB project by clicking a button on the form, instead of navigating to the directory and open the project by double-clicking its icon. (I'm lazy :))
I've added a button to the form. What code should I use to open the project?
Let me know if this does not make sense.
Thanks.
Re: Programmatically Open VB Project
Oh, it makes sense, but could we hear a bit more as to what you intend to do with that? Laziness is the mother of invention, and you are no exception, but you seem to be taking the longest, most convoluted, route to your destination that I have heard of, so I'm wondering what goal you expect to achieve.
Re: Programmatically Open VB Project
Thanks Shaggy.
Here's a scenario -- I'm running the app and I don't have the project open. I realize that I need to address a bug or make notes (in comment form about the app) about a feature I want to add or maybe change the text of a label. Instead of going to the directory where the project is and opening it there I would like to click the temporary button and open the project that way.
Thanks.
Re: Programmatically Open VB Project
Why not use a shortcut to the project file on the desktop or quick launch? Saves stripping/commenting the code out every time you need to build a new version...
Re: Programmatically Open VB Project
Process.Start() should do the trick nicely, as long as your vbproj file has the proper default application set.
Re: Programmatically Open VB Project
Thanks all for your suggestions.
Naigewron -- your solution worked. takk skal du ha