Solved

Removing Tab Control  Header

Posted on 2002-04-23
5
364 Views
Last Modified: 2010-05-03
Hi,

I have created a tab control with 5 tabs. I am using tab control just to organize the information however I want to change the active tab programatically. For that I need to remove/hide the header that let user change the tab. Can I hide the header somehow. Any help would be appreciated. Solution may be in VB.Net or VB6 however solution is required in VB.Net.
Thanks

Akhwand
0
Comment
Question by:akhwand
5 Comments
 
LVL 3

Accepted Solution

by:
kenspencer earned 50 total points
ID: 6963919
Hi,

I can give you a method where you do not have to hide the tab header but can retain control.  My example:

    A form with a tab control (named SSTab1) and a Command Button (cmdPgmTab)

Option Explicit

Dim Master As Boolean

Private Sub cmdPgmTab_Click()
Dim x As Integer

    Master = True
    x = SSTab1.Tab + 1
    If x = 3 Then x = 0
    SSTab1.Tab = x
           
End Sub

Private Sub Form_Load()

    Master = False

End Sub

Private Sub SSTab1_Click(PreviousTab As Integer)

    If Master = False Then
        Master = True
        SSTab1.Tab = PreviousTab
    End If
   
    Master = False
   
End Sub

This way you have programmatic control of the tabs (by setting Master = True and then setting the tab you want).

Ken
0
 
LVL 3

Expert Comment

by:kenspencer
ID: 6963924
By the way, my example just has 3 tabs; any number would work.

Ken
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 6964344
The easiest way to make the TABS "almost" disappear, is to set the Tab Height property to 1 (cannot set it to 0, as that is an "invalid value"), but with a height o 1 Twip, the tabs are essentially gone.

By the way, what you are creating is commonly called a "wizard", as it leads the user through the steps of the application, allowing the developer to have a great deal of control over what happens, and when.

This is precisely how the Package and Deployment Wizard functions, for instance.

Arthur Wood
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 7660744
Hi akhwand,
It appears that you have forgotten this question. I will ask Community Support to close it unless you finalize it within 7 days. I will ask a Community Support Moderator to:

    Split points between: kenspencer and Arthur_Wood@devx

akhwand, if you think your question was not answered at all or if you need help, just post a new comment here; Community Support will help you.  DO NOT accept this comment as an answer.

EXPERTS: If you disagree with that recommendation, please post an explanatory comment.
==========
DanRollins -- EE database cleanup volunteer
0
 

Expert Comment

by:SpideyMod
ID: 7755446
per recommendation

SpideyMod
Community Support Moderator @Experts Exchange

Arthur_Wood: points for you at:
http://www.experts-exchange.com/Programming/Programming_Languages/Visual_Basic/Q_20463733.html
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question