I did it slightly differently, using an "avgsetup.ini" file which contains the licence number:
TARGET_DIR: "C:\Program Files\AVG7"
NAME: "my name here"
COMPANY: "my company here"
This is how it is called from postinst.cmd:
start /w %systemdrive%\Install\AVG\avgsetup.exe /script_file %systemdrive%\Install\AVG\avgsetup.ini
And this is the clever bit, to update it immediately after installation, assuming you have Internet connectivity:
start /w %systemdrive%\Install\AVG\avginetl.exe /UPDATE_AVG
"avginetl.exe" is extracted from the "AVG Admin" tool from Grisoft's website - http://www.grisoft.c...dwnl7.php?ver=8
- a command line tool to perform an update, as I couldn't figure out a way to initiate one without a pop-up prompt with the standard EXEs.
As far as I know this only works for v7.0 (beta), I think the switches are a little different for v6.x.
I don't know if this means you can use the entries in the script file as switches on the command line (e.g. avgsetup.exe /HIDE /DONT_START_APP /LICNO "licence-code"), but I find it a little tidier to keep these things out of the batch file anyway.