Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8916405
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T05:14:06+00:00 2026-06-15T05:14:06+00:00

Initially I thought that it will be a very trivial functionality but now I

  • 0

Initially I thought that it will be a very trivial functionality but now I am not able to implement it.

My requirement is simple. I am programmatically setting the content of a TabItem. The content will be usercontrols. I want to set the text of the header of the TabItem based on the content.

Content doesn’t have a changed event so I am confused as to on which event should I write code.

Also I’m not able to find any style or anything on the net.

Any suggestions? Please help. Thanks in advance.

PS: Please let me know if you need any further information from my side.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T05:14:07+00:00Added an answer on June 15, 2026 at 5:14 am

    I think i got it. Not sure if this is the optimum solution so if anybody has a better solution than this then it will help me a lot.

    I made a custom tabitem and overrided OnContentChanged (Didnt knew that there is an overridable OnContentChanged :)). So my code is like below.

    
        public class TabItemData : TabItem
        {
            protected override void OnContentChanged(object oldContent, object newContent)
            {
                if (newContent.GetType().Name.ToLower().Contains("mycontrolname"))
                    this.Header = "control name";
                else
                    this.Header = "old name";
    
                base.OnContentChanged(oldContent, newContent);
            }
        }
    
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I initially thought that 64 bit instructions would not work on OS-X 10.5. I
Initially I thought this was going to work, but now I understand it won't
I initially thought that how to pass class attribute and value to markdown syntax
Initially I thought it was a CSS issue but I built a small sample
My animationDidStop method is not being called for some reason, initially I thought it
I am working on a simple notification service that will be used to deliver
So, very soon, I will be part of a migration that will move a
I'm hoping that someone has some workflow tips on tracking separate but very (90%)
For example: a) int [x][y][z] vs b) int[x*y*z] Initially thought I'd go with a)
I was trying to solve this problem - http://www.spoj.pl/problems/LISA/ I thought of Greedy initially,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.