Answered by:
WPF Control as WHS Add-In GUI

Question
-
Is it possible to use a WPF Control file as the GUI for a WHS Add-In console tab? If so how is this done? I have attempted to pass an instance of a WPF Control for the TabControl method, but I get a type error. I am coding in C# by the way...
Thanks for your help!
-Brennan Watt
Monday, August 4, 2008 5:17 PM
Answers
-
In order to install the 3.0 framework to your WHS you'll need to login to it with Remote Desktop, download this file and install it.
Tuesday, August 5, 2008 5:13 PMModerator
All replies
-
You have asked this question over here. I believe that the answer is "no", as that is not a feature of .Net Framework 2.0. The console was built using 2.0, so you should probably refrain from using features that were introduced in later versions.Monday, August 4, 2008 7:17 PMModerator
-
Remember that whatever control you pass back from your add-in must inherit from System.Windows.Forms.Control… something none of the standard WPF controls do.
Instead to make WPF work in the console it's best to have the control your add-in return either inherit from or contain an ElementHost control which in turn contains all of your WPF goodies.
For note though… even though you can do this (so long as you've deployed the 3.0 or 3.5 Framework to your WHS)... running WPF inside of the admin console isn't a tested or supported scenario.
Maybe instead of having your add-in target the admin console with WPF… consider breaking it into three pieces. One a simple WinForms UI that is used for limited configuration/administration and then your larger WPF app, ideally running on the client machine (where any heavy UI intensive lifting should occur)… both of which that talk to some underlying data provider/service of your own that runs on the server.
Monday, August 4, 2008 7:28 PMModerator -
Thank you for your help. Could you explain how I deploy .NET 3.0 framework to WHS?
Monday, August 4, 2008 8:10 PM -
In order to install the 3.0 framework to your WHS you'll need to login to it with Remote Desktop, download this file and install it.
Tuesday, August 5, 2008 5:13 PMModerator