Publishing control events
To trigger an event, nests a Publish
element inside a Control
element. The Event attribute identifies the action that you want to publish and the Value attribute sets the required argument for that action. For example, to cause a PushButton
control to open a new modal window, add a Publish
element inside it that specifies the SpawnDialog
event with Value
set to the name of the dialog to open, as in the following snippet:
<Control Id="ShowPopupButton" Type="PushButton" Text="Show Popup" Height="17" Width="56" X="245" Y="243" Default="yes"> <Publish Event="SpawnDialog" Value="PopupDlg" /> </Control>
You'll find that different events require different arguments in the Value
attribute. Here, Value
takes the ID of the Dialog
element you want to open. Also, only certain events can be published by certain controls. The following table lists the events that can be published and which...