Unable to Display Uppercase W in Small Text Box (87770)



The information in this article applies to:

  • Microsoft Visual Basic Standard Edition for Windows 2.0
  • Microsoft Visual Basic Standard Edition for Windows 3.0
  • Microsoft Visual Basic Professional Edition for Windows 2.0
  • Microsoft Visual Basic Professional Edition for Windows 3.0
  • Microsoft Visual Basic Standard Edition for Windows 1.0

This article was previously published under Q87770

SYMPTOMS

An uppercase W character may fail to display in the smallest possible size text box on a Microsoft Visual Basic for Windows form with the default FontSize (8.25) and FontName (Helv or Helvetica) selected. All other uppercase letters display correctly.

CAUSE

Because the uppercase letter W is the widest of the uppercase letters in the Helv 8.25 font, and it is slightly wider then the width of the smallest possible Visual Basic text box, there is not enough room to display the letter. Therefore, nothing appears in the text box.

RESOLUTION

This situation is limitation of the text box control in Microsoft Visual Basic for Windows. Avoid the problem by using a different font for the text box or by increasing the size of the text box.

MORE INFORMATION

Steps to Reproduce Behavior

  1. Start Visual Basic, or from the File menu, choose New Project (ALT, F, N) if Visual Basic is already running. Form1 is created by default.
  2. Add the smallest possible text box to display the letter T in the word Text1 of the text box to Form1.
  3. Press F5 to run the example. Activate the CAPS LOCK key and type an uppercase W.
In Windows version 3.0, the letter W does not appear in the text box. Instead, a space appears as if you had pressed the SPACEBAR.

In Windows version 3.1, the letter W appears not to be entered. It appears as if it is ignored.

For further testing, try other uppercase letters. There should be no problem with displaying other uppercase letters.

Modification Type:MajorLast Reviewed:12/12/2003
Keywords:KB87770