BUG: Grid: No Error Changing FixedAlignment on Non-Fixed Col

Last reviewed: June 21, 1995
Article ID: Q81998
The information in this article applies to:

- Professional Edition of Microsoft Visual Basic for Windows,

  versions 2.0 and 3.0
- Microsoft Professional Toolkit for Microsoft Visual Basic programming
  system for Windows, version 1.0

SYMPTOMS

Using the Grid custom control, setting the text alignment of a non-fixed column with the FixedAlignment property will not generate an error. Though this value is saved, it does not affect the text alignment of the specified non-fixed column.

STATUS

Microsoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.

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. From the File menu, choose Add File (CTRL+F12), and select GRID.VBX to add the Grid control to the Toolbox. The Grid tool appears in the Toolbox.

  3. Add a Grid control to Form1.

  4. Add the following code to the Grid_Click event procedure:

       Sub Grid_Click ()
          Grid1.ColWidth(1)=2000
          Grid1.Col=1
          Grid1.Row=1
          Grid1.Text="Hello"
          Grid1.FixedAlignment(1)=1  'Right Justify
       End Sub
    
    

  5. From the Run menu, choose Start (ALT, R, S) to run the program.

Notice that when you click the grid, the FixedAlignment property accepts the new value, but the alignment of the text does not change.

Note that if you try to do the opposite (that is, attempt to set the text alignment of a fixed-column with the ColAlignment property), an "Invalid Column" error message will be displayed.


Additional reference words: buglist1.00 buglist2.00 buglist3.00 1.00 2.00
3.00
KBCategory: kbprg kbbuglist
KBSubcategory: PrgCtrlsCus


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: June 21, 1995
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.