Results 1 to 10 of 10

Thread: [RESOLVED] Locking some list items

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Sep 2006
    Posts
    160

    Resolved [RESOLVED] Locking some list items

    Is it possible to disable certain items of a listbox instead of just the whole control? especially when its style is set to checkbox.

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: Locking some list items

    It is all or nothing.

    Exactly what do you need to do. Perhaps we can come up with a suitable work around.

  3. #3
    Giants World Champs!!!! Mark Gambo's Avatar
    Join Date
    Sep 2003
    Location
    Colorado
    Posts
    2,965

    Re: Locking some list items

    Quote Originally Posted by Neverbirth
    Is it possible to disable certain items of a listbox instead of just the whole control? especially when its style is set to checkbox.
    Locked how?
    Regards,

    Mark

    Please remember to rate posts! Rate any post you find helpful. Use the link to the left - "Rate this Post". Please use [highlight='vb'] your code goes in here [/highlight] tags when posting code. When a question you asked has been resolved, please go to the top of the original post and click "Thread Tools" then select "Mark Thread Resolved."


  4. #4

    Thread Starter
    Addicted Member
    Join Date
    Sep 2006
    Posts
    160

    Re: Locking some list items

    Quote Originally Posted by Hack
    It is all or nothing.

    Exactly what do you need to do. Perhaps we can come up with a suitable work around.
    I'm just using two listboxes to display different categories in a couple of forms, one using checkbox style and which is being used to choose the categories to display, and the other is used to show, add, edit and delete them.

    I'd like to disable the items which aren't yet defined, but I don't really need to do so.

  5. #5
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: Locking some list items

    What do you mean by "defined"?

  6. #6

    Thread Starter
    Addicted Member
    Join Date
    Sep 2006
    Posts
    160

    Re: Locking some list items

    Quote Originally Posted by Hack
    What do you mean by "defined"?
    The categories are fully configurable, and are by default empty, so instead of showing nothing when they are not set I want them to be shown on list as something like "-- Not yet defined --".

  7. #7
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: Locking some list items

    How is the listbox loaded?

    What is your code?

  8. #8
    PowerPoster gavio's Avatar
    Join Date
    Feb 2006
    Location
    GMT+1
    Posts
    4,462

    Re: Locking some list items

    You can decide if they are (not)"defined" when Click event fires and simply prompt the user.

  9. #9
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: Locking some list items

    Quote Originally Posted by gavio
    You can decide if they are (not)"defined" when Click event fires and simply prompt the user.
    He wouldn't necessarily even need to do that.

    Depending on how he is adding the items to the listbox, he can append "--Not Defined--" to the items so that they show in the listbox already labeled.

  10. #10

    Thread Starter
    Addicted Member
    Join Date
    Sep 2006
    Posts
    160

    Re: Locking some list items

    Quote Originally Posted by Hack
    He wouldn't necessarily even need to do that.

    Depending on how he is adding the items to the listbox, he can append "--Not Defined--" to the items so that they show in the listbox already labeled.
    Well, I already do so. What I'd like is that those list items are disabled (just if possible). Using something like the click event makes the checkboxes change for a brief moment.

    I've anyway just found out about the itemcheck event, that can be used for this. Never tried it before.

    Out of curiosity, were you thinking of some other method? I'm always grateful to hear different methods for a same thing.

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