Jump to content

Gridlist Multiple Selection


GhostXoP

Recommended Posts

Posted

In windows if you held Control down, you could click multiple things at once. Is this the same in MTA's GUI? If so, would guiGridList's get selected item return an array full of the elements selected?

Posted

You have to enabled selection mode "1" with:

guiGridListSetSelectionMode 

And to get the items selected use:

guiGridListGetSelectedItems 

Which returns a table like this:

table = { 
    [1] = { 
        ["column"], -- has the first selected item's column ID 
        ["row"] -- has the first selected item's row ID 
    }, 
    [2] = { 
        ["column"],-- has the second selected item's column ID 
        ["row"] -- has the second selected item's row ID 
    }, 
    ... 
} 

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...