<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: AddBookmark problem using new Silverlight API v2.2.0.629 in ArcGIS API for Silverlight Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355909#M9106</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;This issue was logged as [#NIM076787&amp;nbsp; Adding a bookmark during the Bookmark::Loaded event using the Bookmark::AddBookmark method returns a Null Reference error.&amp;nbsp; ].&amp;nbsp; A fix is currently in QA.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In the meantime, it is necessary to create a Bookmark.MapBookmark object and add it to the bookmarks collection.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//workaround using ESRI.ArcGIS.Client.Toolkit.Bookmark.MapBookmark()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Bookmark.MapBookmark mbitem= new Bookmark.MapBookmark();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;mbitem.Extent = myExtent;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;mbitem.Name = "Test";&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;myBookMarks.bookmarks.Add(mbitem);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;API reference for Bookmark.MapBookmark class:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/silverlight/apiref/ESRI.ArcGIS.Client.Toolkit~ESRI.ArcGIS.Client.Toolkit.Bookmark+MapBookmark_members.html"&gt;http://help.arcgis.com/en/webapi/silverlight/apiref/ESRI.ArcGIS.Client.Toolkit~ESRI.ArcGIS.Client.Toolkit.Bookmark+MapBookmark_members.html&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 27 Apr 2012 20:11:07 GMT</pubDate>
    <dc:creator>JohnGravois</dc:creator>
    <dc:date>2012-04-27T20:11:07Z</dc:date>
    <item>
      <title>AddBookmark problem using new Silverlight API v2.2.0.629</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355902#M9099</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Has anybody else experienced problems using the Addbookmark method of the ESRI.ArcGIS.Client.Toolkit.Bookmark in the version 2.2 (2.2.0.629) of the Silverlight API? Since upgrading, I now get an "Object reference not set to an instance of an object" exception in VB.&amp;nbsp; Rolling the Client &amp;amp; Toolkit reference back to v2.1 (2.1.0.446) solves problem and works perfectly. I even tried using the bookmark code from the interactive samples on the ESRI site and this gives same error.&amp;nbsp; There are no documented changes to the Toolkit DLL listed on the site between V2.1 and V2.2.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 26 Sep 2011 12:51:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355902#M9099</guid>
      <dc:creator>KeithCollins</dc:creator>
      <dc:date>2011-09-26T12:51:09Z</dc:date>
    </item>
    <item>
      <title>Re: AddBookmark problem using new Silverlight API v2.2.0.629</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355903#M9100</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I can't reproduce the issue with the interactive &lt;/SPAN&gt;&lt;A href="http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#Bookmarks"&gt;sample&lt;/A&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Could you give more infos on how to reproduce the issue?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;You can also try to reset the application storage for this site :&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; - right click on the map&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; - silverlight dialog box&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; - application storage tab&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; - remove &lt;/SPAN&gt;&lt;A href="http://help.arcgis.com"&gt;http://help.arcgis.com&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 Sep 2011 15:09:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355903#M9100</guid>
      <dc:creator>DominiqueBroux</dc:creator>
      <dc:date>2011-09-27T15:09:57Z</dc:date>
    </item>
    <item>
      <title>Re: AddBookmark problem using new Silverlight API v2.2.0.629</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355904#M9101</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Dominique, thanks for replying.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;This is a very simple Silverlight project (Visual Web Developer 2010) to illustrate.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;If Client &amp;amp; Client Toolkit v2.1.0.446 is used then it works fine, if v2.2.0.629 is used then I get NullReferenceException on the gblBookMarks.AddBookmark statement.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;XML&lt;/STRONG&gt;&lt;SPAN&gt;&amp;lt;UserControl x:Class="SilverlightApplication5.MainPage"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt; xmlns="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://schemas.microsoft.com/winfx/2006/xaml/presentation" rel="nofollow" target="_blank"&gt;http://schemas.microsoft.com/winfx/2006/xaml/presentation&lt;/A&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt; xmlns:x="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://schemas.microsoft.com/winfx/2006/xaml" rel="nofollow" target="_blank"&gt;http://schemas.microsoft.com/winfx/2006/xaml&lt;/A&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt; xmlns:d="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://schemas.microsoft.com/expression/blend/2008" rel="nofollow" target="_blank"&gt;http://schemas.microsoft.com/expression/blend/2008&lt;/A&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt; xmlns:mc="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://schemas.openxmlformats.org/markup-compatibility/2006" rel="nofollow" target="_blank"&gt;http://schemas.openxmlformats.org/markup-compatibility/2006&lt;/A&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt; xmlns:esri="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://schemas.esri.com/arcgis/client/2009" rel="nofollow" target="_blank"&gt;http://schemas.esri.com/arcgis/client/2009&lt;/A&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; mc:Ignorable="d"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; d:DesignHeight="300" d:DesignWidth="400"&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;Grid x:Name="LayoutRoot" Background="White"&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;!-- Map Control --&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;esri:Map x:Name="Map" Background="White" Loaded="Map_Loaded" IsLogoVisible="False" ZoomDuration="0:00:02" PanDuration="0:00:02"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Canvas.Left="0" Canvas.Top="0" Height="600" Width="800" Cursor="Arrow"&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;esri:Map.Extent&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;esri:Envelope XMin="-20037507.2295943" XMax="20037507.2295943" YMin="-19971868.8804086" YMax="19971868.8804086"&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;esri:Envelope.SpatialReference&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;esri:SpatialReference WKID="102100"/&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;/esri:Envelope.SpatialReference&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;/esri:Envelope&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;/esri:Map.Extent&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;esri:Map.Layers&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;esri:ArcGISTiledMapServiceLayer ID="BaseLayer"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt; Url="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer" rel="nofollow" target="_blank"&gt;http://services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer&lt;/A&gt;&lt;SPAN&gt;" Opacity="60" /&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;/esri:Map.Layers&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;/esri:Map&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;/Grid&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;/UserControl&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;VB&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Imports Microsoft.VisualBasic&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Imports System&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Imports System.IO&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Imports System.Collections.Generic&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Imports System.Windows.Controls&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Imports System.Windows.Media&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Imports ESRI.ArcGIS.Client&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Imports ESRI.ArcGIS.Client.Geometry&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Imports ESRI.ArcGIS.Client.Symbols&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Public Class MainPage&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Inherits UserControl&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Public Shared gblBookMarks As New ESRI.ArcGIS.Client.Toolkit.Bookmark&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; Public Sub New()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; InitializeComponent()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; End Sub&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Private Sub Map_Loaded(ByVal sender As Object, ByVal e As System.Windows.RoutedEventArgs) Handles Map.Loaded&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Map.Focus()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; AddBookMark("TEST", -234635, 7787628, -228574, 7791485)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; End Sub&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; Private Sub AddBookMark(ByVal Name As String, ByVal XMin As Double, ByVal YMin As Double, ByVal XMax As Double, ByVal YMax As Double)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; Dim bmextent As New ESRI.ArcGIS.Client.Geometry.Envelope&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; bmextent.XMin = XMin : bmextent.YMin = YMin&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; bmextent.XMax = XMax : bmextent.YMax = YMax&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; 'bmextent.SpatialReference = _Map.SpatialReference&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; gblBookMarks.AddBookmark(Name, bmextent)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; End Sub&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;End Class&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Oct 2011 07:18:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355904#M9101</guid>
      <dc:creator>KeithCollins</dc:creator>
      <dc:date>2011-10-04T07:18:57Z</dc:date>
    </item>
    <item>
      <title>Re: AddBookmark problem using new Silverlight API v2.2.0.629</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355905#M9102</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I don't see in your code when and how is initialized 'gblBookMarks', so it's difficult to analyze why it's null.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Nevertheless it seems you are relying on the load order i.e. the bookmark is loaded before the map.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Why not add your first bookmark when the bookmark is loaded instead of the map?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Oct 2011 07:36:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355905#M9102</guid>
      <dc:creator>DominiqueBroux</dc:creator>
      <dc:date>2011-10-04T07:36:00Z</dc:date>
    </item>
    <item>
      <title>Re: AddBookmark problem using new Silverlight API v2.2.0.629</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355906#M9103</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Dominique,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;gblBookmarks is declared as public in the declarations section of the Main page VB Code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Public Shared gblBookMarks As New ESRI.ArcGIS.Client.Toolkit.Bookmark&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I missed a line out of the previous sample, in the Map_Loaded event (fired when map loads) there should be an additional line before adding the first bookmark (the bookmark is not added until map is loaded as far as I can understand):&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;gblBookMarks.Map = Map&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This associates the bookmark object with the map.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;To be clear, I am not using the standard bookmark control as provided - I am setting up my own bookmark object and populating it with bookmarks - these bookmarks are shown in a custom dialog, and I have code to handle when one is selected which zooms the map to the appropriate extent.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The ESRI.ArcGIS.Client.Toolkit.Bookmark.Addbookmark method has the same parameters as previous DLL version (Public Sub AddBookmark(ByVal name As String, ByVal extent As ESRI.ArcGIS.Client.Geometry.Envelope). As far as I can see, I am correctly setting up an Envelope object to pass to the Addbookmark method, and the Name is also defined correctly as a string, so I cannot see what can possibly be null, and the same code worked perfectly in the previous version of the API.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for you assistance again.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Oct 2011 15:56:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355906#M9103</guid>
      <dc:creator>KeithCollins</dc:creator>
      <dc:date>2011-10-06T15:56:25Z</dc:date>
    </item>
    <item>
      <title>Re: AddBookmark problem using new Silverlight API v2.2.0.629</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355907#M9104</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Michelle,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I decided to have another look after getting your post, as it was driving me nuts.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Yesterday I downloaded the very latest Silverlight API (2.3.0.774) in the hope that the problem had been fixed, or to see if my previous installation had been corrupt in some way.&amp;nbsp; The same problem exists with the new version.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have come to the conclusion that the error is not related to the parameters being passed (Name and Extent), but is being triggered by something else that happens inside the DLL when the AddBookmark method is called.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I tried without success to set as many of the Bookmarks class properties as I could, to see if the null reference was down to them.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I eventually experimented by adding a physical bookmark control back in to the XAML (previously I had just created a new Bookmarks class object in code - which used to work with version 2.1).&amp;nbsp; After adding the object to the XAML, and using its name as the reference instead, I can get the code to work again.&amp;nbsp; I tried to set the visibility property of this object to collapsed (to hide it) - but this re-introduces the error condition.&amp;nbsp; This leads me to think that the API is trying to do something to a physical bookmark control, even if it is not there!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I then tried to set the width and height of the physical bookmark control to 10,10.&amp;nbsp; This also causes error, as I think the bookmark list is not visible.&amp;nbsp; Eventually, this code will now work - notice that the height has to be large enough to encompass the list region:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;XAML&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; &amp;lt;esri:Bookmark HorizontalAlignment="Left" Margin="0,0,0,0" Name="gblBookmarks" &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; VerticalAlignment="Top" Width="0" Height="100" Visibility="Visible"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Map="{Binding ElementName=Map1}" UseIsolatedStorage="False"/&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;VB&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Private Sub AddBookMark(ByVal Name As String, ByVal XMin As Double, ByVal YMin As Double, ByVal XMax As Double, ByVal YMax As Double)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim extent As New ESRI.ArcGIS.Client.Geometry.Envelope&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; extent.XMin = XMin : extent.YMin = YMin&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; extent.XMax = XMax : extent.YMax = YMax&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; gblBookmarks.AddBookmark(Name, extent)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;End Sub&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope this helps, not an ideal solution I know, but at least I can now start using the other new features in the latest API version.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Nov 2011 13:40:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355907#M9104</guid>
      <dc:creator>KeithCollins</dc:creator>
      <dc:date>2011-11-30T13:40:05Z</dc:date>
    </item>
    <item>
      <title>Re: AddBookmark problem using new Silverlight API v2.2.0.629</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355908#M9105</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Interestingly, further to the last post, I forgot to mention that I found the solution partly by experimenting with a couple of examples in the ESRI API Reference on the ArcGIS API For Silverlight Site.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;There are a couple of examples in the ESRI.Client.Toolkit.Bookmark section.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The example included in Methods/AddBookMark ("Four Corners Kiosk") when copied exactly as provided, fails with the same error message when run.&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/silverlight/apiref/ESRI.ArcGIS.Client.Toolkit~ESRI.ArcGIS.Client.Toolkit.Bookmark~AddBookmark.html"&gt;http://help.arcgis.com/en/webapi/silverlight/apiref/ESRI.ArcGIS.Client.Toolkit~ESRI.ArcGIS.Client.Toolkit.Bookmark~AddBookmark.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The second example provided at the main Bookmark class level (the one with Map of India) does work as provided.&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/silverlight/apiref/ESRI.ArcGIS.Client.Toolkit~ESRI.ArcGIS.Client.Toolkit.Bookmark.html"&gt;http://help.arcgis.com/en/webapi/silverlight/apiref/ESRI.ArcGIS.Client.Toolkit~ESRI.ArcGIS.Client.Toolkit.Bookmark.html&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Nov 2011 14:00:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355908#M9105</guid>
      <dc:creator>KeithCollins</dc:creator>
      <dc:date>2011-11-30T14:00:30Z</dc:date>
    </item>
    <item>
      <title>Re: AddBookmark problem using new Silverlight API v2.2.0.629</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355909#M9106</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;This issue was logged as [#NIM076787&amp;nbsp; Adding a bookmark during the Bookmark::Loaded event using the Bookmark::AddBookmark method returns a Null Reference error.&amp;nbsp; ].&amp;nbsp; A fix is currently in QA.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In the meantime, it is necessary to create a Bookmark.MapBookmark object and add it to the bookmarks collection.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//workaround using ESRI.ArcGIS.Client.Toolkit.Bookmark.MapBookmark()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Bookmark.MapBookmark mbitem= new Bookmark.MapBookmark();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;mbitem.Extent = myExtent;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;mbitem.Name = "Test";&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;myBookMarks.bookmarks.Add(mbitem);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;API reference for Bookmark.MapBookmark class:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/silverlight/apiref/ESRI.ArcGIS.Client.Toolkit~ESRI.ArcGIS.Client.Toolkit.Bookmark+MapBookmark_members.html"&gt;http://help.arcgis.com/en/webapi/silverlight/apiref/ESRI.ArcGIS.Client.Toolkit~ESRI.ArcGIS.Client.Toolkit.Bookmark+MapBookmark_members.html&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Apr 2012 20:11:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355909#M9106</guid>
      <dc:creator>JohnGravois</dc:creator>
      <dc:date>2012-04-27T20:11:07Z</dc:date>
    </item>
    <item>
      <title>Re: AddBookmark problem using new Silverlight API v2.2.0.629</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355910#M9107</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I was able to reproduce this bug it will be fixed in our next up comming release.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Apr 2012 22:54:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/addbookmark-problem-using-new-silverlight-api-v2-2/m-p/355910#M9107</guid>
      <dc:creator>ChristopherHill</dc:creator>
      <dc:date>2012-04-27T22:54:10Z</dc:date>
    </item>
  </channel>
</rss>

