How populate a DataGrid (C.F 2.0 and VB.net)
-
Hi all, I'm find some problem to bind a simple String Array (NamesWpt()) with a Datagrid (DataGrid1). The only result I obtained with this simple code line: DataGrid1.DataSource = NamesWpt is to populate the DataGrid with length of strings contained in Array (NamesWpt()). And the name column is been named "Length". How to see contained Names? Is it possible to bind a multi-column DataGrid with a multi dimensional array? Thanks Marco
-
Hi all, I'm find some problem to bind a simple String Array (NamesWpt()) with a Datagrid (DataGrid1). The only result I obtained with this simple code line: DataGrid1.DataSource = NamesWpt is to populate the DataGrid with length of strings contained in Array (NamesWpt()). And the name column is been named "Length". How to see contained Names? Is it possible to bind a multi-column DataGrid with a multi dimensional array? Thanks Marco
You would need to create an ArrayList, add any number of classes having n number of properties you want to the ArrayList and bind it to DataGrid. To bind an Arraylist to a DataGrid, refer the link below: http://www.c-sharpcorner.com/UploadFile/mahesh/ArrayListBinding10212005102338AM/ArrayListBinding.aspx ~Dave
Dave Traister Software Engineer ComponentOne LLC www.ComponentOne.com
-
You would need to create an ArrayList, add any number of classes having n number of properties you want to the ArrayList and bind it to DataGrid. To bind an Arraylist to a DataGrid, refer the link below: http://www.c-sharpcorner.com/UploadFile/mahesh/ArrayListBinding10212005102338AM/ArrayListBinding.aspx ~Dave
Dave Traister Software Engineer ComponentOne LLC www.ComponentOne.com
Thanks for reply Dave, I visited page you suggested me, and surely I'll can get some guideline. Marco