Commerce Server General - Subject: How do you set the address list in the userobject?

This is Interesting: Free IT Magazines  
Home > Archive > Commerce Server General > November 2005 > Subject: How do you set the address list in the userobject?





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Subject: How do you set the address list in the userobject?
Michael

2005-11-24, 5:52 pm

i have a registration page that adds a billing and shipping address to the
address table. how can i add these addresses to the addresslist in the
userobject. i know the format is 2;guid,guid but how can i set that in code?

MSL

2005-11-25, 2:49 am

Michael escribió:
> i have a registration page that adds a billing and shipping address to the
> address table. how can i add these addresses to the addresslist in the
> userobject. i know the format is 2;guid,guid but how can i set that in code?
>

Hi Michael

The following example code shows how to generate a globally unique
identifier (GUID).

Dim oGenID, sGUID
Set oGenID = Server.CreateObject("Commerce.GenID")

sGUID = oGenID.GenGUIDString()
Set oGenID = Nothing

Marcelo Sánchez
http://www.europapc.com
Michael Rouleau

2005-11-28, 6:02 pm

getting the guid is not the issue. i'm trying to set the userobject in code.
example:
userobject.addresstype = ????.

"MSL" wrote:

> Michael escribió:
> Hi Michael
>
> The following example code shows how to generate a globally unique
> identifier (GUID).
>
> Dim oGenID, sGUID
> Set oGenID = Server.CreateObject("Commerce.GenID")
>
> sGUID = oGenID.GenGUIDString()
> Set oGenID = Nothing
>
> Marcelo Sánchez
> http://www.europapc.com
>

David Hargis [MSFT]

2005-11-29, 5:55 pm

In code, you want to set the property to an object of type object[]. Each
entry in the array should be the ID of the address in string format.

object[] addressList = new object[2];
addressList[0] = addressId1.ToString();
addressList[1] = addressId2.ToString();
userobject["GeneralInfo.address_list"].Value = addressList;
userobject.Update();

Hope this helps,
David

--------------------
Thread-Topic: Subject: How do you set the address list in the userobject?
thread-index: AcX0aHsuOF26u3olSqyFU4n/XVA4JA==
X-WBNR-Posting-Host: 131.239.49.21
From: =?Utf-8?B?TWljaGFlbCBSb3VsZWF1?=
<MichaelRouleau@discussions.microsoft.com>
References: <FFB1DFC1-5E02-4608-91E9-C8AC1233D80F@microsoft.com>
<#rZ9vsZ8FHA.3976@TK2MSFTNGP15.phx.gbl>
Subject: Re: Subject: How do you set the address list in the userobject?
Date: Mon, 28 Nov 2005 14:10:03 -0800
Lines: 25
Message-ID: <2D7E79D9-25DF-4F1F-BAF8-69132ED1E363@microsoft.com>
MIME-Version: 1.0
Content-Type: text/plain;
charset="Utf-8"
Content-Transfer-Encoding: 8bit
X-Newsreader: Microsoft CDO for Windows 2000
Content-Class: urn:content-classes:message
Importance: normal
Priority: normal
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
Newsgroups: microsoft.public.commerceserver.general
NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
Path: TK2MSFTNGXA02.phx.gbl!TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
Xref: TK2MSFTNGXA02.phx.gbl microsoft.public.commerceserver.general:17181
X-Tomcat-NG: microsoft.public.commerceserver.general

getting the guid is not the issue. i'm trying to set the userobject in
code.
example:
userobject.addresstype = ????.

"MSL" wrote:

> Michael escribió:
the[vbcol=seagreen]
code?[vbcol=seagreen]
> Hi Michael
>
> The following example code shows how to generate a globally unique
> identifier (GUID).
>
> Dim oGenID, sGUID
> Set oGenID = Server.CreateObject("Commerce.GenID")
>
> sGUID = oGenID.GenGUIDString()
> Set oGenID = Nothing
>
> Marcelo Sánchez
> http://www.europapc.com
>




--

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.microsoft.com/info/cpyright.htm

Note: For the benefit of the community-at-large, all responses to this
message are best directed to the newsgroup/thread from which they
originated.
Michael Rouleau

2005-11-30, 5:52 pm

thats what i was looking for, thanks david

"David Hargis [MSFT]" wrote:

> In code, you want to set the property to an object of type object[]. Each
> entry in the array should be the ID of the address in string format.
>
> object[] addressList = new object[2];
> addressList[0] = addressId1.ToString();
> addressList[1] = addressId2.ToString();
> userobject["GeneralInfo.address_list"].Value = addressList;
> userobject.Update();
>
> Hope this helps,
> David
>
> --------------------
> Thread-Topic: Subject: How do you set the address list in the userobject?
> thread-index: AcX0aHsuOF26u3olSqyFU4n/XVA4JA==
> X-WBNR-Posting-Host: 131.239.49.21
> From: =?Utf-8?B?TWljaGFlbCBSb3VsZWF1?=
> <MichaelRouleau@discussions.microsoft.com>
> References: <FFB1DFC1-5E02-4608-91E9-C8AC1233D80F@microsoft.com>
> <#rZ9vsZ8FHA.3976@TK2MSFTNGP15.phx.gbl>
> Subject: Re: Subject: How do you set the address list in the userobject?
> Date: Mon, 28 Nov 2005 14:10:03 -0800
> Lines: 25
> Message-ID: <2D7E79D9-25DF-4F1F-BAF8-69132ED1E363@microsoft.com>
> MIME-Version: 1.0
> Content-Type: text/plain;
> charset="Utf-8"
> Content-Transfer-Encoding: 8bit
> X-Newsreader: Microsoft CDO for Windows 2000
> Content-Class: urn:content-classes:message
> Importance: normal
> Priority: normal
> X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
> Newsgroups: microsoft.public.commerceserver.general
> NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
> Path: TK2MSFTNGXA02.phx.gbl!TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
> Xref: TK2MSFTNGXA02.phx.gbl microsoft.public.commerceserver.general:17181
> X-Tomcat-NG: microsoft.public.commerceserver.general
>
> getting the guid is not the issue. i'm trying to set the userobject in
> code.
> example:
> userobject.addresstype = ????.
>
> "MSL" wrote:
>
> the
> code?
>
>
>
> --
>
> 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.microsoft.com/info/cpyright.htm
>
> Note: For the benefit of the community-at-large, all responses to this
> message are best directed to the newsgroup/thread from which they
> originated

Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com