Hi all,
Per the below image, I have a PDF sent out via workflow that is converting one of my signature images into the text url showing where the signature is located. The template expression for the broken signature is relatively simple:
<<switch([Employee Refusal],
TRUE,โEMPLOYEE REFUSEDโ,
switch([Employee Available],
TRUE,[Employee Signature],โEMPLOYEE UNAVAILABLEโ)
)>>
The expression works correctly in that it ends up with the appropriate link, but I suspect I need to enforce the correct data type within the formula. I am unsure how to do this for images or signatures, does anyone have any advice? I might just be missing something simple. The supervisor signature works normally but is a simple <<[Supervisor Signature]>> and does not have an expression yet.
Solved! Go to Solution.
I figured it out! Apparently the next <<If: has to start on a new line. I changed the format to:
<<If: AND(NOT([Employee Refusal]), [Employee Available])>>
<<[Employee Signature]>>
<<EndIf>>
<<If: OR([Employee Refusal], NOT([Employee Available]))>>
<<IFS(
[Employee Refusal],
โEMPLOYEE REFUSEDโ,
NOT([Employee Available]),
โEMPLOYEE UNAVAILABLEโ
)>>
<<EndIf>>
After I moved that to a new line I received the error for the missing on the employee signature, regardless, it works as intended now. Thanks for the help! This conversation also led me to the template specific IF expressions page which I had not seen before, these will be very useful.
All of the possible values returned by SWITCH() must be of a compatible type. Iโm not sure how it decides which type is then expected, but in this case, it seems to expect a textual type, and so forces the Signature value to Text. Youโll have to find another way to approach this. Consider:
<<If: AND(NOT([Employee Refusal]), [Employee Available])>>
<<[Employee Signature]>>
<<EndIf>><<If: OR([Employee Refusal], NOT([Employee Available]))>>
<<IFS(
[Employee Refusal],
โEMPLOYEE REFUSEDโ,
NOT([Employee Available]),
โEMPLOYEE UNAVAILABLEโ
)>>
<<EndIf>>
I tried your expression several different ways but I keep getting the below error:
Appears to be missing <<
and >>
?
I donโt think so, Iโve copied it verbatim and tried playing with the formatting quite a bit, something is throwing it off but I canโt figure it out.
Iโve made a minor change in the template I posted above. Try the new version and let me know.
I figured it out! Apparently the next <<If: has to start on a new line. I changed the format to:
<<If: AND(NOT([Employee Refusal]), [Employee Available])>>
<<[Employee Signature]>>
<<EndIf>>
<<If: OR([Employee Refusal], NOT([Employee Available]))>>
<<IFS(
[Employee Refusal],
โEMPLOYEE REFUSEDโ,
NOT([Employee Available]),
โEMPLOYEE UNAVAILABLEโ
)>>
<<EndIf>>
After I moved that to a new line I received the error for the missing on the employee signature, regardless, it works as intended now. Thanks for the help! This conversation also led me to the template specific IF expressions page which I had not seen before, these will be very useful.
User | Count |
---|---|
43 | |
27 | |
24 | |
23 | |
13 |