|
-
May 14th, 2006, 11:54 PM
#1
Thread Starter
Frenzied Member
enable/disable menu based on listview selection
I want to enable/disable a menu option depending on wether or not an item is selected in a listview.
Is there some event I can use to tell if an item is selected?
-
May 15th, 2006, 12:03 AM
#2
Hyperactive Member
Re: enable/disable menu based on listview selection
you can use click event of list view...whenever user click on an item its relevant menu would b enable or disable....
well if u could explain a lil more then i couold better give u its answer
-
May 15th, 2006, 12:07 AM
#3
Re: enable/disable menu based on listview selection
Private Sub LiST_Click()
If LiST.ItemData(LiST.ListIndex) = 1 Then
Menu1.enabled=false
End If
End Sub
-
May 15th, 2006, 12:36 AM
#4
Thread Starter
Frenzied Member
Re: enable/disable menu based on listview selection
I guess I'm tired.
Enabling the menu won't be had.
But what can I use to tell when to disable the menu?
I know I can use the lostfocus event.
But I have a Delete Item feature.
When it gets used the listview is still active, but there's no longer a selected item.
Last edited by longwolf; May 15th, 2006 at 12:39 AM.
-
May 15th, 2006, 07:47 AM
#5
Re: enable/disable menu based on listview selection
 Originally Posted by longwolf
Enabling the menu won't be had.
I don't understand what you mean by this.
 Originally Posted by longwolf
But what can I use to tell when to disable the menu?
Under what circumstances should the menu item be disabled? Under what circumstances should it be reenabled? What is/are the menu item(s) that we are talking about?
 Originally Posted by longwolf
I know I can use the lostfocus event.
The LostFocus event of what control?
 Originally Posted by longwolf
But I have a Delete Item feature. When it gets used the listview is still active, but there's no longer a selected item.
That would be correct, so the user would have to select something else. If something has been deleted, how does that effect your menu? (If, at all)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|