- NSIS Discussion
- Nit: MUI documentation as installed
Archive: Nit: MUI documentation as installed
l_d_allan
12th October 2005 23:14 UTC
Nit: MUI documentation as installed
When the NSIS documentation is installed locally, I'm encountering a script error when clicking on
2.5 Modern UI
<<Modern UI Examples>>
I believe this works on the web, but something was perhaps overlooked in the HtmlHelp workshop (.hhp?)
Or am I doing something wrong?
iceman_k
12th October 2005 23:38 UTC
I see the same problem. I am guessing that IE places restrictions on what shell open actions can be performed within a CHM file.
IMHO, this link needs to be removed from the documentation if it is going to be problematic.
l_d_allan
13th October 2005 01:25 UTC
Maybe, but other links work. I've built HtmlHelp .chm files, and the cause is typically something being left out of the .hhp, .hhc, or .hhk file ... if HtmlHelp Workshop or equivalent was used.
I took a look in CVS for the original (and maybe submit a patch), but didn't find them (may have been looking in all the wrong places.)
iceman_k
13th October 2005 03:21 UTC
The other links open files. The one that fails opens a folder. What is failing is the shell open call with the folder as the parameter.
Nothing was left out from the hhp. The same code is used for both the web as well as the chm help.
IMHO, it would be better if that link actually pointed to:
../Docs/Modern UI/Readme.html#examples.
kichik
13th October 2005 12:37 UTC
What exactly did you do to get this error? It always works for me, even with all security zones set to high level.
iceman_k
13th October 2005 13:56 UTC
Open the NSIS.chm file, go to section 2.5 and click on the "Modern UI Examples" link.
The attached error is seen.
kichik
13th October 2005 14:00 UTC
That works just fine for me. There's also a try-catch block around that code to make sure this kind of messages don't come up. What might have you done differently? What OS do you use? What version of IE?
iceman_k
13th October 2005 14:17 UTC
Windows XP Pro SP2
IE 6.0.2900.2180.xpsp_sp2_gdr.050301-1519
128 bit encryption
I am not quite sure why the error is being thrown. I debugged it using the MS script debugger and the problem is occurring with the ActiveXObject "Shell.Application".
BTW, there is no try catch block around the area where it is failing.
This is happening in chmlink.js and the problem line is 84:
if (FolderExists(lfn))
{
var objShell = new ActiveXObject("Shell.Application");
objShell.Open(lfn);
}
Perhaps you should call TryShellExec instead of directly trying to open the folder?
kichik
13th October 2005 14:25 UTC
I think it didn't work with TryShellExec, but I'm not sure. Want to give it a shot? I still can't reproduce this...
iceman_k
13th October 2005 14:35 UTC
I will give it a shot.
And, oh, BTW, clicking on the same link on the NSIS web site help docs results in a 403 error:
Forbidden
You don't have permission to access /Examples/Modern UI/ on this server.
Apache/1.3.33 Server at nsis.sourceforge.net Port 80
kichik
13th October 2005 14:47 UTC
Thanks, fixed.
iceman_k
13th October 2005 14:57 UTC
Well... it kind of works- the folder opens within the CHM browser instead of externally.
Let me investigate further.
iceman_k
13th October 2005 15:32 UTC
After some playing around, I can't get it to work.
I think it may be related to Windows XP SP2 which added more stringent security wrt to scripting.
However, browsing to file:///../Examples/Modern%20UI does work.
I still feel that changing the link to
../Docs/Modern UI/Readme.html#examples would be a better idea, since this would also work on the NSIS web site.
[edit]
I see you fixed the web site, so maybe we continue with what we have now, except that you fall back to navigating to the file:/// URL if the shell open fails.
[/edit]
kichik
13th October 2005 15:50 UTC
I have XP SP2, that's not the problem.
I can live with it falling back to opening the folder in the CHM window.
l_d_allan
13th October 2005 15:58 UTC
These may be relevant re Local Machine Zone Lockdown:
http://msdn.microsoft.com/security/p...llockdown.aspx
http://msdn.microsoft.com/security/p...wn_devimp.aspx
http://weblogs.asp.net/jgalloway/arc...20/218123.aspx
I've wondered if HtmlHelp developers may be prone to encounter this hassle. And whether the end-users would experience problems with WinXp-SP2.
There are references to "mark of the web" comments that seems to be a work-around.