I think the code below should work in a Word BI Publisher template, but it's not. When I use the BI Publisher Template Viewer app to test, it is showing Duplicate variable 'branch' definition.
If only the matching <?when: ...?>
block should be executed, how is the variable defined more than once?
I have experience in other programming languages, but XML/XSL/BIP, etc. is new to me. Can anyone shed some light on the below code?
Thanks!
<?variable:payco; xdoxslt:trim(Remit_to_Name_ID445)?>
<?choose:?>
<?when: $payco=”Company1”?>
<?variable@begin:branch;'CO1'?>
<?end when?>
<?when: $payco=’Company2’?>
<?variable@begin:branch;'CO2'?>
<?end when?>
<?when: $payco=’Company3’?>
<?variable@begin:branch;'CO3'?>
<?end when?>
<?end choose?>