Avoid flickering

04-11-2003, 12:29 PM
can anybody help.

I would like to delete top 300 item from listview object VB6 (Not comctl32) via a timer setting. but don't let the user see the flickering on the screen.

On the treeview object, first i lock the window then delete the node by using SendMessageLong API, after that, unlock the window, so there is no flickering .

How can i achive the same result when deleting listview item .


04-11-2003, 12:42 PM
Just thinking out loud...

I know you can turn the "repaint" off, but I just don't remember exactly how (I think it was when I was looking at Subclassing...).

So, you could turn of the repaint, delete what you need, and after that repaint the object!

Hope it helps a bit!

04-11-2003, 12:47 PM
You can just Lock Window Updates on the listview using the LockWindowUpdate API, so the listview won't redraw until you unlock window updates. http://www.allapi.net/apilist/LockWindowUpdate.shtml

SSJ Vegetto
04-11-2003, 12:55 PM
You can also try to use


Gr. Bob

04-13-2003, 08:43 AM
Thanks for all of you

Issue had been resolved by using the following method

lock the window

SendMessageLong hWnd, WM_SETREDRAW, False, &O0

(do my things here)

SendMessageLong hWnd, WM_SETREDRAW, True, &O0


EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum