Tools¶
Properties of a tool (if any) can be specified in the Properties window in MIKE Workbench.
Generate Report¶
Tool for generating a report.
Tool Info | |
---|---|
Display Name | Generate Report |
API Name | Generate Report |
Tools Explorer | /Report Tools/Generate Report |
NuGet Package | DHI.MikeOperations.ReportManager.Tools.GenerateReport |
Assembly name (.dll) | DHI.Solutions.ReportManager.Tools.GenerateReport.dll |
API Reference | DHI.Solutions.ReportManager.Tools.GenerateReport.IGenerateReportTool |
Input Items | A single report |
Output Items | A generated report handle containing report location and information |
Tool Properties
Display Name | API Name | Description |
---|---|---|
Settings | ||
Document Manager Path | DocumentManagerPath | Gets or sets the path in the document manager where the report is saved. Note that the property is only available when: SaveInDocumentManager=True |
Folder | OutputFolder | Gets or sets the folder where the generated report is saved. |
Save In Document Manager | SaveInDocumentManager | Gets or sets a value indicating whether the report should be saved in the document manager |
Code Sample
import clr
clr.AddReference("DHI.Solutions.ReportManager.Tools.GenerateReport")
from DHI.Solutions.ReportManager.Tools.GenerateReport import *
# Get the tool.
tool = app.Tools.CreateNew("Generate Report")
# Add input items.
tool.InputItems.Add(<A single report>)
# Set tool properties before executing the tool.
tool.Execute()
# Read the output from the list of output items.
output = tool.OutputItems
import clr
clr.AddReference("DHI.Solutions.ReportManager.Tools.GenerateReport")
from DHI.Solutions.ReportManager.Tools.GenerateReport import *
# Get the tool.
tool = DHI.Solutions.ReportManager.Tools.GenerateReport.IGenerateReportTool(app.Tools.CreateNew("Generate Report"))
# Add input items.
tool.InputItems.Add(<A single report>)
# Set tool properties before executing the tool.
tool.Execute()
# Read the output from the list of output items.
output = tool.OutputItems
// Get the tool.
var tool = application.Tools.CreateNew("Generate Report") as DHI.Solutions.ReportManager.Tools.GenerateReport.IGenerateReportTool;
// Add input items.
tool.InputItems.Add(<A single report>);
// Set tool properties before executing the tool.
tool.Execute();
// Read the output from the list of output items.
output = tool.OutputItems;
Runtime.config
What tools to load during application startup, is specified in the XML file Runtime.config
in the plugins section of the manager.
The XML below shows the tool plugin information found in the Runtime.config
file.
<Plugin
Name="DHI.Solutions.ReportManager.Tools.GenerateReport.GenerateReportTool"
Type="DHI.Solutions.Generic.ITool"
Assembly="DHI.Solutions.ReportManager.Tools.GenerateReport.dll" />