Double Eval with concat working in designer but not in browser - InfoPath Dev
in

InfoPath Dev

Double Eval with concat working in designer but not in browser

Last post 07-03-2012 07:31 PM by tashatstanwell. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 07-03-2012 05:15 PM

    Double Eval with concat working in designer but not in browser

    Hi everyone

     I have a form (custom list in Sharepoint 2010) with a multichoice box which gets its data from a secondary data source (another list in Sharepoint).

    The users selects one or many of the choices in the multichoice box.

    I have a text field (Email) of which I want the choices made in the multichoice box to be concatenated with a ";" between, however I don't want the 'Value' or Title as it's known in the secondary data source list, I want the email addresses (another field in the secondary data source list).

    I have the following working in designer/preview:

    substring-after(eval(eval(Value, 'concat(xdXDocument:GetDOM("NotifyList")/dfs:myFields/dfs:dataFields/d:SharePointListItem_RW/d:Email[../d:Title = current()], ";", " ")'), ".."), ";")

    Example

    Multichoice box list: Title, Email, ID

    1  Red (1)

    2 Blue (2)

    3 Green (3)

    User selects 1, 2 and 3 and the Email text box shows 1@red;2@blue;3@green

    In the Browser, the following occurs:

    Users selects 1 - email text box shows 1@red;

    User selects 2 - email text box shows 2@blue;2@blue

    User selects 3 - email text box shows 3@green;3@green;3@green

     I've read so many blogs/forums on double eval and I am not a developer - I can only assume its the "current()" that's not working correctly on the browser?

    Hope this makes sense - any ideas please let me know!

  • 07-03-2012 07:31 PM In reply to

    Re: Double Eval with concat working in designer but not in browser

    Hi everyone - after days of searching and finally posting on this forum I have found an answer

    http://www.infopathdev.com/blogs/greg/archive/2005/06/09/Keep-Track-of-List-Selections.aspx

    tweaked for my fields and datasource.  Brilliant!!

     

Page 1 of 1 (2 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.