Results 1 to 4 of 4

Thread: Determining if nothing selected in listview [Resolved]

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Feb 2003
    Location
    Argentina
    Posts
    1,950

    Determining if nothing selected in listview [Resolved]

    Is there a way to see if nothing in a listview is selected, preferably w/o looping through the whole thing? This is in embedded vb, btw. Selected a/o selecteditem don't work because nothing's selected. Thanks.
    Last edited by salvelinus; Mar 4th, 2003 at 02:02 PM.

  2. #2
    Frenzied Member andreys's Avatar
    Join Date
    Sep 2002
    Location
    Los Angeles
    Posts
    1,615
    Then are you saying "selected" do you mean row selection? Or you have a check boxes for each row and they can be selected?

  3. #3
    The Devil crptcblade's Avatar
    Join Date
    Aug 2000
    Location
    Quetzalshacatenango
    Posts
    9,091
    If its just a normal listview...
    VB Code:
    1. If Listview1.SelectedItem Is Nothing Then
    2.     MsgBox "No Selection!"
    3. End If
    Laugh, and the world laughs with you. Cry, and you just water down your vodka.


    Take credit, not responsibility

  4. #4

    Thread Starter
    Frenzied Member
    Join Date
    Feb 2003
    Location
    Argentina
    Posts
    1,950
    Thanks crptcblade, that worked. I tried that before, but used "= Nothing" instead of "Is Nothing".

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