PC Review


Reply
Thread Tools Rate Thread

DataGrid column header text painting problem

 
 
Shravan Kumar
Guest
Posts: n/a
 
      21st Oct 2003
Hi,
I am using my code to set column widths of datagrid
columns dynamically, but when I am setting the column
widths to zero, the header text of the column whose width
is made to zero is appearing on the existing column
headers, and the text gets blurred with the painting of
the column text along with the adjacent width 0 column.

Anybody, can you please give me a solution for it

Thanks,
Shravan.
 
Reply With Quote
 
 
 
 
Dmitriy Lapshin [C# / .NET MVP]
Guest
Posts: n/a
 
      21st Oct 2003
Hi,

Sounds like a bug in the DataGrid control. As a workaround, you could
probably set the column header text to an empty string when you make its
width equal to zero.

--
Dmitriy Lapshin [C# / .NET MVP]
X-Unity Test Studio
http://x-unity.miik.com.ua/teststudio.aspx
Bring the power of unit testing to VS .NET IDE

"Shravan Kumar" <(E-Mail Removed)> wrote in message
news:033a01c397bd$1210cd50$(E-Mail Removed)...
> Hi,
> I am using my code to set column widths of datagrid
> columns dynamically, but when I am setting the column
> widths to zero, the header text of the column whose width
> is made to zero is appearing on the existing column
> headers, and the text gets blurred with the painting of
> the column text along with the adjacent width 0 column.
>
> Anybody, can you please give me a solution for it
>
> Thanks,
> Shravan.


 
Reply With Quote
 
Shravan
Guest
Posts: n/a
 
      21st Oct 2003
Is there any chance of a other easy workaround, since I
have derived datagrid and used a lot of code to support
our functionality which will be disturbed if I use header
text changing dynamically.
>-----Original Message-----
>Hi,
>
>Sounds like a bug in the DataGrid control. As a

workaround, you could
>probably set the column header text to an empty string

when you make its
>width equal to zero.
>
>--
>Dmitriy Lapshin [C# / .NET MVP]
>X-Unity Test Studio
>http://x-unity.miik.com.ua/teststudio.aspx
>Bring the power of unit testing to VS .NET IDE
>
>"Shravan Kumar" <(E-Mail Removed)>

wrote in message
>news:033a01c397bd$1210cd50$(E-Mail Removed)...
>> Hi,
>> I am using my code to set column widths of datagrid
>> columns dynamically, but when I am setting the column
>> widths to zero, the header text of the column whose

width
>> is made to zero is appearing on the existing column
>> headers, and the text gets blurred with the painting of
>> the column text along with the adjacent width 0 column.
>>
>> Anybody, can you please give me a solution for it
>>
>> Thanks,
>> Shravan.

>
>.
>

 
Reply With Quote
 
Shravan
Guest
Posts: n/a
 
      21st Oct 2003
Hi All,

Thanks a lot for the concern, I have found a simple
workaround for the problem.

Just setting the horizontalalignment of the column with
width 0 to left removed the painting problem

Shravan.
>-----Original Message-----
>Is there any chance of a other easy workaround, since I
>have derived datagrid and used a lot of code to support
>our functionality which will be disturbed if I use header
>text changing dynamically.
>>-----Original Message-----
>>Hi,
>>
>>Sounds like a bug in the DataGrid control. As a

>workaround, you could
>>probably set the column header text to an empty string

>when you make its
>>width equal to zero.
>>
>>--
>>Dmitriy Lapshin [C# / .NET MVP]
>>X-Unity Test Studio
>>http://x-unity.miik.com.ua/teststudio.aspx
>>Bring the power of unit testing to VS .NET IDE
>>
>>"Shravan Kumar" <(E-Mail Removed)>

>wrote in message
>>news:033a01c397bd$1210cd50$(E-Mail Removed)...
>>> Hi,
>>> I am using my code to set column widths of datagrid
>>> columns dynamically, but when I am setting the column
>>> widths to zero, the header text of the column whose

>width
>>> is made to zero is appearing on the existing column
>>> headers, and the text gets blurred with the painting of
>>> the column text along with the adjacent width 0 column.
>>>
>>> Anybody, can you please give me a solution for it
>>>
>>> Thanks,
>>> Shravan.

>>
>>.
>>

>.
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to increase DataGrid column header text size venkateswarag@gmail.com Microsoft Dot NET Compact Framework 2 5th Dec 2007 07:08 PM
Wrap the Datagrid Header column Text like Excel =?Utf-8?B?U3Vubnk=?= Microsoft Dot NET Framework Forms 0 6th Oct 2006 05:12 PM
'wrap text' in column header in a datagrid? =?Utf-8?B?YW1iZXI=?= Microsoft Dot NET 1 30th Sep 2005 05:15 PM
Setting column header text of datagrid in PreRender... Do You know how to do it? Adam Boczek Microsoft ASP .NET 4 5th Dec 2004 07:28 PM
Datagrid Column Header Text Demetri Microsoft ASP .NET 0 21st Apr 2004 08:03 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:58 AM.