Hi guys,
I am trying to cache an XML file that is read repeatedly by my site but
I think that I am doing something quite wrong cause when I run my code
I get the following error:
No accessible overloaded 'XmlDocument.Load' can be called without a narrowing conversion
Does anyone have any suggestions as to what I am doing wrong? Here is my code below:
<code>
Dim siteMapFile As String = Cstr(ConfigurationSettings.AppSettings("siteMap"))
Dim siteMap As New XmlDocument()
If
System.Web.HttpContext.Current.Cache.Get("Site") IS Nothing Then
Dim myDataSet
as New DataSet()
myDataSet.ReadXml(Server.MapPath(SiteMapFile))
System.Web.HttpContext.Current.Cache.Insert("Site", myDataSet, New
CacheDependency(Server.MapPath(SiteMapFile)))
siteMap.Load(System.Web.HttpContext.Current.Cache.Get("Site"))
Else
siteMap.Load(System.Web.HttpContext.Current.Cache.Get("Site"))
End if
</code>
I would really appreciate any assistance that I get. Thanks