Microsoft

Use Wingdings to add graphics to Access forms and reports

Embedding pictures in your Access forms may create a nice effect, but it consumes a ton of resources. Here's a simple trick that lets you add a graphical touch without all that overhead: Use the Wingdings font.
You can insert a symbol or picture into a form or report, but embedded graphics consume a lot of resources. You can get a similar effect without embedding a file by using the Wingdings font. This alternative is easy to implement and produces satisfactory results most of the time. For instance, you might be surprised to learn that the phone icon in the following form is actually a combination of the Chr() function and the Wingdings font, not an embedded graphic. To add the Wingding, do the following:

  1. Open the form in Design view and add a text box in the desired location.
  2. Enter =Chr(40) as the control's Control Source property.
  3. Set the following properties as follows:

  • Back Style: Transparent
  • Back Color: Enter the appropriate value to match the section's Back Color property.
  • Special Effect: Flat
  • Border Style: Transparent
  • Font Size: Adjust as necessary; the example uses 20.
  • Font Name: Wingdings
View the form in Form view. If the graphic isn't completely visible, return to Design view and resize the text box, accordingly. If you don't disable the control (by setting the Enabled property to No), users can select the text box. Depending on the effect you're after, you can combine the Back Color and other properties to change the appearance when selected. For instance, you might want the control's background color to turn red when selected. If you disable the control, users won't be able to select the text box, but Access will dim it. This easy technique has potential:
  • You can use the control's Click event to execute some action. For instance, clicking the Phone graphic might dial the current number.
  • You can use a bound text box to update the Chr() function's argument and allow the record to determine the graphic.
Now, you're probably wondering which values produce specific Wingdings. Alan Wood has just what you're looking for -- bookmark the page if you plan to use this technique. Use the appropriate Dec value in his chart as the Chr() function's value.

About

Susan Sales Harkins is an IT consultant, specializing in desktop solutions. Previously, she was editor in chief for The Cobb Group, the world's largest publisher of technical journals.

4 comments
mwb78
mwb78

But I love the option. I am often digging around using the Insert Symbol function in Word or using the Webdings and Wingdings for bullets. Your link to the character codes for Wingdings was helpful, but what about all the Wingdings or Webdings. Until I find a consolidated chart, I can always use Insert Symbol in Word to find the symbol I want and have the dialog box give me the character code. Thanks for a new way to think about my Access objects.

ssharkins
ssharkins

If someone finds a comprehensive chart, I hope the post a link here!

ssharkins
ssharkins

Yes, the entry does include a link to a chart -- it's the best I found -- don't know if it's complete, but very good.

Editor's Picks