I am using Infopath 2003 SP2 and am trying to send a value to a stored procedure in SQL server using a Query in a very simple InfoPath form.
I created the drop box called ProjectComplete in myFields. There are two values Yes and No
This is the Code,
function CTRL2_8::OnClick(eventObj)
{
var ChkComplete = XDocument.DOM.SelectSingleNode("my:myFields/my:ProjectComplete");
XDocument.QueryAdapter.Command = 'execute "dbo"."CheckData" '+ ChkComplete;
XDocument.Query();
}
When I run it I get the following message
Object doesn't support this property or method
File:script.js
Line 24
and line 24 is
var ChkComplete = XDocument.DOM.SelectSingleNode("my:myFields/my:ProjectComplete");