Skip to content

General ​

Page Flow Blocks reference.

Blocks ​

" value " ​

Block name: converttotext2

Converts a value to text using the newer block shape. From the user's perspective, it behaves the same as converttotext.

Inputs ​

InputTypeDescriptionAccepts
valueobjectThe value to convert to text.

Output ​

This block produces an output value of type String.

Behavior ​

Delegates to the same text-conversion generator behavior as converttotext, producing a JavaScript string conversion of the selected value.

Action/Event Info ​

Block name: mkbevinfo

Provides the current event information object inside an event action callback.

Output ​

This block produces an output value of type Any.

Behavior ​

Generates client-side code that returns the current tvEventInfo callback parameter when available. Event handlers created by $io.dom.setEventListener populate this object before invoking the callback.

Calls: $io.dom.setEventListener

Add to List Contents of List ​

Block name: merge_array

Creates a new list by concatenating the contents of one list with the contents of another list.

Inputs ​

InputTypeDescriptionAccepts
listarrayThe first list to include in the merged result.
contents of listarrayThe second list whose items should be appended to the first list.

Output ​

This block produces an output value of type Array.

Behavior ​

Generates code that concatenates two lists using JavaScript array concat(...).

  • lists_create_with
  • lists_repeat
  • lists_split
  • lists_sort
  • math_on_list

Add to or Subtract from Date ​

Block name: dateaddsub

Adds or subtracts a quantity of time from the selected date. This block updates the connected date value in place.

Inputs ​

InputTypeDescriptionAccepts
operationchoiceWhether to add to or subtract from the date.
datedateThe date value to update. This is typically provided by a date block, but dateclone can be used first if you want to preserve the original date.date
quantitynumberThe amount of time to add or subtract. This is typically provided by a math_number block.math_number
unitschoiceThe time unit for the quantity.

Output ​

This block does not produce an output value.

Behavior ​

Generates code that updates the selected ioLoop date object in place by adding or subtracting the given quantity of time. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.add, TvWaDate.subtract

Alert Text ​

Block name: alert

Creates alert-styled content and returns it as a string value that can be inserted into page content.

Inputs ​

InputTypeDescriptionAccepts
alert typechoiceThe alert behavior.
alert colorchoiceThe visual style of the alert.
textstringThe text shown inside the alert. This is typically provided by a text block.text

Output ​

This block produces an output value of type String.

Behavior ​

Generates client-side code that builds alert-formatted content for insertion into other content blocks.

Calls: $io.content.alert

Badged Text ​

Block name: badge

Creates badge-styled content and returns it as a string value that can be inserted into page content.

Inputs ​

InputTypeDescriptionAccepts
badge shapechoiceThe visual shape of the badge.
badge colorchoiceThe visual style of the badge.
textstringThe text shown inside the badge. This is typically provided by a text block.text

Output ​

This block produces an output value of type String.

Behavior ​

Generates client-side code that builds badge-formatted content for insertion into other content blocks.

Calls: $io.content.badgedText

Boolean ( value ) ​

Block name: parse_boolean

Converts a value into a boolean using the ioLoop application's boolean parsing rules.

Inputs ​

InputTypeDescriptionAccepts
valueobjectThe value to convert to a boolean.

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates code that converts a value to boolean using the ioLoop application helper.

Calls: tvAppInstance.parseBoolean

  • logic_boolean
  • logic_negate
  • logic_compare
  • controls_if

Cloud Flow Invoke Hook ​

Block name: scr_hook_httppost

Invokes a Web Hook Cloud Flow using HTTP POST and then runs the nested success or failure statements.

Inputs ​

InputTypeDescriptionAccepts
URLstringThe Web Hook Cloud Flow URL to invoke. This is typically provided by a scr_hook_url block, which lets you click the lookup button to select from valid web hooks available in the current context.scr_hook_url
dataobjectThe data to send to the web hook. This is typically provided by a define_object block.
on successstatementsThe statements to run when the web hook call succeeds. Inside this block, httpdata provides the returned response data. Nested blocks run inside the generated callback for this block. customcode and customcodeexpr blocks inside this area can directly access the documented callback-scope variables.
on failurestatementsThe statements to run when the web hook call fails. Inside this block, httperr provides the returned error information. Nested blocks run inside the generated callback for this block. customcode and customcodeexpr blocks inside this area can directly access the documented callback-scope variables.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that invokes the selected Web Hook Cloud Flow through the ioLoop system runtime and runs the nested success or failure statements from the returned promise. The nested blocks are emitted inside function(result) { ... }; the success branch defines tvwaHttpData, and the failure branch defines tvwaHttpErr, so customcode and customcodeexpr blocks inside those branches can access the matching in-scope variables directly.

Calls: $io.system.execCloudFlowWebHook

Cloud Flow: URL of Web Hook ​

Block name: scr_hook_url

Provides the URL of a selected Web Hook Cloud Flow.

Inputs ​

InputTypeDescriptionAccepts
web hookcloud flow web hookThe Web Hook Cloud Flow to use. You can type the web hook name directly or click the lookup button to select from valid web hooks available in the current context.

Output ​

This block produces an output value of type String.

Behavior ​

Generates a string literal containing the URL of the selected Web Hook Cloud Flow.

Collapsible Area Action ​

Block name: collapsecontrol2

Expands, collapses, or toggles a collapsible area element on a page or form.

Inputs ​

InputTypeDescriptionAccepts
actionchoiceThe collapsible area action to perform.
elementelementThe id of the collapsible area element to control. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and applies the selected collapsible area action.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.ui.controlCollapsibleArea

Compare Dates ​

Block name: datecompare

Compares one date value with another date value.

Inputs ​

InputTypeDescriptionAccepts
datedateThe date value to compare. This is typically provided by a date block, but other date-producing blocks such as datefromstring can also be used.date
comparisonchoiceThe comparison to perform.
reference datedateThe date value to compare against. This is typically provided by another date block.date

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates code that compares two ioLoop date objects using the selected comparison mode. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.isBefore, TvWaDate.isSameOrBefore, TvWaDate.isAfter, TvWaDate.isSameOrAfter, TvWaDate.isSame

Complete Deferred Task ​

Block name: promiseresolve

Completes the current deferred task with a result value.

Inputs ​

InputTypeDescriptionAccepts
resultobjectThe value to return when the deferred task completes.

Output ​

This block does not produce an output value.

Behavior ​

Generates code that calls the internal Promise resolver when it is available. This is intended to be used inside the statement area of a promisecreate block, where the resolver is in scope.

Create Deferred Task ​

Block name: promisecreate

Creates a deferred task as a Promise and runs the nested statements inside that Promise.

Inputs ​

InputTypeDescriptionAccepts
dostatementsThe statements to run inside the deferred task. Use the promiseresolve block inside this area to complete the deferred task with a result. Nested blocks run inside the generated callback for this block. customcode and customcodeexpr blocks inside this area can directly access the documented callback-scope variables.

Output ​

This block produces an output value of type Promise.

Behavior ​

Generates a JavaScript Promise and runs the nested statements inside its executor function. The nested blocks are emitted inside async function(tvwa_promise_resolve, tvwa_promise_reject) { ... }; the generated body also defines resolve as an alias for tvwa_promise_resolve and reject as an alias for tvwa_promise_reject, so customcode and customcodeexpr blocks inside the deferred task can access those in-scope variables directly.

Current User ​

Block name: current_user_name

Gets the current user's name or identifier from the runtime context.

Output ​

This block produces an output value of type String.

Behavior ​

Generates code that reads the current user from the application runtime. When a webhook request context is available, that request context is passed through to the lookup.

Calls: tvAppInstance.getCurrentUser

Current User is in Group and Role ​

Block name: query_user_group

Checks whether the current user belongs to the selected group at the selected role level.

Inputs ​

InputTypeDescriptionAccepts
groupnumberThe user group to check. This is typically provided by a user_group_sel block.user_group_sel
rolenumberThe role level to check within the selected group. This is typically provided by a user_role_sel block.user_role_sel

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates code that queries group membership for the current user through the application runtime. When a webhook request context is available, that request context is passed through to the lookup.

Calls: tvAppInstance.queryGroupMembership

Data Table Action Menu Customize ​

Block name: datatablerowactionconf

Shows or hides the default New, Edit, Delete, and Refresh options in a Data Table action menu.

Inputs ​

InputTypeDescriptionAccepts
data tableelementThe id of the Data Table widget whose action menu should be customized. Use the element's HTML id attribute value. Do not use AI IDs such as ai:... or data-tvwa-ai-id; those IDs are only for modification commands. You can type the element id directly or click the lookup button to select from valid elements available in the current context.
newchoiceWhether the New action should be shown or hidden.
editchoiceWhether the Edit action should be shown or hidden.
deletechoiceWhether the Delete action should be shown or hidden.
refreshchoiceWhether the Refresh action should be shown or hidden.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the Data Table widget element and sends a customize-action-menu command with the selected visibility flags.

Calls: $io.dom.elementIdSel, $io.ui.widgetCommand

Data Table Add Action ​

Block name: datatableaddcustomaction

Adds a custom option to a Data Table action menu and runs the nested logic when the user selects it.

Inputs ​

InputTypeDescriptionAccepts
data tableelementThe id of the Data Table widget whose action menu should receive the custom option. Use the element's HTML id attribute value. Do not use AI IDs such as ai:... or data-tvwa-ai-id; those IDs are only for modification commands. You can type the element id directly or click the lookup button to select from valid elements available in the current context.
labelstringThe text shown for the custom menu option.
iconstringThe icon name or class to use for the custom menu option.
on selectionstatementsThe blocks to run when the custom menu option is selected. Use the Data Table: Table Name and Data Table: Data blocks inside these statements to access the current callback context. Nested blocks run inside the generated callback for this block. customcode and customcodeexpr blocks inside this area can directly access the documented callback-scope variables.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the Data Table widget element and sends an add-action command with a callback containing the nested statements. The nested blocks are emitted inside function(dataTableInfo, dataTableRow) { ... }, so customcode and customcodeexpr blocks inside the custom action callback can access dataTableInfo and dataTableRow directly.

Calls: $io.dom.elementIdSel, $io.ui.widgetCommand

Data Table Custom Query ​

Block name: datatablequery

Sets a custom query configuration for a Data Table widget.

Inputs ​

InputTypeDescriptionAccepts
data tableelementThe id of the Data Table widget that should use the custom query. Use the element's HTML id attribute value. Do not use AI IDs such as ai:... or data-tvwa-ai-id; those IDs are only for modification commands. You can type the element id directly or click the lookup button to select from valid elements available in the current context.
query namestringThe custom query name to use. This is typically provided by a text block.text
input paramsarrayThe input parameter list for the custom query. This is typically provided by a list block.lists_create_with
per pagenumberThe number of records to load per page. This is typically provided by a number block.math_number

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the Data Table widget element and sends a set-custom-query command with the selected query settings.

Calls: $io.dom.elementIdSel, $io.ui.widgetCommand

Data Table Refresh ​

Block name: datatablerefresh

Reloads the current page of records in a Data Table widget.

Inputs ​

InputTypeDescriptionAccepts
data tableelementThe id of the Data Table widget to refresh. Use the element's HTML id attribute value. Do not use AI IDs such as ai:... or data-tvwa-ai-id; those IDs are only for modification commands. You can type the element id directly or click the lookup button to select from valid elements available in the current context.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the Data Table widget element and sends a refresh command.

Calls: $io.dom.elementIdSel, $io.ui.widgetCommand

Date ​

Block name: date

Creates a new date value for either the current moment or the current day.

Inputs ​

InputTypeDescriptionAccepts
typechoiceWhether to create a date for the current moment or the current day.

Output ​

This block produces an output value of type TvWaDate.

Behavior ​

Generates a new ioLoop date object for either the current moment or the current day. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: tvAppInstance.dateNow, tvAppInstance.dateToday

Date from Text ​

Block name: datefromstring

Creates a date value by parsing a text string using the provided format.

Inputs ​

InputTypeDescriptionAccepts
textstringThe text to parse into a date. This is typically provided by a text block.text
formatstringThe format string used to parse the date text.

Output ​

This block produces an output value of type TvWaDate.

Behavior ​

Generates a new ioLoop date object by parsing a text value with the provided format string. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: tvAppInstance.dateFromString

Date is in a Leap Year ​

Block name: dateisleapyear

Checks whether the selected date falls within a leap year.

Inputs ​

InputTypeDescriptionAccepts
datedateThe date value to inspect. This is typically provided by a date block.date

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates code that checks whether the selected ioLoop date object falls in a leap year. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.isLeapYear

Date is in DST ​

Block name: dateisdst

Checks whether the selected date falls within daylight saving time.

Inputs ​

InputTypeDescriptionAccepts
datedateThe date value to inspect. This is typically provided by a date block.date

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates code that checks whether the selected ioLoop date object falls in daylight saving time. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.isDST

Days in Month for Date ​

Block name: datedaysinmonth

Gets the number of days in the month of the selected date value.

Inputs ​

InputTypeDescriptionAccepts
datedateThe date value whose month should be inspected. This is typically provided by a date block.date

Output ​

This block produces an output value of type Number.

Behavior ​

Generates code that reads the number of days in the month of the selected ioLoop date object. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.daysInMonth

Difference Between Dates ​

Block name: datediff

Gets the difference between two date values in the selected time unit.

Inputs ​

InputTypeDescriptionAccepts
unitschoiceThe time unit to use for the difference result.
datedateThe first date value. This is typically provided by a date block.date
reference datedateThe second date value to compare against. This is typically provided by another date block.date

Output ​

This block produces an output value of type Number.

Behavior ​

Generates code that calculates the difference between two ioLoop date objects in the selected time unit. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.diff

DOM Selector ​

Block name: domselasstring

Creates a DOM selector string that can target one or more page or form elements.

Inputs ​

InputTypeDescriptionAccepts
selectorstringThe DOM selector string to use. Standard CSS selector syntax is supported. Do not use AI IDs such as ai:...; those IDs are only for modification commands.

Output ​

This block produces an output value of type String.

Behavior ​

Generates the selector string exactly as entered. Blocks that consume this value pass it to $io.dom.domSel before calling the relevant ioLoop DOM API.

Element ​

Block name: elementidasstring

Creates an element selector string for a selected page or form element using the element's HTML id attribute value.

Inputs ​

InputTypeDescriptionAccepts
elementelementThe id of the page or form element to reference. Use the element's HTML id attribute value. Do not use AI IDs such as ai:... or data-tvwa-ai-id; those IDs are only for modification commands. You can type the element id directly or click the lookup button to select from valid elements available in the current context.

Output ​

This block produces an output value of type String.

Behavior ​

Generates a selector string for the chosen element by prefixing the element's HTML id attribute value with #. The block itself does not call an ioLoop framework method directly.

Enable/Disable Element ​

Block name: enabledisableelement2

Enables or disables an element on a page or form.

Inputs ​

InputTypeDescriptionAccepts
elementelementThe id of the element whose enabled state should be updated. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring
statebooleanThe enabled state to assign to the selected element. Use true to enable the element and false to disable it. This is typically provided by a boolean block.logic_boolean

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and sets its disabled property. The boolean input is inverted so true enables the element and false disables it.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.dom.setProp

Event Action ​

Block name: eventhandler2

Runs the nested logic when the specified event occurs for the chosen page or form element. Use the Action/Event Info block (mkbevinfo) inside the nested logic when you need information about the event that triggered the handler.

Inputs ​

InputTypeDescriptionAccepts
eventstringThe event name to listen for. This is typically provided by a text block.text
elementelementThe id of the page or form element to monitor for the specified event. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring
tasksstatementsThe blocks to run when the specified event occurs. Use the Action/Event Info block (mkbevinfo) inside these statements to access the current event information object, including the underlying DOM event details documented by the $io.dom.setEventListener client API. Nested blocks run inside the generated callback for this block. customcode and customcodeexpr blocks inside this area can directly access the documented callback-scope variables.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and registers an event listener using $io.dom.setEventListener. The nested blocks are emitted inside function(tvEventInfo) { ... }, so customcode and customcodeexpr blocks inside the handler can access tvEventInfo directly. The mkbevinfo block returns that same object.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.dom.setEventListener

Exit Function ​

Block name: function_return

Exits the current function without returning a value.

Output ​

This block does not produce an output value.

Behavior ​

Generates a plain JavaScript return; statement. This is only meaningful inside a generated function body or another context where a return statement is valid.

Exit Function and Return ​

Block name: function_return_value

Exits the current function and returns a value.

Inputs ​

InputTypeDescriptionAccepts
return valueobjectThe value to return from the current function.

Output ​

This block does not produce an output value.

Behavior ​

Generates a plain JavaScript return <value>; statement. This is only meaningful inside a generated function body or another context where a return statement is valid.

Find Pattern in Text ​

Block name: regexp_match

Finds matches for a regular expression pattern within a text value.

Inputs ​

InputTypeDescriptionAccepts
textstringThe text to search.
patternstringThe regular expression pattern to find. This is typically provided by a text block.text
optionsstringThe regular expression flags such as i or ig. This is typically provided by a text block.text

Output ​

This block produces an output value of type Array.

Behavior ​

Generates a JavaScript match(new RegExp(...)) expression for the selected text value.

Flow Start ​

Block name: flow_start

Marks the recommended starting point for a Page Flow or Cloud Flow. This block is guidance for organizing a workspace; blocks do not have to be connected below it to run.

Output ​

This block does not produce an output value.

Behavior ​

Generates no runtime operation of its own. It is a label-only starter block with a bottom connector for optional organization.

Generate JSON ​

Block name: genjson

Converts an object or other value into a JSON text string.

Inputs ​

InputTypeDescriptionAccepts
objectobjectThe value to convert into JSON text. This can be any block that returns an object or compatible value, such as define_object, emptyobject, formdataobject, data_record_object, httpdata, apicalldata, or tvexportobject.

Output ​

This block produces an output value of type String.

Behavior ​

Generates code that converts a value into a JSON string through the ioLoop system runtime.

Calls: $io.system.generateJson

Get Date Property ​

Block name: getdateprop

Gets a numeric property from a date value.

Inputs ​

InputTypeDescriptionAccepts
propertychoiceThe date property to read.
datedateThe date value to read from. This is typically provided by a date block, but other date-producing blocks such as datefromstring can also be used.date

Output ​

This block produces an output value of type Number.

Behavior ​

Generates code that reads a numeric property from the selected ioLoop date object. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.year, TvWaDate.month, TvWaDate.dayOfMonth, TvWaDate.hours, TvWaDate.minutes, TvWaDate.seconds, TvWaDate.dayOfWeek

Get Element Attribute ​

Block name: attributevalue2

Gets the value of an HTML attribute from a selected element on a page or form.

Inputs ​

InputTypeDescriptionAccepts
attributestringThe HTML attribute name to read from the selected element. This is typically provided by a text block.text
elementelementThe id of the element whose attribute value should be read. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring

Output ​

This block produces an output value of type String.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and reads the requested HTML attribute value.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.dom.getAttr

Get Element by Name ​

Block name: elementbyname

Gets a page or form element by its element name.

Inputs ​

InputTypeDescriptionAccepts
namestringThe element name to look up. This is typically provided by a text block.text

Output ​

This block produces an output value of type Any.

Behavior ​

Generates client-side code that looks up the first matching DOM element by its element name.

Calls: $io.dom.elementByName

Get Input Value ​

Block name: getinputvalue2

Gets the current value of an input, dropdown, or multi-line element on a page or form.

Inputs ​

InputTypeDescriptionAccepts
elementelementThe id of the input, dropdown, or multi-line element whose value should be read. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring

Output ​

This block produces an output value of type String.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and reads its current value.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.dom.getVal

Get Toggle Switch State ​

Block name: checkboxstate2

Gets the current checked state of a checkbox or toggle switch element on a page or form.

Inputs ​

InputTypeDescriptionAccepts
elementelementThe id of the checkbox or toggle switch element whose state should be read. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and reads its checked property.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.dom.getProp

is a Valid Number ​

Block name: checknan

Checks whether a value can be treated as a valid number.

Inputs ​

InputTypeDescriptionAccepts
valueobjectThe value to test.

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates a JavaScript isNaN check for the selected value and returns true when the value is a valid number.

Log Category ​

Block name: log_cat

Provides a predefined logging category string for use with logging blocks.

Inputs ​

InputTypeDescriptionAccepts
categorychoiceThe predefined logging category to use.

Output ​

This block produces an output value of type String.

Behavior ​

Generates the selected predefined logging category string.

Login Verify Complete (Deferred) ​

Block name: wait_for_logininfo

Returns a deferred task that completes when client-side login verification information is available. This is useful when later blocks need user or group information that may not be ready immediately during page startup.

Output ​

This block produces an output value of type Promise.

Behavior ​

Generates client-side code that calls the ioLoop system runtime to wait until authentication and login verification information is ready.

Calls: $io.system.waitForAuthInfo

Menu Index ​

Block name: menu_selected_idx

Provides the numeric index of the menu option selected by the user inside a Show Menu callback.

Output ​

This block produces an output value of type Number.

Behavior ​

Generates client-side code that returns the selected menu option index from the current Show Menu callback context when available.

Menu Text ​

Block name: menu_selected_text

Provides the text of the menu option selected by the user inside a Show Menu callback.

Output ​

This block produces an output value of type String.

Behavior ​

Generates client-side code that returns the selected menu option text from the current Show Menu callback context when available.

Move Date to Start or End Of ​

Block name: datestartendof

Moves the selected date to the start or end of the chosen time unit. This block updates the connected date value in place.

Inputs ​

InputTypeDescriptionAccepts
datedateThe date value to update. This is typically provided by a date block, but dateclone can be used first if you want to preserve the original date.date
operationchoiceWhether to move the date to the start or end of the chosen unit.
unitchoiceThe time unit to align the date to.

Output ​

This block does not produce an output value.

Behavior ​

Generates code that updates the selected ioLoop date object in place to the start or end of the chosen time unit. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.startOf, TvWaDate.endOf

Move Date to Weekday ​

Block name: dateweekday

Moves the selected date to the chosen weekday. This block updates the connected date value in place.

Inputs ​

InputTypeDescriptionAccepts
datedateThe date value to update. This is typically provided by a date block, but dateclone can be used first if you want to preserve the original date.date
weekdaychoiceThe weekday to move the date to.

Output ​

This block does not produce an output value.

Behavior ​

Generates code that updates the selected ioLoop date object in place to the chosen weekday. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.dayOfWeek

New Date from ​

Block name: dateclone

Creates a copy of an existing date value.

Inputs ​

InputTypeDescriptionAccepts
datedateThe date value to copy. This is typically provided by a date block, but other date-producing blocks such as datefromstring can also be used.date

Output ​

This block produces an output value of type TvWaDate.

Behavior ​

Generates a clone of the selected ioLoop date object. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.clone

Number ( value ) ​

Block name: converttonumber

Converts a value to a number.

Inputs ​

InputTypeDescriptionAccepts
valueobjectThe value to convert to a number.

Output ​

This block produces an output value of type Number.

Behavior ​

Generates a JavaScript number conversion using Number(...) and falls back to null when no value is connected.

Object ​

Block name: getvariablebyname

Gets a variable or object by name from the current script context.

Inputs ​

InputTypeDescriptionAccepts
namestringThe variable or object name to read.

Output ​

This block produces an output value of type Any.

Behavior ​

Generates an expression that reads a named variable from the current script scope and returns null when it is not defined.

Object from JSON ​

Block name: jsonparse

Parses a JSON text string into an object, array, or other JSON value.

Inputs ​

InputTypeDescriptionAccepts
JSONstringThe JSON text to parse. This is typically provided by a text block.text

Output ​

This block produces an output value of type Any.

Behavior ​

Generates code that parses a JSON string through the ioLoop system runtime.

Calls: $io.system.jsonParse

Replace Pattern in Text ​

Block name: regexp_replace

Replaces text that matches a regular expression pattern and returns the updated text.

Inputs ​

InputTypeDescriptionAccepts
textstringThe text to update.
patternstringThe regular expression pattern to replace. This is typically provided by a text block.text
optionsstringThe regular expression flags such as i or ig. This is typically provided by a text block.text
replacement textstringThe text to insert for each match. This is typically provided by a text block.text

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates a JavaScript replace(new RegExp(...), ...) expression for the selected text value.

Set CSS ​

Block name: setcssclass2

Adds and or removes CSS classes from a selected page or form element.

Inputs ​

InputTypeDescriptionAccepts
elementelementThe id of the page or form element whose CSS classes should be updated. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring
add classesstringSpace-separated CSS classes to add to the element. This is typically provided by a text block.text
remove classesstringSpace-separated CSS classes to remove from the element. This is typically provided by a text block.text

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and adds or removes CSS class names on it.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.dom.modClasses

Set Date Property ​

Block name: setdateprop

Sets a numeric property on a date value. This block updates the connected date value in place.

Inputs ​

InputTypeDescriptionAccepts
propertychoiceThe date property to update.
datedateThe date value to update. This is typically provided by a date block, but dateclone can be used first if you want to preserve the original date.date
valuenumberThe new numeric value for the selected property. This is typically provided by a math_number block.math_number

Output ​

This block does not produce an output value.

Behavior ​

Generates code that updates a numeric property on the selected ioLoop date object in place. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.year, TvWaDate.month, TvWaDate.dayOfMonth, TvWaDate.hours, TvWaDate.minutes, TvWaDate.seconds

Set Element Attribute ​

Block name: setattributevalue2

Sets the value of an HTML attribute on a selected element on a page or form.

Inputs ​

InputTypeDescriptionAccepts
attributestringThe HTML attribute name to set on the selected element. This is typically provided by a text block.text
elementelementThe id of the element whose attribute value should be updated. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring
valuestringThe value to assign to the selected attribute. This is typically provided by a text block.text

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and sets the requested HTML attribute value.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.dom.setAttr

Set Input Feedback ​

Block name: setinputfeedback2

Sets the validation feedback state for an input, dropdown, multi-line, checkbox, or toggle switch element on a page or form.

Inputs ​

InputTypeDescriptionAccepts
elementelementThe id of the element whose feedback state should be updated. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring
feedbackchoiceThe feedback state to apply to the selected element.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and updates its validation feedback CSS classes.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.dom.modClasses

Set Input Value ​

Block name: setinputvalue2

Sets the value of an input, dropdown, or multi-line element on a page or form.

Inputs ​

InputTypeDescriptionAccepts
elementelementThe id of the input, dropdown, or multi-line element whose value should be updated. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring
valuestringThe value to assign to the selected element. This is typically provided by a text block.text

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and sets its current value.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.dom.setVal

Set Style ​

Block name: setstyle2

Sets a CSS property on a selected page or form element.

Inputs ​

InputTypeDescriptionAccepts
propertystringThe CSS property name to set. This is typically provided by a text block.text
elementelementThe id of the page or form element whose style should be updated. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring
valuestringThe value to assign to the CSS property. This is typically provided by a text block.text

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and sets a CSS property value on it.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.dom.setCss

Set Toggle Switch State ​

Block name: setcheckboxstate2

Sets the checked state of a checkbox or toggle switch element on a page or form.

Inputs ​

InputTypeDescriptionAccepts
elementelementThe id of the checkbox or toggle switch element whose state should be updated. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring
valuebooleanThe state to assign to the selected element. Use true to check the element and false to clear it. This is typically provided by a boolean block.logic_boolean

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that resolves the target element from the connected element or DOM Selector block and sets its checked property.

Calls: $io.dom.elementIdSel, $io.dom.domSel, $io.dom.setProp

Set Value of Field Input ​

Block name: setdatafield

Sets the current value of a named form field input element.

Inputs ​

InputTypeDescriptionAccepts
field inputstringThe name of the form field input element to update. This is typically provided by a text block.text
valuestringThe value to assign to the selected form field input. This is typically provided by a text block, but other blocks that produce a compatible value can also be used.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that updates the current value of a named form field input element.

Calls: $io.form.setFieldValue

Show Menu ​

Block name: show_menu

Shows a popup menu with the provided options at the specified screen position and runs the nested logic when the user selects an option.

Inputs ​

InputTypeDescriptionAccepts
optionsarrayThe menu options to show to the user. This is typically provided by a list block.lists_create_with
X positionnumberThe horizontal position where the popup menu should appear. This can come from event information such as the current event X position.
Y positionnumberThe vertical position where the popup menu should appear. This can come from event information such as the current event Y position.
on selectionstatementsThe blocks to run when the user selects a menu option. Use the Menu Text and Menu Index blocks inside these statements to access the selected option. Nested blocks run inside the generated callback for this block. customcode and customcodeexpr blocks inside this area can directly access the documented callback-scope variables.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that shows a popup menu with the provided options and wires the nested statements into the menu selection callback. The nested blocks are emitted inside function(tvwaMenuText, tvwaMenuIndex) { ... }, so customcode and customcodeexpr blocks inside the menu selection callback can access tvwaMenuText and tvwaMenuIndex directly.

Calls: $io.ui.showMenu

Status Animation ​

Block name: spinner

Creates a visual loading or status indicator and returns it as a string value that can be inserted into page content.

Inputs ​

InputTypeDescriptionAccepts
animation typechoiceThe animation style to display.
colorchoiceThe visual style of the indicator.
sizechoiceThe size of the indicator.

Output ​

This block produces an output value of type String.

Behavior ​

Generates client-side code that builds a status or loading indicator for insertion into other content blocks.

Calls: $io.content.statusIndicator

Stop Typing Animation ​

Block name: typewriting_animation_stop

Stops the typing animation for the selected element.

Inputs ​

InputTypeDescriptionAccepts
elementelementThe id of the element whose typing animation should be stopped. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that stops the typewriter animation helper for the selected element or DOM selector.

Calls: $tvDom.stopTypeWriterAnimation

Test or Preview Mode ​

Block name: is_test_mode

Checks whether the current runtime is running in test mode or preview mode.

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates code that queries the ioLoop system runtime for the current test or preview mode state.

Calls: $io.system.isTestMode

Text Ends With ​

Block name: string_endswith

Checks whether a text value ends with another text value.

Inputs ​

InputTypeDescriptionAccepts
textstringThe text to inspect.
patternstringThe ending text to look for. This is typically provided by a text block.text

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates a JavaScript endsWith(...) expression for the selected text value.

Text from ​

Block name: converttotext

Converts a value to text.

Inputs ​

InputTypeDescriptionAccepts
valueobjectThe value to convert to text.

Output ​

This block produces an output value of type String.

Behavior ​

Generates a JavaScript string conversion using String(...) and falls back to an empty string when no value is connected.

Text from Date ​

Block name: datetostring

Formats a date value as text using the provided format string.

Inputs ​

InputTypeDescriptionAccepts
datedateThe date value to format. This is typically provided by a date block, but other date-producing blocks such as datefromstring can also be used.date
formatstringThe format string used to convert the date to text.

Output ​

This block produces an output value of type String.

Behavior ​

Generates code that formats the selected ioLoop date object as text. In JavaScript, ioLoop date values can be converted to and from Moment objects using $io.system.momentObjectFromIoLoopDate and $io.system.ioLoopDateFromMomentObject.

Calls: TvWaDate.toString2

Text Matches Pattern ​

Block name: regexp_test

Checks whether a text value matches a regular expression pattern.

Inputs ​

InputTypeDescriptionAccepts
textstringThe text to test.
patternstringThe regular expression pattern. This is typically provided by a text block.text
optionsstringThe regular expression flags such as i or ig. This is typically provided by a text block.text

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates a JavaScript RegExp(...).test(...) expression using the selected pattern and flags.

Text Starts With ​

Block name: string_startswith

Checks whether a text value starts with another text value.

Inputs ​

InputTypeDescriptionAccepts
textstringThe text to inspect.
patternstringThe starting text to look for. This is typically provided by a text block.text

Output ​

This block produces an output value of type Boolean.

Behavior ​

Generates a JavaScript startsWith(...) expression for the selected text value.

Timer ​

Block name: rearmabletimer

Runs the nested logic after the specified number of milliseconds has elapsed.

Inputs ​

InputTypeDescriptionAccepts
time amountnumberThe timer interval in milliseconds. This is typically provided by a number block.math_number
tasksstatementsThe blocks to run when the timer fires. Nested blocks run inside the generated callback for this block. customcode and customcodeexpr blocks inside this area can directly access the documented callback-scope variables.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that creates an ioLoop timer through $io.system.createTimer. The nested blocks are emitted inside function(timerObj, infoObj) { ... }, so customcode and customcodeexpr blocks inside the timer callback can access timerObj and infoObj directly.

Calls: $io.system.createTimer

Timer Repeat ​

Block name: rearmtimer

Re-arms the current timer so the timer block runs again using the same interval.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that re-arms the current timer when used inside a timer callback context.

Calls: $io.system.reArmTimer

Trigger Embed Resize ​

Block name: embed_resize

Triggers an embed resize event for the current app view.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that requests an embed resize through the ioLoop UI runtime.

Calls: $io.ui.embedResize

Typing Animation ​

Block name: typewriting_animation

Starts or resumes a typing animation for the selected element using the provided list of text values.

Inputs ​

InputTypeDescriptionAccepts
actionchoiceWhether to start a new animation or resume an existing one.
elementelementThe id of the element that should display the typing animation. This is typically provided by an Element block or a DOM Selector block. Use the Element block for a target element HTML id attribute value, or the DOM Selector block for a DOM selector string. Do not use AI IDs such as ai:... or data-tvwa-ai-id.elementidasstring, domselasstring
text listarrayThe list of text values to animate. This is typically provided by a list block.lists_create_with
optionsobjectOptional animation settings object.

Output ​

This block does not produce an output value.

Behavior ​

Generates client-side code that starts or resumes the typewriter animation helper for the selected element or DOM selector and text list.

Calls: $tvDom.startTypeWriterAnimation

URL Parameter Value ​

Block name: url_param_by_name

Gets the value of a URL query string parameter by name.

Inputs ​

InputTypeDescriptionAccepts
namestringThe query string parameter name to look up. This is typically provided by a text block.text

Output ​

This block produces an output value of type String.

Behavior ​

Generates client-side code that reads a URL query string parameter value by name.

Calls: $io.system.queryParameterValue

User Group ​

Block name: user_group_sel

Provides a predefined user group identifier.

Inputs ​

InputTypeDescriptionAccepts
groupchoiceThe predefined user group to use.

Output ​

This block produces an output value of type Number.

Behavior ​

Generates the numeric identifier of the selected predefined user group for use in shared user-membership checks.

User Role ​

Block name: user_role_sel

Provides a predefined user role level identifier.

Inputs ​

InputTypeDescriptionAccepts
rolechoiceThe predefined user role level to use.

Output ​

This block produces an output value of type Number.

Behavior ​

Generates the numeric identifier of the selected predefined user role level for use in shared user-membership checks.

Value of Field Input ​

Block name: getdatafield

Gets the current value of a named form field input element.

Inputs ​

InputTypeDescriptionAccepts
field inputstringThe name of the form field input element to read. This is typically provided by a text block.text

Output ​

This block produces an output value of type Any.

Behavior ​

Generates client-side code that reads the current value of a named form field input element.

Calls: $io.form.getFieldValue

Wait for Multiple Deferred Tasks Completion ​

Block name: promisecombine

Combines multiple deferred tasks into a single Promise using either all or any mode.

Inputs ​

InputTypeDescriptionAccepts
modechoiceHow the deferred tasks should be combined.
deferred tasksarrayThe list of Promises or deferred tasks to combine. This is typically provided by a list block containing Promise values.

Output ​

This block produces an output value of type Promise.

Behavior ​

Generates either Promise.all(...) or Promise.any(...) for the selected list of deferred tasks, depending on the chosen mode.

Wait on Deferred Task Completion ​

Block name: promiseawait

Waits for a deferred task to complete before continuing. This block emits a direct await statement, so it must be used inside an async context such as the then do area of a promisethen block.

Inputs ​

InputTypeDescriptionAccepts
deferred taskpromiseThe Promise or deferred task to wait on. This is typically provided by a promisecreate block or another block that returns a Promise.promisecreate

Output ​

This block does not produce an output value.

Behavior ​

Generates a bare JavaScript await <promise>; statement. Because it emits direct await code, it requires an async context such as the callback generated by promisethen.

Wait on Deferred Task Completion ​

Block name: promiseawaitret

Waits for a deferred task to complete and returns its resolved value. This block emits a direct await expression, so it must be used inside an async context such as the then do area of a promisethen block.

Inputs ​

InputTypeDescriptionAccepts
deferred taskpromiseThe Promise or deferred task to wait on. This is typically provided by a promisecreate block or another block that returns a Promise.promisecreate

Output ​

This block produces an output value of type Any.

Behavior ​

Generates a JavaScript (await <promise>) expression. Because it emits direct await code, it requires an async context such as the callback generated by promisethen.

Wait on Deferred Task to Complete and Then Do ​

Block name: promisethen

Waits for a deferred task to complete and then runs the nested statements. The nested then do area runs in an async function, so other deferred tasks can be awaited directly inside it.

Inputs ​

InputTypeDescriptionAccepts
deferred taskpromiseThe Promise or deferred task to wait on. This is typically provided by a promisecreate block or another block that returns a Promise.promisecreate
then dostatementsThe statements to run after the deferred task completes. Inside this area, the promiseresult block provides the resolved value of the deferred task, and other deferred tasks can be awaited directly with blocks such as promiseawait or promiseawaitret because this callback is generated as an async function. Nested blocks run inside the generated callback for this block. customcode and customcodeexpr blocks inside this area can directly access the documented callback-scope variables.

Output ​

This block does not produce an output value.

Behavior ​

Generates a Promise.resolve(...).then(async function(tvwaPromiseResult) { ... }) wrapper and runs the nested statements after the Promise resolves. The resolved value is exposed inside that callback through tvwaPromiseResult, so customcode and customcodeexpr blocks inside the completion callback can access tvwaPromiseResult directly. The async callback means nested blocks can emit direct await expressions safely.

Write Log Message ​

Block name: log_msg_str

Writes a message to the runtime log output or ioLoop cloud logs.

Inputs ​

InputTypeDescriptionAccepts
messagestringThe message to write to the log. This is typically provided by a text block.text
categorystringAn optional log category such as info, error, or warning.
levelnumberAn optional log level number.

Output ​

This block does not produce an output value.

Behavior ​

Generates code that writes the provided message, category, and level through the ioLoop system logging runtime.

Calls: $io.system.log