HomeHome Product Discus... Product Discus...SmithCartSmithCart4.24 Category Discount error and others4.24 Category Discount error and others
Previous
 
Next
New Post
3/31/2011 10:34 PM
 

This error occurs when Category level discount is applied, when the product is not a variant, and no other items are in the cart.  

DotNetNuke.Services.Exceptions.PageLoadException: Value cannot be null. Parameter name: source ---> System.ArgumentNullException: Value cannot be null. Parameter name: source at System.Data.DataTableExtensions.AsEnumerable(DataTable source) at Smith.DNN.Modules.BuyNow.MyQtyDiscount.GetCategoryQtyDiscount(Int32 ProductID, Decimal Quantity, Decimal price, DataTable _ProductList) at Smith.DNN.Modules.BuyNow.ProductsList.AddToCart(Int32 ProductID, Decimal Quantity, Decimal price, Boolean isRequired, Int32 bundleID, Boolean inBundle, Decimal myWeight, Int32 catID) at Smith.DNN.Modules.BuyNow.ProductsList.btnAddBasket_Click(Object sender, EventArgs e) at System.Web.UI.WebControls.Button.OnClick(EventArgs e) at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) at System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) --- End of inner exception stack trace ---

If items are already in the cart, there is no error.

I also have these 2 errors in my event viewer.

DotNetNuke.Services.Exceptions.PageLoadException: Object reference not set to an instance of an object. ---> System.NullReferenceException: Object reference not set to an instance of an object. at Smith.DNN.Modules.BuyNow.Step1.GetItemTotal() at Smith.DNN.Modules.BuyNow.Step1.GetTax() at Smith.DNN.Modules.BuyNow.Step1.GetTotalAfterTax() at Smith.DNN.Modules.BuyNow.Step1.ibNext_Click(Object sender, EventArgs e) at System.Web.UI.WebControls.Button.OnClick(EventArgs e) at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) at System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) --- End of inner exception stack trace ---

AbsoluteURLReferrer: https://huntersclub.com/Store/tabid/119/ctl/Step2/mid/513/Default.aspx
UserAgent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.16) Gecko/20110319 Firefox/3.6.16
DefaultDataProvider: DotNetNuke.Data.SqlDataProvider, DotNetNuke.SqlDataProvider
ExceptionGUID: 671dabb7-f189-4922-9398-b4c454df6de3
InnerException: Object reference not set to an instance of an object.
FileName
FileLineNumber: 0
FileColumnNumber: 0
Method: Smith.DNN.Modules.BuyNow.Confirm.GetItemTaxTotal
StackTrace
Message: DotNetNuke.Services.Exceptions.PageLoadException: Object reference not set to an instance of an object. ---> System.NullReferenceException: Object reference not set to an instance of an object. at Smith.DNN.Modules.BuyNow.Confirm.GetItemTaxTotal() at Smith.DNN.Modules.BuyNow.Confirm.GetTax() at Smith.DNN.Modules.BuyNow.Confirm.GetTotalAfterTax() at Smith.DNN.Modules.BuyNow.Confirm.Page_Load(Object sender, EventArgs e) at System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) at System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) at System.Web.UI.Control.OnLoad(EventArgs e) at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) --- End of inner exception stack trace ---
 

Nothing makes me happier than knowing someone was about to purchase items from my store but was deterred because the store failed them.

 

 
New Post
4/2/2011 3:13 AM
 
Do you get this error every time category discounts are applied or is it intermittent? Was there anything that triggered this error to start happening like an upgrade? or did you just start using category discounts?

At your service,
Dave Smith
DotNetNuke Consulting, DotNetNuke Store and DNN Ecommerce
 
New Post
4/2/2011 3:31 PM
 

I am still on 4.24.   These errors have been happening the entire time but I didn't realize it.  

Since product level discounts are broke, I decided to use category level discounts.   I have that radio button checked, but I do not have any category level discounts to apply at this time.   Maybe it doesn't like that?

Here is a new error.  


InnerException: Object reference not set to an instance of an object.
FileName
FileLineNumber: 0
FileColumnNumber: 0
Method: Smith.DNN.Modules.BuyNow.Confirm.GetItemTotal
StackTrace
Message: DotNetNuke.Services.Exceptions.PageLoadException: Object reference not set to an instance of an object. ---> System.NullReferenceException: Object reference not set to an instance of an object. at Smith.DNN.Modules.BuyNow.Confirm.GetItemTotal() at ASP.desktopmodules_smith_buynow_confirm_ascx.__Render__control19(HtmlTextWriter __w, Control parameterContainer) in d:\Projects\HuntersClub\DesktopModules\Smith.BuyNow\Confirm.ascx:line 157 at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.HtmlControls.HtmlTableRow.RenderChildren(HtmlTextWriter writer) at System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at ASP.desktopmodules_smith_buynow_confirm_ascx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in d:\Projects\HuntersClub\DesktopModules\Smith.BuyNow\Confirm.ascx:line 112 at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.Control.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at DotNetNuke.UI.Modules.ModuleHost.RenderContents(HtmlTextWriter writer) at System.Web.UI.WebControls.WebControl.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at ASP.portals_1_containers_flex2_set1_dgrad_header___boxed_ascx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in D:\Projects\HuntersClub\Portals\1\Containers\Flex2-Set1\DGrad Header - Boxed.ascx:line 15 at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.Control.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at ASP.portals_1_skins_flex2_h_bar_dgrad_template_01_ascx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in D:\Projects\HuntersClub\Portals\1\Skins\Flex2-H-Bar-DGrad\Template-01.ascx:line 110 at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.Control.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.Control.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.HtmlControls.HtmlForm.RenderChildren(HtmlTextWriter writer) at System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer) at System.Web.UI.HtmlControls.HtmlForm.Render(HtmlTextWriter output) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.HtmlControls.HtmlForm.RenderControl(HtmlTextWriter writer) at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at ASP.default_aspx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in D:\Projects\HuntersClub\Default.aspx:line 5 at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at DotNetNuke.Framework.PageBase.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) --- End of inner exception stack trace ---

Obviously there are serious issues with GetItemTotal and GetItemTotalAfterTax or whatever the method is.   Maybe it is as easy as initializing each variable = 0? 

Here is another error.

Method: System.Data.RBTree`1.GetNodeByIndex
StackTrace
Message: DotNetNuke.Services.Exceptions.PageLoadException: There is no row at position 0. ---> System.IndexOutOfRangeException: There is no row at position 0. at System.Data.RBTree`1.GetNodeByIndex(Int32 userIndex) at Smith.DNN.Modules.BuyNow.Cart.grdFinal_RowDeleting(Object sender, GridViewDeleteEventArgs e) at System.Web.UI.WebControls.GridView.OnRowDeleting(GridViewDeleteEventArgs e) at System.Web.UI.WebControls.GridView.HandleDelete(GridViewRow row, Int32 rowIndex) at System.Web.UI.WebControls.GridView.HandleEvent(EventArgs e, Boolean causesValidation, String validationGroup) at System.Web.UI.WebControls.GridView.OnBubbleEvent(Object source, EventArgs e) at System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) at System.Web.UI.WebControls.GridViewRow.OnBubbleEvent(Object source, EventArgs e) at System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) at System.Web.UI.WebControls.ImageButton.OnCommand(CommandEventArgs e) at System.Web.UI.WebControls.ImageButton.RaisePostBackEvent(String eventArgument) at System.Web.UI.WebControls.ImageButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) --- End of inner exception stack trace 

And another...

InnerException: Value cannot be null. Parameter name: source
FileName
FileLineNumber: 0
FileColumnNumber: 0
Method: System.Data.DataTableExtensions.AsEnumerable
StackTrace
Message: DotNetNuke.Services.Exceptions.PageLoadException: Value cannot be null. Parameter name: source ---> System.ArgumentNullException: Value cannot be null. Parameter name: source at System.Data.DataTableExtensions.AsEnumerable(DataTable source) at Smith.DNN.Modules.BuyNow.MyQtyDiscount.GetCategoryQtyDiscount(Int32 ProductID, Decimal Quantity, Decimal price, DataTable _ProductList) at Smith.DNN.Modules.ProductDetail.ProductDetails.AddToCart(Int32 ProductID, Decimal Quantity, Decimal price, Boolean isRequired, Int32 bundleID, Boolean inBundle, Decimal myWeight, Int32 catID) at Smith.DNN.Modules.ProductDetail.ProductDetails.ibAddtoCart_Click(Object sender, EventArgs e) at System.Web.UI.WebControls.Button.OnClick(EventArgs e) at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) at System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) --- End of inner exception stack trace 

 

Love the stack trace usage.  Please let me know when the new version is out that fixes these issues.

 

 
 

 

 

 

 
New Post
4/4/2011 6:20 PM
 
I just set up a product on the www7 test portal, http://www7.smith-consulting.com/Products/tabid/61/ProductID/124/Default.aspx and tested the product level discounts and it works. I'll set up a new product now and test the category level discounts and let you know what i find.
 
New Post
4/4/2011 6:28 PM
 

I am not sure what version of SC is on www7 now, but it is well known and documented that product level discounts had a major bug.  I sent in video and screen shots from www7.   

 

 
New Post
4/4/2011 7:36 PM
 
The www7 test portal is running version 4.24. I havent seen the video you sent but i will check with Christian and see if he has it. In any event, I did set up product level discounts on www7 and they worked. I also just set up catagory level discounts for this product. http://www7.smith-consulting.com/Products/tabid/61/ProductID/124/Default.aspx. And the catagory level discounts calculated properly. Are there other steps that I need to go through to replicate the error your getting?
 
New Post
4/4/2011 7:39 PM
 
 
New Post
4/8/2011 6:37 PM
 
If you would like to first determine if the issue is with the latest version of the cart or an issue with your site you can login to our test portal and configure the cart settings to match your cart settings and try to replicate the issue.

Please send an email to support@smith-consulting.com if you need a login.

Kevin
 
New Post
4/8/2011 6:44 PM
 
This is the same error that happens when Product/Category etc discounts radio buttons are checked in BuyNow but quantity discounts are not applied in each individual product settings.

I thought that setting was needed for coupons, and it is not. I have unchecked those radio buttons.

Anyone wishing to use those settings should be aware that they must set quantity discounts for variants or they will get that error in the event viewer.

The other errors I listed may have been eliminated by me unchecking those radio buttons.

Also, it is impossible to test some of these errors on www7 because we do not have access to the event viewer. The error is written to the event viewer in exception handling and is not brought to the screen.
 
Previous
 
Next
HomeHome Product Discus... Product Discus...SmithCartSmithCart4.24 Category Discount error and others4.24 Category Discount error and others