Show code in...     

  

 

ExcelTemplate Methods: AnsiToUnicode ContentType DataSource Open
PreserveStrings Process SpreadsheetsCreatedToday UnicodeToAnsi


ExcelTemplate ASP Reference

Open Method


Syntax:
Public Void ExcelTemplate.Open(FileName As String)
Description:

Opens an ExcelWriter template* spreadsheet, that is, a file created in Microsoft Excel that contains data markers where values will be inserted. A data marker is a cell value beginning with "%%=" that specifies a database column, variable, or array to insert in the spreadsheet column containing the marker (see DataSource).

*

In the ExcelWriter documentation, the term "template" refers to an ExcelWriter template, not a Microsoft Excel template (.xlt). However, ExcelWriter can open and generate both .xls and .xlt files. Use an .xlt file the same way you would an .xls file.

The Open method takes one parameter, the file path and name of the template .xls file to open.

Example:
objTemplate.Open "c:\templates\template.xls"
Note:

The ExcelTemplate object supports Excel's BIFF8 (Excel 97/2000/XP) format only; ExcelTemplate does not support BIFF7 (Excel 95) format templates, and will not generate BIFF7 format files.


Copyright © 2005, SoftArtisans, Inc.