Hi
What four-part version of which DLL are you using?
What is the unhandled exception?
How did you declare/initialize the Overview control?
First, 1.2.1.* is not a supported version – that was a beta version. You should install and use the latest kit, for version 1.2.6.4.
Second, what was the unhandled exception? Yes, that’s the declaration for the unhandled exception handler. But I’d like to get as much information as possible about what the exception was, and what happened to cause the exception.
Third, how did you declare the Overview control in XAML?
We really need more information to be able to guess what’s happening in your application.
VerticalAlignment="Top"
Ish*tTestVisible="True">
BusyContent="loading................"
Foreground="Black">
<go:Diagram x:Name="rcDiagram"
Width="Auto"
Height="Auto"
Margin="10,25,0,10"
HorizontalAlignment="Left"
VerticalAlignment="Top"
AllowClipboard="False"
AllowCopy="False"
AllowDelete="False"
AllowMove="False"
AllowUndo="False"
Background="White"
BorderBrush="{x:Null}"
LinkTemplate="{StaticResource LinkTemplate}"
MaximumSelectionCount="1"
NodeTemplateDictionary="{StaticResource NodeTemplateDictionary}"
Padding="75">
<Grid x:Name="OverViewPaneGrid"
Width="180"
Height="146"
Margin="0,0,25,2"
HorizontalAlignment="Right"
VerticalAlignment="Bottom"
MouseRightButtonUp="OverViewPaneGrid_MouseRightButtonUp">
Fill="White"
RadiusX="5"
RadiusY="5"
Stroke="DarkGray" />
<go:Overview x:Name="myOverview"
Width="180"
BorderBrush="White" />
Width="23"
Height="146"
Margin="0,0,0,2"
HorizontalAlignment="Right"
VerticalAlignment="Bottom">
<Grid Height="19"
Margin="0,3,4,0"
VerticalAlignment="Top">
<Button x:Name="Plus"
Margin="1,-2,2,0"
Content="+"
Style="{StaticResource +ButtonStyle}" />
<Slider x:Name="myScaleSlider"
Height="100"
Margin="-6,0,0,0"
HorizontalAlignment="Center"
Cursor="Arrow"
Maximum="3"
Minimum="0"
Orientation="Vertical" />
<Button x:Name="minus"
Height="19"
Margin="0,0,4,3"
VerticalAlignment="Bottom"
Content="-"
Style="{StaticResource -ButtonStyle}" />
Thanks for the XAML, but the important information is still missing: what was the unhandled exception, and have you upgraded to 1.2.6?
Here is additional information.
Timestamp: Fri, 22 Apr 2011 16:31:05 UTC
Message: Unhandled Error in Silverlight Application
Code: 4004
Category: ManagedRuntimeError
Message: System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary.
at System.ThrowHelper.ThrowKeyNotFoundException()
at System.Collections.Generic.Dictionary`2.get_Item(TKey key)
at System.Windows.ResourceManagerWrapper.GetResourceForUri(Uri xamlUri, Type componentType)
Char: 13
Code: 0
Well, the error message clearly shows that you are trying to use a resource name that isn’t defined in any of the resource dictionaries in your application.
Unfortunately Silverlight doesn’t provide good error messages, so it isn’t clear exactly what the key value was.
You’ll need to track down what the problem is. You could try breaking on the KeyNotFoundException in Visual Studio and then look at the stack.
But how would I capture the KeyNotFoundException, if the system is not even getting in to the unhandledException block.
While running the program in the debug mode using VS2010, Its not even hitting any breakpoint, when the error happens. The app is crashing with white screen in browser (IE) and javascript error icon in the bottom left corner of the screen.
This jscript error is thrown from the default implementation of the html page (object tag), where the jscript method is called on OnError event.
In Visual Studio, bring up the Debug > Exceptions window and check the Thrown checkbox to break on that exception, which I believe is listed under System.Windows.
well, its been a while since I replied to this post. We are getting the same error in a difference scenario. Based on your recommendation, I checked Throw for the KeyNotFound exception in the Exception dialog box, under debug menu.
Message=Operation is not valid due to the current state of the object.
StackTrace:
at System.Windows.DependencyObject.MS.Internal.IManagedPeerBase.get_NativeObject()
at System.Windows.DependencyObject.AddEventListener(DependencyProperty property, Delegate handler, Boolean handledEventsToo)
at System.Windows.UIElement.AddHandler(RoutedEvent routedEvent, Delegate handler, Boolean handledEventsToo)
at System.Windows.UIElementExtensions.<>c__DisplayClass2a.b__27(IObserver`1 observer)
at System.Windows.Controls.Internals.AnonymousObservable`1.<>c__DisplayClass1.b__0()
at System.Windows.Controls.Internals.CurrentThreadScheduler.EnsureTrampoline(Action action)
at System.Windows.Controls.Internals.AnonymousObservable`1.Subscribe(IObserver`1 observer)
at System.Windows.Controls.Internals.Observable.<>c__DisplayClass2d`1.<>c__DisplayClass2f.b__2c(Object o)
InnerException:
This is yet another stack trace that doesn’t appear to have anything to do with GoXam.
From what I see nothing makes sense. Perhaps you can find some clues by searching the web for those exceptions and internal Silverlight methods.
Another possibility is that somehow the Silverlight implementation has been corrupted. Do you get the same error on different machines?