|
-
Aug 2nd, 2003, 09:10 AM
#1
Thread Starter
Member
Making an Autorun and I have some questions
Hello guys I am making an autorun for a CD but I got some questions about it, this is the situation
I am using Vb.net
There is a run program button and a Install program button, but the run program button may not be clickable if the program is not installed (it should be like greyed out) Once the program is installed the user must be able to run the program by clicking the run program button.
How would I do this?
Thanks in Advance for the answers,
Olger901
Last edited by olger901; Aug 2nd, 2003 at 10:29 AM.
-
Aug 2nd, 2003, 12:49 PM
#2
Have your installer or program (at first startup) write a registry Value to HKEY_LOCAL_MACHINE\Software\ProgramName that tells your auto run the location of the executable.
Then have your autorun program look in the registry(at the formname_Load event) for that Value if the Value is There it disables the install button if it isnt it disables the Run button
I would provide you with a code sample for this but I am new to VB .Net
Make sure you package the .Net Framework on the CD just incase because if they dont have that installed your program wont run.
Tips:
- Google is your friend! Search before posting!
- Name your thread appropriately... "I Need Help" doesn't cut it!
- Always post your code!!!! We can't read your mind!!! (well, at least most of us!)
- Allways Include the Name and Line of the Exception (if one is occuring!)
- If it is relevant state the version of Visual Studio/.Net Framwork you are using (2002/2003/2005)
If you think I was helpful, rate my post  IRC Contact: Rizon/xous ChakraNET/xous Freenode/xous
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
|