changing datatables for itemsource causes exception
I'm quite new to WPF and the datagrid control and it has been a hard slog learning it (quite different from the datagridview!)
I've been googling all morning but can't find an answer yet. I have a datatable assigned to the ItemsSource and it works great but later on I redo the query and try to change to a new version of the table. It crashes right away and saying something about a block variable not being set (or something close to that). I tried setting ItemsSource to "" and Nothing but that too causes exceptions.
How does one set the Datagrid to a new itemsource?
Re: changing datatables for itemsource causes exception
Show us the code and the exception stack trace.