tabcontrol

Problems with tabcontrol (Silverlight 3) with MediaElement

Hello, I have tab control. Every tab item contains MediaElement. User can download media into them independently. I notice that every time when I toggle between tabs the according mediaelement fires MediaOpen as if there is some initialization every time. It's not so good and I don't know why is it and what should be done to avoid such b...

Silverlight TabControl Inheritance Fails in Expression Blend.

I create a basic TemplatedControl via Visual Studio. I then inherit TabControl instead of Control. It technically works (ie passes compile) but inside Expression Blend 3, I get an error " object reference not set to an instance of an object". Then if i click on the TabItem itself, the error goes away? anyone experience this? I tested ...

I have a focus problem in C# GUI with tabs

I have a focus problem in C# GUI with tabs. I start a process based on an event with the users focus on a tab, and then run the process. The process repaints the the entire GUI -- and I'd like to put the user back on the initial tab. Is there a way I can save the tab focus position when the event is triggered? Cheers ...

Show controls on multiple pages of a tab control in the designer

I want to use a tab control to switch between sets of data displayed in a DataGridView (currently I'm using radio buttons). At runtime I can just move controls from one tab to the next, but the SelectedIndexChanged event doesn't fire in the designer. private void tabControl1_SelectedIndexChanged(object sender, EventArgs e) { tabContro...

WPF TabItem Header Images

I've got a TabControl in WPF with 3 tabs, and each tab has an image next to the title of the tab. Here's an example <TabItem> <TabItem.Header> <StackPanel Orientation="Horizontal"> <Image Name="img" Height="auto" Width="auto" Source="images/1.png" /> <TextBlock...

Loop through controls in TabControl

I am looking for a way to loop through controls on a particular tab of a tabcontrol. For example, I have a tabcontrol with the following tabs: Cars, Pets, Admin On each of these tabs are several controls to display/edit/save data, etc. On the "Save" button, I would like to loop through the controls for that particular tab to check wh...

Multi-tab application (C#)

Hi, I'm creating a multi-tabbed .NET application that allows the user to dynamically add and remove tabs at runtime. When a new tab is added, a control is added to it (as a child), in which the contents can be edited (eg. a text box). The user can perform tasks on the currently visible text box using a toolbar/menu bar. To better expla...

WPF TabControl add extra tabs to a bound control

Hello, I have a Tab Control with a ItemsSource Binding. ... I want to add a predefined tab to the front called All that has an aggregate of all the other tabs, and I would also like to add a button at the end called Add so I can add a new tab. Is there an easy way of doing this ? Thanks, Raul ...

Remove TabPage: Dispose or Clear or both??

I am working on a windows form that has a TabControl named tabDocuments. I came across this piece of code that removes all pages from the TabControl. for (int i = tabDocuments.TabPages.Count - 1; i > -1; i--) { tabDocuments.TabPages[i].Dispose(); } tabDocuments.TabPages.Clear(); The person who wrote this code has already left ...

WPF: Default TabControl's active tab overlaps from it's container, how to replicate this?

Hi, I am subclassing a control from TabControl (to be able to add stuff alongside tabs, like modern browsers do), and I encountered this problem: The active tab of native TabControl (1st and 2nd control from the top in the picture) overlaps the border of ContentPresenter, hiding the thin line underneath. I copied the xaml from Aero dic...

TabControl > TabItem.Header > Image Source with IsSelected Property

How do I change an image source within my TabControl > TabItem > TabItem.Header using triggers? Here's what I have so far: <TabControl Name="tabctlMainTab" Style="{StaticResource PrimaryTabControl}" SelectionChanged="MainTab_SelectionChanged" Background="Transparent"> <TabIte...

Setting TTabControl color after XPManifest in Delphi

I have tabcontrol component on my form. After I put XPManifest, its color became white, I want to change it, but couldn't find color property. And I don't want to remove XPManifest as well. Is there any way to solve this issue? ...

Tabcontrol: How can you remove the tabpage title?

I have a tabcontrol used to display multiple image files in an application. I would like to remove the tabpage title when there is only one tabpage displayed, so I can use that screen space for the image. (This is similar to deselecting "Always show the tab bar" in Firefox.) Is this possible to do with the tabcontrol? Or am I better off...

Centre the background of a TabControl in WPF

I'm trying to get an image to float unstreched in the middle of my TabControl. I started with the below XAML which stretches the image. <TabControl> <TabControl.Background> <ImageBrush ImageSource="/LogoTest;component/logo_final.png" /> </TabControl.Background> </TabControl> I've tried various approaches ...

accessing tabcontrol from myclass.cs

why can't i access the tabcontrol from within myclass.cs? e.g. tabcontrol is on form1.cs and my code that tries to create a new tabpage is in myclass.cs. i've even tried setting tabcontrol property to public but that didnt work thnks :) ...

WPF - how to call mainwindow tabitems from inside a control

Hi, I have tabcontrol in my main window. The different tbas I create with custom controls (for edit, addition etc.). I want to be able to address the other tabs from inside the control, so that when, for example, I click submit at some of the forms, it activates a specific other tab. I tried with BaseWindow n = new BaseWindow(...

TabControl.Orientation?

I wanna set a TabControl that its header are in the left side instead of on top, how do I do that? ...

Need help with TabControl.ItemTemplate

Hello. How do I set the TabItem.Header to bindings taken from few fields, each binding shown in a different size, all in the place of the original header text; without overriding the default style and behavior of the header - I only need the text. I tried to set its template but then it creates a rectangle that contains the inner contr...

C# Tab switching in TabControl

Hi! Iam facing such problem, which I find hard to overcome. In WinForms I got a TabControl with n TabPages. I want to extend the Ctrl+Tab / Ctrl+Shift+Tab switching. so I wrote some code which works fine as long as the focus is on TabControl or on the Form. When application focus is INSIDE of TabPage (for example on a button which is pla...

UserControls, TabControl, Window confusion

I have a number of usercontrols inside tabitems in a tabcontrol in a main Window. One user control per tabitem all inside a window. After some code executes inside one of the controls (inside one of the tabitems), I want to enable/disable other tabitems. How can I do it? ...