I have a secondary data source based on a stored procedure. I'm using JScript to run the query on a button click. Data is returned fine and is displayed in the bound repeating table. Here is the xml from the debugger immediate window:
? XDocument.DataObjects("spSelManualCharges").DOM.xml
"<dfs:myFields xmlns:dfs=\"http://schemas.microsoft.com/office/infopath/2003/dataFormSolution\"><dfs:dataFields>
<d:ServiceDetail xmlns:d=\"http://schemas.microsoft.com/office/infopath/2003/ado/dataFields\" VendorID=\"3\" VendorAccount=\"Service1\" AmountBilled=\".0000\"/>
<d:ServiceDetail xmlns:d=\"http://schemas.microsoft.com/office/infopath/2003/ado/dataFields\" VendorID=\"3\" VendorAccount=\"Service2\" AmountBilled=\".0000\"/>
</dfs:dataFields></dfs:myFields>
"
But, when I try to access the data in JScript using MSXML methods, I get an "undeclared namespace" error:
? XDocument.DataObjects("spSelManualCharges").DOM.selectSingleNode("/dfs:myFields")
Reference to undeclared namespace prefix: 'dfs'.
There is an xmlns declaration for dfs in the XDocument so, I don't understand what is happening. BTW - There are several secondary sources on the form but no main data connection.
Any help at all would be appreciated.
Thank you,
Crazy Raymo