Use different character to end double eval concat - InfoPath Dev
in

InfoPath Dev

Use different character to end double eval concat

Last post 03-22-2012 01:33 PM by erundz. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 03-12-2012 12:22 PM

    Use different character to end double eval concat

    I am using xdMath:Eval(xdMath:Eval(d:tItems, 'concat(@itemName, ", ")'), "..") to display a list of a items in one line. Each item is separated by a comma, but I'd like the last item to have a period after it instead. Can I accomplish this by expanding my formula somehow (another eval/concat function?) or would I have to do some coding?
  • 03-13-2012 09:38 AM In reply to

    Re: Use different character to end double eval concat

    Can you just concat the whole thing with a period at the end like: concat(formula, ".")?  You'll probably need to strip the last character if you don't want the comma either.

    Anson Hidajat
    Qdabra® Software/ InfoPathDev.com
    The InfoPath Experts – Streamline data gathering to turn process into knowledge.™

  • 03-13-2012 12:35 PM In reply to

    Re: Use different character to end double eval concat

    You can set up your double eval so that it doesn't append the separator sequence at the end.  It goes like this:

        substring(xdMath:Eval(xdMath:Eval(d:tItems, 'concat(", ", @itemName)'), ".."), 3)

    Once you have that, you can just use Anson's suggestion to wrap all of that in a concat to tack the period on at the end.

    Jimmy Rishe / Software Developer / Microsoft MVP
    Qdabra Software
  • 03-22-2012 01:33 PM In reply to

    Re: Use different character to end double eval concat

    Thanks, btw, this works great!
Page 1 of 1 (4 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.