Programming Action Buttons in VST
-
Programming Action Buttons in VST
Posted by greg-wahl on March 22, 2018 at 1:33 pm-
?I would like to add an Action Button to a form that will include 2 actions.Ā Are the actions added to that button in modifier when I place the button on the form or do I programmatically add the actions to the button in VST?Ā
I couldn’t find where in modifier I would add them and I can’t find anything on the internet as far as adding actions to action button.
Any help would be appreciated.
——————————
Greg Wahl
Senior Database Administrator
Owensboro Municipal Utilities
Owensboro KY
—————————— -
Hi Greg
You would need to add a Button Drop List field into window control area (toolbar) of the window.
However, it probably will not get added to the ribbon as this requires some Dexterity code to move the button to the ribbon.
I will have a look to see if you can perform this step with VST.
David
——————————
David Musgrave MVP, GPUG All-StarManaging Director
Winthrop Development ConsultantsPerth, Western Australia
http://www.winthropdc.com
——————————
——————————————- -
Thanks, David.
——————————
Greg Wahl
Senior Database Administrator
Owensboro Municipal Utilities
Owensboro KY
——————————
——————————————- -
Andrew Dean
MemberMarch 23, 2018 at 3:44 PM
Hi GregEnvisage Software has developed a FREE utility called VST Controls that allows a programmer to add any Windows Control component onto any GP Form. Check out the details atĀ VST Controls – Envisage Software Solutions
I think you should be able to achieve your aim with this tool.
——————————
Andrew Dean
Envisage Software Solutions
——————————
——————————————- -
Greg
You can add an event to the form level procedure InitializeWindowRibbon.
But I am looking at the code insideĀ InitializeWindowRibbon and I am not sure if adding an after event will work as the call toĀ FinalizeRibbon of form syWebClientRibbon would have already been made.
I think some testing would be needed if you want to make this happen.
David
——————————
David Musgrave MVP, GPUG All-StarManaging Director
Winthrop Development ConsultantsPerth, Western Australia
http://www.winthropdc.com
——————————
——————————————- -
?Thanks.Ā I will take a look at that.
——————————
Greg Wahl
Senior Database Administrator
Owensboro Municipal Utilities
Owensboro KY
——————————
——————————————- -
?Thanks, Andrew.Ā I will take a look at that
——————————
Greg Wahl
Senior Database Administrator
Owensboro Municipal Utilities
Owensboro KY
——————————
——————————————- -
Greg,
It isn’t exactly what you are looking for, but with your Extender Enterprise, you can add Actions to a GP window and have them go onto the Additional menu.Ā You cannot add a button to a GP window using Extender, but you could add it to the menus if that works for you. Ā
The other option that might work is that if you are on Extender 2016 or 2018, there is an Action Type of PreScript.Ā So, you could create a button in Modifier and then potentially add the action in Extender to that button using the PreScript option.Ā The reason I say 2016 is that we added the PreScript option in one of our 2016 builds.Ā I haven’t tested this out completely, but it may work for you as well.
I am not sure what you want your actions to do, but these might be an option for you.Ā If you want to discuss further, just let me know.
Thanks,
Nicole——————————
Nicole Albertson
Product Manager
eOne Solutions
——————————
——————————————- -
The Modifier – VST path would look something like this:
Use Modifier to add the button, this adds a modified form to Forms.DIC.
DAG that dictionary, and import the DLL into your VST project.
Instantiate the modified form in your VS solution, and add whatever code you want to the .NET events.ĀIf you go this route, and you don’t want this code available to everyone, you have to include some kind of check in your .NET code to see if the user should have access to the window or not, I had a case a while back where we had to set up all that, I still have the sample code if you do want to go this route. VST is a little weird in that we’re working with our modified window, but it’s still a part of the original window so certain events can fire regardless of which window is opened.
——————————
Dan Peltier
Sr. Support Engineer
Microsoft
Fargo ND
——————————
——————————————-
greg-wahl replied 8 years, 3 months ago 1 Member · 0 Replies -
-
0 Replies
Sorry, there were no replies found.
The discussion ‘Programming Action Buttons in VST’ is closed to new replies.