Skip to main content

Hi All,

 

I have put a workbench together to populate some GIS metadata but I need to have the <CreateTime> automatically populate every time I run the workbench, below an example of the XMLTemplater transformer settings:

FME_3Currently the time if fixed as 00:00:000, How can I set it as variable parameter ? I have tried the ROOT Template Functions but didn't work.

 

Any advise more than welcome :)

Thanks

 

Hi @galigis​ ,

You can use Date/Time functions in an XML Template expression to get the current time and convert it to a preferable format. e.g.

<root>
    <CreateTime>@DateTimeFormat(@Left(@DateTimeNow(),14),%H:%M:%S)</CreateTime>
</root>

 


Bravo! Sorted, thanks :)


Reply