Archive for November, 2006|Monthly archive page

CodeDom in an IServerObjectExtension

ServerObjectExtensions in 9.2 provide an efficient way to do “fine grain” stuff in AGS.  For example, looping through each feature in a large featureclass and intersecting it with some other geometry to produce a System.Data.Dataset.

I wonder if it would be possible to make a generic ServerObjectExtension that takes source code passed in as an argument, compiles & runs it (via CodeDOM), and returns a Dataset? Or better yet, perhaps it would be possible to take a spatial SQL statement, transform it into C# code, then pass that to the ServerObjectExtension.  Granted, Spatial SQL should now be supported in ArcSDE 9.2  for Oracle, but this approach should work for SQLServer too.


Thanks to scrappad for pointing out a site that I think illustrates why RasterGraphicsLayer would be a useful addition for AGS 9.3.

Look at these heatmaps.

ServerObjectExtension to export Crystal Report to pdf

I ran into a problem creating a pdf with AGS9.2. When I export a layout, the TableFrame elements do not appear. This seems to be a known issue/limitation. OK, fine, I thought, I’ll just use crystal reports to export a Dataset to pdf via the ReportDocument. But nooo, I kept getting an exception saying :”Access to report file denied. Another program may be using it”.

I tried several workarounds. But none solve the problem. So I went ahead and wrote a server object extension and it worked just fine. Seems like Crystal Reports XI just doesn’t like running within the ASPNET process space. Fortunately, the same code ran just fine within the SOC. Next step is concatenating the layout pdf onto the report pdf with aspose pdf.