Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Vb.Net - TabControl Hide Tab

Posted on 2013-05-28
4
Medium Priority
?
557 Views
Last Modified: 2013-05-29
Good Day Experts!

I have searched online but I am not quite sure how to go about this new task.  My application is centered around a Form that has a tabControl on it.  Currently there are 19 tabs on it.  The 20th Tab I added is the one causing the trouble.  I want to hide it for all but 3 Users.  So, in the Form_Load I am checking for Username but I cannot seem to get the syntax down for how to hide the tab.  Also, I am not sure what is going to happen when I have to add a tab for all Users to see right after the one I am hiding based on User.

What do you think?

Thanks,
jimbo99999
0
Comment
Question by:Jimbo99999
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 4

Expert Comment

by:frankd
ID: 39202138
I usually check for proper user on enter and go to another tab if that user isn't allowed.  Something like;
If User not allowed then
     TabControl1.SelectedTab = TabPage7    ' some other tab page
end if

I may be wrong, but I don't think you can hide a tab.
0
 
LVL 70

Accepted Solution

by:
Éric Moreau earned 2000 total points
ID: 39204122
0
 

Author Comment

by:Jimbo99999
ID: 39204468
Excellent...thanks I will try this morning.
0
 

Author Closing Comment

by:Jimbo99999
ID: 39205191
Thanks, it is working now.

Appreciate the help,
jimbo99999
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Creating an analog clock UserControl seems fairly straight forward.  It is, after all, essentially just a circle with several lines in it!  Two common approaches for rendering an analog clock typically involve either manually calculating points with…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …

636 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