So what I need is a way to grab data from a multi-selection list box tool (which grabs values from a data connection to a SP list) and get the " ; " in between the values. For this I am currently using this eval formula:
eval(eval(RepeatingGroup, 'concat(my:Value, substring(";", 1, string-length(my:Value)))'), "..")
Actual Code once the user clicks a button to populate the "Recipient" box which in turn feeds the data connection to send the email:
concat(eval(eval(DM[. != ""], 'concat(., ";")'), ".."), eval(eval(PM[. != ""], 'concat(., ";")'), ".."), eval(eval(TFBW[. != ""], 'concat(., ";")'), ".."), eval(eval(TEEngineer[. != ""], 'concat(., ";")'), ".."), eval(eval(TE_MNGR[. != ""], 'concat(., ";")'), ".."))
but the "value" I am looking at is from a people picker "DisplayName" value which when used in infopath forms for SP2010 adds a duplicate comma, and this duplicate comma is causing issues.
The datasouce is a list box choices that "get choices from an external data source", the data source is an SP List with columns for the filtering criteria and a people picker column, so the Value: pcDisplayName, and Display name: pc:DisplayName. If I used AccountID, it adds extra data in front so I still have to shave off 4 characters to even draw that ID that would work with outlook.
Normally I would use: concat(substring-before(DisplayName, ",, "), ", ", substring-after(DisplayName, ",, ")) which would take care of the comma, but it doesn't work with concatenating the values from a multi-selection list box - or does it???
I cannot use a web browser form option (which fixes the duplicate comma issue with people pickers) because I need the ability to email submit this form and all the collected data via outlook once the user is finished.
I've monkeyed with the nestes evals but I get the error of too many things nested and it fails.
Can anyone out there help me?
Thank you in advance.