I want to know how can i create an crystal report from a XML (XML is from a Web Service), I read in some tutorials that it needs to locate the file and drag the fields in the report, but how about a XML from a Web Service?
Here is the code how I get the XML from a Web Service
var doc = XDocument.Parse(trx.GetCardTrx("xxxxx", "xxxx", "xxx", "", dateTimePicker1.Text, dateTimePicker2.Text, "", "", "", "", "", "", "", "", "", "", "", "FALSE", "", "", "", "", "", "", "", "", "", "", ""));
MessageBox.Show(doc.ToString());
So this code return this kind of values (From MessageBox.Show(doc.ToString()
)
And here is the code for the selected values that should be in the report
var summary = from r in doc.Descendants("TrxDetailCard")
select new
{
Account_Type = r.Element("Account_Type_CH").Value,
Captured = r.Element("Captured").Value,
Trans_Type_ID = r.Element("Trans_Type_ID").Value,
Acct_Num_CH = r.Element("Acct_Num_CH").Value,
Tip_Amt_MN = r.Element("Tip_Amt_MN").Value,
Total_Amt_MN = r.Element("Total_Amt_MN").Value,
Date_DT = r.Element("Date_DT").Value,
};
And What I want to happen is that to create a report using Crystal Reports with this values, not all values. Selected values only. How can I possibly do this? Any ideas will be a big help Thank you :D