December 2006 - Posts

Getting external data into an InfoPath form is extremely easy and creating rich electronic forms is easy as well, so lots of power users and developers are using InfoPath to capture structured data. Publishing those forms is also very easy: in the InfoPath client, just click the Publish menu item and go through the wizard. Et voila, the form is ready to be filled out in a SharePoint document library by the end users. The fun starts when those power users or developers are not allowed to deploy directly to the production SharePoint servers: probably the locations of the external data is different on your development/test server than on the production machine (especially if you automatically submit data). In InfoPath 2007 and Microsoft Office SharePoint 2007 (MOSS 2007) this can be solved by using Universal Data Connection (UDC) files. The InfoPath knows where to find the UDC file (relatively to the location of the form) and the UDC file tells InfoPath where to data is located. So the location of the data is not stored anymore in InfoPath, but it's stored in the UDC file. The result: you can change the location without having to change the InfoPath form.

This is all great if the people who create the InfoPath forms are making use of UDC files, if not ... you can make use of a new Microsoft tool: the Server Upgrade and Migration Tool for Microsoft Office InfoPath. There are some other reasons why you could make use of this tool: backup/restore, upgrade from WSSv2, ...

The Server Upgrade and Migration tool allows a SharePoint farm administrator to change hard-coded URLs in InfoPath form templates, UDC files, and content types to ensure that the form templates continue to work correctly in the following circumstances:

  • When performing a gradual upgrade from Microsoft Windows SharePoint Services 2.0 to Microsoft Windows SharePoint Services 3.0 or from Microsoft Office SharePoint Portal Server to Microsoft Office SharePoint Server 2007.
  • When migrating InfoPath forms and form templates from one Windows SharePoint Services 3.0 or Office SharePoint Server 2007 or Web site collection to another.
During a gradual upgrade, the Windows SharePoint Services 2.0 server is temporarily renamed. The tool can be used to change the following hard-coded URLs so that InfoPath forms on the renamed server continue to work during the upgrade process:
  • Data connections to the local server contained in the InfoPath form template
After a site collection is upgraded, the tool is used again to change the URLs back to the original name.
The tool can also be used on a Windows SharePoint Services 3.0 server after content is migrated from one location to another to fix up URLs that may be broken by the move. Similarly, the tool can be used to fix up URLs when a backup set is restored to a new server or when an existing content database is attached to a new server. When the tool is run on a Version 3.0 Web application or Web site collection, the following are also updated:
  • Data connections to the local server contained in data connection files in a data connection library
  • URL to a form template contained within a content type

[Via Renaud Comte, aka CAML Boy] I haven't tried this tool myself but it looks like a potential must-have-tool for every SharePoint developer's/administrator's toolbox: SharePoint Inspector [download here].

Once in a while I get the remark that there are no document-level templates available in Visual Studio Tools for Office 2005 SE (VSTO 2005 SE). Typically people that used to work with Visual Studio Tools for Office 2005 are worried since they can't find their beloved templates for creating Word documents, Word templates and so on in Visual Studio. Actually the download page for VSTO 2005 SE gives the answer/solution:

Note that if you install on top of Visual Studio 2005 Professional, no document-level customizations or other functionality that is part of the full version of Visual Studio 2005 Tools for Office (VSTO 2005) is installed. VSTO 2005 SE adds only the application-level features listed in the feature highlights section above. If you install on top of one of the Visual Studio Team editions or Visual Studio 2005 Tools for Office, you will have VSTO 2005 project types available side by side with VSTO 2005 SE projects.

To summarize: if you install VSTO 2005 SE on top of a clean VS 2005 Professional, you won't have the document-level templates. If you want to have them you need to have VS 2005 Team Suite/Team Edition or you need to install the previous version of VSTO: VSTO 2005. So VS 2005 Professional + VSTO 2005 + VSTO 2005 SE will give you the document-level templates!

Brice Dunwoodie has written a nice article on CMS Wire about the latest release of the SmartPart (aka the Return of the SmartPart).

Easy Web User Controls for SharePoint (MOSS) 2007

 SmartPart v3, also known as the “SmartPart for SharePoint 2007” has been released. This is a container WebPart that can host any ASP.NET 2.0 Web User Control (ASCX). If you ever needed an excuse to get started with MOSS development, this is certainly it. 

The SmartPart module is an open source WebPart for SharePoint that can host any ASP.NET Web User Control. For single file controls, control deployment is very simple. For more complex controls utilizing code-behind files and assemblies, additional configuration is required.

For those familiar with WebPart development, you know there are some challenges involved. For starters, there is a fair bit of code required and there is no design-time support for WebParts in Visual Studio. These are both substantial issues.

SmartPart addresses both of these issues by allowing developers to code simple (or complex) Web User Controls (.ascx files) utilizing the full set of visual development tools in VS and then deploy the result to a SharePoint (MOSS) 2007 site. (read full article)

[Via ZDNet Belgium] Novell is going to include Microsoft's Office Open XML Format in OpenOffice! Read the full press release in Novell's Press Room.

Novell Boosts OpenOffice.org and Microsoft Office Interoperability

Novell to support Open XML format to advance document interoperability

WALTHAM, Mass.—04 dec 2006—Novell today announced that the Novell® edition of the OpenOffice.org office productivity suite will now support the Office Open XML format, increasing interoperability between OpenOffice.org and the next generation of Microsoft Office. Novell is cooperating with Microsoft and others on a project to create bi-directional open source translators for word processing, spreadsheets and presentations between OpenOffice.org and Microsoft Office, with the word processing translator to be available first, by the end of January 2007. The translators will be made available as plug-ins to Novell’s OpenOffice.org product. Novell will release the code to integrate the Open XML format into its product as open source and submit it for inclusion in the OpenOffice.org project. As a result, end users will be able to more easily share files between Microsoft Office and OpenOffice.org, as documents will better maintain consistent formats, formulas and style templates across the two office productivity suites. (continue reading)

Finally the latest version of the SmartPart is here: the Return of the SmartPart, also know as SmartPart v3, also know as SmartPart for SharePoint 2007. For those of you who are new to the SmartPart: the SmartPart is an open source web part that can host any ASP.NET Web User Control. What is the advantage of creating web parts by making use of the SmartPart? Well if you are familiar with the "traditional" web part development technique you probably know that you have to write lots of code, there is no designer support in Visual Studio. The SmartPart allows you to create a Web User Control (ASCX) in Visual Studio by making use of the designer, and deploy it to a SharePoint site. This release of the SmartPart is targetted for SharePoint 2007, both Windows SharePoint Services v3 (WSSv3) and Microsoft Office SharePoint Server 2007 (MOSS). Since the initial release almost 40.000 SharePoint developers have downloaded the SmartPart, get your copy today (for free of course) from the GotDotNet Workspace (in the releases section)! For those of you who have attended my session about web part development on TechEd: Developers in Barcelona, this is the version that I showed over there.

For more information about the deployment of the Return of the Smartpart, check out this post which also has a link to a small screencast. Keep an eye on my blog or www.smartpart.info for more information, examples and screencast about creating web parts the smart way!

To deploy the Return of the SmartPart to your SharePoint 2007 environment, you have two possibilities:

  • Automatic deployment using the SharePoint Solutions Framework
  • Manual deployment by copying and editing a couple of files

Deploying using the SharePoint Solutions Framework is probably the best thing to do, taken into account scalability and manageability. You can find the complete installation guide in the redistributable which you can download from the GotDotNet workspace (in the Releases section).

You can also watch a screencast which shows you both installation methods:

Last weekend I took the challenge of installing Windows Vista and Office 2007 on my main laptop (Toshiba Tecra M4 Tablet). The installation of Windows Vista went quite smooth, the only problem that I had was an issue with my wireless network at home. I'm using a Belkin router which has a setting called "Turbo Mode" and it seems that Vista doesn't like that one. Luckily I also had a wired connection because it took a while before I figured that one out. :-)

For all my development tasks and my presentations I rely on Virtual PC images, my host operating system only runs Vista Ulitmate, Office 2007 and some tools (but no Visual Studio). So I had to get at least VPC running in a stable state. If you want to run VPC on top of Vista, the latest beta version is the way to go, you can find it on MSDN Connect. Unfortunately there are still some issues with Virtual PC 2007 Beta: when I entered some text once in a while one keypress would be translated into 5 to 10 key presses. Very annoying when writing code of course! In the Feedback section on Connect I discovered that lots of people are having the same issue (in fact it's the number one bug). The status of that issues (ID 225211) is set to "Resolved" so in the next versions it will probably be fixed, but that didn't solve my problem of course. :-) Luckily there's also a workaround posted by a user named DanP1. "Setting the "idle_thread" option in the options.xml file pins the CPU at 100% but does avoid the repeating key problem. Likewise using something like RightMark CPU to execute HLT instructions on idle also causes the problem to go away."

Since I'm running the RightMark RMClock utility to undervolt my CPU (to save some precious battery juice and to keep my laptop cool), I activated the "Run HLT commands when OS is idle" option in the Management section and the keyboard issue went away! If you are wondering what a HLT command is: "It's a command that replaces the idle cycles (which generate heat) with a suspend mode. In advanced CPUs, this command can be executed when a certain percentage of the CPU is idle." (source). The task monitor will show 100% cpu usage but the monitor of RMClock will show the correct values.

Due to a funny coincidence Patrick and I were both in Africa last week! Patrick did a SharePoint course in South Africa and I was in Tanzania, also for a SharePoint course. Btw, did you know that the photo on top of my blog was taken in the famous Kruger National Park last year (original picture can be seen here)?

Anyway, I had a fantastic week over there, teaching SharePoint for the United Nations International Criminal Tribunal for Rwanda in Arusha. Tanzania is a beautiful country: fantastic nature and mountains, very kind people and the weather was just great (compared to rainy Belgium). The students were very interested in all the topics and I'd like to thank one of them in particular: Jean-Yves. So, thank you so much Jean-Yves for making my stay an incredible experience! Here are some photos, you can find more of them in this Flickr Set.

Kilimanjaro Sunset

Arusha, Tanzania Arusha, Tanzania Arusha, Tanzania

Fyi, if you are interested in attending another U2U SharePoint course in an exotic location; Patrick has one in Dubai (UAE), which is, of course, also a very nice country! :-)

More Posts