dkreifus Posted March 18, 2008 Posted March 18, 2008 Can I have multiple entries for certain categories- for example[GuiUnattended] AdminPassword="blahblah" AutoLogon=Yes AutoLogonCount=2 EncryptedAdminPassword=No OEMDuplicatorstring="XP Build 3.2" OEMSkipRegional=1 OemSkipWelcome=1and then further down in the file, have[Guiunattended] TimeZone=35Reason being, I have a boot cd which users choose their location. I can have a command which based on user input, will added guiunattnded/timezone to the end of the sysprep.inf file, therefore eliminating certain registry keys I program.
Mordac85 Posted March 22, 2008 Posted March 22, 2008 What are you using to get the user input and add the entry to sysprep? Can't it handle RW to an ini file? Worst case would be to build the setup and test it.
dkreifus Posted March 22, 2008 Author Posted March 22, 2008 I was just using a batch script based on user inputecho [Guiunattended] >> sysprep.infecho TimeZone=35 >> sysprep.infor something similar
Mordac85 Posted March 22, 2008 Posted March 22, 2008 I guess it would depend on how setup reads the file, so you'd probably have to test that. Or you could switch to something like a powershell perl or vbscript script to run your processing. Then you could use a hash or dictionary object to read in the section contents like this powershell example.get-content sysprep.inf | foreach-object {$infData = @{}}{$infData[$_.split('=')[0]] = $_.split('=')[1]}and then access the key using $infData.key1
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now