Update WF Attribute with a variable without single quotes

Hello everyone,

We are using a WebReport to update a WF attribute with the WF Owner Id (initiator), it is being set but with a single quotes around it.

We are using the below to get the "OwnerId" from the WF, and set it to the WF attribute "InitiatorID"

[LL_REPTAG_'[LL_REPTAG_'[LL_REPTAG_TRIGGERID /]' WFINFO:OWNERID /]' SETWFATTR:IntiatorID SHOW /]

It results in the below:

We tried using the Replace tag but with no use, does any one have any idea about how to remove this single quotes?

Thanks.


Comments

  • Does this compile for you?

    [LL_REPTAG_[LL_REPTAG_'[LL_REPTAG_TRIGGERID /]' WFINFO:OWNERID /] SETWFATTR:IntiatorID SHOW /]

  • appuq
    appuq Member
    edited December 19, 2024 #3

    or even

    [LL_REPTAG_TRIGGERID /] I guess this gives you the WFID when a WR is involved it receives these implicit variables

    WORKID [LL_REPTAG_&workID /]
    SUBWORKID [LL_REPTAG_&subWorkID /]
    TaskID [LL_REPTAG_&taskID /]

    So to get information about a workflow you can really tee off that

    [LL_REPTAG_'[LL_REPTAG_&workID /]' WFINFO:OWNERID SETWFATTR:'IntiatorID' /]

    What I am thinking is you are actually adding the two single quotes by your many single quotes inside so the parser thinks it is a concatenation of '+WFOWNERID+'

  • Hi @appuq,
    Thank you so much for your reply.

    We managed to solve it as follows,

    [LL_REPTAG_"[LL_REPTAG_'[LL_REPTAG_TRIGGERID /]' WFINFO:OWNERID /]" SETVAR:userid /][LL_REPTAG_'[LL_REPTAG_"[LL_REPTAG_!userid /]" USERINFO:MAILADDRESS /]' SETVAR:useremail /][LL_REPTAG_'[LL_REPTAG_!useremail /]' SETWFATTR:IntiatorEmail SHOW /]

  • A lot of these are also available OOB using Dynamic Replacement variables although I haven't completely understood what your WF does.

  • Apologies for not completely illustrate it @appuq, appreciate you taking the time to reply!