473,796 Members | 2,916 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

!Page.IsPostBac k

Tim
I have dropdown list in Login page. The data is adding twice because the
Page_Load event is executing twice. But I am checking !Page.IsPostBac k
property. First time the value for '!Page.IsPostBa ck' is 'true'. When it goes
for second time it is not setting to 'false'. Please remember the '!' before
the property. Which is means that still it is not recognizing that the page
is loaded.

Basically the Login page is redirecting from the Authenticate page.

Any help please, thanks in advance.
Nov 16 '05 #1
1 6347
Tim wrote:
Basically the Login page is redirecting from the Authenticate page.

Redirection is not the same as a post back. The HTML form in the page
must be submitted to the server using HTTP POST to cause a postback.
Redirection just results in a HTTP GET, hence IsPostBack is false.

Anders Norås
http://dotnetjunkies.com/weblog/anoras/
Nov 16 '05 #2

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

Similar topics

1
2197
by: John Blair | last post by:
Hi, I post data to a url using HTTPWebRequest - my intention is to simulate user entry post back - however in my aspx code page.ispostback is false and textbox1.text say is empty but request.form("textbox1") has the data that i assigned i.e. the posted data gets to the page ok. How can i "fool" the aspx page into thinking this is a postback as i want the existing code in the form to access the posted data via textbox1.text i.e. much like...
5
2414
by: Tim | last post by:
To make !Page.IsPostBack to work, do I need to set any properties at page level or in the config files(Web, machine) or aspx files. Because code in under the !IsPostBack is executing twice and adding data twice to dropdown list control. any help please..Tim
5
2560
by: nly | last post by:
Page.IsPostBack Property "The Page_Load subroutine runs EVERY time the page is loaded. If you want to execute the code in the Page_Load subroutine only the FIRST time the page is loaded, you can use the Page.IsPostBack property. If the Page.IsPostBack property is false, the page is loaded for the first time, if it is true, the page is posted back to the server (i.e. from a button click on a form)..." Let's say we have this in a "body"...
14
1741
by: Mike | last post by:
I have a routine that i only want to execute if a variable is set to Y. The routine is getting some information on the screen then redirecting to a new page. How can i passed a variable to the Page.IsPostBack routine on the page_load event? this is what I'm trying to do/ sub page_load if page.ispostback then dim value as string = CType(Session("quesiton"), string)
1
1306
by: Jeff | last post by:
I assume that this is an easy newby question... How can I conditionally force the code in a "if not page.ispostback sub" to run even if the page is posting back? More specifically, I have a web application in VB (2005) which runs through a series of questions stored in a database. Answers to the questions are stored back into the database on the first page post back. The user then clicks a "next" button, which is intended to load the...
3
1962
by: Guy Noir | last post by:
Hello again. I have a form that has 2 buttons. When button 1 is pressed, I want the form to execute a few tasks and give the user feedback. When button 2 is pressed, I want the form to reload as if it is being called for the first time. That is, I want the code in Page_Load if (!Page.IsPostBack) to execute as if we are calling the page for the first time. I guess I could do a server redirect or whatever, but is there a more elegant...
2
2385
by: Joey | last post by:
This is causing us a lot of pain right now. Does anyone know why this happens and, more importantly, how to fix it? TIA JP
5
2138
by: baburk | last post by:
Hi all, What is the differenct between "if (!Page.IsPostBack) " and "if(!IsPostBack)" Thanks.
0
9685
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9535
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10244
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9061
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7558
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6802
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5582
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4130
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3744
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.