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

RadDock and dynamic content

13 Answers 477 Views
Dock
This is a migrated thread and some comments may be shown as answers.
Pat
Top achievements
Rank 1
Pat asked on 09 Aug 2007, 03:09 PM
I have a RadDock on a page and in the code behind, I added some content to it by

RadDock.ContentContainer.Clear();
RadDock.ContentContainer.Add(RadPanelBar);

When the page loads, I don't get any content in the RadDock.

What needs to transpire to get this to work?

Thanks!

I decided to also try something else.
I added the panelbar to the dock and then referenced it in the code behing and updated the panelbar with items.  When the process was complete, I still didn't have anything showing on the page for that Dock.  BTW, I am using an updatepanel for the processing that is taking place and the Dock that I am updating is located in a masterpage. 

Thanks.

13 Answers, 1 is accepted

Sort by
0
Petya
Telerik team
answered on 09 Aug 2007, 03:39 PM
Hello Pat,

The correct syntax is RadDock.ContentContainer.Controls.Add(RadPanelBar);
I am attaching a simple page demonstrating how to add a label in RadDock's content container on PageLoad. Hope this helps.

Greetings,
Petya
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Pat
Top achievements
Rank 1
answered on 09 Aug 2007, 06:06 PM
Thanks for the quick reply but I can't load the control via the page_load.

Here is the scenario:

I have a master page that has a RadDock on it.  I need to populate it with a radpanel from the content page.  The RadPanel that gets created in the contentpage can't load it during page_load because the data that it needs hasn't populated yet.  The data get loaded after page_load but prior to page_loadcomplete.  So in trying to load the radpanel to the RadDock on the masterpage, I dont' get anything.  I have tried to load it during page_load but there is no data to process it.  I have tried to load it in the page_LoadComplete but the instantiation of the controls have already occurred and the radpanel doesn't render.

Any ideas on how to resolve?

Thanks. 
0
Petya
Telerik team
answered on 10 Aug 2007, 06:57 AM
Hi Pat,

We would need more information about your case because with the provided details it is not possible for us to reproduce the issue. Would it be possible for you to create a simple running project demonstrating what you are trying to achieve and we will try to modify it so that you get the expected results. You need to open a support ticket to be able to attach files. I am attaching instruction how to do so. Looking forward to your reply.

Kind regards,
Petya
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Pat
Top achievements
Rank 1
answered on 10 Aug 2007, 04:57 PM
I will need to work on getting a solution together for you.

But in the mean time, here is what I am needing to do:

I need to update a radpanel that resides inside a RadDock on a master page from the click event of a content page.  I am able to make the updates but because the masterpage has already executed it's page_load, the radpanel doesn't update with the new information.  The button click event in the content page collects data that needs to be displayed in the radpanel so the update needs to come from that click event.

Is there some way to get this to work?

Thanks.
Pat.
0
Petya
Telerik team
answered on 13 Aug 2007, 11:48 AM
Hello Pat,

Your configuration is not a simple one - obviously AJAX is involved as well since you are using an UpdatePanel. Therefore, we would really need a simple running project to see the whole picture and try to discover the problem and provide a solution.

Greetings,
Petya
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Pat
Top achievements
Rank 1
answered on 13 Aug 2007, 06:52 PM
I may have this partially fixed.  I posted about another error when I placed a prometheus AjaxManager on the master page.  I receive the following error now and I have looked it over and can't find any issues in how it is defined. The error I am getting now is "

Telerik.Web.UI.RadDockZone can contain only controls of type Telerik.Web.UI.RadDock

0
Petya
Telerik team
answered on 14 Aug 2007, 07:25 AM
Hi Pat,

We have done some testing lately with RadDock being ajaxified by RadAjaxManager and for now we came to the conclusion that this does not work well in most scenarios due to the specifics in both controls. We strongly encourage you to use ASP.NET UpdatePanel to ajaxify those parts of your project where RadDock is involved. As far as your specific error message is concerned, it appears when you place some control different from RadDock in a RadDockZone using RadDock Prometheus. This was possible with the "regular" RadDock but not with Prometheus.

Regards,
Petya
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Pat
Top achievements
Rank 1
answered on 14 Aug 2007, 01:06 PM
In regards to the error message, it appears that the ajaxmanager or something else is adding an update panel to surround the raddock and that was triggering the error.  I hadn't added anything outside of a raddock in the raddockzone.

In regards to using an update panel.  Are you saying to wrap the radpanelbar that is inside the raddock with an update panel and use the ajaxmanager to update the panel?  Can I still use the ajaxmanager for the button in the content page along with the ajaxmanagerproxy?

0
Petya
Telerik team
answered on 14 Aug 2007, 01:23 PM
Hello Pat,

If you need to perform an ajax callback that updates the content of a RadDock, then it would be best to place an UpdatePanel inside RadDock and place all RadDock's content inside this panel. Afterwards, you need to set an async trigger for this UpdatePanel. If you use AjaxSettings of RadAjaxManager to achieve this it will not work as I wrote in my previous post.

Best wishes,
Petya
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Pat
Top achievements
Rank 1
answered on 14 Aug 2007, 02:13 PM
I've finally got some dynamic content getting into the raddock but another issue seems to have come up.  Whenever you move the RadDock now (after creating the dynamic content) and place it into another zone, the content disappears. 
0
Petya
Telerik team
answered on 14 Aug 2007, 03:33 PM
Hi Pat,

There could be different reasons for this to take place. On moving the dock to another zone does a postback take place (have you set RadDock's property autopostback=true)? Are you re-adding the dock's content every time because if you are adding the content on !IsPostBack then on the next postback the content will be lost.

 I am going to ask you once again to send us your code as it is not possible to predict what could be happening without seeing the whole picture. You see that without code it takes us a couple of posts to discuss a simple matter and helping you takes much longer than it would if we could see the code. I kindly ask you to provide us with a simple running project and tell us what you try to achieve and we will provide accurate assistance as soon as possible.

Best wishes,
Petya
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
ashish
Top achievements
Rank 1
answered on 28 Sep 2007, 06:15 AM
Can you give an example on using Prometheus RaDock with Prometheus Ajax Manager ? I am getting the error 

Telerik.Web.UI.RadDockZone can contain only controls of type Telerik.Web.UI.RadDock

When I add the ajax settings for Prometheus Ajax Manager.

I tried putting an Update Panel inside the RadDock Content Container, but it does not help

0
Valeri Hristov
Telerik team
answered on 28 Sep 2007, 09:10 AM
Hello ashish,

We strongly recommend updating only the content of the RadDock controls, e.g. you should add AjaxSetting for the content, not the control itself. Another thing is that RadAjax is still unable to add AjaxSettings with AJAX requests, so it will not work well within dynamic scenarios, such as the PortalSite demo on top of this forum. In this case we recommend using UpdatePanel controls and avoiding RadAjax.
http://www.telerik.com/community/forums/thread/b311D-mkttd.aspx

Sincerely yours,
Valeri Hristov (Senior Developer, MCSD)
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
Dock
Asked by
Pat
Top achievements
Rank 1
Answers by
Petya
Telerik team
Pat
Top achievements
Rank 1
ashish
Top achievements
Rank 1
Valeri Hristov
Telerik team
Share this question
or