Frontend Developers Guide
DevGuide Process Platform 6.2 - Process Frontend Process.
Version: 6.2.3
Publishing date: 2016-08-19
This article is a guide for developers working with the Process Platform Frontend. It is written for third-party developers as well as in house developers that have the task of working with the system.
Contents
2.1 Resultmaker.OC.Frontend.config
3.3 Navigation buttons ("Back"/"Continue") functions
3.3.7 RM_SetHidingContinueButton
3.3.9 RM_ShowContinueButtonWeak
3.3.10 RM_ShowContinueButtonStrong
3.3.11 RM_SetDisablingBackButton
3.3.13 RM_EnableBackButtonWeak
3.3.14 RM_EnableBackButtonStrong
3.3.15 RM_SetDisablingContinueButton
3.3.16 RM_DisableContinueButton
3.3.17 RM_EnableContinueButtonWeak
3.3.18 RM_EnableContinueButtonStrong
3.3.19 RM_EnableContinueButton
3.5.1 Some examples of most used functions .
3.5.3 getdescription (obsolete)
3.5.15 RM_ActivateContinueButton
3.5.32 RM_GetShowHideObjectFromElement
3.9.1 Debug Client Script in Microsoft Visual Studio 2005
3.9.2 Debug Client Script in Internet Explorer with Microsoft Script Debugger
3.10.11 ProjectListSortRunning
3.10.12 ProjectListSortCompleted
3.10.13 ProjectListSortPending
3.10.15 ProjectListItemsPerPage
3.10.16 RM_EnableEnrichedWorkflow
4 Process Frontend User Object Documentation
6.1 Running and Completed projects
This document is a guide for developers working with the Process Platform Frontend. It is written for third-party developers as well as in house developers that have the task of working with the system.
This section describes the configuration settings in the Process Frontend file Resultmaker.OC.FrontEnd.config and the web.config
2.1 Resultmaker.OC.Frontend.config
Configuration setting name |
Description |
Example values |
|
Section: Resultmaker.OC.FrontEnd |
|||
Language |
This setting determines the Frontend user interface language for the fixed texts. |
English, Danish |
|
Culture |
This setting determines the Frontend culture, that controls the presentation of the date time and numeric elements. Available from version 6.0 |
da-DK, en-US |
|
FrontEndIdentifier |
Identifier of the FrontEnd instance (used e.g. as a comment in HTML source and in error messages). Used in scenarios with multiple load balanced Frontend. |
RM_OCFrontEnd_1 |
|
PortalWillBeClosed
|
Determines whether to present the "Portal will be closed"-message on the screen. "1" will present the messsage, "0" will omit the message. |
0, 1 |
|
PortalWillBeClosed.Text
|
The text that will be presented on screen when PortalWillBeClosed setting is set to "1". |
Portal will be closed at 20:15.
|
|
PortalNowClosed
|
Determines whether to present the "Portal now closed"-message on the screen. "1" will present the messsage, "0" will omit the message. |
0, 1 |
|
PortalNowClosed.Text
|
The text that will be presented on screen when PortalNowClosed setting is set to "1". |
Portal is closed until 22:00. |
|
RequireHTTPS
|
Specifies whether or not the Frontend will redirect to HTTPS when the protocol is HTTP. "1" will force the redirect to HTTPS. "0" will not redirect. |
0 or 1 |
|
RequireDomain
|
Specifies the domain that the Frontend will run on. If the domain is not as specified the Frontend will redirect to the specified domain. The domain is specified as "www.mydomain.com" without protocol. |
||
SecurityDomain
|
Specifies top level domain that the Frontend, Data Selector, FileStore and other custom application extensions must use in order to be able to make cross-window JavaScript communication. The domain is specified as "mydomain.com". |
Resultmaker.com |
|
ServerTransport
|
Specifies whether to use the HTTP or HTTPS transport protocol when the Frontend communicates with the Backend. |
http, https |
|
Server
|
Specifies the network name of the Backend server. |
localhost |
|
ServerPort
|
Specifies the HTTP port to use when the Frontend communicates with the Backend. |
80
|
|
ServerResource
|
Specifies the relative path to the aspx file on the Backend server. The default location is "/oc4/process.aspx". |
/oc4/Process.aspx
|
|
ServerWebService
|
Specifies the relative path to the Backend web service. The default location is "/oc4/OC.asmx". |
/oc4/OC.asmx
|
|
DynamicDropDownWebService
|
Specifies the relative path to the Backend web service, that exposes Dynamic Dropdown collections. The default location is "/oc4/admin/transfer.asmx". Available from version 6.0 |
/oc4/admin/transfer.asmx
|
|
ServerConfigurationWebService
|
ServerConfigurationWebService: Specifies the relative path to the Backend web service, that exposes selected central configuration. The default location is "/oc4/accessconfiguration/accessconfiguration.asmx". -->
|
/oc4/accessconfiguration/accessconfiguration.asmx
|
|
ServerSecurityWebService
|
Specifies the relative path to the Backend web service, that exposes the Process Platform security api. The default location is "/oc4/Admin/Security.asmx". |
/oc4/admin/security.asmx
|
|
ServerUsersWebService
|
Specifies the relative path to the Backend web service, that exposes the Process Platform user api. The default location is "/oc4/Users.asmx". |
/oc4/Users.asmx
|
|
ServerPendingWebService
|
Specifies the relative path to the Backend web service, that exposes the Process Platform Pending list api.
This functionality is deprecated in version 6.0. |
|
|
ServerUseDelegationForRequests
|
Determines whether the Frontend should use delegation of windows credentials for the Backend calls.
This requires that the Process Engine IIS application is setup with Windows Authentication. And is also required to be set to True if the Process Engine IIS application is setup to Windows Authentication.
The delegated credentials can either be the account running the Frontend IIS application or the windows credentials of the end user logged.
This is determined in the config setting ServerUseImpersonationForRequests.
Allowed values are false and true.
See also the config setting LoginInformationProvider.
Available from version 6.0 |
true,false |
|
ServerUseImpersonationForRequests |
Determines whether the Frontend should impersonate calls to the Process Engine with the Windows credentials of the logged on user or not to impersonate.
Allowed values are false and true.
If true, it is required that the Process Engine IIS application is setup with Windows Authentication. See the config setting ServerUseDelegationForRequests.
If false, it is required that the Frontend is configured with a LoginInformationProvider and a corresponding configure SecurityProvider in the Process Ending. See the config setting LoginInformationProvider.
Available from version 6.0 |
true, false |
|
DataSelectorURL
|
Relative path including server name to the Data Selector web page. |
localhost/RMFrontEnd/DataSelector
|
|
FileStoreURL
|
Relative path including server name to the File Store web page. |
localhost/RMFrontEnd/FileStore/UploadFile.aspx |
|
ExportServerURL
|
Full http path to the Export Server web service. |
http://localhost/exportserver/export.asmx |
|
StreamerURL
|
Relative path including server name to the File Streamer web page. |
/RMFrontEnd/Layouts/Streamer.aspx
|
|
SubmitSignDataServiceURL |
Full http path to the Signing web service. |
http://localhost/BlueBox/Transactions_30.asmx |
|
TicketServiceURL
|
Full http path to the Signing web service. |
http://localhost/tokenservice/tokenservice.asmx |
|
ProjectTypeFilter
|
Specifies the filter value to apply when rendering the project list for New projects. The filtering of the ProjectTypeFilter happens on the basis of the Category selected on the workflow at design time. Default is empty and it means no filtering. |
|
|
DefaultProjectListType
|
Specifies what type of project list to present if not selected explicitly by the user. "N" ("New"), "R" ("Running"), "C" ("Completed") |
N,R,C |
|
ProjectListSortNew
|
Specifies how to sort the project list for new projects/workflows. Sorting by multiple columns is possible by comma separation of the columns and descenting sorting is possible. Example: "CreatedDate desc,ProjectText desc, Authority desc" |
ProjectText,Authority
|
|
ProjectListSortRunning
|
Specifies how to sort the project list for started/running projects/workflows. Sorting by multiple columns is possible by comma separation of the columns and descenting sorting is possible. Example: "CreatedDate desc,ProjectText,Authority" |
CreatedDate desc,ProjectText,Authority
|
|
ProjectListSortCompleted
|
Specifies how to sort the project list for finished projects/workflows. Sorting by multiple columns is possible by comma separation of the columns and descenting sorting is possible. Example: "CreatedDate desc,ProjectText,Authority" |
CreatedDate desc,ProjectText,Authority
|
|
ProjectListSortPending
|
Specifies how to sort the project list for pending projects/workflows. Sorting by multiple columns is possible by comma separation of the columns and descenting sorting is possible. Example: "DateBegin desc,Subject.
This configuration element is no longer used as Pending List is deprecated in version 6.0. |
DateBegin desc,Subject
|
|
ProjectListItemsPerPage
|
Specifies how many projects/workflows to display per page on the project list pages. |
500
|
|
LayoutsPathForServer
|
Specifies the relative path to the Layouts folder for the server site logic. |
/RMFrontEnd/Layouts
|
|
LayoutsPathForClient
|
Specifies the relative path to the Layouts folder for the client site logic. |
/RMFrontEnd/Layouts
|
|
PresentationFolderName
|
Specifies the relative path to the Presentation folder. |
Presentation
|
|
SkinName
|
Specifies the path to the skin folder, which is located beneath the Presentation folder. |
Default
|
|
XsltFolderName
|
Specifies the path to the Xslt folder, which is located beneath the folder specified in SkinName. |
Xslt
|
|
CssFolderName
|
Specifies the path to the CSS folder, which is located beneath the folder specified in SkinName. |
Css
|
|
ImagesFolderName
|
Specifies the path to the Image folder, which is located beneath the folder specified in SkinName. |
Images
|
|
ProjectListTemplatesFolderName
|
Specifies the path to the ProjectListTemplates folder, which is located beneath the folder specified in SkinName. Empty value blocks the Project List with a message to the user. |
ProjectListTemplates
|
|
RenderCssLinks
|
To be described.
|
0 or 1 |
|
TranslationsPath
|
Specifies the relative path to the folder containing files with translation text for presentation. |
/RMFrontEnd/Layouts/Presentation/Translations
|
|
JSPath
|
Specifies the relative path to the folder containing the core Java Script files. |
/RMFrontEnd/Layouts/Core/JavaScript
|
|
AppletPath
|
Specifies the relative path to the folder containing the signing and login applet files. |
/RMFrontEnd/Layouts/Core/Applets
|
|
AllowEnrichedWorkflow
|
Specifies whether it is possible to show the enriched workflow menu. Deprecated functionality. |
0 or 1 |
|
EnableEnrichedWorkflow
|
Specifies whether to show the enriched workflow menu or not. Requires AllowEnrichedWorkflow to be set to 1. Deprecated functionality. |
0 or 1 |
|
WorkflowOnLeft
|
Specifies whether to show the workflow menu to the left of to the right. 1 is left and 0 is right. |
0 or 1 |
|
SessionRefreshURL
|
Specifies the relative url to the web page that can refresh the session. To disable "session refresh" functionality, provide an empty value or remove the line.
|
Layouts/SessionRefresh.aspx
|
|
SessionRefreshOnClientActivity
|
Specifies whether client activity will refresh the session timeout period. Valid values are 1 and 0. |
0 or 1 |
|
SessionExpirationWarningFactor
|
Specifies the factor to multiply to the session timeout to get the time to displays a warning about session timeout. 0 Disables the warning.
|
0 or some decimal value between 0 and 1 specified with . as decimal separator i.e. 0.75 |
|
SessionExpiredDisplayAlert
|
Specifies whether to present the session expired message to the user. |
0 or 1 |
|
LoginInformationProvider
|
Specifies the provider to use for login handling. Supported types are: Resultmaker.OC.FrontEnd.Login.LoginInformationProvider, Resultmaker.OC.FrontEnd.Login: User name/password and certificate login. Resultmaker.OC.FrontEnd.HttpContextUser.LoginInformationProvider, Resultmaker.OC.FrontEnd.HttpContextUser: Simple Windows Authentication in the Frontend. Converts the Windows Authentication logon to a Backend logon and does not use delegation between Fronend and Backend. Requires Windows Authentication to be enabled and Anonymous Access to be disabled in the Frontend application in IIS. Resultmaker.OC.FrontEnd.HttpContextUser.LoginInformationWithTokenProvider, Resultmaker.OC.FrontEnd.HttpContextUser: Windows Authentication in the Frontend. Uses delegation to pass on the logon to the Backend logon. Requires Windows Authentication to be enabled and Anonymous Access to be disabled in the Frontend application in IIS and in the Backend application in the IIS. Requires that the ServerUseDelegationForRequests is set to true. |
Resultmaker.OC.FrontEnd.Login.LoginInformationProvider, Resultmaker.OC.FrontEnd.Login
|
|
ProjectStartPermissionProvider |
Deprecated |
|
|
SignPermissionProvider |
Deprecated, should always be set to Resultmaker.OC.FrontEnd.AlwaysAllowSignPermissionProvider, Resultmaker.OC.FrontEnd Allowed values: Resultmaker.OC.FrontEnd.CnnSign.SignPermissionProvider, Resultmaker.OC.FrontEnd.CnnSign and Resultmaker.OC.FrontEnd.AlwaysAllowSignPermissionProvider, Resultmaker.OC.FrontEnd |
Resultmaker.OC.FrontEnd.CnnSign.SignPermissionProvider, Resultmaker.OC.FrontEnd.CnnSign
|
|
SatelliteManager
|
Controls the session sharing between Fronend and satelite applications like File Store client and Data Selector. The value specifies which class to load for session handling. Should always be set to Resultmaker.OC.SatelliteManager.SharedSessionSatelliteManager, Resultmaker.OC.SatelliteManager |
Resultmaker.OC.SatelliteManager.SharedSessionSatelliteManager, Resultmaker.OC.SatelliteManager
|
|
Plugins.InfoPathForm
|
Controls the InfoPath integration. The value specifies which class to load for this. Should always be set to Resultmaker.OC.FrontEnd.Plugins.InfoPath.InfoPathForm, Resultmaker.OC.FrontEnd.Plugins.InfoPath. |
Resultmaker.OC.FrontEnd.Plugins.InfoPath.InfoPathForm, Resultmaker.OC.FrontEnd.Plugins.InfoPath
|
|
ErrorLogPath
|
Specifies a folder path on disk, where internal Frontend logs are written. The folder must exist in order for logs to be created. |
c:\Logs\OCErrors
|
|
HelpServer
|
Specifies a folder path on disk, where internal Frontend logs are written. The folder must exist in order for logs to be created. |
/static/rm/documents
|
|
HelpFileExt
|
Specifies the extension for the help files. |
.htm
|
|
DecimalSymbol |
To be described |
, |
|
DateFormat |
To be described |
dd-mm-yyyy |
|
JavaScriptDebug
|
Enables a mode, where the Process Consultant is notified about recommandations for form design. |
0 or 1 |
|
MainPageURL
|
URL that links from the project/workflow list page to some specified page. If empty the link is not shown. |
|
|
MainPageText
|
Text for the URL that links from the project/workflow list page to some specified page. If empty the link and text is not shown. -->
|
|
|
DefaultProjectExitLinkTarget
|
Target browser frame for the link from the workflow page to the project/workflow list page. If empty no Target is used. |
|
|
DefaultProjectExitLinkURL
|
URL link from the workflow page to the project/workflow list page. Standard value is the javascript function "javascript:RM_GoBackToProjectList();". |
"javascript:RM_GoBackToProjectList();
|
|
DefaultProjectExitLinkText
|
Text for the link from the workflow page to the project/workflow list page. If no value is specified the default value from the Translations file is being used. |
|
|
LoginPath
|
The relative path to the login page. If empty the link to the default login page is being used. The standard value is empty. |
|
|
LogoutPath
|
The relative path to the logout page. The standard value is "Layouts/LogOut.aspx". |
Layouts/LogOut.aspx
|
|
AfterLogInRedirURL
|
Url to redirect to after login (must be relative to "LoginPath", or absolute). |
|
|
AfterLogOutRedirURL
|
Url to redirect to after logout (must be relative to "LogoutPath", or absolute). |
../?ShowLogin=1
|
|
NoCache
|
Specifies whether to enable or disable the browser caching. Setting the NoCache to 1 is recommended. |
0 or 1 |
|
ServerType
|
The server type. Used for TDC signing applet. Valid values are Test or Production. |
Test, Production |
|
SignWithLoginCertificate
|
Specifies if the Signing applet will present only the certificate used for login. Valid values are 1 and 0. |
0 or 1 |
|
SignCheckEnabled |
Deprecated |
0 or 1 |
|
SuperSensitiveSignCheckEnabled |
Deprecated. |
0 or 1 |
|
ThrowExceptions
|
If set to 0, exceptions are caught and presented in a nice and end user friendly format. If set to 1, normal yellow .NET exceptions are thrown. They can be used by load testing tools to validate application health. |
0 or 1 |
|
HiddenValuesInSession
|
Stores session values in the ASP.NET session or in hidden post fields. If set to 0, session values are stored in hidden post fields. If set to 1, session values are stored in the ASP.NET session. This makes it easier to use load testing tools. -->
|
0 or 1 |
|
CacheMinutesForDropDownWebService
|
The time span in which the look ups in the Dynamic Dropdown web service are cached in the Frontend. Note the unit of this cache is in minutes. |
60 |
|
IsRequireLoggedout |
Determines whether to present a logout link or not. |
1 or 0 |
|
ErrorMessageDisplayMode |
There are three ways to present error messages in the Resultmaker Process Frontend application. Each one presents different amounts of information. The value is case sensitive. |
minimal: In this mode the minimal amount of error information is displayed to the user. Only the custom error message is displayed.
hidden: This displays the normal custom errors message and by pressing CTRL+SHIFT and clicking on the custom errors message, the usual error details will be displayed.
detail: This is display both custom error and detail error to the frontend where an error is occurred.
|
|
RequireAuthenticationMode |
Specifies the Authentication Mode |
Windows, Forms |
|
Section: Resultmaker.OC.EntityFrontEnd |
|||
EntityConnectionString |
|
|
|
EntityIdQueryStringKey |
|
EntityID |
|
EnableEntitySessionCaching |
|
0 or 1 |
|
ProjectTypeFilterByEntityID |
|
0 or 1 |
|
ShowHeader |
|
0 or 1 |
|
EnablePrefill |
|
0 or 1 |
|
EnableSigning |
|
0 or 1 |
|
The web.config contains a few configuration parameters. They are documented here.
<appSettings> <add key="RM_SecurityDomain" value="pptest60" /> <add key="RM_SharedSessionPersister" value="Resultmaker.Web.SharedSessionState.InProcessSharedSessionPersister, Resultmaker.Web.SharedSessionState,Version=6.0.0000.0, Culture=neutral, PublicKeyToken=e135b4d1c4e6af7d" /> <add key="RM_OCFrontEnd.ascx" value="Layouts/FullHosting.ascx" /> </appSettings>
….
<system.serviceModel> <bindings> <webHttpBinding> <binding name="BasicpointBinding"> <security mode="TransportCredentialOnly"> <transport clientCredentialType="Windows" /> </security> </binding> </webHttpBinding> </bindings> <behaviors> <endpointBehaviors> <behavior name="RMFrontEnd.RmAjaxControlsWebServiceAspNetAjaxBehavior"> <enableWebScript /> </behavior> </endpointBehaviors> <serviceBehaviors> <behavior name="metadataAndDebug"> <serviceMetadata httpGetEnabled="true" httpGetUrl=""/> <serviceDebug httpHelpPageEnabled="true" includeExceptionDetailInFaults="true" /> </behavior> </serviceBehaviors> </behaviors> <serviceHostingEnvironment aspNetCompatibilityEnabled="true" /> <services> <service name="RMFrontEnd.RmAjaxControlsWebService" behaviorConfiguration="metadataAndDebug"> <endpoint address="" behaviorConfiguration="RMFrontEnd.RmAjaxControlsWebServiceAspNetAjaxBehavior" binding="webHttpBinding" bindingConfiguration="BasicpointBinding" contract="RMFrontEnd.RmAjaxControlsWebService"> <identity> <dns value="localhost" /> </identity> </endpoint> </service> </services> </system.serviceModel> |
Configuration setting name |
Description |
Example values |
Section: system.serviceModel |
||
Security mode |
This WCF configuration for the Ajax web service for the dynamic dropdowns needs to be configured for the http protocol you are running on the server. For HTTP you need to set the following security mode for the binding: <security mode="TransportCredentialOnly"> For HTTPS you need to set the following security mode for the binding: <security mode="Transport">
|
TransportCredentialOnly, Transport |
Configuration setting name |
Description |
Example values |
RM_SatelliteManager |
The type name to load for sharing session between the Data Selector and the Frontend. |
Resultmaker.OC.SatelliteManager.SharedSessionSatelliteManager, Resultmaker.OC.SatelliteManager |
RM_SubmitterDebug |
Boolean value that determines whether to show the iframe and pop an alert with the data to be send back to the Frontend form. Useful for debugging. |
1 or 0 |
applicationBaseLocation |
\\127.0.0.1\private\DataSelectorApplications |
|
themeBaseUrl |
Relative web url to the Data Selector themes. |
/public/DataSelectorThemes |
By using the “IFRAME” or “FRAMESET” HTML tags, the main HTML document may contain the frames with their own HTML documents inside.
To enable an inter‑frame communication with the use of JavaScript calls, FrontEnd sets the security domain of the main HTML document (document.domain property in JavaScript) to the shortest possible domain (defined in “SecurityDomain” config setting since v.2.11). E.g. for single‑word domain “MyServer” (usually used inside the intranet) the security domain is set to “MyServer”; for longer names like “MyServer.MyDomain.MyCompany.com” the security domain contains only two last words, i.e. “MyCompany.com” in this example.
In FrontEnd v2.10.0.0 and earlier, this is done only if the main document contains an IFRAME with either codepicker or file store.
In FrontEnd v2.10.0.1 and later, this is done on every page, to enable an inter‑frame communication with any custom HTML document in the frame, and to enable the reliable session timeout handling (refreshing the session, timeout warning etc.).
In every HTML document in the frame that pretends to communicate with the main document it is necessary to set explicitly the security domain to exactly the same value as the main document does. Even if the default security domain is already correct, it is necessary anyway to set it explicitly to this value. Both codepicker and file store do that. In any custom HTML document it is necessary to do the same. For security reasons it is a good practice to set the security domain to the value determined on the server, and not on the client. For details see any available documentation of document.domain property.
3.2.2.1 IsHidden
Property: RM_ShowHide.IsHidden
FrontEnd Version: 1.6
Description:
Example:
3.2.3.1 AddElementById
Method: RM_ShowHide.AddElementById()
FrontEnd Version: 1.6
Description: Adds a layout ID to the internal collection of RM_ShowHide object.
Example: SHobj = GetShowHideObject();
SHobj.AddElementById(“row_1”);
3.2.3.2 RemoveElementById
Method: RM_ShowHide.RemoveElementById()
FrontEnd Version: 1.6
Description: Remove a layout ID from the internal collection of RM_ShowHide object.
Example:
3.2.3.3 AddElementByQuestionName
Method: RM_ShowHide.AddElementByQuestionName()
FrontEnd Version: 1.6
Description: Adds a question element and all its answers to the internal collection of RM_ShowHide object.
Example: objShow.AddElementByQuestionName("MyRadio");
3.2.3.4 RemoveElementByQuestionName
Method: RM_ShowHide.RemoveElementQuestionName()
FrontEnd Version: 1.6
Description: Removes a question element and all its answers from the internal collection of RM_ShowHide object.
Example: objShow.RemoveElementByQuestionName("MyRadio");
3.2.3.5 AddElementByAnswerName
Method: RM_ShowHide.AddElementByAnswerName (strQuestion, strAnswer)
FrontEnd Version: 2.5
Description: Adds a single answer (specified by question name and answer name) to the internal collection of RM_ShowHide object.
Example: objShow.AddElementByAnswerName("MyRadio", "Option0");
3.2.3.6 RemoveElementByAnswerName
Method: RM_ShowHide.RemoveElementByAnswerName (strQuestion, strAnswer)
FrontEnd Version: 2.5
Description: Removes a single answer (specified by question name and answer name) from the internal collection of RM_ShowHide object.
Example: objShow.RemoveElementByAnswerName("MyRadio", "Option0");
3.2.3.7 Hide
Method: RM_ShowHide.Hide()
FrontEnd Version: 1.6
*Description: Hides all elements in an internal collection of RM_ShowHide object.
*Example: SHobj = GetShowHideObject();
SHobj.AddElementById(“row_1”);
SHobj.Hide();
3.2.3.8 Show
Method: RM_ShowHide.Show()
FrontEnd Version: 1.6
*Description: Show all elements in an internal collection of RM_ShowHide object.
*Example: SHobj = GetShowHideObject();
SHobj.AddElementById(“row_1”);
SHobj.Show();
3.2.3.9 ClearElements
Method: RM_ShowHide.ClearElements()
FrontEnd Version: 1.6
*Description: Clear all fields in an internal collection of RM_ShowHide object.
*Example: SHobj = GetShowHideObject();
SHobj = AddElementByQuestionName(“TekstField0”);
SHobj.ClearElements();
3.2.3.10 RequiredSet
Method: RM_ShowHide.RequiredSet (bRequired)
FrontEnd Version: 2.5
Description: For
bRequired = {true}: marks all included elements as “required” (“*” is
added and validation is affected respectively).
For bRequired = {false}: marks all included elements as “not required”
(“*” is removed and validation is affected respectively).
Does not affect the elements with “Required” property set to “Required”.
Due to RequiredOn() and RequiredOff() methods this method may be
considered as redundant, but in some cases its usage may simplify the
conditions in code.
Example: objShow.RequiredSet(true);
3.2.3.11 RequiredOn
Method: RM_ShowHide.RequiredOn()
FrontEnd Version: 2.5
Description: Marks all included elements as “required” (“*” is added and validation is affected respectively). Does not affect the elements with “Required” property set to “Required”.
Example: objShow.RequiredOn();
3.2.3.12 RequiredOff
Method: RM_ShowHide.RequiredOff()
FrontEnd Version: 2.5
Description: Marks all included elements as “not required” (“*” is removed and validation is affected respectively). Does not affect the elements with “Required” property set to “Required”.
Example: objShow.RequiredOff();
3.2.4.1 Safe Mode
FrontEnd Version: 1.6
*Description: When safe mode is on RM_ShowHide.Hide() will not hide the object, if any fields in the internal collection contains data. Default is off.
Methods: SafeModeOn(), SafeModeOff()
*Example: SHobj = GetShowHideObject();
SHobj = AddElementByQuestionName(“TekstField0”);
SHobj.SafeModeOn();
SHobj.Hide(); //only hide if empty
SHobj.SafeModeOff();
3.2.4.2 Clear Mode
FrontEnd Version: 1.6
*Description: Clears all fields in an internal collection of RM_ShowHide object, next time the object is set to hidden. Default is off.
Methods: ClearModeOn(),ClearModeOff()
*Example: SHobj = GetShowHideObject();
SHobj = AddElementByQuestionName(“TekstField0”);
SHobj.ClearModeOn();
SHobj.Hide(); //hide and clear value
3.2.4.3 Hide Modes
Hide Mode |
Method |
Description |
Version |
Collapse (removes completely from page) |
SetToCollapse() |
|
1.6 |
Hide (vanishes though leaves a placeholder) |
SetToHide() |
|
1.6 |
Disabled (get greyed out is unable to be edited) |
SetToDisabled() |
|
1.6 |
Read Only |
SetToReadOnly() |
|
1.6 |
*Example: SHobj = GetShowHideObject();
SHobj.AddElementByQuestionName(“TekstField0”);
SHobj. SetToDisabled();
SHobj.Hide(); //gray out the field
Recommended way to turn on/off the different modes
SomeObject.SafeModeOn();
SomeObject.Hide();
SomeObject.SafeModeOff();
SomeObject.ClearModeOn();
Navigating away and to the page will not cause any information to be deleted.
Information will only be deleted when the user activates some hide mechanism like pushing a button.
3.3 Navigation buttons ("Back"/"Continue") functions
Function: RM_RenameBackButton(caption text)
FrontEnd Version: 2.11
Description: Defines the custom text as a caption for the "Back" button.
Returns: none
Arguments:
Name |
Optional |
Description |
caption text |
No |
The text to use |
Example:
RM_RenameBackButton("Previous page");
Function: RM_RenameContinueButton(caption text)
FrontEnd Version: 2.11
Description: Defines the custom text as a caption for the "Continue" button.
Returns: none
Arguments:
Name |
Optional |
Description |
caption text |
No |
The text to use |
Example:
RM_RenameContinueButton("Next page");
Function: RM_SetHidingBackButton(hide)
FrontEnd Version: 2.11.1
Description: For hide = {true} it arbitrarily hides the "Back" button; for hide = {false} it arbitrarily shows the "Back" button; for hide = {null} it reverts the arbitrary hiding/showing‑related changes that any functions introduced to the "Back" button.
Returns: none
Arguments:
Name |
Optional |
Description |
hide |
Yes |
Null, or Boolean value that indicates whether to hide or show the "Back" button. |
Example:
RM_SetHidingBackButton(true);
Function: RM_HideBackButton()
FrontEnd Version: 2.11.1
Description: Arbitrarily hides the "Back" button.
Returns: none
Arguments: none
Example:
RM_HideBackButton();
Function: RM_ShowBackButtonWeak([Id])
FrontEnd Version: 2.11.1
Description: Tries to show the "Back" button by releasing the hiding lock identified by the Id (if supplied), and by reverting the arbitrary hiding. After that the button may remain hidden if there are any other conditions keeping it hidden.
Returns: none
Arguments:
Name |
Optional |
Description |
allowingId |
Yes |
Id of the hiding lock. |
Example:
RM_ShowBackButtonWeak();
RM_ShowBackButtonWeak("MyElemennt_id");
Function: RM_ShowBackButtonStrong()
FrontEnd Version: 2.11.1
Description: Arbitrarily shows the "Back" button.
Returns: none
Arguments: none
Example:
RM_ShowBackButtonStrong();
3.3.7 RM_SetHidingContinueButton
Function: RM_SetHidingContinueButton(hide)
FrontEnd Version: 2.11.1
Description: For hide = {true} it arbitrarily hides the "Continue" button; for hide = {false} it arbitrarily shows the "Continue" button; for hide = {null} it reverts the arbitrary hiding/showing‑related changes that any functions introduced to the "Continue" button.
Returns: none
Arguments:
Name |
Optional |
Description |
hide |
Yes |
Null, or Boolean value that indicates whether to hide or show the "Continue" button. |
Example:
RM_SetHidingContinueButton(true);
Function: RM_HideContinueButton()
FrontEnd Version:2.11.1
Description: Arbitrarily hides the "Continue" button.
Returns: none
Arguments: none
Example:
RM_HideContinueButton();
3.3.9 RM_ShowContinueButtonWeak
Function: RM_ShowContinueButtonWeak([Id])
FrontEnd Version: 2.11.1
Description: Tries to show the "Continue" button by releasing the hiding lock identified by the Id (if supplied), and by reverting the arbitrary hiding. After that the button may remain hidden if there are any other conditions keeping it hidden.
Returns: none
Arguments:
Name |
Optional |
Description |
allowingId |
Yes |
Id of the hiding lock. |
Example:
RM_ShowContinueButtonWeak();
RM_ShowContinueButtonWeak("MyElemennt_id");
3.3.10 RM_ShowContinueButtonStrong
Function: RM_ShowContinueButtonStrong()
FrontEnd Version: 2.11.1
Description: Arbitrarily shows the "Continue" button.
Returns: none
Arguments: none
Example:
RM_ShowContinueButtonStrong();
3.3.11 RM_SetDisablingBackButton
Function: RM_SetDisablingBackButton(disable)
FrontEnd Version: 2.11.1
Description: For disable = {true} it arbitrarily disables the "Back" button; for disable = {false} it arbitrarily enables the "Back" button; for disable = {null} it reverts the arbitrary disabling/enabling‑related changes that any functions introduced to the "Back" button.
Returns: none
Arguments:
Name |
Optional |
Description |
disable |
Yes |
Null, or Boolean value that indicates whether to disable or enable the "Back" button. |
Example:
RM_SetDisablingBackButton(true);
Function: RM_DisableBackButton()
FrontEnd Version: 2.11.1
Description: Arbitrarily disables the "Back" button.
Returns: none
Arguments: none
Example:
RM_DisableBackButton();
3.3.13 RM_EnableBackButtonWeak
Function: RM_EnableBackButtonWeak([Id])
FrontEnd Version: 2.11.1
Description: Tries to enable the "Back" button by releasing the disabling lock identified by the Id (if supplied), and by reverting the arbitrary disabling. After that the button may remain disabled if there are any other conditions keeping it disabled.
Returns: none
Arguments:
Name |
Optional |
Description |
allowingId |
Yes |
Id of the disabling lock. |
Example:
RM_EnableBackButtonWeak();
RM_EnableBackButtonWeak("MyElemennt_id");
3.3.14 RM_EnableBackButtonStrong
Function: RM_EnableBackButtonStrong()
FrontEnd Version: 2.11.1
Description: Arbitrarily enables the "Back" button.
Returns: none
Arguments: none
Example:
RM_EnableBackButtonStrong();
3.3.15 RM_SetDisablingContinueButton
Function: RM_SetDisablingContinueButton(disable)
FrontEnd Version: 2.11.1
Description: For disable = {true} it arbitrarily disables the "Continue" button; for disable = {false} it arbitrarily enables the "Continue" button; for disable = {null} it reverts the arbitrary disabling/enabling‑related changes that any functions introduced to the "Continue" button.
Returns: none
Arguments:
Name |
Optional |
Description |
disable |
Yes |
Null, or Boolean value that indicates whether to disable or enable the "Continue" button. |
Example:
RM_SetDisablingContinueButton(true);
3.3.16 RM_DisableContinueButton
Function: RM_DisableContinueButton()
FrontEnd Version: 2.5.4020
Description: Arbitrarily disables the "Continue" button.
Returns: none
Arguments: none
Example:
RM_DisableContinueButton();
3.3.17 RM_EnableContinueButtonWeak
Function: RM_EnableContinueButtonWeak([Id])
FrontEnd Version: 2.11.1
Description: Tries to enable the "Continue" button by releasing the disabling lock identified by the Id (if supplied), and by reverting the arbitrary disabling. After that the button may remain disabled if there are any other conditions keeping it disabled.
Returns: none
Arguments:
Name |
Optional |
Description |
allowingId |
Yes |
Id of the disabling lock. |
Example:
RM_EnableContinueButtonWeak();
RM_EnableContinueButtonWeak("MyElemennt_id");
3.3.18 RM_EnableContinueButtonStrong
Function: RM_EnableContinueButtonStrong()
FrontEnd Version: 2.11.1
Description: Arbitrarily enables the "Continue" button.
Returns: none
Arguments: none
Example:
RM_EnableContinueButtonStrong();
3.3.19 RM_EnableContinueButton
Function: RM_EnableContinueButton ()
FrontEnd Version: 2.5.4020
Description: Same as RM_EnableContinueButtonWeak() without arguments; kept for backward compatibility.
Returns: none
Arguments: none
Example:
RM_EnableContinueButton();
Function: RM_ShowContinueButton(allowingId)
FrontEnd Version: 2.2
Description: Same as RM_EnableContinueButtonWeak(allowingId); kept for backward compatibility.
Returns: none
Arguments:
Name |
Optional |
Description |
allowingId |
Yes |
Id of the disabling lock. |
Example:
RM_ShowContinueButton();
RM_ShowContinueButton("MyElement_id");
Function: RM_ResetBackButton()
FrontEnd Version: 2.11.1
Description: Reverts the arbitrary hiding/showing‑ and disabling/enabling‑related changes that any functions introduced to the "Back" button.
Returns: none
Arguments: none
Example:
RM_ResetBackButton();
Function: RM_ResetContinueButton()
FrontEnd Version: 2.11
Description: Reverts the arbitrary hiding/showing‑ and disabling/enabling‑related changes that any functions introduced to the "Continue" button.
Returns: none
Arguments: none
Example:
RM_ResetContinueButton();
Collection: RM_Addon_Params[]
FrontEnd Version: 1.6
Type: string
Description: This collection contains all the parameter strings for the page’s add-on blocks. Change the appropriate string if your add-on needs custom URL parameters. The string will be appended to the end of the URL.
Example:
RM_Addon_Params['MyAddon'] = 'param1="fred"¶m2="michael"';
3.5.1 Some examples of most used functions
3.5.1.1 Radio button
Get: getanswer("MyQuestion","MyOption").checked
Set: getanswer("MyQuestion","MyOption").checked = true/false
3.5.1.2 Dropdown
Get: getquestion("MyQuestion").value
Set: getquestion("MyQuestion ").value = “MyOption”
3.5.1.3 Checkbox
Get: getquestion("MyQuestion").checked
Set: getquestion("MyQuestion ").checked = true/false
3.5.1.4 Text area/field
Get: getquestion("MyQuestion").value
Set: getquestion("MyQuestion").value
Function: getquestion(question name)
FrontEnd Version: 1.6
Description: Gets a question object for JavaScript manipulation.
Returns: question object
Arguments:
Name |
Optional |
Description |
question name |
No |
The name of the question |
Example:
getquestion("MyQuestion").value = "New Value";
getquestion(“MyQuestion”).focus(); //set focus to the field
getquestion(“MyQuestion”).readOnly = true; //set a field to read only
getquestion(“MyQuestion”).checked = true; //set a check box to checked
getquestion(“MyQuestion”).innerHTML = "fred"; //change the question text to fred.
3.5.3 getdescription (obsolete)
Function: getdescription(question name)
FrontEnd Version: 1.6
Description: Gets a description object (of type DIV) for JavaScript manipulation. Modifying the properties of this object affects the description visible on the page, but it doesn’t affect the description visible as a tooltip.
This function is obsolete, maintained for backward compatibility only; use setdescription() instead that affects also the tooltip.
Returns: DIV object
Arguments:
Name |
Optional |
Description |
question name |
No |
Name of the question |
Example:
getdescription("MyQuestion").innerText
= "My Description";
This
is not very browser compatible
getdescription("MyQuestion").innerHTML = "My <b>Description</b>";
Function: setdescription( question name, description )
FrontEnd Version: 2.6.1
Description: Sets a description text for the specified question. It affects both the description visible on the page and the description visible as a tooltip.
Returns: none
Arguments:
Name |
Optional |
Description |
question name |
No |
Name of the question |
description |
No |
Description text |
Example:
setdescription("MyQuestion", "My Description");
setdescription("MyQuestion", "My <b>Description</b>");
setdescription("MyQuestion", "");
Function:getquestionname(question object)
FrontEnd Version: 1.6
*Description: Gets the question name. Can be very useful in conjunction with the java script word “this”
Returns: the question name.
Arguments:
Name |
Optional |
Description |
question object |
No |
|
* Example: //call this with an event like onChange=”alertTxt(this);”
function alertTxt(obj)
{
var Qname = getquestionname(obj);
alert(getquestion(Qname).value); //writes the value of the field
}
Function: getanswer( question name, answer name )
FrontEnd Version: 1.6
*Description: Gets or set the value of a radio button
Returns: the answer object (usually a radio button object)
Arguments:
Name |
Optional |
Description |
question name |
No |
|
answer name |
No |
|
*Example: getanswer("RadioButton0", "Option1").checked = true;
Function: getdate( question name )
FrontEnd Version: 1.6
*Description: Used on a date type to return a date in the format of number of milliseconds since the 1 January 1970 (Unix epoch).
Returns: the date as a number so that it can be compared with other dates. (The number of milliseconds since midnight 1 January , 1970.)
Arguments:
Name |
Optional |
Description |
question name |
No |
Can be a question name or the word “today”. |
date part |
Yes |
A string specifying the part of the date to be returned. It can be “day”, “month” or “year”. If omitted getdate returns the number of milliseconds since 1 January 1970. |
*Example: //display the date of today
getquestion("DateField0").value = displaydate(getdate("today"));
Function: displaydate( date in number format )
FrontEnd Version: 1.6
*Description: Gets the date in dd-mm-yyyy format.
Returns: The date in our standard text format.
Arguments:
Name |
Optional |
Description |
date in number format |
No |
|
*Example: //display the date of today
getquestion("TekstField0").value = displaydate(getdate("today"));
Function: RM_getnumber(question name [, no of decimals])
FrontEnd Version: 1.6
Description: Takes a number in JavaScript format and returns a number as a string with the specified number of decimals in the currently configured number display format.
Returns: A number in JavaScript format so that it can be compared and calculated.
Arguments:
Name |
Optional |
Description |
question name |
No |
|
no of decimals |
Yes |
|
Example:
// This example adds 10% to a question’s value.
getquestion("myquestion").value = RM_displaynumber( RM_getnumber("myquestion") * 1.1 );
Function: RM_displaynumber(number [, no of decimals])
FrontEnd Version: 1.6
Description: Displays a number as a string in the current number display format.
Returns:string
Arguments:
Name |
Optional |
Description |
number |
No |
A number in JavaScript format |
no of decimals |
Yes |
|
Example:
// This example adds 10% to a question’s value.
getquestion("myquestion").value = RM_displaynumber( RM_getnumber("myquestion") * 1.1 );
Function:getselectedname(question name)
FrontEnd Version: 1.6
Description:
Returns: the answer text of the answer that is currently selected.
Arguments:
Name |
Optional |
Description |
question name |
No |
The name of the drop down box |
Example:
Function: RM_ActivatePDFButton()
FrontEnd Version: 1.6
Description: “Pushes” the open PDF button.
Returns: none
Arguments: none
Example:
RM_ActivatePDFButton();
Function: RM_GetProjectID()
FrontEnd Version: 1.6
Description: Returns the current project ID.
Returns: a string containing the current project ID.
Arguments: none
Example:
Var myProjectID = RM_GetProjectID();
Function: getquestiontextobj (question name)
FrontEnd Version: 1.6
Description: Gets the question text object so that the question text can be changed at runtime.
Returns: a div object containing the question text.
Arguments:
Name |
Optional |
Description |
question name |
No |
The name of question of which text you want the object of. |
Example:
getquestiontextobj("myQuestion").innerHTML = "New question text";
3.5.15 RM_ActivateContinueButton
Function:RM_ActivateContinueButton()
FrontEnd Version: 1.6
Description: “Pushes” the open continue button.
Returns: none
Arguments: none
Example:
RM_ActivateContinueButton();
Function:RM_OpenLink (url)
FrontEnd Version: 1.7.1
Description: Opens a URL in a new window.
Returns:none.
Arguments:
Name |
Optional |
Description |
url |
No |
The http link to open. |
Example:
RM_OpenLink("http://www.yahoo.com/");
Function:RM_MoveNext(0)
FrontEnd Version: 2.2
Description: Prevents the project to proceed, it submits, but stays on the same page.
Returns:none.
Arguments:
Name |
Optional |
Description |
? |
No |
?. |
Example:
RM_MoveNext(0);
Function:RM_GetQuestionType(question)
FrontEnd Version: 2.4
Description: Gets the type as a string of the given question.
Returns: The question type as a string.
Arguments:
Name |
Optional |
Description |
question |
No |
The name of the question. |
Example:
var questionType = RM_MoveNext(“MyQuestion”);
Function:RM_OpenCodePicker (pickerName)
FrontEnd Version: 2.4
Description: Runs and / or refreshes a code picker.
Returns:none.
Arguments:
Name |
Optional |
Description |
pickerName |
No |
The name of the codepicker (not to be confused with the application name.) |
Example:
RM_OpenCodePicker("MyCodePicker");
Function:RM_ OpenFileStore (fileStoreName)
FrontEnd Version: 2.4
Description: Runs and / or refreshes a File Store client.
Returns:none.
Arguments:
Name |
Optional |
Description |
fileStoreName |
No |
The name of the file store |
Example:
RM_OpenFileStore("MyFileStore");
Function: RM_Validate(input, validation)
FrontEnd Version: 2.4
Description: Validates a string using standard validation routines.
Returns: True or the error message as a string.
Arguments:
Name |
Optional |
Description |
input |
No |
The string to be validated |
validation |
No |
The validation routine to use. |
Example:
var result = RM_Validate("485734639", "CheckCpr");
Function: RM_GoToActivity(activity)
FrontEnd Version: 2.4
Description: Redirects to the specified activity. You need to specify the phase, activityset and activity separated by backslashes (\).The path takes the format of \phase\ativityset\activity. The path must start with a backslash.
Returns: none.
Arguments:
Name |
Optional |
Description |
activity |
No |
The complete path of the activity to go to. You need to specify the phase, activityset and activity separated by backslashes (\).The path takes the format of \phase\ativityset\activity. The path must start with a backslash. Note that in JavaScript notation of the string the backslash (\) has to be escaped with another backslash to preserve the meaning of the first one. Thus the final string has to be entered with the use of double backslashes as "\\myPhase\\myAtivityset\\myActivity". |
Example:
RM_GoToActivity("\\myPhase\\myAtivityset\\myActivity");
3.5.23 RM_ FormatNumber
Function: RM_FormatNumber(qname,rmNumber)
FrontEnd Version: 6.0
Description: This function formats, validates and inserts a number (rmNumber) into the specified form question (qname). The format will be applied according to the form questions properties set in the Process Designer. The function works with the question types percentage, per mille, decimal, currency and integer.
Returns: none.
Arguments:
Name |
Optional |
Description |
qname |
No |
The Question name. |
rmNumber |
No |
The value to format and display. |
Example:
RM_FormatNumber("TextField0", 23.2);
Function: GetShowHideObject()
FrontEnd Version:
Description: Gets the ShowHide class object with its functionality.
Returns: none.
Arguments: none
Example:
GetShowHideObject();
Function: RM_ShowHideIconByElem(oElem,pShow,pKeepSpace)
FrontEnd Version:
Description: Show or hide icon of specified element object
Returns: none.
Arguments:
Name |
Optional |
Description |
oElem |
No |
The element object |
pShow |
No |
The element icon will be showed or not. |
pKeepSpace |
No |
Preseve spacing or not. |
Example:
var element = document.getElementById(“TextField0_ID”);
RM_ShowHideIconByElem(element,true,true);
Function: RM_ShowHideIconByName(pName,pShow,pKeepSpace)
FrontEnd Version:
Description: Show or hide icon of specified element name
Returns: none.
Arguments:
Name |
Optional |
Description |
pName |
No |
The element name |
pShow |
No |
The element icon will be showed or not. |
pKeepSpace |
No |
Preseve spacing or not. |
Example:
RM_ShowHideIconByName(”TextField0”,true,true);
Function: getquestiontext(RM_obj)
FrontEnd Version:
Description: Show or hide icon of specified element name
Returns: The text on specified question element object.
Arguments:
Name |
Optional |
Description |
RM_obj |
No |
The question element object. |
Example:
var element = document.getElementById(“TextField0_ID”);
getquestiontext(element);
Function: RM_calcnumber(qname1,operator,qname2,pDecimals)
FrontEnd Version:
Description: Calculate mathematic operation based on 2 element name
Returns: none.
Arguments:
Name |
Optional |
Description |
Qname1 |
No |
The first element name |
Operator |
No |
The mathematic operation to be performed |
Qname2 |
No |
The second element name. |
pDecimal |
No |
Decimal digit |
Example:
RM_calcnumber(”TextField0”,"+","TextFiled1",2);
// Note:If TextField0 have value 5 and TextField1 has value 5, the function will return 10.00
Function: RM_AttachOnLoadEvent( FunctionName )
FrontEnd Version: 6.0
Description: This function will try to schedule a call to the javascript function given in the “FunctionName” input parameter on the OnLoad event of the page. That is you can use this function, if your code needs to run OnLoad. If it is not possible to attach the function call to the OnLoad event, a delay of 100 ms is made and and the function is called at that time.
Returns: none.
Arguments:
Name |
Optional |
Description |
FunctionName |
No |
The name of the function to be called when the page has been loaded. |
Example:
RM_AttachOnLoadEvent(”LoadMap”);
Function: RM_ConditionalAlert(elementToOperateBy, logicalOperator, conditionValue, alertIfFalseMessage)
FrontEnd Version: 6.0
Description: This function will try to schedule a call to the javascript function given in the “FunctionName” input parameter on the OnLoad event of the page. That is you can use this function, if your code needs to run OnLoad. If it is not possible to attach the function call to the OnLoad event, a delay of 100 ms is made and and the function is called at that time.
Returns: boolean
Arguments:
Name |
Optional |
Description |
elementToOperateBy |
No |
The question element to evaluate the condition value against. |
logicalOperator |
No |
The logical operator to evaluate against. Can be <, >, =, <= or >=. |
conditionValue |
No |
Specifies the condition value to evaluate by. |
alertIfFalseMessage |
No |
The text message to present if the condition evaluates to false. |
Example:
RM_ConditionalAlert('Group0/TextField0', '>=', '10', 'Specialekarakteren skal være 10 eller derover for at kunne søge', 'true');
Function: RM_ShowHideElement(elementToShowHide, elementToOperateBy, conditionValue, showHideAction, clearModeOn)
FrontEnd Version: 6.0
Description: Shows or hides the specified element, based on the specified element and show hide action.
If the condition is not met, the opposite show/hide action is activated.
Returns: none.
Arguments:
Name |
Optional |
Description |
elementToShowHide |
No |
Internal ID of the question element to show or hide. |
elementToOperateBy |
No |
Specifies the Internal ID of the question element to evaluate the criteria against. |
conditionValue |
No |
Specifies the condition value to evaluate by. |
showHideAction |
No |
Determines whether to show or hide if the evaluation returns true. |
clearModeOn |
No |
Specifies whether to set the clear mode or not. |
Example:
RM_ShowHideElement('Group0', 'Candidates/dt:Fax', '12345' , 'hide', false);
3.5.32 RM_GetShowHideObjectFromElement
Function: RM_GetShowHideObjectFromElement(element, clearModeOn, setToCollapse)
FrontEnd Version: 6.0
Description: Get the show hide element by specifying the question element name.
Returns: object.
Arguments:
Name |
Optional |
Description |
element |
No |
Name of the question element to get the show hide object for. |
clearModeOn |
No |
Determines whether to set the clear mode or not. Specified as a boolean string. |
setToCollapse |
No |
Determines wheter to set the collapse mode or not. Specified as a boolean string. |
Example:
var objShowHideElement = RM_GetShowHideObjectFromElement(elementToShowHide, 'true', 'true');
Function:RM_GetLoginUrl ()
FrontEnd Version: 6.2
Description: Returns the URL the Frontend targets to log in.
Returns: The login URL as a string.
Arguments: None
Example:
Function: RM_GetLogoutUrl()
FrontEnd Version: 6.2
Description: Returns the URL the Frontend targets to log out.
Returns: The logout URL as a strin g.
Arguments: None
Example:
Function: RM_GetElements(groupName, elementTypes)
FrontEnd Version: 6.2 RC3
Description: Returns the elements in a given group.
Returns: An array of element objects from the supplied group.
Arguments:
Name |
Optional |
Description |
groupName |
No |
Name or path of the group as a string. |
elementTypes |
Yes |
A string or array of strings whith the types to include on the resulting element list. |
Example:
var elements = RM_GetElements("ParentGroup\Group1", "Text");
elements.forEach(function(element) {
// List all text elements' name and value.
console.log("Element Name: " + getquestionname(element) + ", Element Value: " + element.value);
});
Function: RM_GetAllElements(elementTypes)
FrontEnd Version: 6.2 RC3
Description: Returns the elements on a page.
Returns: An array of element objects from the page.
Arguments:
Name |
Optional |
Description |
elementTypes |
Yes |
A string or array of strings whith the types to include on the resulting element list. |
Example:
var pageElements = RM_GetAllElements("Symbolic");
pageElements.forEach(function(element) {
// List all page's symbolic elements name and value.
console.log("Element Name: " + getquestionname(element) + ", Element Value: " + element.value);
});
FrontEnd Version: 1.6
Description:
Example:
FrontEnd Version: 1.6
Description:
Example:
FrontEnd Version: 1.6
Description: The RM_CustomValidation() function is a function that can be implemented by developers and is called as part of the page submit.
The function must implement its own validation alerts and return the validation result as either true or false. Returning true will allow the page to be submitted, false will not.
Example:
// The following example show how the RM_CustomValidation() implements the mandatory return values true or false.
function RM_CustomValidation(){
// Do stuff on submit
// Return true if submit is allowed, false otherwise
var amount = getquestion('DropDown0').value;
if (amount > 1 )
return true;
else{
alert("You selected less than two aircraft");
return false;
}
}
FrontEnd Version: 1.6
Description: Represents one day when calculating dates.
Example:
// The following example adds one day to a question of date type.
getquestion("MyQuestion").value = displaydate(getdate("MyQuestion") + RM_oneday);
FrontEnd Version: 1.6
Description: Represents one week when calculating dates.
Example:
FrontEnd Version: 1.6
Description: Represents one year when calculating dates.
Example:
FrontEnd Version: 6.2
Description: Variable containing the textual representation of the page type. This information is provided for custom scripts as well as injected 3. party JavaScript frameworks – which could be pulled in to handle analytics or error handling, which could benefit from the right context. Can have the following values: Project, ErrorPage or ProjectList.
FrontEnd Version: 6.2
Description: Variable containing the textual representation of the internal workflow Id. This information is provided for custom scripts as well as injected 3. party JavaScript frameworks – which could be pulled in to handle analytics or error handling, which could benefit from the right context.
FrontEnd Version: 6.2
Description: Variable containing the textual representation of the reader friendly workflow name. This information is provided for custom scripts as well as injected 3. party JavaScript frameworks – which could be pulled in to handle analytics or error handling, which could benefit from the right context.
FrontEnd Version: 6.2
Description: Variable containing the textual representation of the internal activity id of the current workflow activity. This information is provided for custom scripts as well as injected 3. party JavaScript frameworks – which could be pulled in to handle analytics or error handling, which could benefit from the right context.
FrontEnd Version: 6.2
Description: Variable containing the textual representation of the reader friendly activity name of the current workflow activity. This information is provided for custom scripts as well as injected 3. party JavaScript frameworks – which could be pulled in to handle analytics or error handling, which could benefit from the right context.
FrontEnd Version: 6.2
Description: Variable containing the textual representation of page number of the current form page. This information is provided for custom scripts as well as injected 3. party JavaScript frameworks – which could be pulled in to handle analytics or error handling, which could benefit from the right context. This is almost always 0 as best praxis is one page per form.
3.9.1 Debug Client Script in Microsoft Visual Studio 2005
It is possible to debug client scripts in the following way:
- Open the page you want to debug in a browser
- Start Microsoft Visual Studio and choose Debug and Attach to Process…
- In the Attach to Process window find your process and Attach
- Open Script Explorer, if not open already, choose Debug, Windows and Script Explorer
- Double click the file containing the script you want do debug
- Set breakpoint(s) in the file
- Refresh the browser window, and you are ready to debug in Microsoft Visual Studio.
3.9.2 Debug Client Script in Internet Explorer with Microsoft Script Debugger
First you need to install Microsoft Script Debugger from Microsoft
In your client code write “debugger;” where you want to debug from, and choose the Script Debugger when the page is loaded. If installed it is also possible use Microsoft Visual Studio this way.
This will only works if you uncheck the checkbox Disable script debugging (Internet Explorer) in advanced options.
This section describes the Process FrontEnd query string api.
A typical url with query string could look like this:
http://ServerName/RMFrontEnd/Default.aspx?id=newworkflow
FrontEnd Version: 3.0
Description:
Setting the ProjectTypeFilter results in the project lists being filtered by the name that is specified in the value. This corresponds to the Categories set in the properties of the Workflow Designer in the Process Designer 3.3 and later. ProjectTypeFilter also corresponds to the Main Categories set in the custom properties in the Manual Workflow Editor.
Workflow Designer |
|
Example:
http://ServerName/RMFrontEnd/Default.aspx?ProjectTypeFilter=CompanyStart
FrontEnd Version: 3.0 to 6.0.4000
Description:
The same as ProjectTypeFilter.
This parameter is deprecated but still supported until version 6.0.4000.
Example:
FrontEnd Version: 3.0
Description:
This parameter will start a workflow from a workflow template with the name specified in the parameter. This will spawn a workflow instance.
Example:
http://ServerName/RMFrontEnd/Default.aspx?StartProject=newworkflow
FrontEnd Version: 3.0
Description:
The same as StartProject.
Example:
http://ServerName/RMFrontEnd/Default.aspx?id=newworkflow
FrontEnd Version: 3.0
Description:
It is possible to define several skins. These skins are stored in the following folder structure.
The SkinName parameter overwrites the skin value set in the Resultmaker.OC.FrontEnd.config.
Example:
https://ServerName/RMFrontEnd/Default.aspx?Skinname=SkinTest
FrontEnd Version: 6.0.5300
Description:
With this querystring parameter, it is possible to specify the language to use for the application texts. The language texts are taken from a file stored in the folder /Layouts/Presentation/Translations/ in the Frontend with the file name Translations.[Language].xml. The language parameter value must be the language ISO code i.e. en, ge, da, se etc.
Example:
https://ServerName/RMFrontEnd/Default.aspx?Language=da
FrontEnd Version: 3.0
Description:
With this querystring parameter it is possible to resume a project/workflow with a given project id. The logged in user is validated for the proper permissions for the workflow.
Example:
https://ServerName/RMFrontEnd/Default.aspx?ResumeProject=1001
FrontEnd Version: 3.0
Description:
This parameter makes it possible by query string to access a specific type of Project list, New Projects, Running Projects, Completed Projects.
Valid options are "N" ("New"), "R" ("Running"), "C" ("Completed").
Note that "P" ("Pending") is deprecated in version 6.0.
Example:
https://ServerName/RMFrontEnd/Default.aspx?DefaultProjectListType=R
FrontEnd Version: 3.0
Description:
Example:
FrontEnd Version: 3.0
Description:
Specifies how to sort the project list for new projects/workflows.
Sorting by multiple columns is possible by comma separation of the columns and descenting sorting is possible.
Options: "CreatedDate desc,ProjectText desc, Authority desc"
Example:
https://ServerName/RMFrontEnd/Default.aspx?ProjectListSortNew=ProjectText,Authority
3.10.11 ProjectListSortRunning
FrontEnd Version: 3.0
Description:
Specifies how to sort the project list for started/running projects/workflows.
Sorting by multiple columns is possible by comma separation of the columns and descenting sorting is possible.
Options: "CreatedDate desc,ProjectText desc, Authority desc"
Example:
https://ServerName/RMFrontEnd/Default.aspx?ProjectListSortRunning=ProjectText,Authority
3.10.12 ProjectListSortCompleted
FrontEnd Version: 3.0
Description:
Specifies how to sort the project list for finished projects/workflows.
Sorting by multiple columns is possible by comma separation of the columns and descenting sorting is possible.
Options: "CreatedDate desc,ProjectText,Authority"
Example:
https://ServerName/RMFrontEnd/Default.aspx?ProjectListSortCompleted=ProjectText,Authority
3.10.13 ProjectListSortPending
FrontEnd Version: 3.0. Deprecated in version 6.0
Description:
Options: DateBegin,Subject
Example:
FrontEnd Version: 3.0 to 6.0.4000
Description:
Deprecated as a querystring parameter.
Example:
3.10.15 ProjectListItemsPerPage
FrontEnd Version: 3.0
Description:
Specifies how many projects/workflows to display per page on the project list pages.
Example:
https://ServerName/RMFrontEnd/Default.aspx?ProjectListItemsPerPage=80
3.10.16 RM_EnableEnrichedWorkflow
FrontEnd Version: 3.0 to 5.2
Description:
Specifies whether to show the enriched workflow menu or not. Requires AllowEnrichedWorkflow to be set to 1.
Deprecated in version 6.0
Example:
FrontEnd Version: 3.0 to 5.2
Description:
Deprecated in version 6.0
Example:
FrontEnd Version: 3.0
Description:
Specifies that the Frontend should resume the workflow based on the workflow ID stored in the ASP.NET session.
Example:
https://ServerName/RMFrontEnd/Default.aspx?ResumeCurrent=1
FrontEnd Version: 3.0
Description:
The ResumeFromInvitation functionality makes it possible to send a link to a third party user, and invite this user to a workflow instance in a specified workflow role. The workflow instance id, the role name to give the third party user access to is stored in the TokenService and a token to that information is issued in the form of a guid. This Tokenservice guid is the value of the ResumeFromInvitation query string parameter.
Example:
https://ServerName/RMFrontEnd/Default.aspx?ResumeFromInvitation=4e0f09df-250c-4513-995a-61b6d51d5a39
FrontEnd Version: 3.0
Description:
Specify a path to the activity from the activities Internal ID. Activity levels are separated by a backslash “\”. The Internal IDs can be found in the Process Designer.
Figur 1 How to the the Internal ID from the Transaction level
GoToActivity=\Transaction\WorkflowGroup\FormActivity2
See the related JavaScript function in section 3.5.22.
Note that this query string parameter only works in conjunction with StartProject/ID or ResumeProject, ResumeCurrent or ResumeFromInvitation.
Example:
FrontEnd Version: 3.0 to 5.2
Description:
Not supported in version 6.0.
Example:
FrontEnd Version: 3.0 to 5.2
Description:
Not supported in version 6.0.
Example:
FrontEnd Version: 3.0 to 5.2
Description:
Setting this parameter to 1 will show the login page. Note that the parameter will not be removed, so that subsequent get requests to the same url, will show the login page again.
No longer supported in 6.0.
Example:
FrontEnd Version: 3.0 to 5.2
Description:
Setting this parameter to 1 will show the login page if the user is not logged in.
This functionality requires that a login, username/password or certificate login, is enabled.
No longer supported in 6.0.
Example:
http://server/RMFrontEnd/default.aspx?ShowLoginIf=1
4 Process Frontend User Object Documentation
This section describes the Process Frontend user object interface and its implementations.
The user object has to be provided by the platform to the Process Frontend during log-on and will be accessible within the running session. The object hides actual implementation of user handling on the platform, which thereby has to be implemented by the platform provider.
The section describes the interface ILoginInformation for the Resultmaker user object.
ILoginInformation description
Property name |
Type |
Description |
CommonName |
String |
Returns the friendly user name (as friendly as possible, for displaying purposes).
Goes to "LoggedInCommonName" user variable. Examples: "Børge Åge Bæntsen" or "BAB". |
|
String |
Returns the users email. |
IsLoggedIn |
Boolean |
Returns true if the user is logged in. |
IsRequireLoggedout |
Boolean |
Returns true if the user is require to log out.
Some implementations may use {false} to mark the object as "not-logged-in" (to invalidate it). |
SecurityToken |
String |
Returns the security token used to communicate with the Process Engine Security Provider.
Traditionally goes to the "UserUmsID" user variable. Example: "WinDelegation:OUTOFBANDPAYLOAD==" for the IIS integrated Windows security provider. |
UserCode |
string |
Returns the user unique code. /// If the implementation has no good candidate for the unique code, it may be the string representation of UserGUID. /// Example: "CVR:25369580-RID:1088688576960" (for certificate login); "BAB" (for user/password login).
|
Project properties are the properties a project has on different levels. They are the properties, which can be edited in the Process Designer.
Default purposes are a list of purposes, which are evaluated at project start time. It is possible to use several purposes separated by commas.
The purpose rule property determines the conditions under which a work flow item is presented or hidden in the flow, based on the runtime purposes set and the value of the purpose rule property.
The purposes can be AND, OR, NOT. The default value is OR. Advanced purpose rules can be constructed such as:
Not (PurposeA AND PurposeB OR (PurposeB AND PurposeC) ).
The Resultmaker Process Frontend consists of a series of different views. The main view is the workflow view where the workflow execution is rendered. Another series of important pages are the workflow/project list pages. This section describes the format of the Frontend Project List XML file and how to change the layout of the project list pages.
Figure 2 Main view: Workflow View
Figure 3 Workflow list view: New Workflows
Figure 4 Workflow list view: Open Workflows
Figure 5 Workflow list view: Closed Workflows
The Workflow list view in Figure 2-4 can be controlled by the file DefaultProjectListTemplate.xml. This file is located in the folder \Layouts\Presentation\Default\ProjectListTemplates\ in the RMFrontEnd virtual folder.
The typical full path the the file is:
C:\Inetpub\wwwroot\RMFrontEnd\Layouts\Presentation\Default\ProjectListTemplates\DefaultProjectListTemplate.xml
The file has the following basic structure.
Out of the box, the full file looks like this:
<?xmlversion= "1.0" encoding="utf-8" ?> <ProjectListTemplateName= "Default"LeftHeading="Workflows"> <Menu> <ItemName= "ListNew" OCText="NewProjects" OCDescription="Select_a_new_project_" /> <ItemName= "Current" OCText="ActiveProject"OCDescription="Select_your_active_project_"/> <ItemName= "ListRunning" OCText="RunningProjects" OCDescription="ProjectsAvailableAfterLogin"Disabled="True"/> <ItemName= "ListCompleted" OCText="ClosedProjects" OCDescription="ProjectsAvailableAfterLogin"Disabled="True"/> </Menu> <MenuLoggedIn= "True"> <ItemName= "ListNew" OCText="NewProjects" OCDescription="Select_a_new_project_" /> <ItemName= "Current" OCText="ActiveProject" OCDescription="Select_your_active_project_"/> <ItemName= "ListRunning" OCText="RunningProjects" OCDescription="Select_one_of_your_saved_running_projects_"/> <ItemName= "ListCompleted" OCText="ClosedProjects" OCDescription="Select_one_of_your_saved_closed_projects_"/> </Menu>
<MainText> <InsertName= "Projects" Value="New" /> </MainText> <MainTextLoggedIn= "True"> <InsertName= "Projects" Value="New" /> <InsertName= "Projects" Value="Running" /> <InsertName= "Projects" Value="Completed" /> </MainText>
<ProjectsList= "New"> <divclass= "RM_ProjectCompletionBlock"> <divclass= "RM_ProjectCompletionSubHeader"> <OCTextName= "NewProjects" disable-output-escaping="yes" /> </div> <divclass= "RM_ProjectCompletionText"> <OCTextName= "ProjectList.New.Text" disable-output-escaping="yes"/> </div> <divclass= "RM_ProjectCompletionSubHeader"> <OCTextName= "ProjectList.NotLoggedIn.Header"disable-output-escaping="yes"/> </div> <divclass= "RM_ProjectCompletionText"> <OCTextName= "ProjectList.NotLoggedIn.Note"disable-output-escaping="yes"/> </div> <divclass= "RM_ProjectCompletionText"> <div> <InsertName= "LoginURL"OCText="ProjectList.LoginLink.1"/> <OCTextName="ProjectList.LoginLink.2"disable-output-escaping="yes"/> </div> <div> <OCTextName= "ProjectList.OrderSignature"disable-output-escaping="yes"/> </div> </div> <table> <InsertList> <tr> <td> <InsertName= "Bullet"/> </td> <td> <InsertName= "ProjectText"/> </td> <td> <InsertName= "Authority"/> </td> </tr> </InsertList> </table> </div> </Projects>
<ProjectsList= "New" LoggedIn="True"> <divclass= "RM_ProjectCompletionBlock"> <divclass= "RM_ProjectCompletionSubHeader"> <OCTextName= "NewProjects" disable-output-escaping="yes" /> </div> <divclass= "RM_ProjectCompletionText"> <OCTextName= "ProjectList.New.Text" disable-output-escaping="yes"/> </div> <table> <InsertList> <tr> <td> <InsertName= "Bullet"/> </td> <td> <InsertName= "ProjectText"/> </td> <td> <InsertName= "Authority"/> </td> </tr> </InsertList> </table> </div> </Projects>
<ProjectsList= "Running" LoggedIn="True"> <divclass= "RM_ProjectCompletionBlock"> <divclass= "RM_ProjectCompletionSubHeader"> <OCTextName= "ProjectList.MyProjects"disable-output-escaping="yes"/> </div> <divclass= "RM_ProjectCompletionText"> <OCTextName= "ProjectList.LoggedIn.Note"disable-output-escaping="yes"/> </div> <hr/> <divclass= "RM_ProjectCompletionSubHeader"> <OCTextName= "RunningProjects" disable-output-escaping="yes" /> </div> <divclass= "RM_ProjectCompletionText"> <OCTextName= "ProjectList.Running.Text"disable-output-escaping="yes"/> </div> <table> <InsertList> <tr> <td> <InsertName= "Bullet"/> </td> <td> <InsertName= "ProjectText"/> </td> <td> <InsertName= "CreatedDate"/> </td> <td> <InsertName= "Authority"/> </td> <td> <InsertName= "Delete" /> </td> </tr> </InsertList> </table> </div> </Projects>
<ProjectsList= "Completed" LoggedIn="True"> <divclass= "RM_ProjectCompletionBlock"> <divclass= "RM_ProjectCompletionSubHeader"> <OCTextName= "ProjectList.MyProjects"disable-output-escaping="yes"/> </div> <divclass= "RM_ProjectCompletionText"> <OCTextName= "ProjectList.LoggedIn.Note"disable-output-escaping="yes"/> </div> <hr/> <divclass= "RM_ProjectCompletionSubHeader"> <OCTextName= "ClosedProjects" disable-output-escaping="yes" /> </div> <divclass= "RM_ProjectCompletionText"> <OCTextName= "ProjectList.Completed.Text"disable-output-escaping="yes"/> </div> <table> <InsertList> <tr> <td> <InsertName= "Bullet"/> </td> <td> <InsertName= "ProjectText"/> </td> <td> <InsertName= "CreatedDate"/> </td> <td> <InsertName= "Authority"/> </td> <td> <InsertName= "Delete" /> </td> </tr> </InsertList> </table> </div> </Projects>
</ProjectListTemplate>
|
With this file it is possible to control how the workflow list views are rendered. There are the following different views that can be rendered depending on whether the user is logged in or not:
- <ProjectsList= "New">
- <ProjectsList= "New" LoggedIn="True">
- <ProjectsList= "Running" LoggedIn="True">
- <ProjectsList= "Completed" LoggedIn="True">
6.1 Running and Completed projects
The Running and Completed projects type definitions are explained here.
The Div in the first part references Translations from the translation file
<divclass= "RM_ProjectCompletionSubHeader">
<OCTextName= "ProjectList.MyProjects" disable-output-escaping="yes"/>
</div>
<divclass= "RM_ProjectCompletionText">
<OCTextName= "ProjectList.LoggedIn.Note"disable-output-escaping="yes"/>
</div>
<hr/>
<divclass= "RM_ProjectCompletionSubHeader">
<OCTextName= "RunningProjects" disable-output-escaping="yes" />
</div>
<divclass= "RM_ProjectCompletionText">
<OCTextName= "ProjectList.Running.Text"disable-output-escaping="yes"/>
</div>
These four OCText elements references translations and they are presented in the places shown in this example, marked with yellow.
The next section, the table and InsertList elements define the columns for the actual project list. The values in the Name attribute are reserved words. It is possible to insert the text elements ProjectText and CreatedDate from the project table of the Process Platform. It is also possible to insert bullits and a delete button. And it is possible to remove these as they are merged with normal html.
<table>
<InsertList>
<tr>
<td>
<InsertName= "Bullet"/>
</td>
<td>
<InsertName= "ProjectText"/>
</td>
<td>
<InsertName= "CreatedDate"/>
</td>
<td>
<InsertName= "Authority"/>
</td>
<td>
<InsertName= "Delete" />
</td>
</tr>
</InsertList>
</table>
</div>
</Projects>