Getting the Basket for Shipment selection

Hi,

I'm there to develope the checkout process, as basic information, I take the code from the StarterSite.

But there is a problem: In the StarterSite it gets the actual basket over BasketHelper helper = new BasketHelper(BasketName). The problem is that i cet the basket with the right ID but that one doesnt contain any Line Items or even a total cost. So what do I have to do that it loads the basket correctly? Is there another way to do it?

Thanks

[477 byte] By [TaiChiMaster] at [2008-3-1]
# 1

BasketHelper assumes a couple of things. The first is that it assumes that CommerceContext.Current.UserID is set.

If you don't want to use BasketHelper you can use the order system directly.

CommerceContext.Current.OrderSystem.GetBasket(userGuid, basketName);

This will retrieve or create a new basket for the given user using the basketName (or you can leave off the basketName and the default basket will be returned).

The other situation that may be happening is that you aren't saving your basket after adding the lineitems. Make sure that you call Save() on the basket after adding the LineItems and running the basket pipeline (the basket pipeline will compute the subtotal for you).

JoeWasson-MSFT at 2007-9-4 > top of Msdn Tech,Commerce Server,Commerce Server 2007...