Hi
What kind of report do you want? A HTML table? Here is a code snippet to
generate a html table from a MapGuide query result .You can also generate a pdf
by calling pdf realated API, I think it is nothing related to MapGuide API any
more.
<code_begin>
String layerFeatureIdString = layer.GetFeatureSourceId();
MgResourceIdentifier layerResId = new
MgResourceIdentifier(layerFeatureIdString);
MgFeatureQueryOptions queryOptions = new
MgFeatureQueryOptions();
queryOptions.SetFilter(selectString);
MgFeatureReader featReader =
featureService.SelectFeatures(layerResId, layerClassName, queryOptions);
outString = outString + "<table border=\"1\">\n";
double acre = 0;
while (featReader.ReadNext())
{
outString = outString + "<tr>\n";
outString = outString + "<td>";
outString = outString + featReader.GetString("RNAME");
outString = outString + "</td>\n";
outString = outString + "<td>";
outString = outString + featReader.GetString("RPROPAD");
outString = outString + "</td>\n";
outString = outString + "<td>";
String acreString = featReader.GetString("RACRE");
acre = acre + (acreString == "" ? 0 :
Convert.ToDouble(acreString));
outString = outString + acreString;
outString = outString + "</tr>\n";
}
outString = outString + "</table>\n";
featReader.Close();
<code_end>
From: [email protected]
[mailto:[email protected]] On Behalf Of Spencer Trevor
Sent: 2009年4月1日 17:16
To: [email protected]
Subject: [mapguide-users] after query generate a report
hi there,
do anyone have a sample or a code to generate a report?
what i want to do is, first i want to do a simple query and then i want to
generate a report base on the query that i have perform earlier.
do anyone have a sample or a code to generate a report?
thank you in advance.
regards.
Spencer Trevor
________________________________
Nama E-mel baru untuk anda!
<http://sg.rd.yahoo.com/my/mail/domainchoice/mail/signature/*http:/mail.promotions.yahoo.com/newdomains/my/>
Dapatkan nama E-mel yang telah lama anda mahukan pada @ymail dan @rocketmail
yang baru.
Cepat sebelum orang lain mendapatkannya!
_______________________________________________
mapguide-users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/mapguide-users