generate-id - InfoPath Dev
in

InfoPath Dev

generate-id

Last post 10-07-2010 02:35 AM by garciaj. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 09-28-2010 02:33 AM

    generate-id

    Hy all,

    Is it possible to use xsl generate-id() function within vscript to produce a unique key for a new node ?

    thank you 

     

     

  • 10-05-2010 11:18 PM In reply to

    Hi Garcia,

    As far as I know, you can't pass XSL to XML. XSLT hacks in your view (custom commands) can be used to sort tables and do other things but they are not recommended because sometimes they do not roundtrip when you save the form. Use the xd:preserve control to make sure they roundtrip but this renders the section not editable in the designer.

    In theory, you could use Merge Forms (InfoPath's most undocumented feature) to do this when you import a form and aggregate it into the current one. That's because Merge Forms uses xslts and supports some advanced operations on the incoming data (you can convert from a separate incoming schema into your current one). I doubt this will help you though since you don't need to import data and need to change the tables in your form.

    So, you either need to write a little code, or just install the free trial of qRules and use GenerateGuid. I'm guessing that will take ~20 minutes to do and you'll be off and running.

    Best of luck!

    Patrick Halstead
    Project Manager at Qdabra
  • 10-06-2010 07:21 PM In reply to

    Hello GarciaJ,

    generate-id() is actually an XPath function, not XSL.  I don't know of a way to evaluate the values of scalar XPath functions in VBScript, but like any XPath 1.0 function, generate-id() is available in the InfoPath designer, and you can use this to generate an id for any node you like.

    Jimmy Rishe / Software Developer / Microsoft MVP
    Qdabra Software
  • 10-07-2010 02:35 AM In reply to

    Thank you for your replies

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