Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

-Fruz-

ListView - VB

This topic is 5795 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

How do i lock a listview so the listitems are not editable/writeable? And how do i get the current/selected listitem? Like ListIndex in regular listboxes...? Help me! JFK

Share this post


Link to post
Share on other sites
Advertisement
with regard to making them non-editable, i'm not entirely sure... on the matter of choosing the currently selected one, however, see the following code:

Private Sub ListView_MouseDown(Button As Integer, Shift As Integer, x As Single, Y As Single)

Dim ThisItem = Object

Set ThisItem = ListView.HitTest(x, Y)
:
:
V

End Sub

that should just about do it... you can then simply perform all the necessary procedures available to an item type object... hope that helps...



[edited by - paulus_maximus on September 9, 2002 11:52:47 AM]

Share this post


Link to post
Share on other sites
Oh, that''s great!

Here''s another method i thought of...

For i = 1 to ListView.ListItem.Count
If ListView.ListItem.Selected = true then.....

But thanx alot!

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!