![]() ![]() Label25.Text = " Total SMS In Excel File " rows_counting There Should Be Only Two Columns in Sheet Like Below\r\n\nĬELL NUMBER | MESSAGES", " Error", MessageBoxButtons.OK, ![]() MessageBox.Show( " Kindly Check Column Count Rows_counting = dataGridView1.RowCount - 1 Ĭolumn_counting1 = dataGridView1.ColumnCount OleDbDataAdapter dataAdapter = new OleDbDataAdapterĭataGridView1.DataSource = dataSet.Tables ĭataGridViewAutoSizeColumnsMode.DisplayedCells OpenFileDialog dialog = new OpenFileDialog $]", " SMS") Below code on button click will Open File Select Dialog Box // for Excel File which contains Sheet name SMS and only two columns named // CELL NUMBER and MESSAGES which will be loaded in to DataGridView // Also you need to rename your Excel sheet to SMS because // it is also checking that sheet name private void button3_Click_1( object sender, EventArgs e) Try GSMComm connection with the values got from the DataGrid when Cell is Clicked. As shown below, a Confirmation message will appear and Connected device information will also be shown and DataGrid Cell will be highlighted green. If you get all the COM Port Information from system without error, then the second step is to connect to the device, click on the Cell of Data Grid of your desired device to connect. Object connstatus = queryObj ĭ(capdeviceid, captionObj, New ManagementObjectSearcher( " root\\CIMV2",įoreach (ManagementObject queryObj in searcher.Get()) // Here we are getting the all available information from the Win32_SerialPort // and setting it in to the DataGrid try ![]()
0 Comments
Leave a Reply. |