I wonder if any smart people out there can help me ...
I keep gettng Object reference not set to an instance of an object whenever
I run my aspx page.
I cannot understand why I keep getting this as a while ago this page worked
fine with as far as I can tell no modifications. I have underlined the line
where it throws the exception. I am using DreamweaverMX's Datasets if that
makes any difference :)
I have included the code down to the error line if that helps...
Thanks
<!-- #include file="nocache.asp" -->
<!-- #include file="BasketTotal.aspx" -->
<%@ Page Language="VB" ContentType="text/html" ResponseEncoding="iso-8859-1"
debug="true" %>
<%@ Register TagPrefix="MM" Namespace="DreamweaverCtrls"
Assembly="DreamweaverCtrls,version=1.0.0.0,publicK eyToken=836f606ede05d46a,culture=neutral"
%>
<MM:DataSet
id="dbMenu"
runat="Server"
IsStoredProcedure="false"
ConnectionString='<%#
System.Configuration.ConfigurationSettings.AppSett ings("MM_CONNECTION_STRING_CMC")
%>'
DatabaseType='<%#
System.Configuration.ConfigurationSettings.AppSett ings("MM_CONNECTION_DATABASETYPE_CMC")
%>'
CommandText='<%# "SELECT
categoryID,CatLink,subcategoryid=0,name=categoryna me FROM category union
all select categoryid,CatLink,subcategoryid,name=subcategoryn ame from
subcategory ORDER BY categoryid,subcategoryid" %>'
Debug="true"
</MM:DataSet> <MM:DataSet
id="QryBasketItems"
runat="Server"
IsStoredProcedure="false"
ConnectionString='<%#
System.Configuration.ConfigurationSettings.AppSett ings("MM_CONNECTION_STRING_CMC")
%>'
DatabaseType='<%#
System.Configuration.ConfigurationSettings.AppSett ings("MM_CONNECTION_DATABASETYPE_CMC")
%>'
CommandText='<%# "SELECT COUNT(DISTINCT(sku)) AS TOTALSKUS FROM
dbo.basket_detail INNER JOIN dbo.Basket ON dbo.Basket.Basket_id =
dbo.Basket_detail.Basket_id WHERE dbo.Basket.Shopper_ID =shopper_id" %>'
Debug="true"<Parameters>
<Parameter Name="@shopper_id" Value='<%# IIf((Not
Request.Cookies("shopGuid")("Guid") Is Nothing), Request.Cookies(IIf((Not
Request.Cookies("shopGuid")("Guid") Is
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Nothing), "ShopGUID", 0)).Value, "") %>' Type="VarChar" />
------------------------------------------------------------------------
</Parameters>
</MM:DataSet>