本文介绍了问题更新项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好,
$
我正在尝试从CatalogServiceAgent创建的catalogContext更新产品属性(自定义)。
该属性是从Commerce Server客户和订单管理器创建的。这是代码:
Hi all,
I'm trying to update a product property(custom) from a catalogContext created from a CatalogServiceAgent.
The property was created from Commerce Server Customer and Orders Manager. And this is the code:
CatalogServiceAgent catalogServiceAgent = new CatalogServiceAgent(@"http://localhost/CatalogWebservice/CatalogWebservice.asmx");
CatalogContext cctx = CatalogContext.Create(catalogServiceAgent);
Microsoft.CommerceServer.Catalog.ProductCatalog prodCatalog = cctx.GetCatalog("MyCatalog");
try
{
prodCatalog.UpdateItems("ProductID=" + "'" + theProductID + "'", "cy_list_price", thePrice);
prodCatalog.UpdateItems("ProductID=" + "'" + theProductID + "'", "myProperty", myProperty);
推荐答案
1。您确定您的房产名称正确吗? (DB中列的名称可能与属性名称不同)
1. Are you sure you have the right name for your property? (the name of the column in the DB may be different than the name of the property)
2。您确定您的产品确实具有此属性吗?
2. Are you sure that you have products that actually do have this property?
3。你确定你有合适的数据类型吗?
3. Are you sure you have the right data type?
祝你好运!
这篇关于问题更新项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!