swobjl

For Beginners: Looking out for commas

Blog Post created by swobjl on Jun 2, 2017

I'm realitively new to Nintex workflows but I wanted to pass this tip along to all the fellow newbies out there.  A tip which helped tremendously was knowing how to AND remembering to handle commas when using inline functions even when you think they might not occur.  The trick is to use a combination of {TextStart}Variable{TextEnd}.

Inline functions can cause errors when the source data contains commas. Scenarios include:

  1.   Converting a number (which contains commas) to currency using the fn-Currency function. 
    • The error was: "Error updating document. Currency function expects only 1 parameter"
    • Fix was to utilize {TextStart}Variable{TextEnd} in the equation.  This works even though the variable is acutually a number:   fn-Currency({TextStart}ExpensePTO{TextEnd})
  2. Configure Action - Update document: using a number variable containing a comma in the value
    • The error was a weird output in the newly created document
    • Fix was to utilize: fn-Replace({TextStart}Variable{TextEnd},{TextStart},{TextEnd},"")
  3. Configure Action - Update document: Standardizing Text output using a text input containing a comma
    • The error was a weird output or workflow error
    • Fix was to utilize Replace function inside the text function: fn-ToTitleCase(fn-Replace({TextStart}Variable{TextEnd},{TextStart},{TextEnd},"")

I'm sure this is old hat to many veteran Nintex Gurus...But to newbies such as myself this tid bit cost me several hours of head scratching and research to figure out.  So  when handling an output on an Update Document - Configure Action - if there is possibility of a comma which happens when sharepoint saves a number or a potential user input...be sure to use the {TextStart}Variable{TextEnd}.

Outcomes