Questions tagged as 'datagridview'

1
answer

Fill Data Grid View with property of objects

I have a form where I need to fill a DataGridView with the data of a list of users. To generate this data, I used 3 classes: User Class namespace TesteDataGridView { public class Usuario { public int id { get; set; }...
asked by 13.05.2014 / 13:43
1
answer

Save files from a DataGridVIew

I would like to know how do I get all the content that was passed to a DataGridView and save it to an Excel file. So far I have this: private void btnDiretorio_Click(object sender, EventArgs e) { folderBrowserDialog.RootFo...
asked by 17.12.2014 / 14:39
1
answer

Add grid data to the bank

I have a loan screen and I have a datagrid with a checkbox checkbox and I would like to add only the row selected by the user in the database, how can I do it? Loanscreencode:usingSystem;usingSystem.Collections.Generic;usingSystem.ComponentM...
asked by 19.01.2016 / 17:10
1
answer

Get data from each row of a column in C #

It's as follows, I have a DataGridView with multiple columns. In each line of this DataGridView will be presented the installation path of a program. With this displayed value, I'd like to use it to get the size of that folder and...
asked by 05.06.2017 / 11:17
2
answers

How do I get all the selected values in a DataGridView?

I'm trying to get all the selected values in a DataGridView and add to a IList<Object> but it shows an exception. How to do this? I'm trying like this. IList<Modulo> lista = gridModulos.SelectedRows.Cast<Modulo&...
asked by 10.03.2016 / 18:49
1
answer

How to update a datagridview automatically?

I've created an application that will display the data of a given view in a datagridview control. The whole application is ready: loading the data, the button to update and also the events load and activated . Technologie...
asked by 24.05.2016 / 22:24
1
answer

Add row in a dataTable

I need to add a row in a table in a given position. I have the following methods: public void criarTabela(DateTime dia) { tabela = new DataTable(); switch (dia.DayOfWeek) { //case...
asked by 30.11.2015 / 03:03
1
answer

How to set column width of Grid View?

I would like to know how to set the width of columns of DataGridView manually. My first column must have a fixed value and the other columns must "fill" the grid, so that they are the same size.     
asked by 25.11.2015 / 12:20
1
answer

Search in populated DataGridView by typing on it

I have DataGridView already with recovered data where the user selects an item. But because the items are numerous, I would like to allow the user to type over the DataGrid as the system "goes" to the item entered. I do not know the co...
asked by 23.03.2015 / 14:20
1
answer

Selecting all Rows in a DataGridView

I would like to know how I can select all Rows of a DataGridView . Code that I have: DataGridView.Rows[0].Cells[0].Value.ToString();     
asked by 16.10.2016 / 17:18