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. help needed with passing parameters

help needed with passing parameters

Scheduled Pinned Locked Moved ASP.NET
databasehelpquestion
6 Posts 3 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.
  • F Offline
    F Offline
    Farraj
    wrote on last edited by
    #1

    Hi, i need help in passing parameters from a datalist to another page. this is how my app works: i have a database ( access) a table with the following columns: id,title,desc,photo. another table with the following columns: (startsin, endsin,price,tId) on the first page (tourpack.aspx) i have a datalist, when user clicks on a button that is in the templateitem of the datalist, he will be transfered to another page called (showtour.aspx). what im trying to do is passing the ID parameter from the first page (table 1) to the second page (showtour.aspx) with the id number so he can see the specific details of that "tour" that are located In the second table. any idea how it works? i would appreciate any kind of help. Thanks, Farraj.

    M B 2 Replies Last reply
    0
    • F Farraj

      Hi, i need help in passing parameters from a datalist to another page. this is how my app works: i have a database ( access) a table with the following columns: id,title,desc,photo. another table with the following columns: (startsin, endsin,price,tId) on the first page (tourpack.aspx) i have a datalist, when user clicks on a button that is in the templateitem of the datalist, he will be transfered to another page called (showtour.aspx). what im trying to do is passing the ID parameter from the first page (table 1) to the second page (showtour.aspx) with the id number so he can see the specific details of that "tour" that are located In the second table. any idea how it works? i would appreciate any kind of help. Thanks, Farraj.

      M Offline
      M Offline
      m dhu
      wrote on last edited by
      #2

      Farraj wrote:

      passing the ID parameter from the first page (table 1) to the second page (showtour.aspx)

      you need to have the a column(ID) same in both the tables. Join both the tables. pass the ID through query string to showtour.aspx //on page load of show tour using the id from query string get the tour details

      F 1 Reply Last reply
      0
      • M m dhu

        Farraj wrote:

        passing the ID parameter from the first page (table 1) to the second page (showtour.aspx)

        you need to have the a column(ID) same in both the tables. Join both the tables. pass the ID through query string to showtour.aspx //on page load of show tour using the id from query string get the tour details

        F Offline
        F Offline
        Farraj
        wrote on last edited by
        #3

        Thanks for your reply Do you mean to join the both tables or the both ID columns? if so how do i do that? and how can i the id from query string to get the tour details in the other page (which there i have a datagrid)? Thanks for your help

        1 Reply Last reply
        0
        • F Farraj

          Hi, i need help in passing parameters from a datalist to another page. this is how my app works: i have a database ( access) a table with the following columns: id,title,desc,photo. another table with the following columns: (startsin, endsin,price,tId) on the first page (tourpack.aspx) i have a datalist, when user clicks on a button that is in the templateitem of the datalist, he will be transfered to another page called (showtour.aspx). what im trying to do is passing the ID parameter from the first page (table 1) to the second page (showtour.aspx) with the id number so he can see the specific details of that "tour" that are located In the second table. any idea how it works? i would appreciate any kind of help. Thanks, Farraj.

          B Offline
          B Offline
          Brij
          wrote on last edited by
          #4

          On the buttonclick where you are transferring the user to another page.Pass the id in querystring as showtour.aspx?tourid=1. Now read this id at pageload on showtour.aspx as Request.QueryString["tourid"] and load the details for this ID.

          Cheers!! Brij Check my latest Article :URL Routing with ASP.NET 4.0

          F 1 Reply Last reply
          0
          • B Brij

            On the buttonclick where you are transferring the user to another page.Pass the id in querystring as showtour.aspx?tourid=1. Now read this id at pageload on showtour.aspx as Request.QueryString["tourid"] and load the details for this ID.

            Cheers!! Brij Check my latest Article :URL Routing with ASP.NET 4.0

            F Offline
            F Offline
            Farraj
            wrote on last edited by
            #5

            thanks. sorry for the lack of knowledge in this issue. how can i load the details for this ID in the detailsview control i have on the second page showtour.aspx?

            B 1 Reply Last reply
            0
            • F Farraj

              thanks. sorry for the lack of knowledge in this issue. how can i load the details for this ID in the detailsview control i have on the second page showtour.aspx?

              B Offline
              B Offline
              Brij
              wrote on last edited by
              #6

              See, you need to read the ID from querystring, not get the details of the tour from DB fro this ID and show the detail using You detailsveiw control. If you have problem is using detailsview control,the look at the following links Link 1 Link 2

              Cheers!! Brij Check my latest Article :URL Routing with ASP.NET 4.0

              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