Single Bracket Tokens
Empty Namespace Tokens
Token |
Description |
Enterprise Forms version |
[UID] or [USERID] |
ID of current user |
03.07.00 or later |
[USERNAME] |
Username of current user |
03.07.00 or later |
[FULLNAME] |
Full name of current user in format of "First Last" |
03.07.00 or later |
[PORTALID] |
ID of the current portal |
03.07.00 or later |
[PORTALNAME] |
Name of current portal |
03.07.00 or later |
[PORTALEMAIL] |
Email address of portal or Site admin |
03.07.00 or later |
[PORTALALIAS] |
Current alias of portal e.g. "www.website.com" |
03.07.00 or later |
[PORTALALIASWITHSCHEME] |
Current alias of portal with url protocol e.g. "http://www.website.com" |
03.07.00 or later |
[MODULEID] |
ID of current module |
03.07.00 or later |
[PAGEID] |
ID of current page or tab |
03.07.00 or later |
[PAGENAME] |
Name of current page or tab |
03.07.00 or later |
[HOSTIP] |
IP address of current user's location e.g. "123.43.242.1" |
03.07.00 or later |
[HOSTNAME] |
Host name of current user's location e.g "localhost" |
03.07.00 or later |
[USERAGENT] |
Name of the web browsers being used by current user e.g. "Internet Explorer" |
03.07.00 or later |
[FORMID] or [TEMPLATEID] |
ID of the form template |
03.07.00 or later |
[INSTANCEID] |
ID of the form instance. Only exists after the form has been submitted otherwise will return empty |
03.07.00 or later |
[HISTORYID] |
The history ID of the current form instance. Only exists after the form has been submitted |
03.07.00 or later |
[STATEID] |
ID of the current workflow state |
03.07.00 or later |
[STATENAME] |
Name of the current workflow state e.g. "Submitted" |
03.07.00 or later |
[UNIQUEID] |
A system generated ID with 36 characters e.g 4365fd29-88bf-41cf-80a2-882e43ae50e2 |
03.07.00 or later |
[OWNERID] |
ID of user originally submitted the form. Only exists after form has been submitted. |
03.07.00 or later |
[OWNERNAME] |
Name of user originally submitted the form. |
03.07.00 or later |
[OWNERFNAME] |
First name of user originally submitted the form |
03.07.00 or later |
OWNERLNAME] |
Last name of user originally submitted the form |
03.07.00 or later |
User Namespace Tokens
Token |
Description |
Enterprise Forms version |
[USER:UID] or [USER:USERID] |
ID of the current user |
03.07.00 or later |
[USER:USERNAME] |
Username of the current user |
03.07.00 or later |
[USER:FULLNAME] |
Full name of the current user. Format is "First Last" |
03.07.00 or later |
[USER:DISPLAYNAME] |
Display name of the current user |
03.07.00 or later |
[USER:FIRSTNAME] |
First name of the current user |
03.07.00 or later |
[USER:LASTNAME] |
Last name of the current user |
03.07.00 or later |
[USER:EMAIL] |
Email of the current user |
03.07.00 or later |
[USER:CREATEDDATE] |
Date and time of when user's account was created |
03.07.00 or later |
[USER:LASTLOGINDATE] |
Date and time of when user last logged on |
03.07.00 or later |
[USER:LASTACTIVITYDATE] |
Date and time of when user last accessed the portal |
03.07.00 or later |
[USER:LASTPASSWORDCHANGE] or [USER:LASTPASSWORDCHANGEDATE] |
Date and time of when password was changed |
03.07.00 or later |
[USER:LASTLOCKOUTDATE] |
Date and time of when user was locked out |
03.07.00 or later |
[USER:LOCKEDOUT] |
Indicates whether the user is currently locked out from the system |
03.07.00 or later |
[USER:profilename] |
This token provides access to custom profile properties for the current user.
Example usage:
To access a custom profile property called "Manager" a corresponding Enterprise Form User token is as [USER:Manager]
TIP: "profilename" is case-sensitive thus the exact case of the profile name must be provided otherwise an empty string is returned. Profilename "Manager" is different to "MAnager" |
03.07.00 or later |
Owner Namespace Tokens
Token |
Description |
Enterprise Forms version |
[OWNER:UID] or [OWNER:USERID] |
ID of the current user |
05.00.00 or later |
[OWNER:USERNAME] |
Username of the current user |
05.00.00 or later |
[OWNER:FULLNAME] |
Full name of the current user. Format is "First Last" |
05.00.00 or later |
[OWNER:DISPLAYNAME] |
Display name of the current user |
05.00.00 or later |
[OWNER:FIRSTNAME] |
First name of the current user |
05.00.00 or later |
[OWNER:LASTNAME] |
Last name of the current user |
05.00.00 or later |
[OWNER:EMAIL] |
Email of the current user |
05.00.00 or later |
[OWNER:CREATEDDATE] |
Date and time of when user's account was created |
05.00.00 or later |
[OWNER:LASTLOGINDATE] |
Date and time of when user last logged on |
05.00.00 or later |
[OWNER:LASTACTIVITYDATE] |
Date and time of when user last accessed the portal |
05.00.00 or later |
[OWNER:LASTPASSWORDCHANGE] or [OWNER:LASTPASSWORDCHANGEDATE] |
Date and time of when password was changed |
05.00.00 or later |
[OWNER:LASTLOCKOUTDATE] |
Date and time of when user was locked out |
05.00.00 or later |
[OWNER:LOCKEDOUT] |
Indicates whether the user is currently locked out from the system |
05.00.00 or later |
[OWNER:profilename] |
This token provides access to custom profile properties for the current user.
Example usage:
To access a custom profile property called "Manager" a corresponding Enterprise Form User token is as [USER:Manager]
TIP: "profilename" is case-sensitive thus the exact case of the profile name must be provided otherwise an empty string is returned. Profilename "Manager" is different to "MAnager" |
05.00.00 or later |
Form Namespace Tokens
Token |
Description |
Enterprise Forms version |
[FORM:fieldname] or [FORM:fieldId] |
Returns the current value of the corresponding "fieldname" or "fieldid" of the Main or Parent form.
"fieldname" is the Name property of the field element usually located in the General tab and "fieldid" is the unique Id of the field element usually located in the Custom tab of the Edit Element window.
Example usage:
[FORM:firstName] returns the value of the field element with Name = firstName
[FORM:IDed3451073e104c4fa69d57877cf10ec0] returns the value of the field element with ID = IDed3451073e104c4fa69d57877cf10ec0
TIP: If the provided fieldname or fieldid does not exists, the full token string is returned instead |
03.07.00 or later |
[CHILD:fieldname] or [CHILD:fieldId] |
Returns the current value of the corresponding "fieldname" or "fieldid" of the Child or Sub form.
"fieldname" is the Name property of the field element usually located in the General tab and "fieldid" is the unique Id of the field element usually located in the Custom tab of the Edit Element window.
Example usage:
[FORM:firstName] returns the value of the field element with Name = firstName
[FORM:IDed3451073e104c4fa69d57877cf10ec0] returns the value of the field element with ID = IDed3451073e104c4fa69d57877cf10ec0
TIP: If the provided fieldname or fieldid does not exists, the full token string is returned instead. In addition if the child form does not exists in the current state no data will be returned |
03.07.00 or later |
Querystring Namespace Tokens
Token |
Description |
Enterprise Forms version |
[QUERY:key]
|
Returns the current value of the corresponding "key" in the key/value pairs in the URL query string.
Example usage:
If the URL is http://www.website.com/default.aspx?tabid=12&fname=Joe
[QUERY:tabid] returns the value of "12" for the key "tabid"
[QUERY:fname] returns the value of "Joe" for the key "fname"
TIP: If the provided key does not exists, an empty string is returned |
03.07.00 or later |
Email Namespace Tokens
Token |
Description |
Enterprise Forms version |
[EMAIL:rolename]
|
Returns a list of emails for all the users in the specified "rolename". The list is separated by a coma.
Example usage:
[EMAIL:Registered Users] returns a list of emails of "Registered" users for the current portal.
|
04.02.01 or later |
Role Namespace Tokens
Token |
Description |
Enterprise Forms version |
[ROLE:NATIVE]
|
Returns a list of DNN System Roles for the current logged user. The list is separated by a coma.
Example usage:
[ROLE:NATIVE] returns a list of DNN System roles for the current logged on user.
|
05.00.00 or later |
[ROLE:CUSTOM] |
Returns a list of Custom Form Roles for the current logged user. The list is separated by a coma.
Example usage:
[ROLE:CUSTOM] returns a list of DNN System roles for the current logged on user.
|
05.00.00 or later |
URL Namespace Tokens
Token |
Description |
Enterprise Forms version |
[URL:CURRENT] |
Returns the full URL address of the current form that include the current form id, instance id |
04.02.02 or later |
[URL:RETURNADDRESS] |
The URL address of the referral page. |
04.02.02 or later |
[URL:PAGE#XXX] |
Returns the full URL address of the current form that include the current form id, instance id and page number (XXX).
Example usage:
[URL:PAGE#2] returns the full URL address of the form with reference to page number 2
TIP: This token is generally used for custom page navigation |
04.02.02 or later |
Double Brackets Tokens
Function Namespace Tokens
Token |
Description |
Enterprise Forms version |
||||||||||||||
[[FUNCTION:IF(expression, trueclause, falseclause)]] |
Returns the value from "trueclause" if "expression" evaluates to True otherwise returns value from "falseclause"
Example usage:
1. [[FUNCTION:IF("Hello" == "World", "Match", "Not match")]]
The above IF function returns the string "Not match" as "Hello" is not equals to "World"
2. [[FUNCTION:IF("[FORM:fname]" == "Joe", "First Name is Joe", "First Name is NOT Joe")]]
The above IF function returns "First Name is Joe" if the form token [FORM:fname] evaluates to "Joe" otherwise "First Name is NOT Joe"
TIP: It is possible to use C# string manipulation functions within the expression for advanced evaluation. Acceptable evaluation operators
|
04.00.00 or later |
||||||||||||||
[[FUNCTION:SUM(param1, param2, paramN)]] |
Returns the sum of all provided parameters. The Sum function accepts any number of parameters. Example Usage:
[[FUNCTION:IF(1, 4, "2")]] returns the value of 7
[[FUNCTION:IF("w", 2, 5, 2)]] returns the value of 9
TIP: A parameter will be ignored if can not be converted to a numeric value. |
04.00.00 or later |
||||||||||||||
[[FUNCTION:REPLACE(string, search, replace)]] |
Performs a search and replace on the provided string. The result is returned.
Example Usage:
[[FUNCTION:REPLACE("Hello World", "World", "Joe")]] returns "Hello Joe" |
04.02.02 or later |
Code Namespace Tokens
Token |
Description |
Enterprise Forms version |
||||||||||||
[[CODE:expression]] |
Evaluates the provided C# expression and returns a string from the evaluation.
Example usage:
1. [[CODE: return "Hello world"; ]]
The above code token returns the string "Hello World" when executed
2. [[CODE: return "[FORM:fname]"; ]]
The above code token returns the value from the "fname" field element
3. [[CODE:
string firstName = "[FORM:fname]"; string lastName = "[FORM:lname"];
string fullName = firstName + " " + lastName;
if (fullName.length < 10) return "Your full name is too short"; else return "Your full name is valid"; ]]
The above code function checks if the first and last name obtained from two form fields contain at least 10 characters.
Requirements:
TIP:
|
04.00.00 or later |