Hello,
Welcome to Microsoft Newsgroup Support Service! My name is Marco Zhou. It's
my pleasure to work with you on this thread.
For your first question, the simple answer is no, there is an option to
wrap WPF content inside a Windows Forms UserControl, and expose this
UserControl as ActiveX control so that it could be consumable by HTML
container (aka sidebar container), but this is not a pure WPF solution. I
think you will be more successful if you choose Silverlight rather than WPF
because Silverlight provides much better and integrated support in HTML
interop.
For your second question, I don't fully understand which issue you are
referring to, in particular what you mean by "drag out of the sidebar". If
you mean that the hosted XBAP content cannot be stretched to fill its
available space as its neighboring HTML content does, then this is a known
issue.
When hosting WPF content in native container such as Windows Vista sidebar
container, due to the fact that WPF uses device independent pixels, but the
native HTML container use physical pixels, so both of WPF content and
native HTML content will be stretched up and down unequally. One simple fix
is to use System.Windows.Controls.Viewbox control to wrap the root element
of WPF content, so that the content can be stretched out as it is.
If you have any further questions on this issue, free feel to ask here, we
are glad to answer them.
--------------------------------------------------
Best regards,
Macro Zhou (v-*****@online.microsoft.com, remove 'online.')
Microsoft Online Community Support
Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
ms****@microsoft.com.
This posting is provided "AS IS" with no warranties, and confers no rights.