Absent Member.
Absent Member.

[archive] Tool Bar / Push Button

[Migrated content. Thread originally posted on 20 April 2004]

A push button on a tool bar is returning a different event-type than a push button off the tool bar.

I've created a tool bar and drawn a push button on it. In the event-tab of the property window I keyed in a procedure name for cmd-clicked and then edited the procedure in the event editor.

Did the same for a push button not on the tool bar.

When the button on the tool bar is clicked it returns the cmd-goto event-type. When the button off the tool bar is clicked it returns the cmd-clicked event type.

Has anyone else encountered this also.

6.1 and Windows XP
1 Reply
Absent Member.
Absent Member.

RE: [archive] Tool Bar / Push Button

hi vinsnash,
you encounter one of the most headache behavior when
programming AcuGT in GUI mode (IMHO).
It's has been a little hard to understand at the beginning, but in
the future, you'll remember it by sure.
What you have to do is define the style SELF-ACT in the
push-button of the toolbar.
You receive the cmd-goto message, because actually you're accepting another screen (probably the main form screen), while
the toolbar displays the toolbar screen.
This message mean you have to terminate the actual accept, and
you have to accept the other screen (the one who generated the
event -- you can find it in the EVENT-STATUS structure), infact the next message you receive is the cmd-clicked.

Setting the SELF-ACT, you won't have the cmd-goto message,
because of the push button is "self activated", and you have just to receive the true event.

Hope this help
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.