radajaxmanager

6 posts, 0 answers
  1. Webster Velasco
    Webster Velasco avatar
    114 posts
    Member since:
    Jun 2012

    Posted 25 Feb 2010 Link to this post

    hi

    i want to fire a click event of a button from code behind w/o making a post back using radajaxmanager..

    here is what i want to do:

    from my master page i open a pop up

    then the pop up window on close will register some session which i want to retrieve..

    at pop up close i want to fire the btn click event

    w/o making post back

    is thath possible?.

    cn u provide me the code plz?

    thanks in advance

    regards
    webster
  2. Iana Tsolova
    Admin
    Iana Tsolova avatar
    3388 posts

    Posted 25 Feb 2010 Link to this post

    Hi Webster,

    You can handle the window OnClientClose client-side event and there invoke the button click:

    function OnClientClose(sender, eventArgs)
    {
        $get("<%= MyButton.ClientID %>").click();
    }

    Another option is to use the _doPostBack() client method.

    Sincerely yours,
    Iana
    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.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Webster Velasco
    Webster Velasco avatar
    114 posts
    Member since:
    Jun 2012

    Posted 26 Feb 2010 Link to this post

    this will prevent postback?
  5. Iana Tsolova
    Admin
    Iana Tsolova avatar
    3388 posts

    Posted 26 Feb 2010 Link to this post

    Hello Webster,

    This will fire the Button click event. As far as I understood from your description, this is what you wanted, to fire a Button click event on popup close, right?

    All the best,
    Iana
    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.
  6. Webster Velasco
    Webster Velasco avatar
    114 posts
    Member since:
    Jun 2012

    Posted 26 Feb 2010 Link to this post

    yes but when the page do post back i loose the value of my textbox(which is in read only) that i get from this function:
             function OnClientClose(sender, args) { 
                    //var arg = eventArgs.split("|") 
                     
                    //alert("chiudo"); 
                    // valori: 
                    // 0 --> NomeSP 
                    // 1 --> Codice Ritorno 
                    // 2 --> Descrizione Ritorno 
                    // 3 --> Quale Controllo da Valorizzare 
                     
                    var arg = args.get_argument(); 
                    var QualeControllo;  
                    var QualeLabel; 
                                     
                    if(arg != null){ 
                        var oArg = arg.Oggetto.split("|"); 
                        switch  (oArg[3]) 
                        { 
                            case "txtCOMUNE": 
                                QualeControllo = document.getElementById("<%= txtCOMUNE.ClientID %>"); 
                                QualeLabel = document.getElementById("<%= COMUNE_Descr.ClientID %>"); 
                                break; 
                            case "txtCOMUNENASCITA": 
                                QualeControllo = document.getElementById("<%= txtCOMUNENASCITA.ClientID %>"); 
                                QualeLabel = document.getElementById("<%= COMUNENASCITA_Descr.ClientID %>"); 
                                break; 
                        }    
                         
                        QualeControllo.value = oArg[1]; 
                        QualeLabel.value = oArg[2]; 
                        
                    } 
                }  

  7. Iana Tsolova
    Admin
    Iana Tsolova avatar
    3388 posts

    Posted 01 Mar 2010 Link to this post

    Hi Webster,

    Could you please send us a runnable sample illustrating your scenario and the issues you are facing? You can try opening a formal support ticket where you can attach the project files.
    I could then debug it locally and find a proper resolution for you. Otherwise it would hard to determine the source of the problem based on the provided information.

    Looking forward your reply,
    Iana
    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.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017