ListView threading issue
- From: "Yeghia Dolbakyan" <yeghia@xxxxxxxxx>
- Date: Thu, 26 May 2005 02:52:24 +0500
Hi Guys
I have a problem which I can't solve and hope you can give right direction.
I have a form with listview and slider control. That form runs another
thread (background) which do some operation based on slider current value
and modifies some item in listview. I've read that WinForm controls are not
thread safe and confirmed that myself. Can you tell me how should I protect
listview (problem is in control drawing) and slider controls (problem is in
quering the value)?
the pseudocode follows:
threadfunc()
{
foreach (item in listview)
{
int value = get_slider_value()
string str = do_some_calculation(item, value);
item.SubItems[1] = str;
}
}
Thanks in advance
Regards
Yeghia
.
- Follow-Ups:
- Re: ListView threading issue
- From: Maqsood Ahmed
- Re: ListView threading issue
- Prev by Date: Scrolling and OnPaint
- Next by Date: Scrolling and OnPaint (oops)
- Previous by thread: Scrolling and OnPaint
- Next by thread: Re: ListView threading issue
- Index(es):
Relevant Pages
|