# Wednesday, July 11, 2007

So, I've finally joined the 21st century, and purchased a Samsung Blackjack.  After waiting a two agonizing days, it finally arrived.  Man, it's a beauty!

Samsung Blackjack

I'll spare you a review of all it's features (this is covered in agonizing detail elsewhere), but there are a couple tidbits I'd like to share.

The Blackjack runs Windows Mobile 5.0 with the Messaging and Security Feature Pack.  One of the neatest features that this supports is Exchange ActiveSync w/ Direct Push Technology.  Fortunately, the company I work for has Exchange 2007 setup to push emails directly to smart phones, and this was the first thing I setup.  Worked like a charm!  Very easy.

Note: I know that Windows Mobile 6.0 is out.  If you have an application that runs Windows Mobile 6.0, then good for you!  Unfortunately, the Blackjack is still on 5.0, which is why this post is geared towards 5.0.

The second thing I looked into was how to setup a development environment that allows me to develop applications that I can deploy and run on my Blackjack.  Turns out, it's pretty simple.

My searches lead me to the Windows Mobile 5.0 Developer Resource Kit.  This kit contains (almost) everything you need to develop Windows Mobile 5.0 applications for a SmartPhone and Pocket PC.  I suggest you review the details surrounding the resource kit, and then download it and try it yourself.

As I said, my goal here is to setup a development environment and deploy a simple application to my Blackjack.  In order to consider this a successful test, I don't need the application to actually do anything except run.  Here are the steps I took.

Note: while this is written specifically for the Blackjack, the following steps will (largely) work for any kind of SmartPhone running Windows Mobile 5.0.

  1. Install all the prerequisites.  I already had all the required prerequisites installed (e.g. Visual Studio 2005 and ActiveSync).  I haven't yet tried any of the optional installations.
  2. Download the Windows Mobile 5.0 Developer Resource Kit.  This kit has everything you need to get going.
  3. Run the MSI and install the kit.
  4. Once the kit is installed, run the Windows Mobile 5.0 Developer Resource Kit application.  You can run this by clicking Start --> All Programs --> Windows Mobile 5.0 Developer Resource Kit --> Windows Mobile 5.0 Developer Resource Kit.
  5. Click Install the Developer Tools --> Install the Tools, and then in the detail pane slide down and click Windows Mobile 5.0 SDK for Smartphone (or Pocket PC, if you prefer).

    Windows Mobile 5.0 Developer Resource Kit
  6. This opens up File Explorer in the folder C:\Program Files\Windows Mobile 5.0 Developer Resource Kit\content\Developer Tools\Windows Mobile 5.0 SDKs\.  From here, click Windows Mobile 5.0 SDK for Smartphone.msi or Windows Mobile 5.0 SDK for Pocket PC.msi.
  7. Once the installation completes, Visual Studio will have been updated to include a new project type called "Windows Mobile 5.0 Smartphone" under "Visual Basic" and "Visual C#".  Open Visual Studio 2005, and click File --> New --> Project.

    Windows Mobile 5.0 Smartphone project
  8. Select "Device Application" and click OK.  Yes, I know the name and location are poor.  Change them if you want; remember, this is just a quick test/demo.
  9. The project template includes a Form1.cs file.  The designer shows a form embedded in a phone shell.  Drop a label on the form that says something (e.g. "Hello world!").

    image
  10. Make sure your Blackjack is connected to your computer via your USB cable, and confirm that ActiveSync is able to communicate and synchronize with your Blackjack.
  11. Samsung and Microsoft lock the Blackjack phone so that applications from unsigned publishers (like us!) will not run or deploy to the Blackjack phone.  In order to resolve this, take a look at these two discussions: Application Unlock Your Blackjack and Samsung Blackjack tips and tricks (the latter has some great tips).  I chose the method in the first link, and ran AppUnlock.cab.  Worked great.
  12. Go to Build --> Deploy DeviceApplication1.  A dialog box asks you where to deploy your application.  Choose Windows Mobile 5.0 Smartphone Device.  Click Deploy.

    Deploy Smartphone device
  13. The initial deployment will push a lot of CAB files used to run your .NET application.  Make sure you approve all these cabs from your Blackjack.  You will only have to do this the first time.
  14. Since our application was very simple, we'll have to browse to the executable through the file explorer.  Click Start --> Applications --> File Explorer.  Browse to \Program Files\DeviceApplication1, and click DeviceApplication1.
  15. As we have not signed the application, you will have to confirm that you want to run the application (I'll write a post some other time explaining how to sign the application).  Click Yes to continue.
  16. Lo and behold, our application runs and displays "Hello World!".

Yes, a completely useless and standard example, but it does serve to highlight how easy it is to setup a development environment that can publish applications to your SmartPhone (e.g. your Blackjack).

Now all I need to do is figure out a useful tool to build ...

I hope this helps!

posted on Wednesday, July 11, 2007 2:58:36 AM (Central Standard Time, UTC-06:00)  #    Comments [0] Trackback
# Sunday, July 08, 2007

I've been meaning to start posting an aggregation of notable Commerce Server blog and forum postings.  I've never found that Google or Technorati do a great job of searching or summarizing blog topic discussions, so I'll try to do my best to relate what's going on in the Commerce Server community.  Mostly, these posts come from people listed in my Commerce Server blogroll, as well as the Commerce Server forums.

Please let me know if I've missed any notable Commerce Server posts or announcements!

Blogs (posts you should read)

07/01/2007 - Ryan Donovan [MSFT] - The Best is Yet To Come - Ryan reflects on the long-term product roadmap for Commerce Server.

07/01/2007 - Max Akbar - Looking for Commerce Server Training? - Max announces the completion of his first video training tutorial.  This tutorial focuses on the Commerce Server Catalog System.  I  have had the opportunity to review this tutorial, and I can attest that it is great stuff!  Definitely worth the $$.

07/01/2007 - Jeff Lynch [MVP] - E-Commerce News: Commerce Server 2007 & BizTalk Server 2006 R2 - Jeff posts a summary of some news in the CS world, and explains that BizTalk Server 2006 R2 and Commerce Server 2006 play well together.

07/02/2007 - Nick Mayhew [MSFT] - Commerce Server SP1 available and introducing the Commerce Server team blog - A little behind the times <grin>, Nick announced SP1 and the CS team blog.

07/06/2007 - Ryan Donovan [MSFT] - http://blogs.msdn.com/rdonovan/archive/2007/07/06/speaking-in-denver-wpc-next-week.aspx - Ryan mentions that he'll be here in Denver to talk at the WPC (damn, I can't make it!) about Commerce Server.

07/06/2007 - CS Team Blog [MSFT] - http://blogs.msdn.com/commerce/archive/2007/07/06/commerce-server-worldwide-partner-conference-in-denver-next-week.aspx - The CS Team (via Ryan) discusses their presentation at the Worldwide Partner Conference in Denver, CO.

Forum / Newsgroup (answered questions that you might find useful to peruse)

07/02/2007 - StarterSite HelperClasses Source Code [Urgent!!!] - I've seen this one a lot.  People cannot find the source code for the Commerce Components, and only see the assembly (CommerceComponents.dll).  The source code is available in the CommerceComponentsSource.zip file, which is part of the Starter Site zip.

07/02/2007 - Data warehouse - Resolution to the error "Trans-Ctlg DTS task provider wrapper : Cannot Init timezone object"

07/03/2007 - InventoryQuantityDelta and the out of stock mystery - An explanation as to why orders occasionally come through for a product that is out-of-stock.

07/05/2007 - 'Out of Memory Exception' using CatalogWebService for Inventory - Memory leak when using BizTalk 2006 and Commerce Server 2007 Catalog adapter to update inventory.  The leak is fixed with SP1, and can be resolved by restarting the Catalog Import Host COM+ service.

07/06/2007 - Password Strength - Decreasing the password strength required for a profile.

07/06/2007 - Failed to delete inventory skus / Execute permission denied on 'inv_ValidateSkuType' - A potential bug in the inventory system.

posted on Sunday, July 08, 2007 3:18:35 PM (Central Standard Time, UTC-06:00)  #    Comments [0] Trackback
# Thursday, July 05, 2007

I've started working on a project that integrates into Great Plains 9.0 using eConnect.  Not having done this using BizTalk Server 2006, I thought I'd document some of my observations and the steps I took.

To begin, I was able to get eConnect for GP (en_econnect_for_gp.zip) through my MSDN subscription.  If you have Great Plains 9.0, then you should be able to get your hands on this package.  When you unzip the package, you'll notice two files:

  • eConnectInstallAdminGuide.pdf - This is a great document that, if you are going to interact and develop with eConnect, I highly encourage you to read.  There are three parts: eConnect Basics, Installation, and Administration.  At the very least, developers should reach the first part, which includes an overview and architecture chapter.
  • Microsoft_Business_Solutions_eConnect.msi - This is the actual installation file.  Note: it contains MUCH more than just the BizTalk Server adapters.

After reading through the eConnect guide, I ran the installation MSI file.  A few highlights / comments:

  • I chose the "Custom" setup.  I never choose Standard or Complete.
  • My sole purpose at this point is to install the BizTalk adapter with the eConnect schemas; follow the administration guide, instead of this post, if you're setting up for production.
  • There are a lot of features, including:
    • BizTalk Components - both 2004 and 2006
    • Business Objects - installs the Business Objects into SQL Server
    • COM+ Components - installs COM components and .NET assemblies
    • eConnect Incoming Service - incoming eConnect Win32 service
    • eConnect Outgoing Service - outgoing eConnect Win32 service
    • eConnect Replication Service - eConnect Win32 replication service
    • eConnect Help - help
    • eConnect Samples - .NET and VB6 examples
    • Queue Control - view documents in MSMQ queue
    • Schemas - eConnect XSD and XDR schemas
  • Not knowing any better, I decided to only include the following features:
    • BizTalk Components
    • eConnect Help
    • eConnect Samples
    • Schemas

Once you have installed eConnect 9.0, you must still install the adapters for BizTalk Server.  Browser to the following folder: C:\Program Files\Microsoft Great Plains\eConnect9\BizTalk\BizTalk 2006\ (obviously, choose \BizTalk 2004\ if  you are using 2004).  From here you can run the BTS_eConnectAdapter.msi file and install the BizTalk Server 2006 adapter.

Once the installation for the adapter is complete, make sure you update your platform settings and add the adapter.  Follow these steps:

  1. Open the BizTalk Server 2006 Administration Console.
  2. Go to BizTalk Group -> Platform Settings -> Adapters.
  3. Right-click the Adapters folder, and select New -> Adapter.
  4. Enter a name for the adapter (e.g. eConnect) and select the "Dynamics GP eConnect" adapter from the adapter list.
  5. Click OK.  Make sure you restart your host instances.

Pretty simple and straightforward.

Now, browse to the following folder: C:\Program Files\Microsoft Great Plains\eConnect9\XML Schemas\.  Here you will notice all the XDR and XSD schemas.  In particular, the "Incoming XSD Individual Schemas" and the "Incoming XSD Schemas" folders.  The first has every schema in an individual XSD, whereas the second has them all in an eConnect.xsd file.  Depending on you circumstances, you can import these schemas into your BizTalk projects, so that you can utilize them in Orchestrations, maps, or whatever else you choose.  Additionally, once you deploy your projects assemblies, the schemas will be available within your BizTalk solution.

And finally, one other folder you may want to look at is C:\Program Files\Microsoft Great Plains\eConnect9\XML Sample Documents\Incoming\.  This folder has a number of sample XML documents that you can use for testing.  VERY useful stuff here!

Just a few things I've learned and observed while getting all this configured.  I'm sure I'll post more as I continue to use the eConnect adapter.

I hope this helps!

posted on Thursday, July 05, 2007 11:34:14 AM (Central Standard Time, UTC-06:00)  #    Comments [1] Trackback

I just recently started a new BizTalk Server 2006 project in which I created a custom pipeline component to assist in the compression and decompression of messages.  The plan is to have a receive location monitor a folder via the File adapter, and when a zip file is uploaded via FTP from a 3rrd party process, the receive location will use the custom pipeline component , via a receive pipeline, to decompress the file and publish the message to the MessageBox.  Pretty slick!

See the WingtipToys solution in the SDK folder for a great heads-start to creating a compression / decompression pipeline component.  You can find this solution in the following folder: C:\Program Files\Microsoft BizTalk Server 2006\SDK\Scenarios\PM\.

So, to get this rolling, I added a C# project to my BizTalk solution.  There are few things I configure on these C# library projects, as I need to utilize the output assembly in my Pipelines BizTalk project.

  1. Set the build output path to the following location (for the Debug configuration): C:\Program Files\Microsoft BizTalk Server 2006\Pipeline Components\.  This way, every time the project is built, the debug assembly is placed in the Pipeline Components folder.  From here, you can then reference the pipeline component appropriate through both Visual Studio 2005 (for your receive pipeline) and when you deploy it to BizTalk Server.
  2. Uncheck the "Build" checkbox, for the C# library project, in the Solution Configuration.  This way, when you rebuild or deploy the solution, the C# library project isn't also rebuilt.  The reason is that you will most likely get errors or warnings indicating that the file is in use, and cannot be rebuilt.  This is fine - you can simply do this manually.

Having made these changes, you now have a pretty flexible setup for moving forward.

When you reference the custom pipeline component assembly, you'll want to reference the assembly that has been built in the C:\Program Files\Microsoft BizTalk Server 2006\Pipeline Components\ folder.  This way, when you deploy your receive or send pipelines, BizTalk will continue to reference the same assembly.

However, having referenced this assembly, you will see these warnings the next time you build your solution:

------ Build started: Project: BizTalkApp, Configuration: Development .NET ------
Updating references...
The dependency 'Microsoft.BizTalk.Tracing' could not be found.
The dependency 'Microsoft.BizTalk.Bam.EventObservation' could not be found.
The dependency 'Microsoft.BizTalk.Streaming' could not be found.
The dependency 'Microsoft.BizTalk.XPathReader' could not be found.
Performing main compilation...

While these warnings are harmless, they are annoying.  In order to "suppress" these warnings, select the referenced custom pipeline component assembly, and set Copy Local from True to False.  Once you do this, these warnings will disappear.

I hope this helps!

posted on Thursday, July 05, 2007 9:32:51 AM (Central Standard Time, UTC-06:00)  #    Comments [0] Trackback
# Saturday, June 23, 2007

As was announced yesterday, Service Pack 1 has been released for Commerce Server 2007.  This service pack includes support for Windows Vista, the ability to create web application projects in Visual Studio 2005, performance and security enhancements, and a slew of bug fixes.

I have detailed the process for installing SP1 and upgrading your CS sites in the following posts: Commerce Server 2007 Service Pack 1 (SP1) Walkthrough and Commerce Server 2007 Upgrade Wizard (post SP1 install) Walkthrough.

While installing SP1 I encountered a rather strange problem.  Let me try to explain how the problem occurred, and what I did to resolve it.

To begin, I decided to upgrade my Commerce Server 2007 virtual machine to SP1.  To begin, I did the following:

  1. Followed the steps I detail in my post Commerce Server 2007 Service Pack 1 (SP1) Walkthrough.  In fact, these screen shots were taken during this initial installation of SP1.
  2. After I installed SP1, I immediately launched the Upgrade Wizard.
  3. For the most part, I followed the steps outlined in my post Commerce Server 2007 Upgrade Wizard (post SP1 install) Walkthrough.  However, instead of upgrading both my StarterSite and CSharpSite, I only upgraded my CSharpSite and then rebooted my machine.

Why did I reboot the machine after only upgrading one site?  Well, I'm not exactly sure.  Part of me wanted to see what would happen with only one site upgraded, and another part wanted to upgrade one site at a time while rebooting in-between.  Regardless, I rebooted after installing only the CSharpSite.

After rebooting, here was my first indication that something was wrong.

At least one service or driver failed during system startup.

So, I immediately went to the Event Viewer.  I saw a number of errors involving the SQLSERVERAGENT, Commerce Server, and ENTSSO.  Here's a look at the various errors in the log (the reboot occurred around 10:52 am ... some of these other errors were thrown from my playing around before I resolved the problem):

Event Viewer errors

I should note that the system was previously very healthy, as I use this VM all the time while writing the book Professional Commerce Server 2007 for WROX.  In fact, I had been using the computer with no problems immediately before installing the service pack.

So, at this point it was clear that:

  1. The SQL Server Agent was no longer able to start-up.

    SQLServerAgent could not be started (reason: Unable to connect to server '(local)'; SQLServerAgent cannot start).
  2. Enterprise Single-Sign On (ENTSSO) was also having issues starting because it couldn't communicate to SQL Server 2005.

    The SSO service failed to start.
    Error Code: 0x800710D9, Unable to read from or write to the database.
  3. Commerce Server was complaining that I hadn't updated the StarterSite yet (this one is to be expected, as I hadn't updated it yet):

    Error in Commerce Administration Object : Description - 'The following resources are old. They will not function correctly until they are upgraded:
    Product Catalog (7.1.0)
    Marketing (7.0.0)

Obviously, something here is wrong, and SQL Server seemed to be at the heart of it.

The next thing I did was try to connect to SQL Server 2005.  Using the SQL Server Management Studio, I tried to login with my Windows credentials.  I wasn't surprised to see that I couldn't:

A connection was successfully established to the server, but then an error occured during the pre-login handshake. (provider: Shared Memory Provider, error: 0 - No process is on the other end of the pipe.) (Microsoft SQL Server, Error: 223)

"A connection was successfully established to the server, but then an error occurred during the pre-login handshake. (provider: Shared Memory Provider, error: 0 - No process is on the other end of the pipe.) (Microsoft SQL Server, Error: 223)" (copied directly from dialog window)

I have never seen this error before, but wasn't surprised to see that I couldn't find anything anything on Google or Live (although, hopefully this post will come up in the future).  Sure, various iterations of the first part can be found, but nothing seems applicable to this situation.

So, I decide to poke around.  What bothered me was that SQL Server (MSSQLSERVER) was running yet I couldn't connect to it, and the SQL Server Agent (MSSQLSERVER) itself couldn't start.  Even my attempts to manually start the service failed.  Here's a look at SQL Server Configuration Manager:

SQL Server Configuration Manager

Also, I attempted to connect to Commerce Server by running the Upgrade Wizard ... it didn't start, nor did I receive an error.  It simply didn't start.

For some reason, one thing jumped out at me -- I was running as LocalSystem rather than NT AUTHORITY\NetworkService.  Could this have something to do with it?

Not having any other ideas, I changed both SQL Server and SQL Server Agent to "Log on as" the "Network Service" (NT AUTHORITY\NetworkService) instead of the LocalSystem account.  I then restarted SQL Server 2005 and the SQL Server Agent.  Lo and behold, the SQL Server Agent started-up!

Config2

A little baffled, but encouraged that I was on track to resolving the problem (even if I don't understand the root cause), I tried to connect to SQL Server 2005.  Sure enough, I was able to login to the database server and interact with the various databases.  I also attempted  to connect to the Commerce Server 2007 Upgrade Wizard, which immediately started with no problems.

Since I wasn't too confident with the state of the computer (given that some services still weren't started), I decided to restart the computer.  It restarted without a single error, and I was able to run the Upgrade Wizard successfully to upgrade the StarterSite.

At this point I don't quite know why there was a problem with the LocalSystem account after I installed SP1 for Commerce Server 2007.  I intend to do a little more research to look into it.

Have any of you encountered this problem?  Can you shed some light on the situation?

Thanks, and I hope this helps!

posted on Saturday, June 23, 2007 1:23:16 PM (Central Standard Time, UTC-06:00)  #    Comments [0] Trackback

In my previous post, I detailed the process for installing the Commerce Server 2007 SP1.  In this post, I have created a walkthrough for the Commerce Server 2007 Upgrade Wizard.  The upgrade wizard should be run for all of your Commerce Server 2007 sites immediately after you have installed SP1.  So, before you begin this process, be sure you have successfully installed SP1.

(Note: I created this walkthrough, along with verbose screen shots and text, largely for documentation I am delivering to clients.  Please feel free to use these screen shots and/or text for your own documentation.)

A couple comments based on my experience installing SP1 and upgrading through the wizard:

  • Immediately upgrade all of your Commerce Server 2007 sites.  Do not reboot your machine before you run the Upgrade Wizard.
  • Make sure SQL Server 2005 is running with the appropriate built-in account.  For example, when I initially installed SP1 my SQL Server 2005 instance ran as "Local System".  However, post install, I had to switch the built-in account to "Network Service" for SQL Server 2005 to start-up properly.  I will write a separate post about some issues I had the first time installing SP1.

That said, here's the process for using the Upgrade Wizard to upgrade your Commerce Server 2007 sites.

  1. Launch the Upgrade Wizard.  You can launch this application automatically after installing SP1 or by running the Upgrade Wizard (Start -> All Programs -> Microsoft Commerce Server 2007 -> Tools -> Upgrade Wizard).  Click Next to begin.

    CS 2007 Upgrade Wizard: Welcome
  2. On the Select Options screen, specify the log file path.  I left the default location.  Click Next to continue.

    CS 2007 Upgrade Wizard: Select Options
  3. On the Select a Commerce Site screen, specify the site you want to upgrade.  Note: if you have more than one site, you can only upgrade on at a time; you can re-run the Upgrade Wizard to upgrade additional sites.  Click Next to continue.

    CS 2007 Upgrade Wizard: Select a Commerce Site
  4. On the Upgrade Site Resources screen, you have the option to choose Migrate or Do Nothing for your various resources.  Select the action Migrate for all your resources.  Click Next to continue.

    CS 2007 Upgrade Wizard: Upgrade Site Resources
  5. The Upgrade Summary screen reviews the selections you have made.  Review the selections, and click Next to start the upgrade.

    CS 2007 Upgrade Wizard: Upgrade Summary

    CS 2007 Upgrade Wizard: Upgrade Process
  6. Once the upgrade is complete you will have to click the Next button to continue.

    CS 2007 Upgrade Wizard: Upgrade Process (summary)
  7. On the Summary screen, you can review the upgrade and click Main error log to review any errors.  Click Next to continue.

    CS 2007 Upgrade Wizard: Summary
  8. You have successfully upgraded  your Commerce Server 2007 site.  Click Finish to complete the upgrade wizard.

    CS 2007 Upgrade Wizard: Complete
  9. After you click Finish you are reminded to restart.  Click OK to continue.

    CS 2007 Upgrade Wizard: Restart notice
  10. If you have additional Commerce Server 2007 sites to upgrade, repeat steps 1-8.
  11. Once you have upgraded all your Commerce Server 2007 sites, restart your computer.

The process is reasonably straightforward, and I encountered no problems.

Please be sure to share your experiences.

I hope this helps!

posted on Saturday, June 23, 2007 12:33:18 PM (Central Standard Time, UTC-06:00)  #    Comments [0] Trackback

I went through the process of upgrading my Commerce Server 2007 sites today.  While I had a few issues with the installation, I was able to get everything updated and functioning.

There are really two parts to the SP1 installation: the first is the installation of SP1 itself, and the second is the upgrade wizard that must run against your Commerce Server 2007 sites.  This post will walk you through the installation of the service pack itself.  The upgrade wizard walkthrough is discussed in a separate post.

Before you install Service Pack 1 for Commerce Server 2007, I recommend you do the following:

  1. Test SP1 by installing first in your development environment.  Ensure that your application continues to function.  If necessary, run regression tests against your application to make sure nothing has been broken.
  2. Install SP1 in your QA or UAT environments, followed by your Stating environment (if you have one).  Again, this is to ensure that your systems are not broken by the installation of the service pack.
  3. Make sure to thoroughly back-up your production environments before you upgrade.  This is VERY important, as you must ensure that you have an exit strategy, should something go wrong.  Do not neglect this step, or you may regret it.

Okay, that said, you must first download SP1 before you can begin.  You can download SP1 for Commerce Server 2007 here: http://www.microsoft.com/downloads/details.aspx?FamilyId=748049C5-A9BF-4AEC-91A0-AFE2DE0BF860&displaylang=en

(Note: I created this walkthrough, along with verbose screen shots and text, largely for documentation I am delivering to clients.  Please feel free to use these screen shots and/or text for your own documentation.)

Once you have downloaded the file, you can begin the following steps:

  1. Double-click "CS2007-SP1-ENU.exe".  You will receive a security warning - click Run to continue.

    WalkThru1
  2. Specify a location to unzip the necessary files, and click Unzip.

    WalkThru2
  3. Browse to the location you unzipped the files and review the ReadMe.htm file.
  4. After you have read the ReadMe.htm file, double-click SP1Setup.exe to launch the installation wizard.
  5. On the CS 2007 SP1 Installation Wizard starter screen, click Next to continue.

    WalkThru3
  6. Read the license agreement, specify that you accept the terms, and click Next to continue.

    WalkThru4
  7. Click Next to begin the installation.

    WalkThru5
  8. A dialog box will indicate that various services will be stopped.  Click OK to acknowledge and continue.  The installation of SP1 will (finally!) begin.

    WalkThru6

    WalkThru7
  9. Once the installation is complete, a summary page displays.  You can take a look at the log file (which I would recommend) and can also immediately launch the Commerce Server Upgrade Wizard (which I would also recommend).  Click Finish to complete the Commerce Server 2007 SP1 upgrade.

    WalkThru8

At this point you must upgrade any Commerce Server 2007 sites you have installed on the machine.  I will discuss this process in a separate post.  I have two recommendations for you at this point:

  • Immediately upgrade all of your Commerce Server 2007 sites.  If you don't upgrade them, you will get errors like the following (notice that I learned this out of experience):

     Error
  • Wait to reboot your server until you have upgraded all of your Commerce Server 2007 sites.  See my post for more details.

I hope this helps!  Best of luck!

posted on Saturday, June 23, 2007 11:57:08 AM (Central Standard Time, UTC-06:00)  #    Comments [0] Trackback
# Friday, June 22, 2007

The Commerce Server team has just announced the release of SP1 for Commerce Server 2007.

Here's the new features/enhancements they highlight:

  • Support for Commerce Server 2007 Developer Edition and business user applications on Windows Vista
  • Ability to create a Commerce Server 2007 Web Application Project in Visual Studio 2005 -- something that  it definitely needed!
  • Performance enhancements
  • Security enhancements
  • Various fixes (here's a list of all the bugs fixed with SP1)

Note the fine print from the site: "Commerce Server 2007 SP1 includes updated binaries in English only. Each business user application that Commerce Server 2007 provides is available in English only. This does not affect your ability to develop a multilingual Commerce Server Web site.  Installing SP1 on non-English versions of Commerce Server 2007 is not supported."

You can download SP1 here: http://www.microsoft.com/downloads/details.aspx?FamilyId=748049C5-A9BF-4AEC-91A0-AFE2DE0BF860&displaylang=en

Also, you can download the updated partner SDK here: http://www.microsoft.com/downloads/details.aspx?FamilyId=BDEA4873-2C06-4C7F-AD51-830A0309FECC&displaylang=en

I plan to update my virtual images with SP1, so I'll be sure and blog about the experience later tonight!

[Update]

posted on Friday, June 22, 2007 5:35:40 PM (Central Standard Time, UTC-06:00)  #    Comments [0] Trackback
# Tuesday, June 19, 2007

As a Commerce Server developer, you are bound to come across a situation where the smart client business user applications (e.g. the Catalog Manager, Catalog and Inventory Schema Manager, Customer and Orders Manager, and Marketing Manager) do not satisfy a business requirement, need to reflect a company's brand or style, or your business users simply want it changed.

Fortunately, you can get the full C# source code for the business user applications (except for the Catalog and Inventory Schema Manager; see Max's comment in this thread) through the Commerce Server 2007 Partner SDK.  This gives you the ability to modify the business user applications and be a hero to all your colleagues and clients (chuckle!).

Yeah, yeah, this is all old news.  However, I just came across a great idea from Søren Spelling Lund in which he talks about his experiences using ClickOnce Deployment along with the business user applications.

What is ClickOnce Deployment?

ClickOnce deployment is a technology designed to ease the difficulty in creating self-updating Windows-based applications.  Using the Publish Wizard in Visual Studio 2005 (or mage.exe, mageui.exe, or MSBuild), you can publish your application in three different ways: to media (such as a CD-ROM), to a network file share, or to a Web page.

When an application is published, two files are created: an application manifest, and a deployment manifest.  The application manifest describes the contents of  the application, including the assemblies, dependencies, and the files that make up the application.  The deployment manifest describes how the application is deployed, the location of the application manifest, and the version of the application that should be run by the clients.

Here's an example of an application published to a Web page (this particular example is from the SpaceWar SDK for the XNA framework - yes, I truly aspire to be an XBOX 360 game developer):

Example of application published to a Web page via ClickOnce

(Note the deployment version number.)

Once the end-user installs the application from the deployment location, the application is, by default, added to the Start menu and the Add/Remove programs group in the Control Panel.  Nothing is added to the Program Files folder, the registry, or the desktop.  When I first played around with ClickOnce this last part caught me unaware -- I couldn't figure out where my application had been installed!  Also, no administrative rights are required to install the application.

Now, remember the deployment version number?  The best part about this technology is that, if a developer publishes a new version of the application, the deployment version number is incremented.  Consequently, the next time the end-user runs the application they are presented with an opportunity to update their application.  What's neat is that, as a developer, you actually have a lot of control: you can require an update, and you can even require that a user rolls back to an earlier version of the application (not that any of us would ever have to roll back to an earlier version ...).

All-in-all, it's neat stuff.  And, while it's not a perfect solution and has it's own problems, you can very rapidly integrate it into your application and quickly reap the rewards.  Oh, and you can easily become a hero to your colleagues and clients (are you starting to sense a pattern?).

Integrate ClickOnce Deployment into the Partner SDK?

So, we're back to the smart client business user applications.  I'm sure you're now asking yourself, what does this have to do with the Commerce Server 2007 business user applications (or maybe not, since I alluded to it above)?

Søren Spelling Lund posted an article about integrating ClickOnce Deployment into the business user applications.  It's a great idea, and one I will definitely use in the future.  Additionally, he takes the time to point out a problem him and his colleagues ran into when they tried to run the ClickOnce installer on the Customer and Orders Manager.  Essentially, it appears that the project file included a <TargetZone> element that interfered with the ClickOnce installer.  Removing the <TargetZone> element resolved the problem.  Check out his blog article for the full details.

What are the benefits of integrating ClickOnce Deployment into the Partner SDK?

  • Ease - Easily deployment of business user applications to end-users
  • Versioning - Make sure your end-users are running the latest and greatest
  • Safety - The ability to roll back to a previous version of the application (just in case!)
  • Security - The applications run in a security context that prevents users from doing malicious things
  • Fame - Yes, you too can be a hero ...

Thanks to Søren for a great idea and a great post!

What great ideas have you put into play?  Please let me know!

posted on Tuesday, June 19, 2007 8:50:33 PM (Central Standard Time, UTC-06:00)  #    Comments [0] Trackback

During the installation of the Commerce Server 2007 Starter Site, I received the following error in the Pup.log file:

[10:57:50] Error importing object data for Transaction Config from file C:\Documents and Settings\Administrator\Local Settings\Temp\Transaction Config 8004E024:COM+ activation failed because the activation could not be completed in the specified amount of time. (Exception from HRESULT: 0x8004E024)

I also saw the following error in the Application Log, written at the exact same time:

Failed to import orders configuration data. System.Runtime.InteropServices.COMException (0x8004E024): COM+ activation failed because the activation could not be completed in the specified amount of time. (Exception from HRESULT: 0x8004E024)
   at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
   at System.EnterpriseServices.Thunk.Proxy.CoCreateObject(Type serverType, Boolean bQuerySCInfo, Boolean& bIsAnotherProcess, String& uri)
   at System.EnterpriseServices.ServicedComponentProxyAttribute.CreateInstance(Type serverType)
   at System.Runtime.Remoting.Activation.ActivationServices.IsCurrentContextOK(Type serverType, Object[] props, Boolean bNewObj)
   at Microsoft.CommerceServer.Orders.DataManagement.ServerOrderSystem.ImportRegionCodes(String txnConfigResourceConnectionString, DataTable regionCodesTable)
   at Microsoft.CommerceServer.Orders.DataManagement.ServerOrderSystem.ImportConfigurationData(Stream stream, String txnConfigResourceConnectionString)

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

I should note that, rather than install the Starter Site to a virtual directory under the Default Web Site, I decided to create a new Web site to which I installed the Starter Site.  The reason I did this is I already had the CSharpSite installed to the Default Web site, and I didn't want the two sites interfering with each other.

Also, to provide other information regarding this installation (just to show I'm not making an obvious mistake):

  • I ran it as the local Administrator account; full access to the system and SQL Server
  • Windows Server 2003 Standard R2; SQL Server 2005 Standard SP2; Commerce Server 2007 Developer edition
  • All hot fixes have been applied to the O/S
  • Instructions provided by the Commerce Server 2007 Start Site Installation Guide were followed
  • The CSharpSite was previously installed successfully
  • Everything is running locally (CS 2007, SQL Server 2005, BizTalk 2006), so it's not as if DTC (or some nefarious networking issue) is causing problems

This was the only error I received during the installation.  I took note of it, then continued onward.

Lo and behold, when I went to test the installation of the Starter Site, I received the following error:

The specified value for the newOrderStatus attribute is not valid.  The value provided was: 'NewOrder'. Please make sure an entry for this value exists in the AllowedStatus table in the transaction config database.

So, I decided to investigate.  Sure enough, the tables in the StarterSite_transactionconfig database were empty.  Specifically, the AllowedStatus, RegionCodes, and StatusManager tables did not contain any data.  So, I created scripts based on the data contained in these tables in the CSharpSite_transactionconfig database (which installed without any problems).

[Update] Note: see below for the actual resolution to this problem.  Although the following steps will correctly resolve the problem, there's a better way.

For example, here's the script generated for the AllowedStatus table (it's a bit more extensive for the RegionCodes table -- e-mail me if you need a copy of the script):

INSERT INTO [StarterSite_transactionconfig].[dbo].[AllowedStatus] ([Status]) VALUES ('Cancelled')
INSERT INTO [StarterSite_transactionconfig].[dbo].[AllowedStatus] ([Status]) VALUES ('InProcess')
INSERT INTO [StarterSite_transactionconfig].[dbo].[AllowedStatus] ([Status]) VALUES ('NewOrder')
INSERT INTO [StarterSite_transactionconfig].[dbo].[AllowedStatus] ([Status]) VALUES ('Rejected')
INSERT INTO [StarterSite_transactionconfig].[dbo].[AllowedStatus] ([Status]) VALUES ('Shipped')
INSERT INTO [StarterSite_transactionconfig].[dbo].[AllowedStatus] ([Status]) VALUES ('Submitted')

After inserting the missing data into these three tables, and running iisreset from the command-line, the Starter Site ran without any problems.

I still plan to try and investigate the underlying cause of the problem ... when I learn more, I'll update this post.  At the very least, I wanted to post this solution.

I hope this helps!

[Update] The actual solution to this problem.

Shortly after going through the previous steps, I performed the this Google search and noticed the following in the Commerce Server 2007 Readme file:

Unpacking a site might not populate the AllowedStatus table
The following error message might occur in the site packager log file:

"8004E024:COM+ activation failed because the activation could not be completed in the specified amount of time. (Exception from HRESULT: 0x8004E024)"

This error message indicates that Commerce Server could not populate the AllowedStatus table in the transactionconfig database. To populate the AllowedStatus table, open SQL Server Management Studio (open SQL Query Analyzer if you are using SQL Server 2000), and run the regiondata SQL script against the transactionconfig database. The regiondata script is located at %COMMERCE_SERVER_ROOT%\SDK\Samples\SiteCreate\.

So, it appears to be a known issue (previously unknown to me, though!) and easy to resolve!

What's the moral of this story?  Make sure to thoroughly research errors before you try to hack the solution yourself (or blog about it), even if you accidentally get the resolution correct.

I hope this saves someone the 30 minutes it cost me!

posted on Tuesday, June 19, 2007 1:15:30 PM (Central Standard Time, UTC-06:00)  #    Comments [1] Trackback
# Monday, June 18, 2007

I'm finally taking the time to highlight two blogging widgets that I have been using on my blog: ClustrMap and whos.amung.us.  These aren't the only widgets I use, but of the half-dozen scattered throughout my blog these are (arguably) the least well-known (at least, I don't see them very often).

The first is ClustrMap.  ClustrMap is a mapping widget that embeds itself into your blog and visually displays the location of your various visitors.  ClustrMap provides HTML source that renders as a map, and when it loads it increments a counter and displays the locations of all the visitors to your page.  Clicking on the map zooms to a big world map, and allows you to zoom into the continents.

I use this in my sidebar, toward the bottom of my blog.  Here's what it looks like:

ClustrMap example

It reminds me of a small-scale version of the map Google Analytics provides.  Here's an example of the script you would embed within your HTML:

<a href="http://www2.clustrmaps.com/counter/maps.php?url=http://blog.wadewegner.com"
temp_href=http://www2.clustrmaps.com/counter/maps.php?url=http://blog.wadewegner.com
id="clustrMapsLink">
  <img src=http://www2.clustrmaps.com/counter/index2.php?url=http://blog.wadewegner.com
style="border:0px;"
alt="Locations of visitors to this page"
title="Locations of visitors to this page"
id="clustrMapsImg"
onError="this.onError=null;
this.src='http://clustrmaps.com/images/clustrmaps-back-soon.jpg';
document.getElementById('clustrMapsLink').href='http://clustrmaps.com'" />
</a>

Very easy to use and setup.  It takes about a day for it to gather enough information and draw a map, so don't expect it to work immediately.  If you click on the map you can get a few statistic about the site.  Here's an example:

ClustrMap stats

The second widget is whos.amung.us.  Have you ever wanted to know how many users are reading your Web site or blog in real time?  This widget is the answer.  Again, they provide HTML script that you can embed within your Web site, and it renders as an image that counts the number of users on your Web site.  Clicking on the images takes you to their Web page, which shows you exactly which pages your readers are on, as well as how long ago they arrived.

Here's what the widget looks like:

counter

Here's the page that shows the URLs your readers are currently at (it's also neat that the links refresh themselves every few seconds):

whos.amung.us stats

Also, whos.amung.us provides a functional Color Wheel that allows you to change the colors of the widget:

whos.amung.us color map

As with ClustrMap, the code for this widget is very simple:

<a href=http://whos.amung.us/show/ds0261t1>
  <img src=http://whos.amung.us/cwidget/ds0261t1/7cbafcffffff 
temp_src=http://whos.amung.us/cwidget/ds0261t1/7cbafcffffff
alt="counter" width="81" height="29" border="0" />
</a>

Neither of these tools, ClustrMap or whos.amung.us, require you to setup an account or provide any personal information.  Simply paste the HTML code into your Web page, and off you go!

What tools and/or widgets do you use on your blog or Web site that are useful?

posted on Monday, June 18, 2007 6:45:51 PM (Central Standard Time, UTC-06:00)  #    Comments [0] Trackback

Max Akbar, Commerce Server expert and former Senior Product Manager for the Commerce Server team, has announced his new training company and web site.  Training resources include video tutorials, DVDs, PowerPoint presentations, codes samples, and on-site training.  You can find more information on his Web site at http://www.commerceservertraining.com/.

Max recently left Microsoft to consult and train companies using Commerce  Server.  While this is a huge loss for Microsoft, it is a huge win for the Commerce Server community as there has been a noticeable lack of training resources available.  Max is sure to do an excellent job filling this void.  Additionally, Max is acting as the technical editor on my forthcoming book Professional Commerce Server 2007.

Best of luck, Max!

posted on Monday, June 18, 2007 12:18:58 PM (Central Standard Time, UTC-06:00)  #    Comments [0] Trackback