mIRC Scripting

mIRC: Dialogs

Dialog is a way of creating GUI (Graphical user interface) for your script. They are used to enhance the user experience and the script’s user-friendliness.

There are two types of dialogs; a modeless dialog and a modal dialog.

Basic Dialog Command

The /dialog command allows you to create a dialog. The name is simply the name you use to reference the dialog. The table is the most important part. We will talk about it later on. This is what you actually use to design and create the dialog.

dialog -mdtsonkcvie <name> [table] [x y w h] [text]

$dialog()

This identifier is used to execute a modeled dialog. This is very helpful when you want to simply use the dialog to retrieve a few values.

%result = $dialog(name,table[,parent])

Dialog Table

The dialog table is the structure of the dialog. This is what you used to design all the objects, design where they go and how they look.

Dialog [-l] name {
  title "text"
  icon filename, index
  size x y w h
  option type
  /*
    All Your Dialog's Object Will Go In Here
    More details below
  */

}
  • -l – This switch make the table local. (Can only be accessed by other script on that file)
  • "test" - is the default text for the dialog.
  • id - is a unique number designated to only one control. The id is used as a reference number for the rest of the script.
  • x y w h - are the position in which the dialog will start up at (x,y). The w h are the width and heights of the dialog itself.
  • Option Type:

  • mIRC offers three different types of dialogs style:

  • notheme - The notheme option loads up a dialog without the windows theme (classic windows 95 style).
  • dbu – The dbu (Dialog Base Unit) is used in this option. This makes the dialog look the same on just about every computer.
  • pixels – While this is still the default option it is not recommended since it can look significantly different depending on the user’s resolution.

 

Dialog Objects

Please select from the drop list an object for more information: