Tabber B+ selected?

Blitz3D Forums/Blitz3D Beginners Area/Tabber B+ selected?

Apollonius(Posted 2003) [#1]
MainTabber = CreateTabber(1,1,392,350,wndMain)
InsertGadgetItem MainTabber,0,"sum1"
InsertGadgetItem MainTabber,1,"sum2"
InsertGadgetItem MainTabber,2,"sum3"

I wana select thoses in the EventID $401 using EventSource() but i cant see how as we cant give it a variable, how?


soja(Posted 2003) [#2]
I'm not sure what you're asking... what is "thoses" and what is "it" (as in "give it a variable")?

Basically, if eventid() = $401 and eventsource() = MainTabber, then it means the user has clicked on one of the tabs and changed it. You can find out which one he clicked on with SelectedGadgetItem(MainTabber). What are you asking?


Apollonius(Posted 2003) [#3]
Exactly what you just answered lol,

You know Gadget Event($401)
If I take a button for example
CreateButton(...)
How will you tell if it was clicked in the $401 if it hasnt been stored in a Variable?
So you do this
var_whatever = CreateButton(...)
so now you can know.

So I thought
Tabsum1 = InsertGadgetItem MainTabber,0,"sum1"
Would do the same thing but It wasnt working so
SelectedGadgetItem() is the one I should use.. so you understand why I made the error now? ;)


soja(Posted 2003) [#4]
Oh, yeah, I get it. You were thinking the EventSource would be the tab itself, not the Tabber. Cheers.