Yes, I don't need to set the current shopping cart object to the shopping cart object.
ECommerceContext.CurrentShoppingCart = cart;
Cart has created properly but still i am not able to get ECommerceContext.CurrentShoppingCart.CartItems
[WebMethod]
private string getShoppingCart()
{
ShoppingCartInfo oShoppingCartInfo = ECommerceContext.CurrentShoppingCart;
bool isCurrentShoppingCartEmpty = false;
if(ShoppingCart.ShoppingCartGUID == Guid.Empty)
isCurrentShoppingCartEmpty = true;
if(!isCurrentShoppingCartEmpty)
{
List<clsShoppingCart> lstShoppingCart = new List<clsShoppingCart>();
foreach (ShoppingCartItemInfo item in ECommerceContext.CurrentShoppingCart.CartItems)
{
}
}
....
}
I am not getting any cart items which i have added in a previous step..
Getting true value inside isCurrentShoppingCartEmpty variable
Any guidance would be helpful.
Thanks