The information in this article applies to:
SUMMARYThe Visual Basic for Applications MacID function is unique to the Macintosh platform and can be used when you use the Kill, Shell, Dir, and AppActivate functions. Because the Macintosh does not support wild cards, you can instead use the MacID function to specify the file type of a group of files. MORE INFORMATION
The following macro code examples use the MacID function, as well as the
equivalent Microsoft Excel for Windows code. Q82980 Excel: Unexpected Quit Under Macintosh System 7.0.x Kill Statement
This will delete all text files in the current directory.
Dir Function
This will return the name of the first Microsoft Excel file in the
specified folder to the variable "myfile." Note that in the Macintosh
example, you need to follow the specified folder with a colon.
Shell Function
This will start Microsoft Word from within your Microsoft Excel macro, and
in the Windows example, assumes that Microsoft Word is in the
C:\Msoffice\Winword folder. If the Shell function successfully runs the
named file, it returns the task identification (ID) of the started program
to the variable "myprog". The task ID is a unique number that identifies
the running program.
AppActivate Statement
This will activate Microsoft Word from within you Microsoft Excel macro.
NOTE: In order for the AppActivate Statement to work, you must first have
the application started.
REFERENCESFor more information about the MacID Function, click the Index tab in Microsoft Excel Help, type the following text
and then double-click the selected text.
Additional query words: 5.00a 98 XL98 XL5 Mac ID
Keywords : xlmac |
Last Reviewed: September 22, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |