Greasemonkey Script to help filter Salesforce.com Setup screen

I have real pains with the Setup screen within Salesforce.com, I think it’s simply evolved to where it is today and as a result it is far from intuitive. For example ‘Packages’ live under the ‘Create’ menu but ‘Apex Classes’ are under ‘Develop’ – I don’t think I’ll ever get it!

However I’ve just stumbled across this excellent “Setup Enhancer for Salesforce” which is a Greasemonkey script for Firefox. For those who don’t know Greasemonkey is an addon for Firefox which is installed quickly and simply using the Addons menu within Firefox.

Once that’s installed visit http://userscripts.org/scripts/show/60438 and click the Install button, you should see a warning and then that’s it. Now logon to Salesforce.com and go to setup and you should see a filter box in the top-left corner:

Now, as you type in to the box you should see the left-hand menu filter down:

Kudos to ‘setupscripter‘ for something which is going to make my life a little easier.

IndustryComplete is Salesforce.com AppExchange App of the Week

Our latest product for Salesforce.com, IndustryComplete has been named App of the Week, read more about it here, and here.

IndustryComplete provides a user interface to quickly look up Industry Codes (SIC / NAICS / ISIC ) and for an administrator to map each code to a small list of Industries / vertical markets. This allows consistent classification of accounts within Salesforce.com leading to better segmentation.

If you require any custom development of IndustryComplete or CountryComplete don’t hesitate to contact us.

How to disable the Pointing Stick / TouchPad on a Dell Latitude D620 (and probably D630, D820, D830)

I recently took advantage of my MSDN subscription and installed Windows 7 RTM on my trusty old Latitude D620 (and for anyone who follows this am still dual booting Server 2008). This installed fine with everything detected and working with the only exception being the touchpad.

To start this by default uses the standard PS/2 mouse driver which is horribly slow to move across the screen. After much searching about I found an Alps driver however although this made the mouse quicker it left the pointing stick enabled. This then drove me crazy as if I slightly touch it by accident when typing quickly the pointer would move across the screen.

Eventually I found a driver from HP that seems to work fine and add the UI to the control panel to disable the pad etc. Check it out at:

ftp://ftp.hp.com/pub/softpaq/sp40501-41000/sp40715.exe

 

Print Selection in Outlook 2007

<rant>

Why doesn’t Outlook 2007 have a ‘print selection’ option? It’s meant to be using the Word rendering engine and Word has a print selection option.

So many people have footers saying ‘consider the environment before printing this email’. Well I think Microsoft could help a lot on this by allowing people to easily print just what they want to, when they need to without having to copy + paste.

Oh, and I shouldn’t need to ‘upgrade’ to a new version to accomplish this, I’m sure it was present in Outlook 2003!

</rant>

Windows Server 2008 R2 (RC) – where’s desktop search for Outlook 2007?

I’m still in the process of building my trusty Latitude D620 with Windows Server 2008 R2 (Release Candidate) as a replacement for my install of Server 2008 which has served me well for the past 18months or so. I’m looking forward to running Hyper-V without sacrificing my power management features. However I’ve come across a few niggles in configuring it for “Workstation” use, the first I’m going to discuss is the process for enabling the instant search within Outlook 2007, see the error below:

If you visit the Windows Desktop Search page you will quickly discover that there is no Windows Server 2008 R2 download, if you try a standard Server 2008 download it won’t install. In fact Windows Search is built-in to R2 but is hidden under the “File Services” role of course.

Once the Windows Search Service is installed restart Outlook and it should be fully functional.

Top-Global-Spam from info@topgloballink.com, info@topglobalfuture.com

Over the fortnight or so I have over 10 spam emails from these email addresses, including some from ‘reputable’ UK businesses such as Littlewoods.com, LoveFilm and Experian!

After a lot of digging it seems that the data was harvested by Clash-Media using a form at http://www.ukprizedraw.co.uk/default.aspx?campid=1 in July 2008 (even though I already owned an XBOX 360!). I am pretty sure I would never have put my details in to it as it currently looks, also their privacy policy appears to be anything but private!

I would suggest that anyone receiving spam from these domains register their complaint with Clash Media directly and also to unsubscribe@clash-media.co.uk and 3rdpartyunsubscribe@clash-media.co.uk. I also think that data is being sold on via Direct Agents

Good luck out there!

View the spam I received here

Killing the right svchost.exe process

Today I had an issue whilst deploying some Sharepoint code locally where the “World Wide Web Publishing” (W3SVC) service had hung in the Stopping state.

This was very annoying as I couldn’t identify the process in Task Manager to just end task it, this was leaving me with only one option – reboot. Going in to the properties of the service simply tells me that the service is started with “C:\Windows\system32\svchost.exe -k iissvcs” so I know that the process is called svchost.exe giving me a choice:

As you can see I have rather a lot of svchost and killing them randomly is likely to end in tears, thus I must be more scientific and execute tasklist /svc

This helpfully tells me the ProcessID (PID) together with the service name (W3SVC). I can now re-open Task Manager, go to View->Select Columns and select PID. This allows me to easily identify the process and end it!

Editing Word 2007 XML – choose your tools wisely!

I’m currently involved in a project that involves effectively ‘mail-merging’ and formatting a document based on external data. As certain sections need to disappear and others need to repeat I am actually using an XSL to generate my MS Word document.

However, I’m finding that after each change/iteration I have to look very carefully at the output document. Thus far this is what I’ve found – sometimes when Oxygen XML reformats the XML the ouput Word document contains lots of white space mid-paragraph on long paragraphs. This is due to the <w:t
xml:space=preserve>
tags where the text of the paragraph spans multiple lines. The XML indentation is effectively being shown in Word. Other XML editors will probably have the same issue – BEWARE!

Altova DiffDog is very useful to work out what has changed when things do go wrong with the exception of whitespace issues. Beware though, it doesn’t appear to be able to cope with curved apostrophes or quotes (the type word does for you and aren’t part of ASCII !). Thus if you save any changes you make using DiffDog your Word document will end up full of those pesky empty white boxes signifying strange characters. See below:

Altova DiffDog

Visual Studio 2008

 

Note that Altova XMLSpy does display these characters correctly however I’m now using Visual Studio 2008 (SP1) for editing the XML/XSL and so far so good…

DISCLAIMER: I’m no expert with these things so it’s quite likely I’m missing a setting somewhere, if so please let me know.

Utility to find commands on the Office 2007 Ribbon

Anyone who knows me will know that I am not a fan of the Office 2007 ribbon. For various reasons I now have to use Office 2007 and despite living with it for approx 18months I still can’t always find what I’m looking for on the ribbon….

Step in “Search Commands” from Microsoft Office Labs available at http://www.officelabs.com/projects/searchcommands/

This adds a search ribbon to Office which is actually pretty intelligent checkout the screenshots below:

OK it can’t add functionality that isn’t there…unfortunately.

Creating a Word 2007 document from a template and XML data (or Infopath) programmatically

First things first, I exaggerate a little when I say programmatically what I really mean is not manually! What we’re going to look at is effectively performing a mail-merge without having to use any COM or other API nasties, just the CustomXML support within MS Word. In order to run through this you will need the following:

  1. MS Word 2007 (of course!)
  2. A source XML file, in my case I’m going to use Infopath 2007
  3. The Word 2007 Content Control Toolkit available here
  4. [optional] XML Spy to view what’s going on

The Scenario

You have a standard set of documents that you require customers to fill in at the start of a new engagement, these documents are full of customisations of the customer’s name, order details etc. You would like to generate these documents automatically on a server without having to automate MS Word (!).

You would rather not convert the document to an XSL as the document changes quite frequently and you don’t want the burden of changing the documents each time, a solution whereby the user’s can change the template would be preferable.

The Data Source

There are two categories of data source, the first is the content for the customisations (i.e. customer name) the second are the template documents. For this data source we will use an Infopath form as below:

This should form should be self-explanatory so lets move on to the template word document. In this case we’ll assume the document has been written by someone else and merged in fields have been clearly shown such as:

Now we want to replace the values inside <> with values that come out of our Infopath form. We must now convert the temporary placeholder text for Word Content Controls. We do this by highlighting the text and then selecting the plain text control from the developer toolbar as below:

Next we need to set the properties for our new control by highlighting the control and clicking properties. You should then put some meaningful text in the ‘Tag’ field as you will need this to identify the control later.

Perform this action for all of the fields you wish to populate, where the same field is used you can copy+paste content controls which will retain the same tag. I recommend switching on design mode to ensure you have got all of the controls on and they are tagged correctly giving you something like:

Now let’s complete our InfoPath form and save some data:

Save the output XML file somewhere temporarily as we will need this later. Ensure the word document is closed and open it with the Content Control toolkit:

Note the tags that we applied to the word document are shown, without these you can’t tell the controls apart. Now create a new Custom XML part using the link on the right and switch it to Edit View and you should see:

We must now put our custom XML data from the Infopath form in to the word document. To do this simply open up the XML file from Infopath using the folder icon in the Custom XML parts pane as shown above giving:

Now change to the bind view and drag the fields from the right-pane on to the appropriate control tag on the left:

Save and close the document and re-open in Word and….

…you should have the values from the Infopath form showing inside the Word document. Obviously you’re not going to want to go through this process to generate the document each time, however changing the data now that it is bound is very easy.

Rename the document from “yourdoc.docx” to “yourdoc.docx.zip”, open in explorer and navigate to the ‘CustomXml’ folder and you will see a file called item1.xml

If you double-click that file you will note that it opens in Infopath, thus to change the document ‘data’ you just need to replace the xml file within the word document package each time.

Also I should mention that following the steps above the document is bound “two-ways” that is if you change the clientName field in the Word document not only will all occurrences of that field source change throughout the document but also the xml file will be changed. This behaviour can be changed using the properties of each content control.

Limitations

This type of data merging / generation is only really suitable for simple text insertion, if you have repeating data for example you will probably need to use an XSL approach.