473,387 Members | 1,535 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Auto Postback Issue

Hi,

I've added a button control in my webpage, and called a onClick event.

However it will always go back to the page load, then execute my onClick
event.

Is there a way which I can bypass page load??

Regards


Nov 17 '05 #1
6 2048
If you want to skip some operations that are made in the Page Load, then you
can construct an if clause as
If not IsPostBack then
..operations you want to make in the load event...
End If

"yoyo" <ju******@hotmail.com> wrote in message
news:#X**************@TK2MSFTNGP12.phx.gbl...
Hi,

I've added a button control in my webpage, and called a onClick event.

However it will always go back to the page load, then execute my onClick
event.

Is there a way which I can bypass page load??

Regards

Nov 17 '05 #2
If you want to skip some operations that are made in the Page Load, then you
can construct an if clause as
If not IsPostBack then
..operations you want to make in the load event...
End If

"yoyo" <ju******@hotmail.com> wrote in message
news:#X**************@TK2MSFTNGP12.phx.gbl...
Hi,

I've added a button control in my webpage, and called a onClick event.

However it will always go back to the page load, then execute my onClick
event.

Is there a way which I can bypass page load??

Regards

Nov 17 '05 #3
You need to understand the event flow and sequence. During
postback the page load function is called before the
onClick event.
If u need to stop some action in the page load, u need to
use Page.IsPostBack to check if the page is called as the
first request or post back request and act accordingly.
Does this answer your question?
-----Original Message-----
Hi,

I've added a button control in my webpage, and called a onClick event.
However it will always go back to the page load, then execute my onClickevent.

Is there a way which I can bypass page load??

Regards


.

Nov 17 '05 #4
You need to understand the event flow and sequence. During
postback the page load function is called before the
onClick event.
If u need to stop some action in the page load, u need to
use Page.IsPostBack to check if the page is called as the
first request or post back request and act accordingly.
Does this answer your question?
-----Original Message-----
Hi,

I've added a button control in my webpage, and called a onClick event.
However it will always go back to the page load, then execute my onClickevent.

Is there a way which I can bypass page load??

Regards


.

Nov 17 '05 #5
I get what you mean. But there's some actions in the page load that will be
used by other events.

And there's no way I can detect that the event comes from this onClick event
and stop a particular action.

So now I am researching whether I can go straight to the onClick function
without going to the page load.
"Ravi Sankar" <ra*****@lycos.com> wrote in message
news:03****************************@phx.gbl...
You need to understand the event flow and sequence. During
postback the page load function is called before the
onClick event.
If u need to stop some action in the page load, u need to
use Page.IsPostBack to check if the page is called as the
first request or post back request and act accordingly.
Does this answer your question?
-----Original Message-----
Hi,

I've added a button control in my webpage, and called a

onClick event.

However it will always go back to the page load, then

execute my onClick
event.

Is there a way which I can bypass page load??

Regards


.

Nov 17 '05 #6
I get what you mean. But there's some actions in the page load that will be
used by other events.

And there's no way I can detect that the event comes from this onClick event
and stop a particular action.

So now I am researching whether I can go straight to the onClick function
without going to the page load.
"Ravi Sankar" <ra*****@lycos.com> wrote in message
news:03****************************@phx.gbl...
You need to understand the event flow and sequence. During
postback the page load function is called before the
onClick event.
If u need to stop some action in the page load, u need to
use Page.IsPostBack to check if the page is called as the
first request or post back request and act accordingly.
Does this answer your question?
-----Original Message-----
Hi,

I've added a button control in my webpage, and called a

onClick event.

However it will always go back to the page load, then

execute my onClick
event.

Is there a way which I can bypass page load??

Regards


.

Nov 17 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Rhys | last post by:
I have a page which has an IFrame on it. The src of the IFrame is a page with a datagrid on it. The Datagrid has bound template columns. The columns of the datagrid pass the bound data value of...
5
by: Psych971 | last post by:
Hi, I'm wondering how I can generate a postback using javascript on a page that does not have any controls with the auto-postback property set to true. I know I can just use the submit() function...
4
by: nicholas | last post by:
Hi, On this page you can see a dropdown with auto postback: http://www.b2blearning.be/en/planning.aspx When you change the dropdown, the planning dates are populated. But if you do that a few...
9
by: junlia | last post by:
Does anyone how how can we disable the auto-postback feature in asp.net page? I have to use a server side control in the page, but the auto post back feature in it causes problems for me. Please...
5
by: Tom Anderson | last post by:
I am currently having an issue with an ASP.Net 1.1 Web page that does the following remotely but not locally. Click on a control Check for postback, if postback, handle the event, otherwise...
0
by: Achim Domma (SyynX Solutions GmbH) | last post by:
Hi, in my application I suddenly get the error: "An error has occurred because a control with auto-generated id 'main:institutionManagement:institutionOverview' could not be located to raise...
3
by: teo | last post by:
Mozilla error on postback and validation ----------- A Button causes a Listbox to desappear. If no item has been selected on the Listbox, all is OK. If one or more items are selected,
2
by: =?Utf-8?B?QW1pciBUb2hpZGk=?= | last post by:
Hi I have a web page that has a TreeView on it. If I DONT'T expand the TreeView nodes, the auto refresh works nicely: my page gets refreshed every minute. As soon as I expand a node on the...
3
by: =?Utf-8?B?Y21lZWsxXzE5OTk=?= | last post by:
Hello, On a webpage, create an UpdatePanel with two DropDownLists. Set AutoPostBack of DropDownList1 to true. In the SelectedIndexChanged method, refill DropDownList2 and set the focus to...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.