Home   Help Search Login Register  

Author Topic: Multiple selection listbox  (Read 1925 times)

0 Members and 3 Guests are viewing this topic.

Offline einherj

  • Members
  • *
Multiple selection listbox
« on: 25 Aug 2007, 15:52:57 »
I was unable to find a thread related to this with the search function.

I will now quote the "lbSetSelected" function's description:
Quote
Set the selection state of the given row of the given listbox.
Listbox must support multiple selection.

I presume the listbox can be made to support multiple selection via some description.ext classification line. What could that line be?

Offline LCD

  • Former Staff
  • ****
    • Everon Cartel
Re: Multiple selection listbox
« Reply #1 on: 25 Aug 2007, 15:58:32 »
listbox is somin in dialogs... reead da TUT by vektorboson... shud b helpfull

LCD OUT
"guess being the community has downsides .." - cheetah
Help Perfecting Da Next Best Thing - O-Team Beta

Offline einherj

  • Members
  • *
Re: Multiple selection listbox
« Reply #2 on: 25 Aug 2007, 16:05:18 »
I know what a listbox is and I know how to use them. Did you even read my post?

Actually the vektorboson's tutorial explains nothing related to the issue in hand.

Offline h-

  • OFPEC Site
  • Administrator
  • *****
  • Formerly HateR_Kint
    • OFPEC
Re: Multiple selection listbox
« Reply #3 on: 25 Aug 2007, 16:24:47 »
Dialogs are listed as being under the 'advanced' category so I moved this here.

Carry on.  :cool2:
Project MCAR   ---   Northern Fronts   ---   Emitter 3Ditor
INFORMATIVE THREAD TITLES PLEASE. "PLEASE HELP" IS NOT ONE..
Chuck Norris can divide by zero.

Offline LCD

  • Former Staff
  • ****
    • Everon Cartel
Re: Multiple selection listbox
« Reply #4 on: 25 Aug 2007, 16:33:04 »
lol d00d chill out :P  :cool2:

so dere was a lil misunderstandin :P

i think (didnt try it tho) dat its used 2 chose if da selection is higlighted (or selected)... use da row nd make it equal true itll make it higlight... but anywayz... y dont u try it ? :P

LCD OUT

p.s if im wrong... u dont have 2 kill me :P


ohh nd i forgot

WELCOME 2 OFPEC M8
"guess being the community has downsides .." - cheetah
Help Perfecting Da Next Best Thing - O-Team Beta

Offline Mandoble

  • Former Staff
  • ****
    • Grunt ONE and MandoMissile suite
Re: Multiple selection listbox
« Reply #5 on: 25 Aug 2007, 16:34:32 »
There seems to be two listbox control types: 5 (normal one) and 42 (didnt test that one). And three styles: 0 (single selection), 0x10 (textures) and 0x20 (multiple selection). You may play with these.

Offline LCD

  • Former Staff
  • ****
    • Everon Cartel
Re: Multiple selection listbox
« Reply #6 on: 25 Aug 2007, 16:36:50 »
ohhh now i understod da question  :blink: .......... just ignore me... im off 2 fell st00pid

LCD OUT
"guess being the community has downsides .." - cheetah
Help Perfecting Da Next Best Thing - O-Team Beta

Offline einherj

  • Members
  • *
Re: Multiple selection listbox
« Reply #7 on: 25 Aug 2007, 17:15:55 »
No worries LCD, i just got a little frustrated.  :good:

It seems that the style 0x20 makes the listbox multiselectable so I defined a new style in my description.ext for easier remembering:
Code: [Select]
#define ST_MULTIPLESELECTION 0x20

I can now choose multiple items in the listbox by holding CTRL or SHIFT and selecting them

Thank you Mandoble for enlightening me in this matter :clap:

Offline Spooner

  • Members
  • *
  • Mostly useless
    • Community Base Addons
Re: Multiple selection listbox
« Reply #8 on: 26 Aug 2007, 22:32:43 »
I was just about to ask this question, so thanks for that! I'd tried 0x10 already, but it just changed the look of the listbox, without allowing multiple-selection.
« Last Edit: 26 Aug 2007, 22:35:12 by Spooner »
[Arma 2] CBA: Community Base Addons
[Arma 1] SPON Core (including links to my other scripts)