24U SimpleDialog Plug-In 2.8 Syntax

This file describes syntax of 24U SimpleDialog Plug-In's functions.
 

SDialog_Version ( { versionFormat } )
 
Returns version string of the active 24U SimpleDialog Plug-In, formatted as requested by the parameter. Use:

"short" to get just the version number
"long" to get the plug-in name followed by its version number
"platform" to get the platform of the code currently running
 

SDialog_Register ( registrationCode )
 
Attempts to unlock (register) your copy of 24U SimpleDialog Plug-In with the specified code. If the code is valid, 24U SimpleDialog Plug-In gets unlocked and stays in this state until you quit the FileMaker application, deactivate the plug-in, or the registration code expires. While unlocked, 24U SimpleDialog Plug-In is fully functional and does not bother the user with a shareware reminder.
 
Returns a non-zero result when operation is not permitted.
 

SDialog_InputDialog ( dialogPrompt { ; dialogButtons { ; dialogItems... } } )
 
Shows a custom dialog.

dialogPrompt text to be displayed as dialog prompt
dialogButtons names of dialog buttons right to left, separated by "¶"
no dialogButtons parameter => dialog has no buttons
dialogButtons = "" => auto buttons OK and Cancel
dialogItems... = dialogItem { ; dialogItems... }
dialogItem = itemOptions { { ; valueList } ; currentValue }
itemOptions = itemKind { & "¶" & itemName } { & "¶" & moreOptions }
moreOptions = optionName & "=" & optionData { & "¶" & moreOptions }
itemKind = "text" | "password" | "radio" | "checkbox" | "menu"
valueList = valueName { & "¶" & valueList }
moreOptions variants supported by SimpleDialog 2.8:
  "validation=NONE" (default)
  "validation=CREDIT_CARD"
  "validation=SSN"
  "validation=SIN"
  "validation=CZECH_ID"
  "validation=REGEXP" & "¶" & expression not containing newlines

Returns zero if successful, negative error code in the case of failure.
 

SDialog_ProgressDialog ( { dialogNumber ; } action { ; actionData... } )
 
Shows a progress bar.

dialogNumber the number of progress bar if multiple progress bars needed.
action = "open" | "close" | "value" | "newmax" | "newmin" | "text" | "subtext" | "show" | "incr" | "stop" | "update"

for "open", "show"

  actionData = { minValue ; maxValue { ; curValue } ; } { topMessage { ; bottomMessage } }
  Defaults: minValue = 0, maxValue = 100, curValue = minValue, topMessage = "", bottomMessage = ""

for "close", "stop"

  actionData = { "all" } - Closes all active progress bars.

for "value", "newmax", "newmin", "text", "subtext":

  actionData = newValue

for "update":

  actionData = { { minValue ; maxValue ; } curValue ; } { { topMessage ; } bottomMessage }
  Defaults: unspecified value remains unchanged

for "incr":

  actionData = { increment } { ; topMessage }
  Defaults: increment = 1, unspecified value remains unchanged.

Returns 0 if successful, negative error code in the case of failure.
 

SDialog_Get ( selector { ; moreData } )

SDialog_Get ( "dialog-button" )
SDialog_Get ( "dialog-value" ; itemNumber )
SDialog_Get ( "dialog-text" ; itemNumber )
SDialog_Get ( "dialog-all-values" ; valueSeparator )
SDialog_Get ( "dialog-all-text" ; valueSeparator )

For text, textarea and password items, both "text" and "value" return the same result except that empty values are omitted by "dialog-all-text" while they still appear as empty values when using "dialog-all-values".

For radio buttons and checkboxes, "text" returns name of the radio or checkbox if it is selected and empty string if it is not. "value" returns 1 for selected, 0 for unselected and 2 for mixed state.

For menu, "text" returns name of the selected menu item, "value" returns its ID, where ID is 1-based index of the item.

SDialog_Set ( selector { ; newValue } )

SDialog_Set ( "dialog-icon" ; iconSpecifier )
  iconSpecifier= iconID | iconName
  iconID= 0 | 1 | 2 | 3
  iconName= "stop" | "note" | "caution" | "question"

SDialog_Set ( "dialog-title" ; text )
SDialog_Set ( "dialog-position" ; leftPosition ; topPosition )

  "DEFAULT" can be used instead of leftPosition or topPosition

SDialog_Set ( "dialog-width" ; pixels )
SDialog_Set ( "dialog-min_width" ; pixels )
SDialog_Set ( "dialog-timeout" ; seconds )

SDialog_Set ( "progress-title" ; text )
SDialog_Set ( "progress-position" ; leftPosition ; topPosition )

  "DEFAULT" can be used instead of leftPosition or topPosition

SDialog_Set ( "clear" )

  Clear stored values from last dialog

SDialog_Set ( "reset" )

  Equal to deactivating and re-activating the plug-in