Machsupport Forum

Mach Discussion => VB and the development of wizards => Topic started by: kc5qoc on June 28, 2006, 11:14:35 AM

Title: Calling a specific Wizard
Post by: kc5qoc on June 28, 2006, 11:14:35 AM
So I have this Wizard that I would like to call from a button on my new screen.

I can get to it by clicking the "Load Wizard" button and scrolling down the list, selecting it and then selecting "Run".
I am to lazy for that - I want to create a button that just calls my wizard.

What is the VB syntax for calling a specific wizard from a button ?
Title: Re: Calling a specific Wizard
Post by: Brian Barker on June 28, 2006, 02:34:29 PM
call loadwizard("Cut Arc") would open the Cut Arc wizard :)
Title: Re: Calling a specific Wizard
Post by: kc5qoc on June 28, 2006, 02:54:55 PM
Thanks Brian - we are off and running now  :)
Title: Re: Calling a specific Wizard
Post by: kc5qoc on June 29, 2006, 11:07:07 AM
I tried what you said - call LoadWizard("wizard")

I created a button called "Call Wizard" on my screen which I have added to 1024.set and saved as a new name.
The VB Script for the button is call LoadWizard("Wizard")

On initially starting up of Mach3 (1.90.x) I do the mandatory EStop reset and then select my screen and press the call wizard button - it does not work.

If I go back to the first screen and select the button "load wizard" - and load any wizard - and exit out of that wizard and then go to my screen and my button works fine. Seems like something gets initialized when the "Load Wizard" button is pressed. A call to loadwizard() without initializing that something does not work.  :(

Any ideas ? or did I stumble upon an undocumented feature  ???

Getting Closer -  :P
Title: Re: Calling a specific Wizard
Post by: Brian Barker on June 29, 2006, 01:06:04 PM
Sounds like a feature... It is off to Art :)
Title: Re: Calling a specific Wizard
Post by: ART on June 29, 2006, 01:09:52 PM
Hi:
 This has to do with the database internally is not loaded until the first load of any wizard. Ill list this for correction so the Wizards are databased on startup.
Probably take a few versions to appear though..

Thanks, sorry for the bug..

Art