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
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Trouble modifying example

Thread ID:





21756 Nov 19,2004 10:44 AM UTC Nov 19,2004 11:55 AM UTC WinForms 1
Tags: GridControl
Asked On November 19, 2004 10:44 AM UTC

I''m trying to duplicate your "Customized Cell Buttons" example in my application. However, I want to use a larger bitmap that displays text and i want the button centered in the column. I''ve changed about everything in that example and cannot seem to get it to behave as I want. I''ve changed most of the numeric data in an attempt to make the button bigger or show in the center of the column, and nothing happens. Any chance i could get you to show me the way?

Administrator [Syncfusion]
Replied On November 19, 2004 11:55 AM UTC

In the EllipsisCell.cs file, in OnLayout, make this change. //buttonsBounds[0] = GridUtil.CenterInRect(rightArea, new Size(20, 20)); buttonsBounds[0] = GridUtil.CenterInRect(innerBounds, new Size(40, 40)); In the EllipsisCellModel constructor, make this change. //base.ButtonBarSize = new Size(20, 20); base.ButtonBarSize = new Size(40, 40); Also, make sure the row height for these cells are taller than 40. With these changes, I think you should see your centered larger buttons. I do not know where you want the text, but you should make your OnLayout return a bounding textrectangle so the grid knows where you want it. You may also want to tweak OnQueryPrefferedClientSize.


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

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

Live Chat Icon For mobile
Live Chat Icon