I believe this issue will be addressed in the next Office 2007 SP2, coming soon, but until then and for any legacy sites there’s a fairly quick fix…
Visio’s Save As Web output contains, amongst other things, a method to parse parameters contained in the URL. This enables you to add specific zoom, page index, shape focus and search settings in the following format:
The function responsible for extracting the parameters is called ParseParams and it’s this function that falls over when passed an empty string.
There are two options here, to fix the problem – one is to ensure the function isn’t called in the first place (probably the simplest fix if you never intend to use URL parameters), and two, to deal with the empty string issue inside the function itself.
Option 1 – Stop calling the function
- Open the main .htm page that Visio generates in a text editor, such as Notepad, and search for var gParams = ParseParams (location.search);
- Replace this line with var gParams = “”;
- Save the file and close.
Option 2 – Fix the function
- Open the main .htm page that Visio generates in a text editor, such as Notepad, and search for function ParseParams (strRawParams)
- Add the two lines highlighted in the image below or just replace the entire function with the this code.
If you're interested in other js changes in IE8 then you might want to have a look at the JScript team blog.