Contents - Index


EXCEL. (Macro Commands)

 

EXCEL.Cell('A1','text' or EES variable)

This command will set information into the specified cell of a previously opened EXCEL worksheet.  The command requires two parameters.  The first parameter indicates the cell location.  It may be a string constant (enclosed within single quotes) or a string variable.  The letter provides the column and the number provides the row.  The second parameter can be text (enclosed within single quotes) or an EES string or numerical variable. If a numerical EES variable is provided, the value corresponding to the EES variable will be assigned to the cell using the numerical format assigned to the EES variable.  If a string variable is provided, the text assigned to the string variable will be assigned to the cell.

 

EXCEL.Copy('C10:C11')

Copy the text in the specified cell range of the active EXCEL worksheet to the Clipboard.  Once copied, the information on the Clipboard can be moved into EES variables using the Import macro command or into a table using the Paste Parametric or Paste Lookup macro commands.

 

EXCEL.FileNew

Start EXCEL if it is not already open and create a new empty worksheet.

 

EXCEL.FileOpen('FileName')

Start EXCEL and open the specified EXCEL file.  It is necessary to provide the complete file name, including the filename extension, e.g., 'C:\EES32\USERLIB\EXAMPLES\EXCEL_WS1.xlsx'.

 

EXCEL.FileSaveAs('FileName')

Save the current EXCEL file with the specified filename. It is necessary to provide the complete file name, including the filename extension, e.g., 'C:\EES32\USERLIB\EXAMPLES\EXCEL_WS1.xlsx'.

 

EXCEL.Hide

Hide the open EXCEL application.

 

EXCEL.Open

Open the EXCEL program.  This command must be the first EXCEL macro command in the macro file.  The EXCEL.Open command can be issued even if EXCEL is already open.

 

EXCEL.Paste

Paste the current contents of the Clipboard into EXCEL at the current selection point.  (See EXCEL.RANGE)

 

EXCEL.RANGE('A2:C4')

Set the selection for the active EXCEL worksheet.  In this example, A2 is the upper left corner of the selection and C4 is the lower right corner of the selection.  To set the insertion point for a paste operation, set the upper left and lower right corners to the upper left of the insertion point, e.g., 'A1:A1'.

 

EXCEL.Quit  

Close EXCEL and shut down communication.  Don't use the EXCEL.Quit command until you are completely done using EXCEL as it is time-consuming to reopen EXCEL.

 

EXCEL.Sheet('Sheet2')

Activate the EXCEL sheet with the given name in the current EXCEL application.  If this sheet does not exist, a new sheet having this name will be created and activated.

 

EXCEL.Show

Make the open EXCEL worksheet visible.

 

MacroCommands