Hi,
When I am adding some controls to a project I get the following message from VS2010. In particular the XamWebHtmlViewer, and the XamChart. VS2010 closes and reopens. Sometimes it recovers and allows you work with the design view and xaml view. It will allow you to run the project but when it return the error will occur again.
This issue is happenning on 2 machines. Win 7 Pro 64bit. We are using the trial version of the Silverlight controls.
Cheers
Phil
Normal 0 false false false EN-AU X-NONE X-NONE MicrosoftInternetExplorer4
System.InvalidOperationException
Layout measurement override of element 'Microsoft.Windows.Design.Platform.SilverlightViewProducer+SilverlightContentHost' should not return PositiveInfinity as its DesiredSize, even if Infinity is passed in as available size.
at System.Windows.UIElement.Measure(Size availableSize) at System.Windows.ContextLayoutManager.UpdateLayout() at System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg) at System.Windows.Media.MediaContext.InvokeOnRenderCallback.DoWork() at System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks() at System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget) at System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget) at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs) at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(Object source, Delegate method, Object args, Int32 numArgs, Delegate catchHandler)
Phil,
I created a support ticket on your behalf (CAS-46959-87H60Z) where we can continue discussing this issue.
Thank you for reporting this issue.
Hi Vlad,
The service pack helped enormously, however I am still occasionally getting some errors in the designer. Particularly after I stop debugging. The error is below. The xmal for the page is in bold.
<UserControl xmlns:ig="http://infragistics.com/Controls" x:Class="SilverlightApplication10.Spriva" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d" d:DesignHeight="300" d:DesignWidth="400" xmlns:toolkit="http://schemas.microsoft.com/winfx/2006/xaml/presentation/toolkit"> <Grid x:Name="LayoutRoot" Background="White"> <toolkit:HeaderedContentControl Height="16" HorizontalAlignment="Left" Margin="26,12,0,0" Name="headeredContentControl1" VerticalAlignment="Top" Width="120"> <Grid Height="Auto" HorizontalAlignment="Stretch" Name="grid1" VerticalAlignment="Stretch" Width="Auto" /> </toolkit:HeaderedContentControl> <HyperlinkButton Content="View CMI" Height="23" HorizontalAlignment="Left" Margin="300,12,0,0" Name="hyperlinkViewPDF" VerticalAlignment="Top" Width="100" Click="hyperlinkViewPDF_Click" /> <ig:XamWebHtmlViewer x:Name="htmlViewer" Margin="0,85,0,0" /> <Image /> </Grid></UserControl>
System.InvalidOperationExceptionAn unhandled exception was encountered while trying to render the current silverlight project on the design surface. To diagnose this failure, please try to run the project in a regular browser using the silverlight developer runtime. at Microsoft.Windows.Design.Platform.SilverlightViewProducer.OnUnhandledException(Object sender, ViewUnhandledExceptionEventArgs e) at Microsoft.Windows.Design.Platform.SilverlightViewProducer.OnViewUpdated() at Microsoft.Windows.Design.Platform.ViewProducerBase.<get_DesignModeValueProviderService>b__7(IInstanceBuilderContext invokingContext) at MS.Internal.Services.DesignModeValueProviderService.ValueTranslationServicePropertyInvalidated(Object sender, PropertyInvalidatedEventArgs e) at MS.Internal.Features.DesignModeValueProviderConnector.ValueTranslationServiceImpl.InvalidateProperty(ModelItem item, PropertyIdentifier property) at MS.Internal.FrameworkElementControl.FrameworkElementDesignTimePropertiesAdorner.SetDesignResizeMode(Boolean updateView) at MS.Internal.FrameworkElementControl.FrameworkElementDesignTimePropertiesAdorner..ctor(ModelItem item) at MS.Internal.FrameworkElementControl.FrameworkElementDesignTimePropertiesGrabHandleAdornerProvider.Activate(ModelItem item) at Microsoft.Windows.Design.Interaction.AdornerProvider.InvokeActivate(EditingContext context, ModelItem item) at MS.Internal.Features.AdornerProviderFeatureConnector.FeatureProvidersAdded(ModelItem item, IEnumerable`1 extensions) at Microsoft.Windows.Design.Policies.PolicyDrivenFeatureConnector`1.OnPolicyItemsChanged(Object sender, PolicyItemsChangedEventArgs e) at System.EventHandler`1.Invoke(Object sender, TEventArgs e) at Microsoft.Windows.Design.Policies.ItemPolicy.OnPolicyItemsChanged(PolicyItemsChangedEventArgs e) at MS.Internal.Policies.SoleSelectionPolicy.RaisePolicyItemsChanged(ModelItem oldSoleSelection, ModelItem newSoleSelection) at MS.Internal.Policies.SoleSelectionPolicy.OnSelectionChanged(Selection newSelection) at Microsoft.Windows.Design.ContextItemManager.SubscribeProxy`1.SubscribeContext(ContextItem item) at Microsoft.Windows.Design.SubscribeContextCallback.Invoke(ContextItem item) at Microsoft.Windows.Design.EditingContext.DefaultContextItemManager.OnItemChanged(ContextItem item) at Microsoft.Windows.Design.EditingContext.DefaultContextItemManager.SetValue(ContextItem value) at MS.Internal.Designer.VSDesigner.VSDesignerClientImpl.RestoreSelection(List`1 selectionOffsetsInXamlFile) at MS.Internal.Designer.VSDesignerClient.RestoreSelection(List`1 offsetsInXamlFile) at MS.Internal.Designer.DesignerPane.LoadDesignerView() System.NullReferenceExceptionObject reference not set to an instance of an object. at MS.Internal.XcpImports.MethodEx(IntPtr ptr, String name, CValue[] cvData) at MS.Internal.XcpImports.MethodEx(DependencyObject obj, String name) at MS.Internal.XcpImports.UIElement_UpdateLayout(UIElement element) at Microsoft.Windows.Design.Platform.SilverlightViewProducer.OnViewUpdated()
I am also using Resharper 5.0
This is a known issue (#33710) with the XamWebHtmlViewer that is addressed for the next service release. In the meantime you can try to set Width and Height of the control.