SSTab problems 
Author Message
 SSTab problems

Hi,

Pretty new to this VB stuff, hopefully someone can
help me out.

I've created a Tab on a Window, and need to
dynamically rename the Tab Captions. I can rename
the first tab, but can't work out how to rename the
other 2.

Any ideas or fixes, would be appreciated.

Cheers,
Mick.



Tue, 16 Feb 1999 03:00:00 GMT  
 SSTab problems

Quote:

> Hi,

> Pretty new to this VB stuff, hopefully someone can
> help me out.

> I've created a Tab on a Window, and need to
> dynamically rename the Tab Captions. I can rename
> the first tab, but can't work out how to rename the
> other 2.

> Any ideas or fixes, would be appreciated.

> Cheers,
> Mick.

For i = 0 to 2
        SSTab1.Tab = i
        Select Case i
                Case 0
                        SSTab1.TabCaption = "Tab 0 Name"
                Case 1
                        SSTab1.TabCaption = "Tab 1 Name"
                Case 2
                        SSTab1.TabCaption = "Tab 2 Name"
        end select
next i

Peter

--

Quote:
>__________________________________________________________________


                                  _ / /_ \_______________________
Tel: (415) 372-6178              |  \  / /                       |
1300 South El Camino Real        |   \/\/                        |
Suite 600                        |                               |
San Mateo, CA 94402              | Cambridge Technology Partners |
Main: (415) 574-3710              -------------------------------
Fax: (415) 372-6200
__________________________________________________________________


Tue, 16 Feb 1999 03:00:00 GMT  
 SSTab problems

Peter,

Thanks for the reply, but your code does not seem to work either. I changed the
.TabCaption to .Caption to get it to compile, but with no success.

My code looks like this.....

SSTab1.Tab = 0
SSTab1.Caption = GetSetting("c:\\vb\\infoeye.ini", "Tab 1", "TabName", "General1")
SSTab1.Tab = 1
SSTab1.Caption = GetSetting("c:\\vb\\infoeye.ini", "Tab 2", "TabName", "General1")
SSTab1.Tab = 2
SSTab1.Caption = GetSetting("c:\\vb\\infoeye.ini", "Tab 3", "TabName", "General1")

I'm using VB 4.0 (don't know if that makes a difference).

Thanks Again,
Mick Furey.



Fri, 19 Feb 1999 03:00:00 GMT  
 SSTab problems


Quote:
>Peter,
>Thanks for the reply, but your code does not seem to work either. I changed the
>.TabCaption to .Caption to get it to compile, but with no success.
>My code looks like this.....

Hi Mick:
Since I don't use this Tab control I'm only guessing but the Video
Soft Tabs are accessed as an array.

Like this. It would also explaing why you could set the first one and
not the others (i.e. being the 1st it is the default).

SSTab1.Tab(1) = 0
SSTab1.Caption(1) = "Tab1"
SSTab1.Tab(2) = 1
SSTab1.Caption(2) = "Tab2"

Also I don't rember if they are base 0 or base 1.

Quote:
>SSTab1.Tab = 0
>SSTab1.Caption = GetSetting("c:\\vb\\infoeye.ini", "Tab 1", "TabName", "General1")
>SSTab1.Tab = 1
>SSTab1.Caption = GetSetting("c:\\vb\\infoeye.ini", "Tab 2", "TabName", "General1")
>SSTab1.Tab = 2
>SSTab1.Caption = GetSetting("c:\\vb\\infoeye.ini", "Tab 3", "TabName", "General1")
>I'm using VB 4.0 (don't know if that makes a difference).

Jim Huguley

* Those who sit and think *
* Mostly sit              *


Fri, 19 Feb 1999 03:00:00 GMT  
 SSTab problems

Quote:

> Peter,

> Thanks for the reply, but your code does not seem to work either. I changed the
> .TabCaption to .Caption to get it to compile, but with no success.

> My code looks like this.....

> SSTab1.Tab = 0
> SSTab1.Caption = GetSetting("c:\\vb\\infoeye.ini", "Tab 1", "TabName", "General1")
> SSTab1.Tab = 1
> SSTab1.Caption = GetSetting("c:\\vb\\infoeye.ini", "Tab 2", "TabName", "General1")
> SSTab1.Tab = 2
> SSTab1.Caption = GetSetting("c:\\vb\\infoeye.ini", "Tab 3", "TabName", "General1")

> I'm using VB 4.0 (don't know if that makes a difference).

> Thanks Again,
> Mick Furey.

OK.  I tried this myself in VB4.0 - 32bit and it seems to work:

For i = 0 to whatever
        SSTab1.TabCaption(i) = "tab caption " & i
next i

See if that doesn't do it for you....

Peter

__________________________________________________________________

                                  _ / /_ \_______________________
Tel: (415) 372-6178              |  \  / /                       |
1300 South El Camino Real        |   \/\/                        |
Suite 600                        |                               |
San Mateo, CA 94402              | Cambridge Technology Partners |
Main: (415) 574-3710              -------------------------------
Fax: (415) 372-6200
__________________________________________________________________



Sat, 20 Feb 1999 03:00:00 GMT  
 SSTab problems

Peter, Jim,

Thanks for your help. It's working now.
Thanks for taking the time to help out, this was much appreciated.

Cheers,
Mick.



Sun, 21 Feb 1999 03:00:00 GMT  
 
 [ 6 post ] 

 Relevant Pages 

1. SStab Problem - Dragover event

2. SSTab Problem

3. SStab Problem - Drag and Drop

4. SSTAB problem

5. SSTAB:Problem with creating tabs at runtime

6. SSTab problem

7. Horrendous SStab problems

8. SSTab problem

9. SSTab Problem/Queston.

10. SStab Problem

11. SSTab problem

12. SSTab problem

 

 
Powered by phpBB® Forum Software