Desktop User Guides > Professional > Interview scripting > Writing interview scripts > Creating wizards for UNICOM Intelligence Reporter > UNICOM Intelligence Reporter wizard examples > Example wizard routing
 
Example wizard routing
The following routing prepares the question based on the selected table, asks the question, then sets the format expression:
SpecifyFormatExpression[..].FormatExpression.Validation.Function = "ValidateFormatExpression"
SpecifyFormatExpression[..].FormatExpression.MustAnswer = False
For Each Table In tables_selected
SpecifyFormatExpression.QuestionFilter = Null
' Ask for a format expression for each cell item in the table
SpecifyFormatExpression.Label.Inserts["InsertTable"].Text = Table.Description
For i = 0 To Table.CellItems.Count - 1
SpecifyFormatExpression.Categories[i].Label.Inserts["ItemName"].Text = CellItem_InfoBlock["_" + CText(Table.CellItems[i].
Type)].Label
SpecifyFormatExpression[i].FormatExpression.Response = Table.CellItems[i].FormatExpression
Next
SpecifyFormatExpression.QuestionFilter = "Item1..Item" + CText(i)
SpecifyFormatExpression.Ask()
For i = 0 To Table.CellItems.Count - 1
If (SpecifyFormatExpression[i].FormatExpression <> Table.CellItems[i].FormatExpression) Then
Table.CellItems[i].FormatExpression = Trim(SpecifyFormatExpression[i].FormatExpression)
End If
Next
Next
See also
UNICOM Intelligence Reporter wizard examples