06-20-06 07:34 PM
With Commerce Server 2007, you can use the TrackingNumber property for this
purpose. If you set it on the Basket before a SaveAsOrder call, it is copied
over to the PO. If not set then a new trackingNumber is
assigned to the PO.
From the CS 2007 docs:
This value is a string to allow use of non-numeric, unique tracking numbers
assigned by a shipping company to be applied to an order. It is present in t
he Basket, OrderTemplate, and PurchaseOrder classes so
that it can be set as part of pre-checkout processing of a basket if a track
ing number is known prior to conversion of a basket to a placed purchase ord
er. This property value defaults to null at creation of a
basket or order template; if it is still null when a basket is converted to
a purchase order (using SaveAsOrder), a new, unique 64-bit integer value wil
l be generated, converted to a string, and placed in this
property, so that the uniqueness characteristics of this field are upheld wh
en saving the purchase order.
Thanks,
Nihit Kaul[MSFT]
Commerce Server
http://blogs.msdn.com/nihitk
This posting is provided "AS IS" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at http://www.mi
crosoft.com/info/cpyright.htm
--------------------
From: "J.F. Larente" <jflarente@cactus.ca>
References: < 24e0b2393a97a748d900420eaada8f39@localho
st.talkaboutsoftware.c
om> <7E9795A0-A243-4C77-81FE-DFAF01BA9DFA@microsoft.com>
Subject: Re: Assigning Order NUmber before placing an order
Date: Thu, 15 Jun 2006 16:43:45 -0400
Lines: 28
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
X-RFC2646: Format=Flowed; Original
Message-ID: <uJZ30xLkGHA.4660@TK2MSFTNGP05.phx.gbl>
Newsgroups: microsoft.public.commerceserver.general
NNTP-Posting-Host: user1-nat.noc.tmpw.net 63.112.170.65
Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGP01.phx.gbl!TK2MSFTNGP05.phx.gbl
Xref: TK2MSFTNGXA01.phx.gbl microsoft.public.commerceserver.general:17901
X-Tomcat-NG: microsoft.public.commerceserver.general
We have created a new field called "order number" and it becomes a standard
property that doesn't get overwritten.
I'd have to look at the code but if you need more help...
J.F. Larente
"Ravi Shankar" <shankycheil@newsgroup.nospam> wrote in message
news:7E9795A0-A243-4C77-81FE-DFAF01BA9DFA@microsoft.com...[vbcol=seagreen]
> In my experience, it'd get overwritten
>
> The way we've done it is to do a baset.SaveAsOrder.. assign this to the
> newly formed PO... do a PO.item("purchase_order_no") = what you want and
> follow it up with a PO.Save
>
> --
> Ravi Shankar
>
>
> "ukeu" wrote:
>
[ Post a follow-up to this message ]
|