Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Unable to get client entered data from webcontrol

Unable to get client entered data from webcontrol

Scheduled Pinned Locked Moved ASP.NET
databasequestionjavascripthtmlsysadmin
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Sigfried
    wrote on last edited by
    #1

    I have created a webform with controls. My idea is to load the text values from these controls as values that the user enters for an insert stored procedure. The insert works. I have one control (server side) that I preload with "today's date", this can be considered the default value. But the user is allow to change the date. My problem is, I enter a new date (like the day before, etc, 1/16/2006 instead of 1/17/2006) and the new date (1/16/2006) does not show as the text value for the textbox control, the control keeps the value I load in at the Page_load method. I am missing how I get the control to "update" to the value I type in. the control is not connected to a dataset or table, etc. I want to use controls to provide text and number data for my insert sql procedure. I remember that the client-side is where the user "changes" the data, how do I get the client-side data to the "server" side? Do I need to use an html button, and use javascript, etc to run an onclick event for the html button??? Thanks, suffering from brain-fade! Thanks for the information!

    S 1 Reply Last reply
    0
    • S Sigfried

      I have created a webform with controls. My idea is to load the text values from these controls as values that the user enters for an insert stored procedure. The insert works. I have one control (server side) that I preload with "today's date", this can be considered the default value. But the user is allow to change the date. My problem is, I enter a new date (like the day before, etc, 1/16/2006 instead of 1/17/2006) and the new date (1/16/2006) does not show as the text value for the textbox control, the control keeps the value I load in at the Page_load method. I am missing how I get the control to "update" to the value I type in. the control is not connected to a dataset or table, etc. I want to use controls to provide text and number data for my insert sql procedure. I remember that the client-side is where the user "changes" the data, how do I get the client-side data to the "server" side? Do I need to use an html button, and use javascript, etc to run an onclick event for the html button??? Thanks, suffering from brain-fade! Thanks for the information!

      S Offline
      S Offline
      siva pinnaka
      wrote on last edited by
      #2

      did you check for !Page.IsPostBack in page_load function when you load default value. otherwise control gets initialized to default value always. Thanks

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups