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

getting columns From ChildTableDefination

13 Answers 98 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Ganesh Jagdale
Top achievements
Rank 1
Ganesh Jagdale asked on 19 Jan 2010, 02:01 PM
Hi telerik,

I have added relation in RadGridView using ChildTableDefination at runtime for showing multilevel hirarchy.
But I want to access columns in ChildTableDefination for changing its width so that it will same as parent ColumnWidth.

So how to get Columns from ChildtableDefination... OR is there any other way to access Grid which is shown as child(which is added due to adding ChildTableDefination)?.

Pls help me to solve this issue..

It help me a lot
Thanks .
Ganesh

13 Answers, 1 is accepted

Sort by
0
Vlad
Telerik team
answered on 22 Jan 2010, 07:09 AM
Hi Ganesh,

You can use DataLoaded event of the child grid to access child grid columns.

Best wishes,
Vlad
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Ganesh Jagdale
Top achievements
Rank 1
answered on 25 Jan 2010, 08:26 AM
Hi Vlad ,
Thanks for replying..
But I want to access Child Grid in event  like
 1] LayoutChanged Event
 2] by adding DependancyProperty  of event "OnColumnWidthChanging"

This is beacause I want to change Child grid ColumnWidth on resizing parent Grid which is added using ChildTableDefination with Relation.
U said that use "DataLoaded event " but I want to fire event on Resizing Parent ColumnWidth which can be possible using above two event.
Pls help me ...
For solving this .. I have spend a lot time ..

Thanks ,
Ganesh

0
Pavel Pavlov
Telerik team
answered on 28 Jan 2010, 01:06 PM
Hi Ganesh Jagdale,

I am currently preparing an online demo with synchronized column widths of parent and child grid s in hierarchy. I will do my best to have it online in a day or two. I will post you the link as soon as it is online.

All the best,
Pavel Pavlov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Ganesh Jagdale
Top achievements
Rank 1
answered on 28 Jan 2010, 03:23 PM
Hi Pavel Pavlov ,

Thanks a lot for replying..
Yes it is very usefull to me and also good functionality.
Resultant Grid looks very nice when it is achived because there will be  no partition between column Width of child and parent  even  after resizing Parent Grid. 

I will waiting for ur reply..
 Pls send me the link  as soon as it is online. ..

Thanks a lot once again ..

Thanks and Regards,
 Ganesh

0
Pavel Pavlov
Telerik team
answered on 03 Feb 2010, 02:44 PM
Hi Ganesh Jagdale,

Please excuse me for the late response. I am attaching  a sample application where the child columns are synchronized with the parent columns.
Let me know if you find troubles adapting this toi your project.

Regards,
Pavel Pavlov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Ganesh Jagdale
Top achievements
Rank 1
answered on 04 Feb 2010, 11:59 AM
Hi Pavel Pavlov ,

Thank's a lot Pavel. This is the best solution for me. Even I worked for multilevel Hirarchy with littile bit changes in

"ColumnWidthChangedCallBack"..
Now in that I have DataPager attached to that Grid.
When I have shows all childs say upto 3 levels and change page Index. That all childs are shriken means they are not appear as same way  as before changing page index..
For solving this is there any chaged in Dependancy propetry?
 Or something I have to specify propery of RadGridView Or DataPager.

What I have to do again call our ColumnWidthChangedCallBack event again so that it will again change childs Grid Column Grid.

Pls Help me Pavel...
And One more thing
 Is there any document or book so that I easily implement  DependencyProperty for any control because it is very difficult for me.
 Even the PDF given on your site is also not include this DependancyProperty implementation.
If u have any document pls Share with me if possible..

Thanks a lot one again..

Thanks and Regards
Ganesh

 

 

 

 

 
0
Pavel Pavlov
Telerik team
answered on 05 Feb 2010, 12:56 PM
Hello Ganesh Jagdale,

RadGridView exposes RadGridView.ExpandAllHierarchyItems() method . When called  in the right place it should do the work for you .

On your second question : If I got the question right , I believe  this online article. will be in help.

Kind regards,
Pavel Pavlov
the Telerik team

Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Follow the status of features or bugs in PITS and vote for them to affect their priority.
0
Pavel Pavlov
Telerik team
answered on 05 Feb 2010, 01:34 PM
Hi Ganesh Jagdale,
Plsease excuse me , I forgot to paste the link , here it is :

http://msdn.microsoft.com/en-us/library/cc221408(VS.95).aspx

Kind regards,
Pavel Pavlov
the Telerik team

Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Follow the status of features or bugs in PITS and vote for them to affect their priority.
0
Ganesh Jagdale
Top achievements
Rank 1
answered on 15 Feb 2010, 10:31 AM
Hi Pavel,
            Thanks for giving me such a nice document.

I was asked this quetion :
I have DataPager attached to that Grid.
When I have shows all childs say upto 3 levels and change page Index. That all childs are shriken means they are not appear as same way  as before changing page index..

Your solution is :: use RadGridView.ExpandAllHirarchyItems()

this is works fine but it unnecesary expand all hirarchy which i doesn't want because I had shown child Grid Ondemand (clicking "+" sign)
I want to shown that  many  child Grid only not all Which I shown before changing PageIndex..

Pls help me....
 
Thanks, 
Ganesh  

 

0
Pavel Pavlov
Telerik team
answered on 18 Feb 2010, 09:34 AM
Hello Ganesh Jagdale,
There is not internal support for such behavior in RadGridView. However still you can do something -
You may use the

RadGridView.ExpandHierarchyItem()
and

RadGridView.CollapseHierarchyItem()

Using these you may store information about expanded/collapsed rows and after a paging operation - restore the state.

This is as close as e can get with the current version of RadGridView.


Sincerely yours,
Pavel Pavlov
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
Selvakumar Savarimuthu
Top achievements
Rank 1
answered on 30 Jun 2011, 09:04 AM
Hi,

Should the parent and child grid be a SelfReferencing Hierarchy for the column width sync to work?

Thanks,
Prasanna R
0
Pavel Pavlov
Telerik team
answered on 30 Jun 2011, 09:31 AM
Hello Selvakumar ,
I am not sure I understand the question. In general the type of hierarchy is not connected with the column width .

All the best,
Pavel Pavlov
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
Selvakumar Savarimuthu
Top achievements
Rank 1
answered on 30 Jun 2011, 12:14 PM
Hi Support,

Let me rephrase my question:

Today when we have a hierarchy grid in SL with the same headers, the column resizing works individually for parent and child. They aer not in sync. For getting this into sync, we found a code in one of your blog. Though that works, we were finding it difficult to achieve the same functionality for data loaded from 2 different ItemsSource with the same set of headers.

So my query was, would this work only if the parent and child grid in the hierarchy is Self referencing. That is to say, SelfReferencing = "true"?

Thanks,
Prasanna R
Tags
GridView
Asked by
Ganesh Jagdale
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Ganesh Jagdale
Top achievements
Rank 1
Pavel Pavlov
Telerik team
Selvakumar Savarimuthu
Top achievements
Rank 1
Share this question
or