From: Ryan on 12 Feb 2010 13:51 I am trying to hide a coloumn if the DataType is Byte (Byte[]) but still get the exception; how do I either hide this field or not add to the DataGridView? the following exception occured in the DataGridView: system.argumentexception:parameter is not valid Dim oAdapter As OracleDataAdapter oAdapter = New OracleDataAdapter(sSQL, oConn) myDataSet = New DataSet() oAdapter.Fill(myDataSet) myBindingSource = New BindingSource() myBindingSource.DataSource = myDataSet With myDataSet.Tables(0) For i As Integer = 0 To myDataSet.Tables(0).Columns.Count - 1 If InStr(.Columns(i).DataType.ToString, GetType(Byte).ToString) > 0 Then myDataSet.Tables(0).Columns(i).ColumnMapping = MappingType.Hidden End If Next End With DataGridView1.DataSource = myDataSet.Tables(0)
|
Pages: 1 Prev: Should se send PDB files along with EXE/DLL's Next: Accessing a 3rd party DLL |