<XLS> tag
The XLS tag can be used to specify different actions on the excel sheet, add formulas or draw a chart...
XLS tag has no action on standard vpxPrint report, it just specifies additional actions for Excel export.
Syntax :
<XLS:Excel_Action_List>
Setting of header and footer :
<XLS-LEFT-HEADER=left header value>
<XLS-CENTER-HEADER=center header value>
<XLS-RIGHT-HEADER=right header value>
<XLS-LEFT-FOOTER=left footer value>
<XLS-CENTER-FOOTER=center footer value>
<XLS-RIGHT-FOOTER=right footer value>
Before sending any command through the OLE link, vpxPrint replaces sequences in the <XLS> tag:
•%Ais replaced by the first column identification,
•%Z" " " " last " " " " "
•%1is replaced by the first line number,
•%9is replaced by the last line number
•%Xis replaced by the column identification pointed by X
•%Yis replaced by the line number pointed by Y
Note that vpxPrint evaluates % variables when processing individual entries and not before processing the full sequence of commands.
That means that you can write (example) :
<XLS:CHART,X=%A,X++,SELECT=%X,VALUES>
(chart source is set to the 2nd column of the Excel array)
The Excel_Action_List parameter is a comma delimited list where each entry may be one of the following :
Keyword |
Explanation |
Note |
CHART |
Draws a chart on the current excel sheet. The default is a vertical '3D Pie exploded' chart with all the data of the sheet. Default value is the last column. The syntax of the CHART keyword is : CHART [=xlChartConstant ] where xlChartConstant is the value of the chart type (Excel constants) |
|
SELECT |
Selects a range of cells in the current sheet.
Syntax: SELECT=valid_excel_range
The specified value must be an Excel valid range syntax. |
The notation is in format A1. Examples: SELECT=A1:C10 SELECT=%A%1:C%9
|
XVALUES |
Sets the current selected range as the X values for the graph |
After CHART and SELECT |
VALUES |
Sets the current selected range as the values for the graph |
After CHART and SELECT |
NAME |
Names the current selection |
After SELECT |
X |
sets a column descriptor. Syntax: X= number sets X to a given column X+1 increase X by 1 FIRST sets X to the first column LAST sets X to the last filled column -OR- X++ increase X by 1 -OR- X- - decrease X by 1 -OR- X=%A X=%Z |
Examples: X=3 X++ X=X+1 |
Y |
Sets a line descriptor. Syntax: Y= number sets X to a given line Y+1 increase Y by 1 FIRST sets X to the first line LAST sets X to the last filled line -OR- Y++ increase Y by 1 -OR- Y- - decrease Y by 1 -OR- Y=%1 Y=%9 |
|
SAVE |
Saves the Excel workBook with the given name. Syntax: SAVE=filename |
|
FORMULA |
Inserts an Excel formula in the selected range area. Syntax: FORMULA=Excel_Formula |
After SELECT |
VALUE |
Sets the current selected range to this value. Syntax: VALUE=xxxxxxxxxxxxxxxxxxxxx |
After SELECT |
HOR |
Switches to an horizontal serie (CHART orientation defaults to vertical if HOR is not specified) |
After CHART |
TITLE |
Chart title. Syntax: TITLE=xxxxxxxxxxxxxxxxxxxxxxxxxxxx |
After CHART |
SOURCE |
Sets the current selected range as the chart source. |
After CHART and SELECT |
VISIBLE |
Sets the Excel window as visible. |
|
Examples:
<XLS:CHART>
<XLS:SELECT=%A%1:C%9,CHART,HOR>