.net WindowsFormsHost无法旋转。要抑制此错误,请处理LayoutError事件并将ThroweException设置为false
我在WPF中有VLC ActiveX插件控件.net WindowsFormsHost无法旋转。要抑制此错误,请处理LayoutError事件并将ThroweException设置为false,.net,xaml,vlc,windowsformshost,.net,Xaml,Vlc,Windowsformshost,我在WPF中有VLC ActiveX插件控件 <Grid> <WindowsFormsHost HorizontalAlignment="Stretch" Margin="0,0,0,0" Visibility="Hidden" Name="windowsFormsHost1" VerticalAlignment="Stretch" ClipToBounds="True" SnapsToDevicePixels="True" /> </Grid
<Grid>
<WindowsFormsHost HorizontalAlignment="Stretch" Margin="0,0,0,0" Visibility="Hidden" Name="windowsFormsHost1" VerticalAlignment="Stretch" ClipToBounds="True" SnapsToDevicePixels="True" />
</Grid>
有什么线索可以解决吗?这个错误很简单。您无法旋转或调整
WinFormsHost
控件的大小。请参阅。从错误中可以看出,您无法为嵌入式winforms控件设置动画。要修复它,请不要使用winforms控件。@mydogisbox是的。。。但这意味着我也放下了VLC ActiveX插件,买了一些在WPF中完成的其他东西。这很不幸,但错误信息似乎很清楚。
A WindowsFormsHost cannot be rotated. To suppress this error, handle the LayoutError event and set ThrowException to false.