Send data from taskpane to form - InfoPath Dev
in

InfoPath Dev

Send data from taskpane to form

Last post 10-22-2008 02:50 AM by Shiva. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 10-22-2008 01:13 AM

    • hippie
    • Not Ranked
    • Joined on 10-22-2008
    • Posts 2

    Send data from taskpane to form

    Hello,

    im want to send text from the task pane to a form field.

    what i itried is this ...

    XDocument = window.external.Window.XDocument;

    XDocument.DOM.setProperty('SelectionNamespaces', 'xmlns:my="http://schemas.microsoft.com/office/infopath/2003/myXSD/2007-09-27T16:18:33"' );

    XDocument.DOM.selectSingleNode("/my:myFields/my:testtext").text = "123"; 

    I recieved an error " XDocument.DOM.selectSingle........." is Null ... Any Ideas ?

    Thank you very much !

  • 10-22-2008 02:50 AM In reply to

    • Shiva
    • Top 25 Contributor
    • Joined on 04-15-2005
    • India
    • Posts 694

    Re: Send data from taskpane to form

    Hello Welcome to the Forums,

    In your case not required to set the namespace property. First you can try once are getting the node or not?

    var testtextNode = XDocument.DOM.selectSingleNode("/my:myFields/my:testtext");

    if(testtextNode != null)

    {

              testtextNode.text = "123";

    }

    In this you have to check once again XPath should be correct?

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