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. DataGridView

DataGridView

Scheduled Pinned Locked Moved C#
helptutorial
4 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.
  • N Offline
    N Offline
    nasambur
    wrote on last edited by
    #1

    Hi, I have a DataGridView control with one column as ComboBox control. I want to raise the event "SelectedValueChanged" of combo box. How to do this. Please help. Thanks & Regards, nas

    R 1 Reply Last reply
    0
    • N nasambur

      Hi, I have a DataGridView control with one column as ComboBox control. I want to raise the event "SelectedValueChanged" of combo box. How to do this. Please help. Thanks & Regards, nas

      R Offline
      R Offline
      Rocky
      wrote on last edited by
      #2

      read an article on deploying events in C# applications over MSDN or search google. write this line in your constructor. dataGridView1.SelectedValueChanged+= then you start coding in the function made for the event handler Rocky

      N 1 Reply Last reply
      0
      • R Rocky

        read an article on deploying events in C# applications over MSDN or search google. write this line in your constructor. dataGridView1.SelectedValueChanged+= then you start coding in the function made for the event handler Rocky

        N Offline
        N Offline
        nasambur
        wrote on last edited by
        #3

        Hi Rocky, Thanks for reply. Actually in DataGridView we can make any Column-Type as controls (Button,ComboBox, CheckBox...). So i have selected one column of DGV as ComboBox. But this ComboBox differs from the normal ComboBox control. By coding i want to access the ComboBox control of the DGV. :confused:

        R 1 Reply Last reply
        0
        • N nasambur

          Hi Rocky, Thanks for reply. Actually in DataGridView we can make any Column-Type as controls (Button,ComboBox, CheckBox...). So i have selected one column of DGV as ComboBox. But this ComboBox differs from the normal ComboBox control. By coding i want to access the ComboBox control of the DGV. :confused:

          R Offline
          R Offline
          Rocky
          wrote on last edited by
          #4

          OK I know ur talking abt the datagridviewcombobox control right? try using the event 'CellValueChanged' on the dGV and in that you can get the column as if(e.columnIndex == yourdgvcomboboxname.ColumnIndex) { //perform you task } and c if this things works for u or not incaseif it does give this msg and full rating

          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