Microsoft KB Archive/890211

= FIX: The cells are not cleared when you set the Datasource property to NULL on cells that have a custom DataGridColumnStyle property in the .NET Framework 1.1 =

Article ID: 890211

Article Last Modified on 12/3/2007

-

APPLIES TO


 * Microsoft .NET Framework 1.1 Service Pack 1

-





SYMPTOMS
When a DataGrid control's DataSource property is set to NULL, all cells are cleared and an empty grid is displayed. However, if you apply a custom DataGridColumnStyle property to the DataGrid control and you click a cell before you set the DataSource property to NULL, the selected cell is not cleared and still appears in the grid.



CAUSE
This problem occurs because the following behavior occurs when the DataSource property of a DataGrid control is set to NULL:
 * The content of the selected cell is not cleared.
 * The image of the contents of the cell continues to appear.

This problem occurs when the following conditions are true:
 * A DataGridColumnStyle property has been applied to the DataGrid control.
 * The Microsoft .NET Framework 1.1 Service Pack 1 (SP1) has been installed.



RESOLUTION
A supported hotfix is now available from Microsoft, but it is only intended to correct the problem that is described in this article. Only apply it to systems that are experiencing this specific problem. This hotfix may receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next .NET Framework 1.1 service pack that contains this hotfix.

To resolve this problem immediately, contact Microsoft Product Support Services to obtain the hotfix. For a complete list of Microsoft Product Support Services telephone numbers and information about support costs, visit the following Microsoft Web site:

http://support.microsoft.com/contactus/?ws=support

Note In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question.

The English version of this hotfix has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.   Date         Time   Version            Size    File name ---  17-Nov-2004  05:57  1.1.4322.2048   2,052,096  System.windows.forms.dll



WORKAROUND
To work around this problem, call the GridColumnStyles.Clear method to clear the column styles before you set the DataSource property to NULL.



STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the &quot;Applies to&quot; section.



MORE INFORMATION
For more information, click the following article numbers to view the articles in the Microsoft Knowledge Base:

888528 A list of the bugs that are fixed in the .NET Framework 1.1 Service Pack 1 but are not described elsewhere in individual Microsoft Knowledge Base articles

824684 Description of the standard terminology that is used to describe Microsoft software updates

Keywords: kbhotfixserver kbqfe kbfix kbbug KB890211

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.