RadDock and dynamic content

14 posts, 0 answers
  1. Pat
    Pat avatar
    31 posts
    Member since:
    Aug 2007

    Posted 09 Aug 2007 Link to this post

    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.
  2. Petya
    Admin
    Petya avatar
    869 posts

    Posted 09 Aug 2007 Link to this post

    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
  3. Pat
    Pat avatar
    31 posts
    Member since:
    Aug 2007

    Posted 09 Aug 2007 Link to this post

    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. 
  4. Petya
    Admin
    Petya avatar
    869 posts

    Posted 10 Aug 2007 Link to this post

    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
  5. Pat
    Pat avatar
    31 posts
    Member since:
    Aug 2007

    Posted 10 Aug 2007 Link to this post

    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.
  6. Petya
    Admin
    Petya avatar
    869 posts

    Posted 13 Aug 2007 Link to this post

    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
  7. Pat
    Pat avatar
    31 posts
    Member since:
    Aug 2007

    Posted 13 Aug 2007 Link to this post

    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

  8. Petya
    Admin
    Petya avatar
    869 posts

    Posted 14 Aug 2007 Link to this post

    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
  9. Pat
    Pat avatar
    31 posts
    Member since:
    Aug 2007

    Posted 14 Aug 2007 Link to this post

    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?

  10. Petya
    Admin
    Petya avatar
    869 posts

    Posted 14 Aug 2007 Link to this post

    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
  11. Pat
    Pat avatar
    31 posts
    Member since:
    Aug 2007

    Posted 14 Aug 2007 Link to this post

    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. 
  12. Petya
    Admin
    Petya avatar
    869 posts

    Posted 14 Aug 2007 Link to this post

    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
  13. ashish
    ashish avatar
    28 posts
    Member since:
    Jun 2012

    Posted 28 Sep 2007 Link to this post

    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

  14. Valeri Hristov
    Admin
    Valeri Hristov avatar
    2252 posts

    Posted 28 Sep 2007 Link to this post

    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
Back to Top