|
-
December 5th, 2002, 08:56 AM
#1
TabControl
Hello everyone
the Tabcontrol in .Net is not very adequate. I can't disable only one tab or I can't hide only one tab. Do you know a better tabControl?
Thank you
-
December 5th, 2002, 05:49 PM
#2
This disable's a tab page, is that what you want?, it works for me.
Code:
'disable this page
Me.TabPage3.Enabled = False
EDIT:
I think i may have mis-read your post, you want to disable the tab itself, i think the above disable's any controls on the tabpage.
I'm not sure how to disable or hide a tab.
Last edited by CC_; December 5th, 2002 at 08:55 PM.
-
December 6th, 2002, 08:35 AM
#3
I found this in VS help:
Use the Add method of the TabPages property.
' Visual Basic
Dim myTabPage As New TabPage()
myTabPage.Text = "TabPage" & (TabControl1.TabPages.Count + 2)
TabControl1.TabPages.Add(myTabPage)
Use the Remove method of the TabPages property to remove selected tabs; or to remove all tabs, use the Clear method of the TabPages property.
' Visual Basic
' Removes the selected tab:
TabControl1.TabPages.Remove(TabControl1.SelectedTab)
' Removes all the tabs:
TabControl1.TabPages.Clear()
Have a nice day! (^_^)
-
December 6th, 2002, 10:13 AM
#4
allright
but this will destroy the tab and all is controls. What I want is, I have two radio button, when radio button 1 is selected, the tab 3 isn't visible. If the radio button 2 is selected, the tab 3 is visible. The user can change the radio button selection so the tab must be hide and unhide and hide and unhide. If I remove the tab, I will remove all the controls. I don't want to create all the controls dynamicly each time
any solution?
Thank you
-
December 6th, 2002, 10:34 AM
#5
http://msdn.microsoft.com/msdnmag/is...s/default.aspx
This article discusses a problem similar to yours. Maybe you can get some insight from it.
Hope it helps.
Have a nice day! (^_^)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|