i am created the datagridview at run time.
i need to move (drag and drop) the datagrid view (only gridview) during the run time.
(task is : if i select the datagridview and placed in some where in same window form.
Ex: in our desktop we select the icon and drag and drop in some other place in the desktop)
i have no idea about this. so please share ur ideas.
open a form when will press F2 key on DataGridViewComboBoxColumn
Try following codes:
Private Sub Datagridview1 _KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles dgv1.KeyDown
Dim other As New others
If e.KeyCode = Keys.F2 Then
If Datagridview1.CurrentCell.OwningColumn.Name = "DataGridViewComboBoxColumn Name" Then
other.MdiParent = MDIParent1
other.frmwhich = "purchase"
Dim Adapter As New OleDbDataAdapter
Dim Command As New OleDbCommand
Dim xFrom As String = dtpFrom.Value.ToString.Substring(0, dtpFrom.Value.ToString.IndexOf(" "))
Dim xTo As String = dtpTo.Value.ToString.Substring(0, dtpTo.Value.ToString.IndexOf(" "))
sqlQuery = MainQuery ...