This is a migrated thread and some comments may be shown as answers.

VisualStudio Crashing in designmode

1 Answer 64 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Abdulhameed
Top achievements
Rank 1
Abdulhameed asked on 27 Mar 2012, 07:38 AM
I have a.xaml, b.xaml pages with RadControls a&b are called in Homepage.xaml. In design mode when i click on homepage in visudalstudio it is crashing. How could i stop this?

XAML
<UserControl x:Class="OSPAS_Dashboard.MainPage"
    xmlns:ospas="clr-namespace:OSPAS_Dashboard"
    mc:Ignorable="d"
    d:DesignHeight="1000" d:DesignWidth="770"
    xmlns:telerikQuickStart="clr-namespace:Telerik.Windows.Controls.QuickStart;assembly=Telerik.Windows.Controls">
     
    <Grid x:Name="LayoutRoot" Width="770">
        <Grid.RowDefinitions>
            <RowDefinition Height="100" x:Name="TilteRow" />
            <RowDefinition Height="*" x:Name="ChartseRow" />
        </Grid.RowDefinitions>
        <StackPanel Grid.Row="0" HorizontalAlignment="Center" VerticalAlignment="Center">
            <TextBlock Text="Saudi Aramco Operational Data" />
        </StackPanel>
        <Grid Grid.Row="1">
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="*" />
            <ColumnDefinition Width="10" />
            <ColumnDefinition Width="*" />
        </Grid.ColumnDefinitions>
        <StackPanel FlowDirection="LeftToRight" Grid.Column="0" Height="1000" HorizontalAlignment="Left">
            <ospas:LineChartControl x:Name="CrudeProductionRadChart"/>
            <ospas:LineChartControl x:Name="CrudeSalesRadChart"/>
 
        </StackPanel>
 
        <StackPanel FlowDirection="LeftToRight" Grid.Column="2" Height="1000" HorizontalAlignment="Left">
            <ospas:LineChartControl x:Name="RefinedProductsProductionRadChart"/>
            <ospas:LineChartControl x:Name="RefinedSalesRadChart"/>
            <ospas:AreaChartControl x:Name="RefinedProductsProductionRadChartArea"/>
        </StackPanel>
        </Grid>
    </Grid>
</UserControl>

Error Details
System.InvalidOperationException
An 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.ArgumentException
Value does not fall within the expected range.
   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()

1 Answer, 1 is accepted

Sort by
0
Zik
Top achievements
Rank 2
answered on 28 Mar 2012, 02:53 PM
I am seeing the same thing.  Even pages without Telerik controls are causing Visual Studio to crash.  The only thing that makes it not crash is removing the Telerik controls from the References.  What is really strange is if I load the MetroPageTransitions project that you guys posted it works just fine.  So why does my project crash?

UPDATE: ** Never mind, solved my problem.
Tags
General Discussions
Asked by
Abdulhameed
Top achievements
Rank 1
Answers by
Zik
Top achievements
Rank 2
Share this question
or