IconFileName method
Sets a custom icon file for a menu or toolbar item.
Version added
4.0
Syntax
| |
object |
Required. An expression that returns a Menu, MenuItem, or ToolbarItem that loads the icon file. |
fileString |
Required String. The path and name of the ICO, EXE, DLL, or VSL file to load. |
N |
Optional Integer. The icon resource location. If you are using an EXE, DLL, or VSL file, N specifies the location of the icon in the file, beginning with zero (0). |
Remarks
The IconFileName method loads the file that contains the icon, saves the bits, and discards the file name.
If the icon contains multiple images, Visio always uses the 16x16 (16-color) image.
Unless fileString is a fully qualified path, the application searches for the ICO, EXE, DLL, or VSL file in the folders indicated by the Application object's AddonPaths property (assuming that the UIObject object is in the Visio process).