Create new order using shopping cart - Kentico 11

Naresh Ede asked on February 8, 2021 03:48

Hi All,

We are developing an e-commerce application in Kentico 11 portal engine along with custom development using Kentico API.

We are creating a shopping cart for the customer and adding cart items to the shopping cart (also able to modify the cart using API).

How can I create an order directly using the shopping cart items? I don't see anywhere the cart can be converted to order.

Any suggestions or thought would be helpful.

Regards, Naresh Ede

Correct Answer

David te Kloese answered on February 8, 2021 10:51

In Kentico 11 you can use SetOrder which accepts the a ShoppingCart object that transfers the default properties data from the cart to an order.

ShoppingCartInfoProvider.SetOrder(this.ShoppingCart);

1 votesVote for this answer Unmark Correct answer

   Please, sign in to be able to submit a new answer.