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.
Syncfusion Feedback

DataGrid - Alignment when using custom DataGridTextBoxColumn styl

Thread ID:

Created:

Platform:

Replies:

29893 Jun 6,2005 10:42 AM Windows Forms 0
loading
Tags: FAQ
Randall Cornish
Asked On June 6, 2005 10:42 AM

I have implemented the DataGridTextBoxColumn code that allows a particular cell to have custom formatting (DataGrid FAQ 5.67). This code was straight-forward and I had no trouble making it do what I wanted - bold the last row in the grid. However, when implementing this code, I seem to have lost the ability to influence the Horizontal alignment at the Column level. if (j == 1 || j == 2) { cs.Alignment = HorizontalAlignment.Center; cs.Width = 100; } Both examples I have seen on this Paint() event handler seem to also have ALL the cells left-aligned. Do I now need to implement another event handler to get my alignment ability back? Thanks,

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.

Warning Icon 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.Close Icon

;