::PostMessage
This command posts a message to the message log for the wizard dialog. When the wizard dialog is closed, these messages are copied to the main application message log.
Syntax
::model::mdlWizardDlg::PostMessage msg type
Application
MotionView Tcl GUI
Description
This command posts a message to the message log for the wizard dialog. When the wizard dialog is closed, these messages are copied to the main application message log.
Inputs
- msg
- The message that is to be displayed in the message log for the wizard dialog.
- type
- The type of message being posted to the message log. It is normally either “Error”, “Warning”, or “Info”, but can be any arbitrary text.
Example
namespace eval ::my_wizard {
variable p_dlg ""
}
proc ::my_wizard::Run {} {
set mangle [::model::GetMangle my_wizard_Run]
variable p_dlg
set p_dlg [::model::mdlWizardDlg wiz$mangle -width 600 -height 400 -show_eb \
-title "My Wizard" -showExport false -callback "::my_wizard::OnClose"]
set frm [::model::mdlWizardDlg::GetButtonFrame $p_dlg]
::model::mdlWizardDlg::AddButtonToActionFrame $frm btnShow 4 "Time" ::my_wizard::OnTimeButton
::model::mdlWizardDlg::ShowDialog
}
proc ::my_wizard::OnTimeButton {} {
::model::mdlWizardDlg::PostMessage [clock format [clock seconds]] Info
}
proc ::my_wizard::OnClose { args } {
variable p_dlg
hwt::UnpostWindow $p_dlg
return 1
}
::my_wizard::Run
Errors
None.