Archive for March 2009
In my previous blog entry, I have explained how to create ASP.NET ecommerce website in CS2009.
http://microsoftblog.co.in/commerceserver/aspnet-website-in-commerce-server-2009/
Now, in this post, I will explain how to import CS2009 pub without using “SharePointCommerceServicesConfiguration” tool.
- Open Commerce server manager.
- Right click on commerce sites –> New –> Unpack site.
- Navigate to “\Program Files\Microsoft Commerce Server 2007\Microsoft Commerce Server 2009\Site” directory and click on “MicrosoftCommerceDefaultSiteWithSampleData.pup” file or “MicrosoftCommerceDefaultSiteNoData” file.
- Now site unpacker wizard starts and it will create commerce server 2009 sites.
- In the first screen, click on custom unpack.
- In the second screen, click on “Create a new site” radio button.
- In the third screen, give the site name as “SampleSite”.
- In the fourth screen, make sure you add all available resources to “resource to unpack” section.
- In the fifth screen, leave the default configuration (it creates new profile and CS authentication resources).
- In the sixth screen, all databases are shown, if required, you can change the database name or database location.
- In the seventh screen, make sure you select all applications.
- In Eight screen, the tool will show the website details. If you want to can change the virtual direction name, you can do it here.
- By clicking next, the site creation process starts. In between, the tool asks for profile system resources (schema, site terms, expression definitions) and schema definition scripts. Keep the defaults (don’t change them).
- After successfully creation of sites, the site packer shows the popup.
If you observe commerce server manager, web services are created but it will not create the site. So, we have to manually add our web application under application directory in commerce server manager.
If you like this post, please click on our sponsor advertisement.
SharePointCommerceServicesConfiguration tool is nice tool and helped us not to update the configuration settings on multiple locations. By default it is creating commerce site provided by Microsoft. Can I create a new MOSS site with the commerce server database I have? and the answer is yes. It is pretty simple, follow below steps to achieve it.
- Open “"{drive name}:\Program Files\Microsoft Commerce Server 2007\Microsoft Commerce Server 2009\Site” folder and copy your site pub file into this folder.
- Open “SharePointCommerceServicesConfiguration.exe.config” file in notepad. This file has configuration settings and the tool uses this configuration settings while creating a new site.
- Make sure you provide your pub file either in PupWithDataFileName value or PuPSchemaOnlyFileName value.
|
<appSettings> |
Note: When you execute the tool, In third screen it will ask for two options.
If you select “Unpack Commerce Server Site (schema only)” then the tool will import the pub file specified in “PupSchemaOnlyFileName” key or if you select “Unpack Commerce Server Site (with sample data)” then the tool will import the pub file specified in “PubWithDataFileName” key.
If you like this post, please click on our sponsor advertisement.
Commerce server 2009 has provided a utility named “SharePointCommerceServicesConfiguration”, by which we can easily create a MOSS starter site within minutes. You can find this utility in “"{drive name}:\Program Files\Microsoft Commerce Server 2007\Microsoft Commerce Server 2009\Site” folder. In the observe the folder properly, you will find two pub files – one is with schema (MicrosoftCommerceDefaultSiteNoData) and another is schema with sample data (MicrosoftCommerceDefaultSiteWithSampleData). This tool is just creating sites in commerce server and MOSS (sites in CS is different from MOSS).
Let’s see how to create a starter site in CS2009.
- Double click on SharePointCommerceServicesConfiguration.exe file.
- Before it start creating the site, the tool checks whether all services are available or not. If they are not, then it will prompt the user to enable that service. If all services are running (as shown below), click next button.
- In the next step, the tool will ask give us two options. Import only web parts on existing moss site or Create new SharePoint site with web parts.
- In the third screen, we have to provide web application details. Tool asks following things from the user.
- Web application: if possible, you can create new application or provide existing application. As part of web application creation, you have to provide site description, port number, application pool, extended IIS website details etc.
- Site collection details like title, description, site administrator.
- Commerce server site details like site name, site description. Apart from this, we can specify here whether to create commerce site without data or with data.
- Specify the database name. By clicking on “Advance” we can change the database location. Once done, click on next button.
- Now the real work starts. The tool creates commerce server sites from the pub file, create SharePoint site with web parts and finally it will show the completion screen.
That’s all, your site is ready and you can start playing with it. If you open the site, you may get a warning –“Web part can not be displayed as channel name is not specified”. Click below blog entry to address this issue.
If you like this post, please click on our sponsor advertisement.
After installing & configuring commerce server 2009, you may be able to see the moss site with adventure works catalog & its products. There is a tool “SharePointCommerceServicesConfiguration. exe”, located in “Program Files\Commerce Server\Site\” directory by which we can create new MOSS ecommerce sites. What if we want to create asp.net website on top of commerce server 2009? Follow below steps to make it work.
- Open visual studio and create a new website.
- From MOSS website, add following files and folders to asp.net site
- Bin & Pipeline Folders
- Web.config
- OrderObjectMappings.xml
- OrderPipelineMappings.xml
- ChannelConfiguration.config
- MetadataDefinitions.xml
- Add Reference to System.Core, System.Web.Extensions, System.Xml.Linq, System.Data.DataSetExtensions
- If required, you can remove all reference of SharePoint and Microsoft.Commerce.Portal.UI.
Now your asp.net website is ready for commerce server 2009.
If you like this post, please click on our sponsor advertisement.
