Adding Global Toolbar to WPF Application (C#)

Asparagus

Senior member
Aug 16, 2001
284
1
81
WPF/C# newbie here...

I have a WPF app with several pages. I've created a toolbar with a custom logo on it and a few icons. Each time I add a new page to the app, I have to manually copy/paste the code for the toolbar into each new page's XAML file. Is there a way that I can define the toolbar in App.xaml and make it be an inherent part of each new page I create?
 

Crusty

Lifer
Sep 30, 2001
12,684
2
81
You can create the toolbar as a custom User Control and just place it on each of your forms during design time like you would any other form element, or I believe you can use a Resource Dictionary.

I'm not too familiar with the Resource Dictionary route(I've only been doing WPF for a month or so now)