I have a problem, i have a form with some input boxes and a submit
button. In the Submit_Click event, the data from the input boxes is
stored in a database.
But, if you click the button, ASP.NET will first load the next
Page_Load and when that is done, it will do the Submit_Click event.
So on the page you don't see the data from the database, because it
is not there yet. When you refresh the page, the data is there, but
it has to be there without the refresh!
does anyone know how to fix this?
Greetz Vincent Scheel from the Netherlands 2 1483
Hi there,
Try to load you value in if(!ispostback) condition, then value will be
loaded only once.
Harshdeep Mehta
"Skating_vince" <Sk***********@hotmail-dot-com.no-spam.invalid> wrote in
message news:41**********@Usenet.com... I have a problem, i have a form with some input boxes and a submit button. In the Submit_Click event, the data from the input boxes is stored in a database.
But, if you click the button, ASP.NET will first load the next Page_Load and when that is done, it will do the Submit_Click event. So on the page you don't see the data from the database, because it is not there yet. When you refresh the page, the data is there, but it has to be there without the refresh!
does anyone know how to fix this?
Greetz Vincent Scheel from the Netherlands
No, that's the problem, it has to be loaded, but only after the data
is changed in the database, but because of ASP.NET doing the
Button_Click event after the Page_Load, the data in the database
hasn't changed yet. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: in |
last post by:
I pass a variable from one aspx page to another using Context.Item.Add
This works fine when the page first loads.
I set the value of a static global var to the value of Context.Item in
the...
|
by: Tim T |
last post by:
Hi,
I have the need to use dynamically loaded user controls in a webform page.
I have the controls loading dynamically, and that part works fine. this is
the code used in a webform to dynamically...
|
by: Michael Johnson Jr. |
last post by:
The problem is the following pseudo code causes you need to click buttons
twice to get event.
This is notable via debugging and single stepping.
I can't seem to quite figure out how to do...
|
by: Krista Lemieux |
last post by:
Hello,
In my form I have a button, and the button_Click function
(which gets called when the button is clicked). However
the functionality that I have in the button_Click
function, needs to be...
|
by: Carlos |
last post by:
Hi all,
I just tried to use a static variable within the scope of the
page_load event handler, but apparently it did not work
all I wanted to do is to evaluate the postback condition
and...
|
by: I am Sam |
last post by:
Please help. I'm dying here and pulling out the last few remaining elements
of my hair over this.
I have built a form that will identify and authenticate users. I keep
getting the following...
|
by: John Austin |
last post by:
I need to understand why if I add a control and use AddHandler to connect its
click event, it will work in Page_Load, but not in a Button_Click.
The idea is that the user types some data, presses...
|
by: rn5a |
last post by:
A Form has a DataGrid which displays records from a SQL Server 2005 DB
table. Users can modify the records using this DataGrid for which I am
using EditCommandColumn in the DataGrid. This is the...
|
by: =?Utf-8?B?TWlrZXkgQmFieQ==?= |
last post by:
Greetings
Hopefully, I can be clear and concise on this one, but I'm confused.
I have a page with a ListBox <- ODS <- BusinessObject and a button.
The Parameter Source is 'None'. The Default...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
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
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
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,...
|
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...
|
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...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
| | |