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. General Programming
  3. C#
  4. how can I send datagridview cell value to another form

how can I send datagridview cell value to another form

Scheduled Pinned Locked Moved C#
csharphelpquestionlearning
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.
  • H Offline
    H Offline
    hama2
    wrote on last edited by
    #1

    Hi ....everybody I have two forms the first form is the main form .it has textbox and the second form has a datagridview I want when i click the current cell send it's value to the text box in the main form. I have already done the code to get the current cell value but I couldn't send the value to the main form I tried to wrote some methods but it didn't work.....I am still a beginner in C#. SOOOOOOOOO please help me. with my best regards. Ahmed with my best regards. Ahmed

    G 1 Reply Last reply
    0
    • H hama2

      Hi ....everybody I have two forms the first form is the main form .it has textbox and the second form has a datagridview I want when i click the current cell send it's value to the text box in the main form. I have already done the code to get the current cell value but I couldn't send the value to the main form I tried to wrote some methods but it didn't work.....I am still a beginner in C#. SOOOOOOOOO please help me. with my best regards. Ahmed with my best regards. Ahmed

      G Offline
      G Offline
      Gammaza
      wrote on last edited by
      #2

      Have you tried session variables ?? ex: on the datagrid page ..... Session["myValue"] = CellValue; and then on the main page ..... TextBox1.Text = Session["myValue"].ToString(); Hope this helps.

      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