I am trying to implement this:
http://blogs.msdn.com/bimusings/archive/2006/03/24/560026.aspx
my web service seems to work because i can view the data in the page when i invoke the public web method i created.
i'm trying to retreive the data and use it as the dataset in a report. this is my query string:
<Query>
<ElementPath IgnoreNamespaces="True">
GiveMeDataResponse {}/
GiveMeDataResult/diffgram{}/
Results {}/Table {CompanyID, CompanyName, ABN, Abbreviation}
</ElementPath>
<SoapAction>
http://tempuri.org/GiveMeData
</SoapAction>
<Method Namespace="http://tempuri.org/"
Name="GiveMeData">
</Method>
</Query>
When i try to run the query, it returns my four columns, but there is no data in the columns. it just returns one empty row.
what am i doing wrong?i don't know what i was doing wrong, but i got the example working.
But now i have a new problem and was hoping someone can help me?
I'm still following this example:
http://msdn2.microsoft.com/en-us/library/aa337489.aspx
I've changed the web method to return a dataset that has a datatable added to it. here is my code:
DataSet ds = new DataSet("Results");
DataTable dt = new DataTable("Results");
dt.Columns.Add("FirstName");
dt.Columns.Add("LastName");
dt.Columns.Add("Address");
dt.Columns.Add("City");
dt.Columns.Add("State");
dt.Columns.Add("PhoneNumber");
DataRow row = dt.NewRow();
row["FirstName"] = "Bob";
row["LastName"] = "The Builder";
row["Address"] = "10 My Street";
row["City"] = "Sydney";
row["State"] = "NSW";
row["PhoneNumber"] = "123456";
dt.Rows.Add(row);
ds.Tables.Add(dt);
return ds;
the query in Reporting Services doesn't return any data. It doesn't throw an error, it just returns one empty row.
Thanks for your help.
No comments:
Post a Comment