We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Image in header

Thread ID:

Created:

Updated:

Platform:

Replies:

52764 Dec 4,2006 06:46 AM Dec 5,2006 05:36 AM Windows Forms 7
loading
Tags: GridControl
Administrator [Syncfusion]
Asked On December 4, 2006 06:44 AM

Hi Surti,

Here is a forum thread that discuss with simillar issue.
http://www.syncfusion.com/support/Forums/message.aspx?&MessageID=48719

Best Regards,
Haneef

Surti
Replied On December 4, 2006 06:46 AM

Hellow,

could i show an icon or an image in a header cell?

Thanks,
Surti.

Administrator [Syncfusion]
Replied On December 4, 2006 07:01 AM

Thanks, i want to show the image alinged to the center because now is showed alinged to the left, is it posible???

>Hi Surti,

Here is a forum thread that discuss with simillar issue.
http://www.syncfusion.com/support/Forums/message.aspx?&MessageID=48719

Best Regards,
Haneef

Administrator [Syncfusion]
Replied On December 4, 2006 07:50 AM

Hi Surti,

Use the NumberedColumnHeader property to turn off the number in a column header of the grid. Andthen you can handle the DrawCell event to draw the center aligned image in a column header cell. Please try the attached sample and let me know if this helps.

Sample : GCColumnHeaderImage.zip

Best Regards,
Haneef

Administrator [Syncfusion]
Replied On December 4, 2006 10:55 AM

Great!!! Thanks!!! But now i have another question...

Can i do the same out of the event "DrawCell". Could i create a function that works like the event.

>Hi Surti,

Use the NumberedColumnHeader property to turn off the number in a column header of the grid. Andthen you can handle the DrawCell event to draw the center aligned image in a column header cell. Please try the attached sample and let me know if this helps.

Sample : GCColumnHeaderImage.zip

Best Regards,
Haneef

Administrator [Syncfusion]
Replied On December 5, 2006 02:10 AM

Hi Surti,

This can be achieved by using a custom celltype in a grid. It requires a model class and a renderer class. The model class handles the serialization requirements for the control and creates the renderer class. The renderer class handles the UI requirements of the cell.

Please refer to the below sample for more details.
GCColumnHeaderImage_9ec11c0d.zip

Best Regards,
Haneef

Administrator [Syncfusion]
Replied On December 5, 2006 04:52 AM

please, could you send me VB.NET code???

Thanks,
Surti

>Hi Surti,

This can be achieved by using a custom celltype in a grid. It requires a model class and a renderer class. The model class handles the serialization requirements for the control and creates the renderer class. The renderer class handles the UI requirements of the cell.

Please refer to the below sample for more details.
GCColumnHeaderImage_9ec11c0d.zip

Best Regards,
Haneef

Administrator [Syncfusion]
Replied On December 5, 2006 05:36 AM

Hi Surti,

Here is a VB sample.
VBSample.zip

Best Regards,
Haneef

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;