Note that the "M" in the icon stands for ModelName. The idea of the report is that it looks at the maps selected set of features and generates a report based on a configuration XML (Telvent.SE.ReportTools.Config.XML). Essentially it reports out each item in the selected set if that feature is in the configuration list. if it is in the configuration list, then all of the fields that you specify are reported. Below is an example of the output based on the XML snippet shown below:
<SelectionByModelNameReport>
<ClassModelName name="ControllableFitting" primaryField="FacilityID" fields="fACILITYID,OBJECTID" />
<ClassModelName name="Valve" primaryField="FacilityID" fields="ObjectID,FacilityID,InServiceDate,CreationUser,ValveType,ValveUse,ValveDiameter" />
<ClassModelName name="Pipe" primaryField="OBJECTID" fields="ObjectID,PipeType,PipePressure,Shape_Length" />
<ClassModelName name="Regulator" primaryField="FacilityID" fields="FacilityID,ObjectID" />
<ClassModelName name="NonControllableFitting" primaryField="FacilityID" fields="FacilityID,ObjectID" />
<ClassModelName name="ServicePoint" primaryField="FacilityID" fields="FacilityID,LocationID,Premise" />
</SelectionByModelNameReport>
Unlike Brook's reports, this does not use an XSLT style sheet. Instead it uses a template HTML file. The file is named, SelectionByModelNameTemplate.htm, and must be located in the same directory as the reports .dll and the configuration file. If you are familiar with HTML, it should be easy to modify this template file. You will see two special placeholder locations within the HTML file. ***GENERATED_DATE***, and ***TABLE***. These two areas are overwritten during the creation of the report.
As you can see from the output, you can have one specific field which is shown with a brown background color which acts as the Primary field. Typically this would be FacilityID or maybe ObjectID. The comma separated list of fields in the configuration XML then specifies which fields you want to see in the report.
Like some of the other reports on the Reports toolbar, you can right-click and have the relevant feature blink in the map.
Update - This report was just modified to add support for images. The ShowImages attribute is now required. If ShowImages is set to "True", then the other parameters shown in the working XML snippet below become mandatory as well.
<SelectionByModelNameReport>
<ClassModelName name="ControllableFitting" primaryField="FacilityID" fields="FacilityID,ObjectID" showImages="False" />
<ClassModelName name="Valve" primaryField="FacilityID" fields="FacilityID,ObjectID" showImages="True" imagePrompt="True" imageHeight="300" imageWidth="300" imageResolution="96" imageScale="500" imageTempPath="c:\temp\images" imageClearSelection="False"/>
<ClassModelName name="Pipe" primaryField="ObjectID" fields="FacilityID,ObjectID,LastUser,NominalDiameter,PipeType" showImages="True" imagePrompt="True"
imageHeight="100" imageWidth="150" imageResolution="96" imageScale="1500" imageTempPath="c:\temp\images" imageClearSelection="True"/>
<ClassModelName name="Regulator" primaryField="FacilityID" fields="FacilityID,ObjectID" showImages="False" />
<ClassModelName name="NonControllableFitting" primaryField="FacilityID" fields="FacilityID,ObjectID" showImages="False" />
<ClassModelName name="ServicePoint" primaryField="FacilityID" fields="FacilityID,ObjectID" showImages="False" />
</SelectionByModelNameReport>


No comments:
Post a Comment