Results 1 to 4 of 4

Thread: how to lock and unlock listview?

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Mar 2000
    Posts
    17
    How do I lock and unlock ListView such that I can control when the user can edit the ListView?

  2. #2
    New Member
    Join Date
    Feb 2000
    Posts
    4
    Just disable it when you don't want them to have control.

    ListView1.Enabled = False 'disable it

    ListView1.Enabled = True 'enable it

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Mar 2000
    Posts
    17
    the .enable had to be true, all the time, as I want the user to be able to sort the listview by column_header anytime (except when editing).

    if .enable = false, then user could never sort by the column_header but they cannot edit the data.

    if .enable = true, then user could sort by the column_header but they can edit the data too.

    no other way??

  4. #4
    Addicted Member
    Join Date
    Jan 2000
    Location
    Fresno, California, USA
    Posts
    195
    Probably the simplest way is to intercept the keystrokes in the keypress and/or keyup events of the list control and set keyascii to zero.

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