0

I worked before with "Microsoft Commerce server 2007" and used it's Catalog API to get products data in my web site. But I have a requirement to make a windows service that uses the commerce product catalog data, but I don't know how to adjust the APP.Config of this service to get data.

Every time I try commerce code it returns Null "CommerceContext.Current"== null

any Idea or sample config?

Tarek El-Mallah
  • 4,015
  • 1
  • 31
  • 46

1 Answers1

1

You need to create a CatalogContext object in Local or Agent mode. See How to Create a CatalogContext Object for details.

CommerceContext.Current is only non-null when running in the context of an ASP.NET web application.

bentayloruk
  • 4,060
  • 29
  • 31
  • Thanks a lot for that, it's working with me , I understand now; I don't need the "CommerceContext.Current" in web service , I need only "CatalogContext" and for it I can get any product data I need. – Tarek El-Mallah Sep 14 '12 at 15:01