Bug 52356 - App's Resource Dictionary not available to Control Template
Summary: App's Resource Dictionary not available to Control Template
Alias: None
Product: Forms
Classification: Xamarin
Component: Forms ()
Version: 2.3.3
Hardware: Macintosh Mac OS
: Normal normal
Target Milestone: ---
Assignee: Paul DiPietro [MSFT]
Depends on:
Reported: 2017-02-07 11:54 UTC by david
Modified: 2017-06-20 00:03 UTC (History)
3 users (show)

Tags: resourcedictionary
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description david 2017-02-07 11:54:59 UTC
Trying to use a Control Template to set up a default container for my page content.

I want to use styles and colours etc defined in App.xaml's ResourceDictionary just as I do in ContentPage XAML and other ContentViews. However it doesn't work. The app's resource dictionary appears to be out of scope for the control template.

As a potential workaround I tried copying the resources to a common resource dictionary class and using the MergedWith attribute on the control template, app and page, but this only crashed the app.
Comment 1 Paul DiPietro [MSFT] 2017-02-27 17:28:01 UTC
Can you upload a reproduction project just so I can verify what you're trying to do?
Comment 2 Samantha Houts [MSFT] 2017-06-20 00:03:02 UTC
Because we have not received a reply to our request for more information we are closing this issue. If you are still encountering this issue, please reopen the ticket with the requested information. Thanks!