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. Image for the cookie policy date
close icon

Cell borders

Hi

I am having trouble setting different styles for borders in the same cell. For example, I want a single line bottom border but no top, left or right border. I have tried many combinations for CellFormat properties but can't get it to work. The following is my latest attempt:

fieldCell.CellFormat.Borders.Bottom.LineWidth = 0.5f;
fieldCell.CellFormat.Borders.Bottom.BorderType = BorderStyle.Single;
fieldCell.CellFormat.Borders.Top.LineWidth = 0f;
fieldCell.CellFormat.Borders.Top.BorderType = BorderStyle.None;
fieldCell.CellFormat.Borders.Left.LineWidth = 0f;
fieldCell.CellFormat.Borders.Left.BorderType = BorderStyle.None;
fieldCell.CellFormat.Borders.Right.LineWidth = 0f;
fieldCell.CellFormat.Borders.Right.BorderType = BorderStyle.None;

Any advice on how to achieve this would be welcome.

Adrian

1 Reply

JA Jafrin Syncfusion Team October 29, 2009 03:17 PM UTC

Hi Adrian,

Thank you for your patience.

We are able to see the mentioned issue in “Table border style”. You can workaround this issue by setting “BorderStyle.Cleared” instead of using “BorderStyle.None”. Could you please find the sample from the below link.

Patch:
http://files.syncfusion.com/support/DocIO.Web/Forum/90979/CellBorderStyle.zip


Could you please report the issue through Direct Trac developer Support System https://www.syncfusion.com/account/login?ReturnUrl=%2fsupport%2fdirecttrac%2fincidents because you can have the solution from a support engineer and a guaranteed response time. Thank you for your participation in Syncfusion,s Community forum.

Please let us know if you have any questions.

Regards,
Jafrin J


Loader.
Live Chat Icon For mobile
Up arrow icon