Maptitude GISDK Help

TaskDialog()

Summary

Creates an enhanced version of a standard Windows MessageBox.

 

Changes

Added in Maptitude 2021. Added option Disabled Button in Maptitude 2025.

 

Syntax

ret = TaskDialog(array options)

 

Option Type Contents
Contents String Message text
Main Instruction String The headline above contents text
Buttons Array Array of strings which are button texts to use, default {"OK"}
Default Button String Which button is selected (default, the first)
Disabled Button Array An string array of buttons that should be disabled when the dialog opens up
Icon String One of standard dialog icons, "Information" (default) , "Warning", "Shield", "Error" or "None" for no icon, or a path to an icon file
Title String Text for title bar (default: "Note")
Radio List Array Array of strings to present as radio list options. By default, no radio list is displayed.
Radio Item Integer The index of the radio list item that is selected by default (default 1, the first item)
Checkbox Text String If provided, a checkbox will be displayed with this prompt
Help String A help link to launch when user presses F1 or clicks on Question mark in title bar. If not provided, no Question mark will appear in title bar
AutoSize Boolean "True" means the dialog box will resize to fit the text in Contents
Callback Macro String or Macro Block Name of macro to be run, or a macro block to run when a link is clicked. If not provided, default shell "open" action is launched

 

Returns

An options array.

 

Option Type Contents
Button String name of button clicked (one of: "Ok", "Cancel", "Yes", "No", "Retry", "Close").
Radio Item Integer 1-based index of which radio list item was selected (if radio list was provided)
Checkbox Integer 0/1 value, indicating if check box was unchecked/checked, respectively (if check box text was provided)

 

Notes

 

Example

 

opt = {{"Contents",  "This may take a long time.  \nChoose an action"},

{"Main Instruction",  "A large number of records match your criteria"},

{"Buttons" ,  {"&Ok", "&Cancel" }},

{"Default Button",   },

{"Icon",  "Warning"},

{"Title",  "Choose an option"},

{"Radio List" , {"Stop processing", "Keep processing" }},

{"Radio Item ",  2},

{"Checkbox Text", "Do not ask me again"}

}

ret = TaskDialog(opt)

 

 

See also

Function Summary
ShowMessage() Shows a message in a standard Windows message box.
MessageBox() Creates a dialog box with a message.

 

 

 

©2025 Caliper Corporation www.caliper.com