Prefilling form with data RRS feed

  • Question

  • User599335957 posted

    I am creating a XML form using the following tag and XSLT

    <asp:Xml ID="XmlForm" runat="server" ></asp:Xml>

    and in the code behind I get the XML and XSLT like this

    ' init the XML
      Dim xmlDoc As New XmlDocument
      'Used XPathNavigator to get the xmlDoc and
      'used the Transformsource to find the XSLT
       xmlForm.XPathNavigator = xmlDoc.CreateNavigator()
       XmlForm.TransformSource = Server.MapPath("/mytransform.xslt")

    I was wondering how would I populate the fields if I am creating the form this way. The XML does not contain any values. The values are being populated from the server or the local storage on the browser. Any idea or hints?

    Tuesday, July 23, 2013 12:45 PM


  • User-902516579 posted


    Have you looked at LINQ to XML capabilities, then bind the result to a ListBox or do a foreach through the result and set the values to the Text propoerty of a textox.

    HTH, Benjamin

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, July 24, 2013 6:00 AM