CustomInlineFunctions sample
The CustomInlineFunctions sample provides an example of implementing a set of custom inline functions for date and string manipulation in Nintex Workflow 2013.
Overview
The sample is a Visual Studio 2012 project for a signed, strongly-named assembly that contains two static classes:
-
DateInlineFunctions
A collection of public static methods for date manipulation, such as calculating the first and last day of the week for a specified date.
-
StringInlineFunctions
A collection of public static methods for string manipulation, such as identifying whether a string is null or empty.
The methods defined in both classes include code comments for documentation purposes, but do not include exception handling.
The sample also includes a Windows batch (.bat) file, named CreateFunctionAliases.bat, that contains the commands needed to define the function aliases for the methods defined in the DateInlineFunctions and StringInlineFunctions classes. The batch file uses the NWAdmin.exe command line tool to perform an AddInlineFunction operation for each public static method defined in both classes. For more information about the NWAdmin.exe command line tool, see NWAdmin Operations - Nintex Workflow 2013.
Using the sample
This sample does not include an automatic deployment mechanism, and so must be manually deployed before it can be used, or an automatic deployment mechanism can be created for the sample. To manually deploy the sample, you must perform the following general steps:
-
Build the Visual Studio 2012 project.
-
Manually add the CustomInlineFunctions assembly to the Global Assembly Cache (GAC) of each web front end used by Nintex Workflow 2013. For more information about manually adding an assembly to the GAC, see Install the assemblies into the Global Assembly Cache.
-
Start Command Prompt as an administrator, and then run the CreateFunctionAliases.bat file included with the sample.