Reloading a webform page
-
Hi, I'm completely new to this theme and I have the following problem: I want to reload the page via code like a serverside button does (PostBack event should be triggered), when beeing clicked. So, how can i achieve that? Till now I didn't find any proper function looking in the System.Web.UI.Page class and using the meta tag reloads the site but triggers no PostBack event. Thanks. BTW: I'm using webforms and c#
-
Hi, I'm completely new to this theme and I have the following problem: I want to reload the page via code like a serverside button does (PostBack event should be triggered), when beeing clicked. So, how can i achieve that? Till now I didn't find any proper function looking in the System.Web.UI.Page class and using the meta tag reloads the site but triggers no PostBack event. Thanks. BTW: I'm using webforms and c#
hi, you can cause postback with JS:
var form = document.getElementById(formID) form.submit;
This will have same effect like user hitting submit button. best regards, David 'DNH' Nohejl Never forget: "Stay kul and happy" (I.A.) -
Hi, I'm completely new to this theme and I have the following problem: I want to reload the page via code like a serverside button does (PostBack event should be triggered), when beeing clicked. So, how can i achieve that? Till now I didn't find any proper function looking in the System.Web.UI.Page class and using the meta tag reloads the site but triggers no PostBack event. Thanks. BTW: I'm using webforms and c#
How do you plan to trigger this reload? Is it the result of a button press or ?? If it's the result of a button press (running at the server), then chances are the page is already posting back (unless you've changed the default behavior of the button). If you're trying to do it from the client side, then you're most likely going to have to use script, as the previous post suggests, unless you're using one of the Html controls that includes a ServerClick event.
The most exciting phrase to hear in science, the one that heralds the most discoveries, is not 'Eureka!' ('I found it!') but 'That's funny...’
-
How do you plan to trigger this reload? Is it the result of a button press or ?? If it's the result of a button press (running at the server), then chances are the page is already posting back (unless you've changed the default behavior of the button). If you're trying to do it from the client side, then you're most likely going to have to use script, as the previous post suggests, unless you're using one of the Html controls that includes a ServerClick event.
The most exciting phrase to hear in science, the one that heralds the most discoveries, is not 'Eureka!' ('I found it!') but 'That's funny...’
BTW, this question really belongs in the ASP.Net forum, not this one.
The most exciting phrase to hear in science, the one that heralds the most discoveries, is not 'Eureka!' ('I found it!') but 'That's funny...’