Results 1 to 3 of 3

Thread: Faster ListView Load

  1. #1

    Thread Starter
    Lively Member Daniel McCool's Avatar
    Join Date
    Oct 2002
    Posts
    127

    Faster ListView Load

    Everytime I change/add/remove items in a listview, and the listview has lots of items, it will take a while to reload them sometimes. Is there a quicker/easier way to refresh a listview?

  2. #2
    The Devil crptcblade's Avatar
    Join Date
    Aug 2000
    Location
    Quetzalshacatenango
    Posts
    9,091
    I think the best you can do is stop the window from updating until you are finished loading it...
    VB Code:
    1. Private Declare Function LockWindowUpdate Lib "user32" Alias "LockWindowUpdate" (ByVal hwndLock As Long) As Long
    2.  
    3.  
    4.     Call LoackWindowUpdate(Listview1.hWnd)
    5.     'Load the items
    6.     Call LockWindowUpdate(0&)

    Laugh, and the world laughs with you. Cry, and you just water down your vodka.


    Take credit, not responsibility

  3. #3
    PowerPoster
    Join Date
    Aug 2000
    Location
    IN SILENCE
    Posts
    6,441

    Well

    Related, sort of. You can use a flexgrid which has a refrsh property that can be turned on/off. (Sucks that one was not included for the listview)
    Remaining quiet down here !!!

    BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width