This is a migrated thread and some comments may be shown as answers.

AutoGeneratingColumn event not working in a Custom Control

3 Answers 136 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Sachin
Top achievements
Rank 1
Sachin asked on 16 May 2011, 10:29 AM
Hello Everyone,
I am new to Silverlight 4.0. I am creating a custom control using Telerik RadGridView for Silverlight. My aim is to do all the generic handling like formatting of cells, text alignment and so on, in the custom control. I don't want any end developer to code for such generic handling. To handle such logic I am using the AutoGeneratingColumn event of the RadGridView in which I am applying the text alignment for coulumns, headers etc.. The event gets fired in the custom control, but I don't see any changes in the Grid. It gives a default formatting of text alignment.
I am stuck in this for a week now, tried everything that I could on net, but couldn't get hold of anything.

A help in this would be well appreciated.

Thanks In Advance.

3 Answers, 1 is accepted

Sort by
0
Ivan Ivanov
Telerik team
answered on 16 May 2011, 12:22 PM
Hello Sachin,

I have created a very simple custom control that inherits from RadGridView and while testing it with our latest binaries I have never faced such an issue. I am attaching the project for your reference. Would you please send us your implementation, in order to help us find the problem and provide better support for your case. Please, excuse us for the inconvenience.

Best wishes,
Ivan Ivanov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Sachin
Top achievements
Rank 1
answered on 16 May 2011, 01:06 PM

Thanks Ivan for you reply.

I tried the example that you have attached, yes it working fine. However, I am looking to create an custom control inheriting RadGridView. Here I am unable to attach the event in the CustomControl through xaml. So, I have explicitly subscribed for the AutoGeneratingColumn event.

I possibly think it is the issue with the sequence of methods that fire while I am subscribing to the AutoGeneratingColumns event in my CustomControl.

Normal scenario, things are working fine, however, when I am using the RadGridView in a custom control it is kinda mess.

Can you please provide me with an example of using RadGridView in a Custom Control?

0
Ivan Ivanov
Telerik team
answered on 16 May 2011, 01:57 PM
Hello Sachin,

May I kindly ask you to send me your custom control implementation or at least give me a very detailed information on its internal structure. It is extremely difficult for me to guess the source of this issue, so I will need a proper starting point, in order to continue providing support for this problem. Excuse me for the inconvenience.

All the best,
Ivan Ivanov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
GridView
Asked by
Sachin
Top achievements
Rank 1
Answers by
Ivan Ivanov
Telerik team
Sachin
Top achievements
Rank 1
Share this question
or