Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- InitializeComponent();
- dataGridView1.Rows.Add(21);
- for (int i = 0; i < 21; i++)
- dataGridView1.Rows[i].Cells[0].Value = degree [i]`
- using System.Windows.Data; // for table
- public MainWindow()
- {
- InitializeComponent();
- DataTable dt= new DataTable();
- dt.Columns.Add("Header name");
- for (int i = 0; i < degree.Length; i++)
- dt.Rows.Add(degree[i]);
- DG.ItemsSource = dt.DefaultView; // DG - имя DataGrid, в который помещаю DataTable.
- }
Add Comment
Please, Sign In to add comment