From WikiChip
mirc/commands/dialog
< mirc‎ | commands
Revision as of 21:37, 2 December 2013 by David (talk | contribs) (Created page with "The '''/dialog command''' is used to create a dialog using a given table. The name is what the script/you will use to refer to the table. The standard dialog created using the...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

The /dialog command is used to create a dialog using a given table. The name is what the script/you will use to refer to the table. The standard dialog created using the /dialog command can be used to create model or modeless dialogs. Modeless it does not return a value when the dialog closes. As a result it does not halt the mIRC scripting engine, letting other script to keep processing. Dialogs can be kept open for as you want.

Synopsis

/dialog -mbpardievon <name> [table]
/dialog -kcx <name>
/dilaog -g <name> <newName>
/dialog -t <name> [text]
/dialog -s <name> [x y w h]
/dialog -mbpardievonts <name> [table] [x y w h] [text]

Switches

  • Mode:
  • -m - Modeless dialog
  • -b - Size Mode: DBU
  • -p - Size Mode: Pixels
  • Modes Used with -m:
  • -a - Uses the current window as parent
  • -d - opens the dialog on the window
  • Modes Used with -d:
  • -i - Minimize dialog
  • -e - Restores dialog
  • Close:
  • -k - clicks the ok button
  • -c - clicks the cancel button
  • -x - closes the dialog without triggering any event
  • Change:
  • -t - Sets the dialog's title
  • -s - Sets the dialog's size [X Y W H]
  • -o - Sets the dialog on top of all windows
  • -n - Unset -o
  • -r - Centers the dialog
  • -v - Sets the dialog as the active window
  • -g - Renames dialog <name> <new name>

Parameters

  • <name> - Dialog Name
  • [table] - Table Name
  • [x y w h] - (x,y) coordinates, width and height
  • [text] - Text

Example

Consider:

Dialog Example1 {
  title "This is Example 1"
  size -1 -1 172 129
  option dbu
  tab "Tab A", 14, 2 0 165 123
  tab "Tab B", 15
  tab "Tab C", 16
  edit "", 17, 8 16 154 104, tab 16 multi return autohs vsbar
  menu "&File", 1
  item "&New", 6, 1
  item "&Open", 7, 1
  item break, 8, 1
  item "&Save", 9, 1
  item "Save &as", 10, 1
  menu "&Edit", 2
  item "&Copy", 11, 2
  item "P&aste", 12, 2
  menu "&view", 3
  item "&All", 13, 3
  menu "&Help", 4
  item "&About", 5, 4
}

Example 1:

;Modeless, Desktop
/dialog -md Example1 Example1

Example 2:

;Change the title of the dialog
/dialog -t Example1 This is Example 2!


Example 3:

;Rename the dialog
/dialog -g Example1 Example3

Example 4:

;Close the dialog, don't trigger any event
/dialog -x Example3

Compatibility

Added: mIRC v5.5

Added On: 08/01/1999

Note: Individual switches were not taken into consideration.

See also