CygNet Excel Export

CygNet Excel Export is a sample usage of the CxExport dll automation interface to export data to a Microsoft Excel worksheet in tabular format. Using this feature, you can create reports from historical values, current values, or current values by group. The points included in the report can be specified using point identifiers, facility IDs/attributes and UDCs, or groups.

Notes:

The .dll can be used to create reports in a variety of applications, including Microsoft Excel,VBA, C++, Microsoft Word. CygNet Excel Export is a sample usage of the .dll with Excel, although it can be exercised completely outside of the Excel environment. Do not confuse this feature with the CygNet History Export (CExport.exe), which is a utility for exporting VHS-only data to a .csv file.

The CygNet Excel Export application replaced CygNet Excel Reports, which reached its official end of life in July 2007.

There are two dlls, CxExport.dll and CxExport64.dll, found in CygNet\Support\ and CygNet\Support64\ respectively. The 32-bit CygNet Excel Export (CxExport.dll) works with 32-bit Excel; the 64-bit CygNet Excel Export (CxExport64.dll) works with 64-bit Excel.

The CxExport dlls use native CygNet messaging.

How CygNet Excel Export Works

The CygNet Excel Export application is comprised of two software components:

The ExlRpt.xls file has two worksheets: Main and CygNet Data. The Main worksheet contains the report configuration information, including Auto Run parameters. The CygNet Data worksheet is the location where the exported data is stored.

The report configuration is performed in the Setup dialog box, which is accessed by clicking the Configure button on the Main worksheet. The Setup dialog box contains options for the report type, point specification, column specification, report format, and export file name.

Once you configure the report and click the Get CygNet Data button on the Main worksheet, the data is gathered and exported to a .csv file and then imported into the ExlRpt.xls file on the CygNet Data worksheet page.

If you configure the report to Auto Run, you can schedule it using a third-party scheduler, such as Microsoft’s Scheduled Tasks. Auto Run includes options for printing, exporting, and archiving the report. The export formats are comma-separated value (CSV) file, text (TXT), Hypertext Markup Language (HTML), or a Microsoft Excel Worksheet (XLS).

If the report contains a finite amount of points and values, you can add another worksheet to the .xls file for the final report. This worksheet can use references to cells on the CygNet Data worksheet page and contain formatting and functions.

Once you configure a report, save it with a unique file name otherwise it will be overwritten when version management occurs.

The ExlRpt.xls file contains macros, which must be enabled so that the data can be retrieved. See Installing and Configuring CygNet Excel Export for more information about enabling macros.

Report Limits

Be aware that the default Microsoft Excel report (ExlRpt.xls) is limited to 256 columns and 65,536 rows. A Microsoft Excel Macro-Enabled Workbook report (ExlRpt.xlsm) is limited to 16,384 columns and 1,048,576 rows. As such, the amount of data that you can include in a report is limited.

To convert an Excel .xls file to an .xlsm file, save as "Excel Macro-Enabled Workbook (*.xlsm)" file type. Close and then re-open the Excel file prior to testing it out, to allow the changes to take place within the Workbook and remove the file from compatibility mode. This is important, since compatibility mode can cause the column and row restrictions of an .xls file to persist.


More:

Back to top