Multiple App.xaml in Solution

Posted on 2009-02-11
Last Modified: 2013-11-12
let's say I have a silverlight solution with three projects in it. First two are silverlight projects (application and web page for testing), and the third one is the project I added to be separated from the first two. When I define style and put it into App.xaml everything works just fine. My goal is to add another App.xaml (Silverlight Application Class) to the new project I created so I can have it all in one (classes and styles) project separated from the main silverlight projects (first two). I did it but it doesn't work, style is not applied and NewApp.Current.Resources.Count is zero even though i put style in it. If i put it back and adjust all headers to work, everything is fine again. What is my mistake?
Question by:zstapic
    1 Comment
    LVL 8

    Accepted Solution

    instead of creating another app.xaml, you can use <resourcedictionary> in your a seperate xaml. your all styles will come between
    <resourcedictionary> and </resourcedictionary> tags. and these will be root tags in your xaml.
    and whereever you want to use it, you can merge this resourcedictionary.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Suggested Solutions

    Title # Comments Views Activity
    Connecting Excel to SQL Server 3 88
    Windows Installer 4 52
    T-SQL Debugging - Temp Object Content 2 43
    Post a good COM tutorial 1 20
    This article shows a few slightly more advanced techniques for Windows 7 gadget programming, including how to save and restore user settings for your gadget and how to populate the "details" panel that is displayed in the Windows 7 gadget gallery.  …
    This article shows how to make a Windows 7 gadget that extends its U/I with a flyout panel -- a window that pops out next to the gadget.  The example gadget shows several additional techniques:  How to automatically resize a gadget or flyout panel t…
    This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA.…
    Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

    794 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

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now