Jump to content

First time Unnattended disc - couple of questions


Recommended Posts

Hi,

First time poster on these boards, firstly I wanted to say thanks to all the previous posters, I've found these forums invaluable in creating my own unnatended windows DVD.

I've just tried out my first disc, and was very happy with the result. I have managed to strip windows down, put in SP2 and hotfixes with nlite, and apply some very useful registry tweaks.

I have used the RunOnceEx method for installing all the programs I use, quite an extensive list, which also went fairly well, except for two problems I can't seem to solve.

I have searched through these forums and just in general on the web, but am stumped, I was hoping someone may be able to help me.

A ) The first problem related to installing a utility (explorer replacement) I use called DirOpus.

It uses installshield, so I extracted the main exe to a folder, where I now have the setup exe and cab's etc. Using some instructions I found on the forums I made an iss file to help with the silent install.

start /wait Setup.exe /r /f1"F:\XPCD\$OEM$\$1\Install\Applications\DirOpus\setup.iss"

now when I install with this from a batch file:

start /wait Setup.exe /s /f1"F:\XPCD\$OEM$\$1\Install\Applications\DirOpus\setup.iss"

The application does indeed install silently, however, when I converted to the RunOnceEx method nothing seems to happen.

REG ADD %KEY%\003 /VE /D "Directory Opus 8" /f
REG ADD %KEY%\003 /V 1 /D "%SystemDrive%\Install\Applications\DirOpus\Setup.exe /s /f1\"%SystemDrive%\Install\Applications\DirOpus\setup.iss\"" /f

I am hoping perhaps I have made an error in this code? Any suggestions? Do I need to specify the directory for the iss file? I haven't actually tried it without yet.

B ) The 2nd problem relates to PowerArchiver 2004. I can silently install it without any problem. However I have a legit registration key which I would like to apply. I've discovered that if you simply install powerarchiver and then apply the registration to the registry, when powerarchiver is run for the first time it overwrites the registration information with the 30 day trial key. At which time you can reapply the registry keys for registration and all is well, however duplicating this in the installation silently and automatically has been a bit of a dilemna.

I am installing with this:

REG ADD %KEY%\017 /VE /D "PowerArchiver 2004 v9.10.06" /f
REG ADD %KEY%\017 /V 1 /D "%SystemDrive%\Install\Applications\Powerarchiver\powarc910.exe /VERYSILENT /NORESTART" /f

I then added some code to a register batch file which runs from my cleanup.cmd file, which in turn runs as the last entry in my RunOnceEx.

start %systemdrive%\install\Applications\Powerarchiver\zip.bat
sleep 2
taskkill /IM POWERARC.EXE /F
REGEDIT /S power.reg
exit

the zip.bat simply contains:

"C:\Program Files\PowerArchiver\powerarc.exe"
exit

I found if I used that line in the register bat the batch file pauses until powerarchiver is killed.

If I uninstall powerarchiver (making sure the registry keys are also deleted) and run these bat files in windows with %systemdrive% replaced with the real path, it all works as planned, powerarchiver opens, adds the trial registry info, is killed and then my reg file adds my proper key. next time I open powerarchiver its registered. However when I ran my install disc it didn't work. Powerarchiver was installed, I saw it open for a moment, and close. but when I logged in for the first time, powerarchiver still considered it hadn't been run, and the first time I open it it overwrites the registry information. I am not sure if I needed to specify the directory for the reg file either, but its in the same dir as the batch file so I think not, either way my problem seems to lay with powerarchiver not editing the registry when it ran, is it possible that I just need to make the sleep delay longer, or is there an easier way of doing this?

I hope this all makes sense, if anyone has some insight on either of these problems I would be most appreciative. I'm probably taking the long way around, but I wanted to try to find a solution before I asked for help.

And I apologise for the length of my post, I wanted to provide all the information I could.

And thanks again for all the help, even though up till now it was all silent through the search command ;)

Brett

Link to comment
Share on other sites


If I remember correctly (and I may be wrong because it's been a long time since I have done this...) I don't believe you can use quotes within' that registry setting... As I said, I might be wrong. You have no spaces so really no need for quotes... give it a try.

Link to comment
Share on other sites

Concerning that powerarchiver problem... Powerarchiver must do SOMETHING to know it has been started once. Maybe you should try to find the key for that? Or check the install directory if anything is changed there after first run. If the program knows it has been run once then it wouldn't overwrite the key.

*EDIT*

About that first problem...

I am hoping perhaps I have made an error in this code? Any suggestions? Do I need to specify the directory for the iss file? I haven't actually tried it without yet.

Can't see any mistakes. Specifying the directory is in most cases a safer bet. The only thing I can think of is that.. your setup.exe isn't located in the directory you specified.

Link to comment
Share on other sites

Thanks for the quick responses.

I'll try your edited version of the reg keys and see how that goes pmcx9. I guess those quotes were redundant.

And un4given1, my understanding is you can use quotations in the registry so long as they are preceded by a \. But again miy quotations are redundant.

I'm going to have some more play time with powerarchiver and the registry stuff. There's a lot of keys get written the first time you run it, and you are probably putting me on the right track Gagorian with the powerarchiver problem, I need to look into where it writes that it has run once. And it doens't seem it has to do anything but open. The open and kill works fine from a batch file just not from the registry. Quite odd really. I'll used Windows Intaller LE to see what I can find.

Thanks.

Link to comment
Share on other sites

Powerarchiver has very stupid way of installing and creating every setting per user. I have created an MSI installer for that with registry settings applied in installer.

And also I import its registry settings with cmdlines.txt to be applied to all users.

Link to comment
Share on other sites

Try using the /f2 option and redirect the log file to the local hard drive (C:\DirOpus.log). I have seen some applications fail because they try to write the log file to the install directory. If that doesn't work you can try creating a batch file and call it from runonce.

Further if you should decide to compress these files into a single compressed executable file to save space you need to add the /SMS switch.

As for Powerarchiver try using RegShot. This will let you see what changes are made by Powerarchiver. Then all you should need to do is create a reg file and run it as part of the powerarchiver install.

Link to comment
Share on other sites

Try using the /f2 option and redirect the log file to the local hard drive (C:\DirOpus.log).  I have seen some applications fail because they try to write the log file to the install directory.  If that doesn't work you can try creating a batch file and call it from runonce. 

Further if you should decide to compress these files into a single compressed executable file to save space you need to add the /SMS switch.

As for Powerarchiver try using RegShot.  This will let you see what changes are made by Powerarchiver.  Then all you should need to do is create a reg file and run it as part of the powerarchiver install.

Try this. I have installed PowerArchiver without a problem using this for quite some time.

REM PowerArchiver

REG ADD %KEY%\260 /VE /D "PowerArchiver 910" /f

REG ADD %KEY%\260 /V 1 /D "%CDROM%\Apps\PowerArchive\powarc910.exe /VERYSILENT /SP- /NORESTART" /f

REG ADD %KEY%\260 /V 2 /D "REGEDIT /S %CDROM%\Apps\powerarchive\powerarc.reg" /f

REG ADD %KEY%\260 /V 3 /D "REGEDIT /S %CDROM%\Apps\powerarchive\powerarchiver.reg" /f

Link to comment
Share on other sites

Thanks guys, I haven't retested the results yet on an unnatended install, but I think i have managed to get around the problems.

I just realised I posted this in the wrong forum too, I think it should have been in the application switches forum? So thanks for not grumbling at me. :D

I haven't been able to find the exact registry key that tells powerarchiver it has been run and not to apply the trial keys, but I simply set it up as I use it and exported the whole powerarchiver currentuser registry section, and when I import those keys instead of just the registration keys it works perfectly.

As for DirOpus, I ended up repackaging it with WinInstaller Lite. I've had to repackage another application called Qvadis Express Reader, which I use for my PDA, that lacked silent install options, and am finding that its not too much drama to do if you have a machine with a clean install. My new msi package installs fine on a cleanly installed machine, will be giving it another go via runonce later today I hope.

When I get that all working, my next project is to try and impliment WPI.

:thumbup

Link to comment
Share on other sites

The repackaged msi for Diropus works wonderfully.

My new reg data for powerarchiver works famously too, and all you really have to do its export [HKEY_CURRENT_USER\Software\PowerArchiver] after you set it up the way you like and have entered your registration details. There's quite a few sub keys under this but they all get exported, so its all good.

Thanks

:thumbup

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...