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. Visual Studio 2015 & .NET 4.6
  4. Updating Value of ComboBoxColumn Item of the DGV

Updating Value of ComboBoxColumn Item of the DGV

Scheduled Pinned Locked Moved Visual Studio 2015 & .NET 4.6
helpannouncement
3 Posts 2 Posters 12 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.
  • R Offline
    R Offline
    Raabi Anony
    wrote on last edited by
    #1

    Hello everybody! I am using a data entry Form, which has only one DataGriedView. The DGV properties include: Name: tblStaffInfoDGV DataSource: tblStaffInfoBindingSource The properties of the tblStaffInfoBindingSource are: DataSource: StaffEvaluationDataSet DataMember: tblStaffInfo The 2nd Column (CampusID), of the DGV has the following properties: ColumnType: DataGridViewComboxColumn DataPropertyName: CampusID DataSource: CampusesBindingSource DisplayName: CampusName ValueMember: CampusID The properties of the CampusesBindingSource include: Name: CampusesBindingSource DataMember: tblCampuses DataSource: CampusesDataSet The "CampusName" and the"CampusID" are the only two Fields of the table tblCampuses My Dataset is StaffEvaluationDataSet The code, of the Form, is as below:

    Public Class frmStaffEntry
    Private Sub TblStaffInfoBindingNavigatorSaveItem_Click(sender As Object, e As EventArgs) Handles TblStaffInfoBindingNavigatorSaveItem.Click
    Me.Validate()
    Me.tblStaffInfoBindingSource.EndEdit()
    Me.TableAdapterManager.UpdateAll(Me.StaffEvaluationDataSet)

    Me.tblStaffInfoBindingSource.EndEdit()
    Me.tblStaffInfoTableAdapter.Update(Me.StaffEvaluationDataSet.tblStaffInfo)
    End Sub

    Private Sub frmStaffEntry_Load(sender As Object, e As EventArgs) Handles MyBase.Load

    Me.tblCampusesTableAdapter.Fill(Me.CampusesDataSet.tblCampuses)

    Me.tblStaffInfoTableAdapter.Fill(Me.StaffEvaluationDataSet.tblStaffInfo)
    End Sub
    End Class

    ISSUE After selecting a different item from the drop-down list of the ComboBox and clicking Save button of the tblStaffInfoBindingNavigator, the new value is Not saved in the tblStaffInfo table. Would an expert help me in resolving this issue, please! Regards

    R 1 Reply Last reply
    0
    • R Raabi Anony

      Hello everybody! I am using a data entry Form, which has only one DataGriedView. The DGV properties include: Name: tblStaffInfoDGV DataSource: tblStaffInfoBindingSource The properties of the tblStaffInfoBindingSource are: DataSource: StaffEvaluationDataSet DataMember: tblStaffInfo The 2nd Column (CampusID), of the DGV has the following properties: ColumnType: DataGridViewComboxColumn DataPropertyName: CampusID DataSource: CampusesBindingSource DisplayName: CampusName ValueMember: CampusID The properties of the CampusesBindingSource include: Name: CampusesBindingSource DataMember: tblCampuses DataSource: CampusesDataSet The "CampusName" and the"CampusID" are the only two Fields of the table tblCampuses My Dataset is StaffEvaluationDataSet The code, of the Form, is as below:

      Public Class frmStaffEntry
      Private Sub TblStaffInfoBindingNavigatorSaveItem_Click(sender As Object, e As EventArgs) Handles TblStaffInfoBindingNavigatorSaveItem.Click
      Me.Validate()
      Me.tblStaffInfoBindingSource.EndEdit()
      Me.TableAdapterManager.UpdateAll(Me.StaffEvaluationDataSet)

      Me.tblStaffInfoBindingSource.EndEdit()
      Me.tblStaffInfoTableAdapter.Update(Me.StaffEvaluationDataSet.tblStaffInfo)
      End Sub

      Private Sub frmStaffEntry_Load(sender As Object, e As EventArgs) Handles MyBase.Load

      Me.tblCampusesTableAdapter.Fill(Me.CampusesDataSet.tblCampuses)

      Me.tblStaffInfoTableAdapter.Fill(Me.StaffEvaluationDataSet.tblStaffInfo)
      End Sub
      End Class

      ISSUE After selecting a different item from the drop-down list of the ComboBox and clicking Save button of the tblStaffInfoBindingNavigator, the new value is Not saved in the tblStaffInfo table. Would an expert help me in resolving this issue, please! Regards

      R Offline
      R Offline
      Raabi Anony
      wrote on last edited by
      #2

      I am desperate for the solution of my issue, but surprisingly received no response. Please help!

      M 1 Reply Last reply
      0
      • R Raabi Anony

        I am desperate for the solution of my issue, but surprisingly received no response. Please help!

        M Offline
        M Offline
        Mycroft Holmes
        wrote on last edited by
        #3

        Probably because you missed by 2, forums that is the VB.Net forum is 2 above this one one the left menu!

        Never underestimate the power of human stupidity RAH

        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