cancel
Showing results for 
Search instead for 
Did you mean: 

Parsing and Re-Formatting OnBase Date Keywords / Attributes (challenges with NO leading zeros)

Benjamin_Peter1
Confirmed Champ
Confirmed Champ

Hello.  I have a need for re-formatting AND inserting an OnBase Date (Keyword or WV Attribute, doesn't matter which) into a dynamic web address within an iFrame. (in a WV View)

The web address calls for a more global/universal date format of:  YYYY-MM-DD

I've been trying to use 'Set Property to Expression' for each Date part (Y, M and D).  However, the LACK of leading zeros is really rearing it's head here.  If leading zeros were in use by the KW/Attribute field, I would be done in 5 minutes if I could just use RIGHT(), LEFT() and MID().  (w/ fixed and predictable positions)

I am barely a moderate/beginner with string manipulation code, so doing some kind of REPLACE() function so (setting a variable in 'Set Prop to Expression'?) and finding a separator (like '/') and working from that position (to workaround no leading zeros for D and M) is mostly new territory for me.

Has anyone reformatted a Date value previously?  Is there some potentially easier way (or function) that I'm overlooking?  (to workaround/account for no leading zeros for Day and Month)

1 REPLY 1

Thomas_Reu
Elite Collaborator
Elite Collaborator

if you are using workflow - check out the FormatDateTime function or if that doesn't fly, perhaps one of the 2 Format functions on either side of it - see p. 558 of the workflow1701.pdf mrg.  Not sure if v18 uses the same page, but I would imagine it would be close...

Getting started

Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.