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 3675900
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T03:02:04+00:00 2026-05-19T03:02:04+00:00

Update I am embarrassed to say that I made a mistake. The error was

  • 0

Update

I am embarrassed to say that I made a mistake. The error was that my theme doesn’t style the elements I was using to test, so of course I wasn’t seeing the applied styles.

However, the answers made in response to this question do show how to explicitly set resources from one UserControl to another… which is interesting.

When I set resources on the application in the way I describe below, it does indeed implicitly set all user control themes in the resulting application.


I am using a theme, set as a ResourceDictionary on my main Application class. My main window I guess implicitly uses this theme to style itself.

<Application>
    <Application.Resources>
        <ResourceDictionary Source="Themes/ExpressionDark.xaml" />

The following comments are wrong, and everything is styled implicitly

When I show a dialog however, this is not styled.

DialogBox dialog = new DialogBox();
dialog.ShowDialog();

Is there some way to do this implicitly without specifying the style explicitly in the XAML of DialogBox?

Edit

I tried setting the resources in the following ways. They did not work.

Window main = App.Current.Windows[0];
dialog.Resources = main.Resources;
dialog.Owner = main;

Also tried setting the from the main App… which is where the original resources are defined.

dialog.Resources = App.Current.Resources;
  • 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-05-19T03:02:04+00:00Added an answer on May 19, 2026 at 3:02 am

    You could transfer resources one way or another, or just set the dialogue’s resources to the resources of the main window if you don’t need to specify dialogue specific resources as well:

        public Dialogue(Window owner)
        {
            this.InitializeComponent();
            Owner = owner;
            Resources = Owner.Resources;
        }
    

    (Since it’s a dialogue i set the Owner property as well)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

UPDATE: I made a mistake in my debugging - this question is not relavent
UPDATE: Focus your answers on hardware solutions please. What hardware/tools/add-in are you using to
Update: Now that it's 2016 I'd use PowerShell for this unless there's a really
UPDATE: Solution at bottom. I recently switched from using a set up such as
Update: I am sorry i pasted in list.xml twice by mistake, my question is
[update: I am using MySQL 4.1.25 ] I think this must be a simple
[UPDATE] Was just an idiot mistake. See end for solution. I am trying to
Update 14th May It's the mix of text sizes that breaks it, if I
Update Sir this is current code of my web page.I made changes according to
Update 2 : Found the forward declare bug that caused this Update : Compiled

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.