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. passing date values between forms

passing date values between forms

Scheduled Pinned Locked Moved ASP.NET
htmlsysadminquestion
3 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.
  • B Offline
    B Offline
    beacon dartmouth
    wrote on last edited by
    #1

    I am unable to display a short-date value passed from a previous page. What's wrong with this syntax?? 'Sending page Context.Items.Add( "Usage_start_Date", lblStartDate.Text ) server.transfer( "appEdit.aspx", true ) 'Receiving page 'On page load I assign a date value to a text box: txtStartDate.text = Context.Items("Start_Date") 'html Thanx

    A 1 Reply Last reply
    0
    • B beacon dartmouth

      I am unable to display a short-date value passed from a previous page. What's wrong with this syntax?? 'Sending page Context.Items.Add( "Usage_start_Date", lblStartDate.Text ) server.transfer( "appEdit.aspx", true ) 'Receiving page 'On page load I assign a date value to a text box: txtStartDate.text = Context.Items("Start_Date") 'html Thanx

      A Offline
      A Offline
      Andrew Quinn AUS
      wrote on last edited by
      #2

      Hi, Should this not be:

      'Sending page

      Session["Usage_start_Date"] = lblStartDate.Text

      server.transfer( "appEdit.aspx", true )

      'Receiving page
      'On page load I assign a date value to a text box:

      txtStartDate.text = Session["Usage_start_Date"]

      Hope this helps, Andy

      B 1 Reply Last reply
      0
      • A Andrew Quinn AUS

        Hi, Should this not be:

        'Sending page

        Session["Usage_start_Date"] = lblStartDate.Text

        server.transfer( "appEdit.aspx", true )

        'Receiving page
        'On page load I assign a date value to a text box:

        txtStartDate.text = Session["Usage_start_Date"]

        Hope this helps, Andy

        B Offline
        B Offline
        beacon dartmouth
        wrote on last edited by
        #3

        HI Andy, Your suggestion is equally usable and it's actually less typing than the one I used, but in this case my problem was a typo: I had "Usage_start_Date" on my sending page and "Usage_Start_Date" on my receiving page, and since case sensitivity is crucial that small 's' in 'start' caused it not to assigned. Thanx for your input. b-d

        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