PageViews, UserControls and updating between

5 posts, 0 answers
  1. RichJ
    RichJ avatar
    83 posts
    Member since:
    Aug 2006

    Posted 22 Mar 2012 Link to this post

    Hi all,

    I'm hoping someone can help with a problem I'm having concerning tabstrip, pageviews and ajax updates.

    I have a MultiPage in place with several tabs, and each tab relates to a PageView that in turn contains UserControls.
    I have a RadAjaxManager on the main page containing these tabs, and I'm also using a RadAjaxManagerProxy control on each of the UserControls.
    I need to communicate between two of these pageviews and usercontrols but I'm having a problem with a particular piece of functionality.
    To make it easier to understand I have a "Garment" tab/UserControl that allows customisation of a garment.  As a result of changes to the garment, I'd like to update a second tab/pageview ("Branding").  I currently have this working when an "Update" button is clicked on the garment tab that updates an ajaxed datalist on the branding tab (by calling a public subroutine).  It seems to work great.
    This is based on using an @ Reference tag on the Garment usercontrol, casting an object to this control and then calling the subroutine. 

    However, there is a situation where if a certain garment is selected, I'd like to be able to show/hide a placeholder on the Branding tab when a radcombobox selectedindexchanged event is fired.  I have a public sub on the Branding usercontrol that DOES get called (tested using ajaxpanel.alert), but the placeholders and other controls contained within it do not update.  This is doing my head in! :-)

    Can anyone suggest why the datalist in the Branding usercontrol can be updated based on an event on the Garment usercontrol, and that a subroutine IS being called for the placeholder update, but the PH doesn't update?

    I hope that makes sense and appreciate any insights you may have.

    Cheers
    Rich
  2. RichJ
    RichJ avatar
    83 posts
    Member since:
    Aug 2006

    Posted 22 Mar 2012 Link to this post

    More Info:  I have tried replacing the asp placeholder with a panel based on another post I found, but the problem remains.
    Also, there is no MasterPage/ContentPlaceHolders involved and none of the user controls are dynamic.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Maria Ilieva
    Admin
    Maria Ilieva avatar
    4017 posts

    Posted 27 Mar 2012 Link to this post

    Hello,

    Please note that single PageView (or control added in PageView) could not be added as AJAX initiator or updated control in the AJAX settings. The only possible approach is to add the whole MultiPage in the RadAjaxManager settings or wrap the whole control into RadAjaxPanel. When we set the MultiPage as an updated control, you should also include the TabStrip associated with it in the Ajax settings. You can review the following help topic which elaborates on this matter:
    http://www.telerik.com/help/aspnet-ajax/ajax-tips-and-tricks.html


    Kind regards,
    Maria Ilieva
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  5. RichJ
    RichJ avatar
    83 posts
    Member since:
    Aug 2006

    Posted 27 Mar 2012 Link to this post

    Hi Maria,

    Thanks for the response.
    This still doesn't explain how I was able to update an ajaxed datalist on the second user control?

    Rich
  6. Maria Ilieva
    Admin
    Maria Ilieva avatar
    4017 posts

    Posted 30 Mar 2012 Link to this post

    Hello,

    As I'm not aware with the exact code you are using for ajaxifying the UserControls I could not say why exactly in this specific case the UserControl has been updated. Even your approach works in some case as I already stated this is not a supported scenario and it could lead to many other issues like in your case.

    All the best,
    Maria Ilieva
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017