Archive: UpgradeDLL question


UpgradeDLL question
hello again !

actualy i have 2 questions:

1. i am using the UpgradeDLL and ShareDLL (as explained on NSIS Dev Site in "how to install vb6 runtime files"). it's very strange, on diferent operating sistems i have diferent errors. ex. i have ususaly 2-3 errors for the "oleaut32.dll", "olepro32.dll" and sometimes for "stdole2.tlb" and always for "msjet35.dll". i don't know if the name of the files are important... i saw that the files are installed and registered corectly after reboot (the problem files), so everything is ok except for the error message (abort, retry, ignore)... so my question is : how NOT to show that message??? something to bypass this message ??? eventualy to display it in the install log, but not to stop the install process ??? some ideas ?

2. i am using multiple languages. i set the default language to english, but i saw that the installer detects the system regional settings and in concluzion the default language is NOT english... how can i set the default language, and to stay that way ?

thanks.


1. Which error message do you get? File in use? UpgradeDLL inserts SetOverwrite try, so you should not get the error? Did you remove that line?

2. StrCpy $LANGUAGE ${LANG_ENGLISH}
before the language selection dialog.


the language is ok. thank you.

i'm ataching a bitmap with the error messages.

thanks.

ps: i modified "SetOverwrite Try" to "SetOverwrite IfNewer". no programs are opened, none in taskbar, and i tried also to reboot the system before the installation - same result.


The macro handles the version check, you should never modify SetOverwrite.

Set SetOverwrite to whatever you like for your script after inserting the macro.


ok. i tested on 3 pc's - WinXP, Win2000 and Win98 and it seems to work fine. thanks.

sorry for all this questions...:(

thanks again.


well... it does not work !

in a clean, just installed Win98SE (interesesting - the 3rd system with 98 that i tested) the installer does not copy not a sigle dll.

and in WinXP i still have the error for "msjet35.dll" as in the JPG i atached.

any ideas ?


NSIS doesn't show that message box if the overwrite flag is set to try. Are you sure you didn't try with an old installer?


Please try again with the original macro.


now it is the original macro.

the "abort, retry, ignore" messages are gone, but i still have the "the application failed to start ... msjet35.dll...".

and there is the other problem: on win9x (the installer except for this message, does not show any errors, and this error only on NT systems - W 2K, W XP) the installer does not show any errors, but some dll files does not register and/or oinstall corectly (i think) because my program (vb) does not start. "class not registered".

i'm very confused.
help!

thanks.


Do you know that you have to reboot before most of the DLL's will be installed? You should add a Finish page, which will automatically ask for a reboot.

If you want the installer to start apps that need the new DLL, you should add the filename to the registry to let Windows start it after the reboot.


i have a finish page and i do reboot...

any ideas?


[edit]heh, never mind :)[/edit]

Are you checking for the reboot flag or using the MUI's finish page? If the reboot flag is set after this macro you must reboot for the registration to complete.

The MUI's finish page shows a "Are you sure you want to reboot?" message for you if the reboot flag is set.


it's very strange. on a new win98 works corectly, my program works. on another it does not. i will try to figure it out.!?

thanks again.


So you still get the 'File in use' error? And you are absolutely sure that there is 'SetOverwrite try' in the macro?

NSIS never complains about a file in use when overwrite is set to try.

Can you attach the complete script?


here is my script.

one question:

can i log in a file everything that UpgradeDLL and ShareDLL are trying to copy/upgrade/register ?

ex: x1.dll -> skiped.
x2.dll -> registering on reboot.
x3.dll -> registered.

is it posible? it would be usefull for the uninstall process. if one dll was on the system - the uninstaller will not remove it...

thanks.


You should never remove VB6 runtime files, even if you have installed them. They are used by many applications and may be used my applications in the future.

The shared DLL registration does not always work correctly. If an application does not install the DLL's but only asks the user to install the MS runtimes, the application will not be registered as a user of the DLL.


About your script:

SetOverwrite try should be inside the macro.

Please get the complete orignal macro from http://nsis.sourceforge.net/archive/nsisweb.php?page=21. That should work.

This macro automatically sets overwrite to on after it has been inserted, so you do not have to add 'SetOverwrite on' after inserting the macro. If you want another SetOverwrite value, you still have to set it again.


ok. i will try i a few minutes and i'll tell you how it works. thanks for the quick reply.

thanks again.


I FOUND THE ERROR !!! it was ME ...

well, first i observed that i was getting the error message about a dll when the installer was copying another dll. :weird:

so, i finaly read the error message. :igor: and the error mesage was not telling me that some dll was not copied/registered corectly, was telling me that the dll was not found! :up:
i have 5 dll files that are linked. changed the order of the files at instalation... and ... DONE!

i am testing it now. thanks everyone.