Commerce Server General - inserting products into catalog

This is Interesting: Free IT Magazines  
Home > Archive > Commerce Server General > February 2004 > inserting products into catalog





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 inserting products into catalog
Zach

2004-02-07, 9:37 am

i need to insert products stored in an xml file into my
product catalog does anyone have any examples of how to do
this using c#.

thank you
Max Akbar

2004-02-07, 9:37 am

Use the following code to add products but first read the xml file and based
on it's structure you need to iterate the nodes and get the related product
information then add the product into Commerce Server. You will need to set
references to ADODB and the Catalog Interop.

CatalogManagerClass CatMgr = new CatalogManagerClass();

CatMgr.Initialize("sCatalogName", "bIsDBConString");

IProduct prd = PrdCat.CreateProduct("ProductDef", "varProductID", "Price",
null);
_Recordset rs = prd.GetProductProperties;

rs.Fields["ProductDefValues"].Value = "";

prd.SetProductProperties(rs, true);

good luck,
-Max


"Zach" <anonymous@discussions.microsoft.com> wrote in message
news:bc1e01c3ecc7$77a142d0$a401280a@phx.gbl...
> i need to insert products stored in an xml file into my
> product catalog does anyone have any examples of how to do
> this using c#.
>
> thank you



Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com