How to Find Face ID Numbers for Your Microsoft Office 97 Toolbars

Written by darrin koltow
  • Share
  • Tweet
  • Share
  • Pin
  • Email
How to Find Face ID Numbers for Your Microsoft Office 97 Toolbars
Changing a toolbar button's face ID, or icon, doesn't change its function. (binary world image by Attila Toro from

The applications in Microsoft Office 97 have toolbars whose commands display icons. These icons have unique identifying numbers called face IDs associated with them. By changing a command's face ID, you can change its icon. Finding the face ID for a command is a task you can complete with Office's programming language, Visual Basic for Applications, or VBA. One step involved in finding a command's face ID is querying objects of the Office 97 object model -- a network of virtual objects representing Office's programmable elements. Finding the face IDs for Office 97 toolbars is a first step toward customising command icons.

Skill level:


  1. 1

    Open one of the Office 97 applications, then press "Alt"+"F11" to enter the VBA integrated development environment, or IDE.

  2. 2

    Click the "Insert" menu's "Module" command to open a new window for entering VBA source code.

  3. 3

    Paste the following program code into the code window. This program prints out to the IDE's "Immediate" window, a list showing all toolbar buttons and their face IDs. The "CommandBars" function provides a list of toolbars. Each toolbar has a list of controls that your program accesses through the toolbar's "Controls" function. Since not all toolbar commands have icons, the program would cause an error if it tried accessing the face ID of these commands. The program catches this error with the "On Error" statement.

    Public Sub showFaceIds()

    Dim x

    Dim i, j, cur Bar

    Dim s, curCtl

    Dim t

    Debug.Print "Description|Summary|Type|Face id"

    For i = 1 To CommandBars.Count

    Set cur Bar = CommandBars(i)

    For j = 1 To curBar.Controls.Count

    Set curCtl = curBar.Controls(j)

    s = curCtl.DescriptionText & "|" & curCtl.Caption & "|" & curCtl.Type

    On Error Resume Next

    s = s & "|" & curCtl.FaceId

    Debug.Print s

    Next j

    Next i

    End Sub

  4. 4

    Open the IDE's "Immediate" window by pressing "Control"+"G."

  5. 5

    Click one of the program's statements, then click the "Debug" menu's "Run" command to execute the program. The "Immediate" window will fill with the face ID and other properties of each toolbar command.

  6. 6

    Click inside the "Immediate" window, then select and copy all of its text.

  7. 7

    Open Word 97. Paste the text you just copied.

  8. 8

    Press "Control"+"A" to select all text, then click the "Table" menu's "Convert Text" item to open the dialogue box for converting plain text to a Word table. This conversion will make it easy to read the data.

  9. 9

    Type "|" (the pipe symbol) in the textbox that says "Other," then press "Enter" to create the table.

  10. 10

    Print out the document, then surf to the MSDN "Type Enumeration" page, which names each of the command button types referred to by your printout's "Type" column.

  11. 11

    Read the printout as follows: the first column relates the command's function, such as "Cut the Selection." The second column summarises that function. The third is a number representing the type of command (e.g., "Command Button," "Combo Box"). Refer to the page you surfed to in the last step to associate a name with this number. The printout's last column relates the face ID of the command.

Don't Miss

  • All types
  • Articles
  • Slideshows
  • Videos
  • Most relevant
  • Most popular
  • Most recent

No articles available

No slideshows available

No videos available

By using the site, you consent to the use of cookies. For more information, please see our Cookie policy.