Help with GetListItem in a Web Service



Hi,

I'm creating a Web Service to get an specific Item from a list via
GetListItem. However, the query portion of my GetListItem doesn't seem
to work for some reason. I'm able to get the list node.

Here's my code:

[WebMethod]
public string GetData_Credit(int regDataId)
{
string credit = "";

WebServices.Lists.Lists l = new WebServices.Lists.Lists();
l.Credentials=System.Net.CredentialCache.DefaultCredentials;
XmlDocument xmlDoc = new XmlDocument();
XmlNode ndQuery = xmlDoc.CreateNode(XmlNodeType.Element,"Query","");
XmlNode ndViewFields =
xmlDoc.CreateNode(XmlNodeType.Element,"ViewFields","");
XmlNode ndQueryOptions =
xmlDoc.CreateNode(XmlNodeType.Element,"QueryOptions","");

// ndQuery.InnerXml = "<Query><Where><Eq>" +
// "<FieldRef Name=\"regDataId\" /><Value
Type=\"String\">1</Value></Eq></Where></Query>";

ndViewFields.InnerXml = "<FieldRef Name=\"credit\" />";
ndQueryOptions.InnerXml = "";

XmlNode nodeListItems = null;
try
{
nodeListItems = l.GetListItems("ListName", null, ndQuery,
ndViewFields, null, null);
credit = nodeListItems.OuterXml.ToString();
}

catch(SoapException e)
{
credit = e.Message;
String error=e.Detail.OuterXml;
}

finally
{
if ( l != null )
{
l.Dispose();
l = null;
}
}
return credit;
}

Please notice how I commented ndQuery. This WebMethod works the same
with or without ndQuery. Again, my question is: Why is ndQuery not
working? Have I forgotten something?
By the way, I have checked this CAML query in various tools in the web
and the ndQuery is written correctly (ort at least it worked in the
CAML tools). I would appreciate any help provided. Thanks!

.