CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 1 of 1
  1. #1
    Join Date
    Aug 2001
    Location
    Texas
    Posts
    645

    [RESOLVED] testing code tags

    Here's a sample of how to use the code tags.

    Copy your code to the edit box

    Code:
            If e.Control.ToString() Like "System.Windows.Forms.DataGridViewComboBoxEditingControl*" Then
                If DataGrid.CurrentCell.OwningColumn.Name = "colTOOLBROADTYPE" Or _
                        DataGrid.CurrentCell.OwningColumn.Name = "colTOOLSUBTYPE" Or _
                        DataGrid.CurrentCell.OwningColumn.Name = "colTOOLCVSTAG" Then
                    Dim myEditingControl As DataGridViewComboBoxEditingControl = TryCast(e.Control, DataGridViewComboBoxEditingControl)
                    If myEditingControl IsNot Nothing Then
                        myEditingControl.DropDownStyle = ComboBoxStyle.DropDown
    
                        ParseComboBoxDropDown(Me.DataGrid.CurrentCellAddress.X)
                        myEditingControl.SelectedItem = Me.DataGrid.Rows(Me.DataGrid.CurrentCellAddress.Y).Cells(Me.DataGrid.CurrentCellAddress.X).Value.ToString()
                    End If
                End If
            End If
    Last edited by cvogt61457; May 2nd, 2008 at 04:35 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured