Hello Every one,
I am getting following error while showing the Total amount on the header page. I have add the following code in header.ascx.cs in page load. Please give me solution for the following error.
ShoppingCart Cart = ShoppingCartManager.GetCurrentShoppingCart(ShoppingCartTypeEnum.ShoppingCart);
decimal applieddiscount;
decimal subTotalDiscountBase = decimal.Zero;
Discount appliedDiscount = null;
List<AppliedGiftCard> appliedGiftCards = null;
decimal subtotalBaseWithoutPromo = decimal.Zero;
decimal subtotalBaseWithPromo = decimal.Zero;
string SubTotalError = ShoppingCartManager.GetShoppingCartSubTotal(Cart, NopContext.Current.User, out subTotalDiscountBase, out appliedDiscount, out appliedGiftCards, out subtotalBaseWithoutPromo, out subtotalBaseWithPromo);
string shoppingCartSubTotal = ShoppingCartManager.GetShoppingCartSubTotal(Cart, NopContext.Current.User, out applieddiscount, out appliedDiscount, out appliedGiftCards, out subtotalBaseWithoutPromo, out subtotalBaseWithPromo);
Error 21 The best overloaded method match for 'NopSolutions.NopCommerce.BusinessLogic.Orders.ShoppingCartManager.GetShoppingCartSubTotal(NopSolutions.NopCommerce.BusinessLogic.Orders.ShoppingCart, NopSolutions.NopCommerce.BusinessLogic.CustomerManagement.Customer, out decimal, out NopSolutions.NopCommerce.BusinessLogic.Promo.Discounts.Discount, bool, out decimal, out decimal)' has some invalid arguments C:\NopCommerceStore\Modules\Header.ascx.cs 70 36 NopCommerceStore
I have added the following lines in the Header.ascx
<li><a href="<%=Page.ResolveUrl("~/ShoppingCart.aspx")%>" class="ico-cart">
<%=GetLocaleResourceString("Account.ShoppingCart")%>
</a><a href="<%=Page.ResolveUrl("~/ShoppingCart.aspx")%>">(<%=ShoppingCartManager.GetCurrentShoppingCart(ShoppingCartTypeEnum.ShoppingCart).Count%>)</a>
<strong>
<%=GetLocaleResourceString("ShoppingCart.OrderTotal")%>:$</strong>
<asp:Label ID="lblTotalAmount" runat="server" CssClass="productPrice" />
</li>
i want to show the total on the lblTotalAmount.. Please provide help for solving this problem by giving any example.