How to get edited value of the textboxes???

Hi,

I am having 4 textboxes with field name,address,phone,email .... OnLoad they get filled with database values....and all fields are in inactive state...as user click the edit button,  all textboxes get active and user can edit the values in it.....Now after editing values, as user click UPDATE button, All edited values should get updated in the database....My update query working fine...But the Problem is that Update query not getting edited value.....getting only the value filled during the load time.....

Please help me ...How can i get the edited value in the update query....

Thanks & Regards..

Nick


Regards Nick,

Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

If this solution doesn't solve your problem, just feel free to mark it as not answer and reply.
0
nickgenius
2/1/2008 9:05:23 AM
asp.net.web-forms 93655 articles. 5 followers. Follow

4 Replies
531 Views

Similar Articles

[PageSpeed] 9

Hi,

I think u have placed the code for populating the textboxes with database values in page load event. This should be done only once in the page load, place this code in the below block

if(!isPostBack)

{

  //Populating the textboxes should be here

}

If I am not clear, please reply with your code.

Hope this Helps ("Mark as Answer")

 

0
ramshr02
2/1/2008 10:31:27 AM

In page Onload

        If Not Page.IsPostBack Then
           'your filling code should come here
        End If

otherwise, on page post back your textboxes will get filled with the values from database your going to loose your edited values  


Surendra
If this helps mark it as answer
0
surendra_kla
2/1/2008 11:11:19 AM

yeah ! i got that...thanks for ur reply


Regards Nick,

Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

If this solution doesn't solve your problem, just feel free to mark it as not answer and reply.
0
nickgenius
2/1/2008 11:28:37 AM

yeah ! i got that...thanks for ur reply


Regards Nick,

Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

If this solution doesn't solve your problem, just feel free to mark it as not answer and reply.
0
nickgenius
2/1/2008 11:29:40 AM
Reply:

Similar Artilces:

Trying to edit web form, can't get database updated with newly edited values.
 This is my code:  when I try to update any of the fields, the update statement retains the old values retrieved from the database.  Could you tell me where my code is bad? -Thanks, Mark   <%@ Page Language="VB" %><%@Import Namespace="System.Data"%><%@Import Namespace="System.Data.SqlClient"%><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><script runat="server"> Protected Sub Page_Load(ByVa...

getting values from a web form to windows form
Hot Requirement ..... Is there any possible of getting values from a web form to windows form ????? Yes One way i to use the WebRequest and WebResponse classes of the System.Net namespace. For example:  WebRequest request = WebRequest.Create("URL of the web page); WebResponse response = request.GetResponse(); StreamReader reader = new StreamReader(response.GetResponseStream()); string content = reader.ReadLine(); ....    Reza Nassabehwww.professionalcsharp.comDon't forget to click "Mark as Answer" on the post that helped you. That way fut...

C#.NET WEB APPLICATION
hei guys, i need help on my application, i'm using C#.NET as front-ed and SQL as back-end, aside from a datagrid, i want to display my data using textboxes and not a datagrid, i can do it using Visual Basic 6 but since i'm a newbee at C#.NET i don't know how to do it, specially the codes, can anyone help me with it? thank you in advance! If you are doing windows development, i would suggest using 'DataForm wizard' (Use Solution Explorer-->Rightclick project-->Add new Item-->New DataForm). It will guide you through steps. If you are doing web apps. Use quickstart to learn them. h...

Passing Values from a Web Form to Another Web Form
Hello All! I am trying to pass values from one web form to another web form. I know that there are 3 ways of doing this: queryString, Server.Transfer and Session. I am using the Server.Transfer method. But I am not able to create, in my 2nd web form, an instance of my 1st web form. My 1st Web form is named CallTrack.aspx and my 2nd is named Export.aspx. What I mean is something like this: Public value as CallTrack. I can't create it in my 2nd web form because when the intellisense is displayed, there's no CallTrack in the options. Thanks!   How about using cross-...

How to get the HREF value of the Anchor tag in a web page using the web browser control in vb.net
Hi Friends,               i have a webserver control in my application.i load the web browser control on a button click using the below code Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click                AxWebBrowser1.Navigate("http://www.rateitall.com/i-322335-.aspx", False) End sub once the page is loaded in the browser i want the <a> HREF value in that page.For example if that page has ...

problem with get value from textbox after get it value in load page
hi every one  i have problem with my web site when i get textbox value in load page   and Changed textbox the page do not take last value .   it take value in load page   this is code:Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs)   TextBox1.Text = "aa" End SubProtected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) MsgBox(TextBox1.Text) End Sub   when i press button message write "aa" while i changed the textbox   please if enyone knowen help me &nbs...

Get listbox value from the other web form
 Dear all, I want to get the lisbox selecteditem value to a textbox in one web form from the other web page. Should I use session to get this value?Can any one help in this regard? Thanks a lot in advance.  People Develop People Yes you can use Session to get the informations between cross pages.. see below for your referenceTO STORE THE INFO in Session Session["key"] = ListBox1.SelectedItem.Value; Response.Redirect("Page2.aspx");TO GET THE VALUES FROM Sessionprotected void Page_Load(object sender, EventArgs e){    if (Sessio...

problem in getting edited value of a textbox
hi, I have a textbox inside a usercontrol registration.ascx. <asp:TextBox ID="email" runat="server" Width="260px"></asp:TextBox> when the user wants to edit his account then this textbox is populated with the email address that the user is using currently. the problem is that when the user edits the textbox then I am unable to get the edited value. Say the old email id is demo@abc.com and the user changed it to demo123@abc.com then when i am doing String sEmail = email.Text i am getting demo@abc.com instead of  demo123@abc.com. here i...

problem in getting edited value from a textbox
hi, when a user clicks on edit profile link i am showing the ´new registration form with the user's data filled in. The problem is that when the user edits his data and clicks on the save button i am not getting the new edited data. Instead of giving me the new data textbox.Text is giving the same old value that I am displaying. what I need to do to get the new value? <asp:TextBox ID="email" runat="server" Width="260px"></asp:TextBox> sEmail = email.Text;     tamanna06:when a user clicks on edit profile link i am showing the ...

Implementing .Net Form into an APS.net web form, can this be done
I am new here, but have been searching for a while, and may not have the correct lingo to find what I am looking for.  I am tasked with implementing a .exe application that was writen vb6 then converted to .net into a new website my team is developing. The idea is to put each of the 3 different forms in this .exe application of 3 different .aspx pages. I have attempted multiple things to get this into the page and even started to just rewrite it as an ASP.net web form, but even then I can't reuse any of the code since the System.Web.UI.Page doesn't inherit the sa...

Getting textbox value when all rows in edit mode
Hi There, I'm currently writing a small shopping cart for a site of mine. All rows are in edit mode so that a user can enter the qty's he/she desires and the click submit. I have an autopostback on the text box so that every time a value is changed, I return to the server to recalc the totals. The datagrid is defined as below (the text box in question is QUANTITY) : <form runat="Server"> <p> <asp:DataGrid id="BuyNowGrid" runat="server" AutoGenerateColumns="False" HorizontalAlign="Center...

form getting old textbox.text values
I've got a form that when loaded loads it's values from the database and then allows you to edit them (using textbox controls). When you click save it adds what I would think should be the newly edited values into the parameters and updates the database. However it is instead loading the values prior to them being changed rather than the current values in the text boxes. Anybody know what would cause this?Could be WAAAY off in any suggestions I give in posts, so be on the lookout for stupidity :P As you have  not included any code samples, I can only suggest a possibility.Check...

passing values to .net web form application
Hi Can any explain me abt how to pass values to my .NET web form application (designed using PB 11.1) from other web application? My intension is to redirect from a web application (ASP.NET to .net web form application) to my web application with user information. Thanks & Regards, Anbazhagan From the "Deploying Applications and Components to .NET" manual: >>> Starting an application with command line parameters If your application requires command line parameters, you can assign values to the PBCommandParm global property before you deploy the...

How to get Textbox value in web user control?
Hi friends,I created a web user control with only one textbox.(textbox.ascx) and textbox id=" txtSimple"textbox user control having some property. another user control with button(button.ascx) next i use two textbox usercontrol and one button usercontrol in sample.aspx. when i click button at that time call the required field validate property in textbox user control.in property have following code.public bool RequireValidate    {        set        {     &nbs...

Web resources about - How to get edited value of the textboxes??? - asp.net.web-forms

Notes Plus on the App Store on iTunes
Get Notes Plus on the App Store. See screenshots and ratings, and read customer reviews.

Training - Algodoo
Navigation Home For Fun Algodoo Play Algodoo Physics Scenes Demo Buy For Education Algodoo for Education Lessons User stories Solutions Demo ...


Automated Test Design
... tests along with doing ET. Here's my take on a UI test for Alan's app: Open the page Check that text "Total" exists. Check that the 6 textboxes ...

Quick Answers - CodeProject
Questions - Free source code and tutorials for Software developers and Architects.; Updated: 11 Jul 2012

Cyprus By Bus Route Planner - Find your bus journey in Cyprus
Cyprus By Bus route planner for finding the best possible bus route between two bus stops in Cyprus. Based on origin bus stop, destination bus ...

Issues - gwen - GUI system aimed at games - Google Project Hosting
My favorites ▼ - Sign in gwen GUI system aimed at games Project Home Downloads Wiki Issues Source New issue Search Search within: All issues ...

ASP.NET Web Forms DynamicData FieldTemplates for DbGeography Spatial Types
... Those templates are simple. Here's the Edit example. You might say, hang on, this is just a text box! I thought we weren't using TextBoxes? ...

uCan Post WordPress Plugin Demo - Cartpauj & iComNow
This is a demo for the uCan Post WordPress plugin by cartpauj. This plugin lets users create posts and site content without having to access ...

Jennifer Semtner [ Web Designer / Developer ] » CSS
If you're using Grails and the Grails UI plugin's autocomplete feature, you may have noticed all of your textboxes have disappeared in Chrome ...

Resources last updated: 1/4/2016 11:03:56 AM