RE: Is Basket.Load and Basket.Add the same?? CHANGE EXISTING ORDE
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > Microsoft Commerce Server > Commerce Server General > RE: Is Basket.Load and Basket.Add the same?? CHANGE EXISTING ORDE




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    RE: Is Basket.Load and Basket.Add the same?? CHANGE EXISTING ORDE  
Ravi Shankar


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-03-06 11:18 PM

Here is the code (please verify as I'm doing this off the top of my head)

Dim oOGSO as OrderGroupSearchOptions
Dim oOGS as OrderGroupSearch

oOGSO = new OrderGroupSearchOptions()
oOGSO.FetchOrderFormInformation = true
oOGSO.Columns.Add("OrderGroup.[ordergroup_id]")
oOGSO.PageSize = 25 ' must

oOGS = new OrderGroupSearch(CommerceContext.Current.OrderSystem)
oOGS.UserID = CommerceContext.Current.UserID
oOGS.OrderNumber = <your order number> ' substitute with the order number

Dim oDSOrders as new Dataset()
oDSOrders = oOGS.Search(oOGSO)

'
' If there is an order as per your requirement then you should get a table
with ONE
' record

Dim sPOId as string =
oDSOrders.Tables(0).Rows(0).Columns(0).Value.ToString() ----- something like
this.. basically get the value of the first column of the first row of the
ONLY table in the dataset.

Dim oPOGUID as guid = new System.guid(sPOId)
Dim oUserGUID as guid = new System.guid(CommerceContext.Current.UserId)
Dim oPurchaseOrder as PurchaseOrder

oPurchaseOrders = CommerceContext.Current.OrderSystem.getPurchaseOrder _
(oUerGUID, oPOGUID)

Dim oCart as basket
oCart = CommerceContext.Current.OrderSystem.getBasket(oUserGUID)
oCart.Add(oPurchaseOrder)

'
' This should add the PO to the basket
' Hope this helps !!
--
Ravi Shankar


"Jeremy" wrote:
[vbcol=seagreen]
> could you show me how to use basket.Load - maybe some code? I cannot find 
it
> in the retail site nor can i find how to do it on the web. people just say
> use basket.load(purchaseorder) but nothing else.
>
> your help would really help.
>
> "Ravi Shankar" wrote:
> 





[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 12:13 AM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register