The TXText ╰ TX Text Control .NET for Windows Forms
╰ DocumentServer Namespace
TXTextControl.DocumentServer Namespace encapsulates the Text Control reporting functionality, the TXText ╰ TX Text Control .NET for Windows Forms
╰ DocumentServer.Fields Namespace
╰ FieldAdapter Class
The abstract FieldAdapter class is the base class of all special DocumentServer field adapters. , the TXText ╰ TX Text Control .NET for Windows Forms
╰ DocumentServer.DataSources Namespace
╰ DataSourceManager Class
The DataSourceManager class is designed for handling all existing kinds of data sources which can be used together with the MailMerge class. and also reporting dialog boxes that can be used in your applications.
These dialog boxes are ready-to-use for typical data selection tasks. The following dialog boxes are available:
-
ChartDataRelationDialog
This dialog is used to set the data relations for charts.The following code loads a data source into a new instance of a DataSourceManager and opens a chart data relation dialog for a selected chart frame in TextControl:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersDataSourceManager dsManager = new DataSourceManager(); dsManager.LoadSingleObject(report); TXTextControl.DocumentServer.Windows.Forms.ChartDataRelationDialog dlg = new ChartDataRelationDialog(textControl1.Charts.GetItem(), dsManager); dlg.ShowDialog(); The dialog lets the user select the parent and child tables that define the data relation and two data columns in the child table that are used as the x-axis label text and the actual data.
-
FilterAndSortDialog
This dialog is used to specify the filter and sorting settings for a merge block.The following code opens an instance of the dialog and passes the TXText
Control. Document Server. Data Shaping. Sorting Instruction class ╰ TX Text Control .NET for Windows Forms
╰ DocumentServer.DataShaping Namespace
╰ SortingInstruction Class
The SortingInstruction class contains merge block data sorting information such as the sort order and the column name to sort the data rows after. list to the TXTextControl. Document Server. Data Sources. Merge Block Info class ╰ TX Text Control .NET for Windows Forms
╰ DocumentServer.DataSources Namespace
╰ MergeBlockInfo Class
The MergeBlockInfo class is used to insert a table or paragraph based repeating merge block into a TextControl instance using the DataSourceManager.InsertMergeBlock method. :This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersDataSourceManager dsManager = new DataSourceManager(); dsManager.LoadSingleObject(report); FilterAndSortDialog filterSortDialog = new FilterAndSortDialog(dsManager.MasterDataTableInfo); filterSortDialog.ShowDialog(); MergeBlockInfo mergeBlockInfo = new MergeBlockInfo("TableName"); mergeBlockInfo.SortingInstructions = filterSortDialog.SortingInstructions.ToList(); -
DatabaseConnectionDialog
This dialog allows the user to build connection strings and to connect to specific data sources.The following code opens an instance of the dialog. The connection string is applied to the DataSourceManager:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersDataSourceManager dsManager = new DataSourceManager(); dsManager.LoadSingleObject(report); TXTextControl.DocumentServer.Windows.Forms.DatabaseConnectionDialog dlg = new DatabaseConnectionDialog(dsManager); dlg.ShowDialog(); -
DataSourceExtractionDialog
This dialog allows the user to save an excerpt from the currently loaded data source. An upper limit of extracted data rows can be specified in the dialog.The following code opens an instance of the dialog. The dialog returns the filename, the maximum number of exported rows and the selected DataTable:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersDataSourceManager dsManager = new DataSourceManager(); dsManager.LoadSingleObject(report); TXTextControl.DocumentServer.Windows.Forms.DataSourceExtractionDialog dlg = new DataSourceExtractionDialog(dsManager); dlg.ShowDialog(); var fileName = dlg.FileName; var maxRows = dlg.MaxRows; var selectedTable = dlg.SelectedTable; -
EditDataRelationsDialog
This dialog allows the user to add or remove data relations to or from the current data source.The following code opens an instance of the dialog. The relations are applied to the connected DataSourceManager automatically:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersDataSourceManager dsManager = new DataSourceManager(); dsManager.LoadXmlFile("sample_db.xml"); TXTextControl.DocumentServer.Windows.Forms.EditDataRelationsDialog dlg = new EditDataRelationsDialog(dsManager); dlg.ShowDialog(); -
EditMergeBlocksDialog
This dialog allows the user to remove or rename merge blocks contained in the current document.The following code opens an instance of the dialog with a connected TextControl instance that has merge blocks added to a document:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersDataSourceManager dsManager = new DataSourceManager(); dsManager.LoadSingleObject(report); TXTextControl.DocumentServer.Windows.Forms.EditMergeBlocksDialog dlg = new EditMergeBlocksDialog(dsManager, textControl1); dlg.ShowDialog(); -
InsertMergeBlockDialog
This dialog allows the user to design and insert a merge block based on the currently selected master table. It is inserted at the current input position of a given TextControl instance.The following code opens an instance of the dialog with a connected TextControl instance and the selected DataTableInfo object:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersDataSourceManager dsManager = new DataSourceManager(); dsManager.LoadSingleObject(report); TXTextControl.DocumentServer.Windows.Forms.InsertMergeBlockDialog dlg = new InsertMergeBlockDialog(dsManager, textControl1, dsManager.DataTables["Products"]); dlg.ShowDialog();
Text Control comes with out-of-the-box UI elements to create powerful reporting applications. At the same time, it is completely customizable and programmable.