I'm trying to follow S.Y.M. Wong-A-Ton' s instructions for saving InfoPath XML to SQL via a web service. I'm not sure whether I set up the Visual Studio Project correctly.
When I access the web page from InfoPath, the error I get is:
"A namespace cannot directly contain members such as fields or methods".
A portion of my code is below. The line that gets the error is indicated.
P.S. I'm new at this so it might be an obvious error.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
namespace SubmitResourceRequestForm
{
public partial class _Default : System.Web.UI.Page
{ protected void Page_Load(object sender, EventArgs e)
{
ERROR IS ON THIS LINE --->>>> System.Xml.XPath.XPathDocument xDoc =
new System.Xml.XPath.XPathDocument(Request.InputStream);
System.Xml.XPath.XPathNavigator navigator = xDoc.CreateNavigator();