"news.microsoft.com" <As******@hotmail.com> schrieb:
I tried to use thread to load data to datagrid but it gived me errors?
Anyone know how to solve it?
Windows Forms controls' instance members are not safe for multithreading,
which means that you cannot access them directly from another thread. Make
sure you are using 'Control.Invoke'/'Control.BeginInvoke' together with
'Control.InvokeRequired' to access the datagrid from the thread. Some more
information about Windows Forms and multithreading can be found here:
Multithreading in Windows Forms applications
<URL:http://dotnet.mvps.org/dotnet/faqs/?id=multithreading&lang=en>
--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>