I think I need javascript to call server side function

Last post 05-15-2008 7:28 AM by okkko. 1 replies.

Sort Posts:

  • I think I need javascript to call server side function

    05-14-2008, 8:49 AM
    • Loading...
    • fatthippo
    • Joined on 08-30-2006, 2:52 PM
    • Posts 84

    Hello!I have a multi-view control in  my project. Each time a user clicks, proceeds to the next panel. In one of the panels I have an AJAX setup that does not have any server side links or  controls in it. How can I call a server side function without a server control that would tell the page to move to the next panel in my multiview? It would have to be through Javascript but clarification on how to implement this. When the user clicks, the app needs to also save his selection to a server side variable. So I need two things
    1. save prefernce to server side variable
    2. Advance to next panel in multi-view.

    Any insight would surely be appreciated.
    Thanks in adavance!!!!

  • Re: I think I need javascript to call server side function

    05-15-2008, 7:28 AM
    Answer
    • Loading...
    • okkko
    • Joined on 01-08-2008, 6:32 AM
    • Slovenia
    • Posts 70

    Hmm... try to be more specific.

    Where does user click? If you have a button you can simply use the ServerClick method and then it's also easy to save his selection.

    You might also want to set the trigger in the UpdatePanel for your control to cause a postback or async postback if you have the "conditional" UpdateMode.

    Or try Me.ScriptManager1.RegisterPostBackControl(myControl) in the Page_PreRender event.
     

Page 1 of 1 (2 items)