On Wed, 13 Aug 2008 07:52:42 am M0E Lnx wrote: > I'm still having a little problem getting this to work > > I want to add tabs to a tabs strip, and populate the new tabs as I go > along. Here is an example of what I want to do > > With tabstrip1 > .count = .count + 1 ' this works... adds a new tab to the tabstrip > .index = .count ' This is where the problem is, it keeps saying bad index > End With > I want it to add a tab and select it so I can set this new tab's .text > property > > Any ideas or other ways to do it?
Not really sure what you want but I quickly typed this out and it works. Adds tabs, and changes tab name and puts button on some of them. Private tab As TabStrip Private bt As Button Public Sub form_Open() Dim x As Integer tab = New TabStrip(Me) tab.Arrangement = 5 'fill - will make the buttons fill the tab - there is probably a constant somewhere for this) For x = 1 To 5 Inc tab.count tab.text = "tab " & Str$(x) bt = New Button(tab) bt.text = "Button on tab " & Str$(x) Next End > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's > challenge Build the coolest Linux based applications with Moblin SDK & win > great prizes Grand prize is a trip for two to an Open Source event anywhere > in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user