Help regarding DataView.

  • Thread starter Thread starter trialproduct2004
  • Start date Start date
T

trialproduct2004

hi all
I am having application in c# which is using dataview.
my problem is i have one global dataview which i can use through the
application.
I am creating 2 threads in which i am setting rowfilter property of
this global view.
My question is when i am starting 2 threads at the same time then at a
time of setting rowfilter proerty should i have to use synchronization
object on it or it will work properly?
any help will be appreciated.
thanks in advance.
 
Hi,

Yes, DataView is not threadsafe.
But there is another problem. If this view is data bound then modifying its
properties through non UI thread will affect bound controls and thus it will
case strange errors (because UI controls can be modified only through the
same thread that created them).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top