MSFN Forum: Installing some applications upon firstlogon - MSFN Forum

Jump to content



  • 2 Pages +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic

Installing some applications upon firstlogon Troubles!

#1 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 13 March 2010 - 02:09 PM

Hi,

I am trying to install some things upon firstlogon.

I tried this:
            <FirstLogonCommands>
                <SynchronousCommand wcm:action="add">
                    <CommandLine>cmd /q /c for %i in (C D E F G H I J K L M N O P Q R S T U V W X Y Z) do if exist %i:\APPS\RegTweaks.reg REGEDIT /S %i:\APPS\RegTweaks.reg</CommandLine>
                    <Description>Register Tweaks</Description>
                    <Order>10</Order>
                    <RequiresUserInput>false</RequiresUserInput>
                </SynchronousCommand>
                <SynchronousCommand wcm:action="add">
                    <CommandLine>cmd /q /c for %i in (C D E F G H I J K L M N O P Q R S T U V W X Y Z) do if exist %i:\APPS\MSSE-NL-v1.0.1961.0_64bit.exe start %i:\APPS\MSSE-NL-v1.0.1961.0_64bit.exe</CommandLine>
                    <Description>Register Tweaks</Description>
                    <Order>20</Order>
                    <RequiresUserInput>false</RequiresUserInput>
                </SynchronousCommand>                
            </FirstLogonCommands>



But nothing happening when I logon in my test install @ VMWare?
Some registertweaks apply to useraccount, so thats why I want it at firstlogon.
Also I want to install the MSSE at firstlogon.


Someone knows a way that does work?


#2 User is online   maxXPsoft 

  • MSFN Master
  • Group: Developers
  • Posts: 2,482
  • Joined: 14-November 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 13 March 2010 - 09:56 PM

View PostRaoul90, on 13 March 2010 - 02:09 PM, said:

I am trying to install some things upon firstlogon.

you don't need the FOR %%i IN (C but 1 time as long as it is first
here are examples
Use &quot;Windows Media&quot; around anything might have names with spaces in it.
<SynchronousCommand wcm:action="add">
        <Order>1</Order>
        <Description>Setting Path Variable</Description>
        <CommandLine>cmd /c "FOR %%i IN (C D E F G H I J K L N M O P Q R S T U V W X Y Z) do if exist %%i\sources\install.wim set MEDIA=%%i"</CommandLine>
</SynchronousCommand>
<SynchronousCommand wcm:action="add">
        <Order>2</Order>
        <Description>MSSE-NL-v1.0.1961.0_64bit</Description>
        <CommandLine>cmd /c start %MEDIA%\APPS\MSSE-NL-v1.0.1961.0_64bit.exe</CommandLine>
</SynchronousCommand>


This will set %MEDIA% to a drive then you use that variable %MEDIA%\

This post has been edited by maxXPsoft: 14 March 2010 - 06:23 AM


#3 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 14 March 2010 - 05:32 AM

Hmm OK, thanks, will give it a try:

            <FirstLogonCommands>
                <SynchronousCommand wcm:action="add">
                    <CommandLine>cmd /c "FOR %%i IN (C D E F G H I J K L N M O P Q R S T U V W X Y Z) do if exist %%i\sources\install.wim set MEDIA=%%i"</CommandLine>
                    <Description>Setting Path Variable</Description>
                    <Order>1</Order>
                    <RequiresUserInput>false</RequiresUserInput>
                </SynchronousCommand>            
                <SynchronousCommand wcm:action="add">
                    <CommandLine>%MEDIA%\APPS\RegisterSettings.reg REGEDIT /S %i:\APPS\RegisterSettings.reg</CommandLine>                
                    <Description>Register Tweaks</Description>
                    <Order>2</Order>
                    <RequiresUserInput>false</RequiresUserInput>
                </SynchronousCommand>
                <SynchronousCommand wcm:action="add">
                    <CommandLine>%MEDIA%\APPS\MSSE-NL-v1.0.1961.0_64bit.exe start %i:\APPS\MSSE-NL-v1.0.1961.0_64bit.exe</CommandLine>
                    <Description>MSSE-NL-v1.0.1961.0_64bit</Description>
                    <Order>3</Order>
                    <RequiresUserInput>false</RequiresUserInput>
                </SynchronousCommand>                
            </FirstLogonCommands>


#4 User is online   maxXPsoft 

  • MSFN Master
  • Group: Developers
  • Posts: 2,482
  • Joined: 14-November 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 14 March 2010 - 06:12 AM

View PostRaoul90, on 14 March 2010 - 05:32 AM, said:

Hmm OK, thanks, will give it a try:

won't work REGEDIT /S %i:\APPS\ sorry I really didn't look at your cmd lines just copied and fixed

use
cmd /c REGEDIT /S %MEDIA%\APPS\RegisterSettings.reg
cmd /c start %MEDIA%\APPS\MSSE-NL-v1.0.1961.0_64bit.exe

%MEDIA% represents your drive like F:

This post has been edited by maxXPsoft: 14 March 2010 - 06:16 AM


#5 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 14 March 2010 - 06:45 AM

Ah allright, will try that. :) Thanks.

#6 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 14 March 2010 - 07:11 AM

Hmm I used this:
            <FirstLogonCommands>
                <SynchronousCommand wcm:action="add">
                    <CommandLine>cmd /c "FOR %%i IN (C D E F G H I J K L N M O P Q R S T U V W X Y Z) do if exist %%i\sources\install.wim set MEDIA=%%i"</CommandLine>
                    <Description>Setting Path Variable</Description>
                    <Order>1</Order>
                    <RequiresUserInput>false</RequiresUserInput>
                </SynchronousCommand>            
                <SynchronousCommand wcm:action="add">
                    <CommandLine>cmd /c REGEDIT /S %MEDIA%\APPS\RegisterSettings.reg</CommandLine>                
                    <Description>Register Tweaks</Description>
                    <Order>2</Order>
                    <RequiresUserInput>false</RequiresUserInput>
                </SynchronousCommand>
                <SynchronousCommand wcm:action="add">
                    <CommandLine>cmd /c start %MEDIA%\APPS\MSSE-NL-v1.0.1961.0_64bit.exe</CommandLine>
                    <Description>MSSE-NL-v1.0.1961.0_64bit</Description>
                    <Order>3</Order>
                    <RequiresUserInput>false</RequiresUserInput>
                </SynchronousCommand>                
            </FirstLogonCommands>


No register-tweaks applied and also MSSE is not installed?

This post has been edited by Raoul90: 14 March 2010 - 07:11 AM


#7 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 14 March 2010 - 10:22 AM

Would a this work?
            <FirstLogonCommands>
                <SynchronousCommand wcm:action="add">
                    <CommandLine>cmd /C start /wait %systemdrive%\Windows\Setup\SCRIPTS\FirstLog.cmd</CommandLine>
                    <Description>FirstLogonScript</Description>
                    <Order>1</Order>
                    <RequiresUserInput>false</RequiresUserInput>
                </SynchronousCommand>                        
            </FirstLogonCommands>



FirstLog.cmd:
@echo off
FOR %%i IN (C D E F G H I J K L N M O P Q R S T U V W X Y Z) do if exist %%i\sources\install.wim set MEDIA=%%i
REGEDIT /S %MEDIA%\APPS\RegisterSettings.reg
Start /Wait %MEDIA%\APPS\MSSE-NL-v1.0.1961.0_64bit.exe
EXIT


Copied it from one of your autounattend.xml files, will try this out (copied cmd to mounted wim).

#8 User is online   maxXPsoft 

  • MSFN Master
  • Group: Developers
  • Posts: 2,482
  • Joined: 14-November 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 14 March 2010 - 03:23 PM

View PostRaoul90, on 14 March 2010 - 10:22 AM, said:

Would a this work?
            <FirstLogonCommands>
                <SynchronousCommand wcm:action="add">
                    <CommandLine>cmd /C start /wait %systemdrive%\Windows\Setup\SCRIPTS\FirstLog.cmd</CommandLine>
                    <Description>FirstLogonScript</Description>
                    <Order>1</Order>
                    <RequiresUserInput>false</RequiresUserInput>
                </SynchronousCommand>                        
            </FirstLogonCommands>



FirstLog.cmd:
@echo off
FOR %%i IN (C D E F G H I J K L N M O P Q R S T U V W X Y Z) do if exist %%i\sources\install.wim set MEDIA=%%i
REGEDIT /S %MEDIA%\APPS\RegisterSettings.reg
Start /Wait %MEDIA%\APPS\MSSE-NL-v1.0.1961.0_64bit.exe
EXIT


Copied it from one of your autounattend.xml files, will try this out (copied cmd to mounted wim).


most likely it will. Thats what I do :thumbup
seems a lot of people can't get applications to install from xml, course some can

#9 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 15 March 2010 - 12:22 PM

ARGHH!!! It doesnt work either, this is getting pretty **** annoying, lol.
Other ideas?


Also my timezone setting doesnt pass:
            <TimeZone>C. Europe Time</TimeZone>


Is it wrong or something? Should it be Central Euro Time? (full) or?

#10 User is offline   MrJinje 

  • Tool™ Developer
  • Group: Developers
  • Posts: 862
  • Joined: 14-October 09
  • OS:none specified
  • Country: Country Flag

Posted 15 March 2010 - 12:38 PM

goto command line

type "tzutil /G"

that will tell you exactly how to specify your current time zone from your local machine. If I had to guess it will either be this.

<TimeZone>Central European Standard Time</TimeZone>

or this, both are UTC +1

<TimeZone>Central Europe Standard Time</TimeZone>

#11 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 15 March 2010 - 02:47 PM

View PostMrJinje, on 15 March 2010 - 12:38 PM, said:

goto command line

type "tzutil /G"

that will tell you exactly how to specify your current time zone from your local machine. If I had to guess it will either be this.

<TimeZone>Central European Standard Time</TimeZone>

or this, both are UTC +1

<TimeZone>Central Europe Standard Time</TimeZone>


If I type that I get:
W. Europe Standard Time
Which is correct because I had that in my old autounattended.xml, forgot to change that then.
I will try both, see what happens. :)

#12 User is online   maxXPsoft 

  • MSFN Master
  • Group: Developers
  • Posts: 2,482
  • Joined: 14-November 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 15 March 2010 - 02:55 PM

View PostRaoul90, on 15 March 2010 - 12:22 PM, said:

ARGHH!!! It doesnt work either, this is getting pretty **** annoying, lol.
Other ideas?

<RequiresUserInput>false</RequiresUserInput>
is not needed. I think it is used with AsynchronousCommand

%systemdrive%\Windows\Setup\SCRIPTS\FirstLog.cmd
OEMs use that folder to fire off certain cmd files so should be able to.

I do it different since Windows 7 is a tight a$$ about using them folders so I create an Install dir on root. attrib it when I first start then run my scripts, could then delete the folder

This post has been edited by maxXPsoft: 15 March 2010 - 02:56 PM


#13 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 19 March 2010 - 12:09 PM

View PostmaxXPsoft, on 15 March 2010 - 02:55 PM, said:

View PostRaoul90, on 15 March 2010 - 12:22 PM, said:

ARGHH!!! It doesnt work either, this is getting pretty **** annoying, lol.
Other ideas?

<RequiresUserInput>false</RequiresUserInput>
is not needed. I think it is used with AsynchronousCommand

%systemdrive%\Windows\Setup\SCRIPTS\FirstLog.cmd
OEMs use that folder to fire off certain cmd files so should be able to.

I do it different since Windows 7 is a tight a$$ about using them folders so I create an Install dir on root. attrib it when I first start then run my scripts, could then delete the folder



Hmm, OK, I will try that, why you attrib the dir first?

#14 User is online   maxXPsoft 

  • MSFN Master
  • Group: Developers
  • Posts: 2,482
  • Joined: 14-November 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 19 March 2010 - 02:00 PM

View PostRaoul90, on 19 March 2010 - 12:09 PM, said:

Hmm, OK, I will try that, why you attrib the dir first?
I used to need to do that cause Sysprep was not firing off in x64 when I test Audit Mode. I'd edit the .cmd files to try something different but they wouldn't save. Found that to be a path problem

#15 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 06 April 2010 - 08:00 AM

Allright, I have time to test again, so I will basically test this now:

X86:
@echo off
REGEDIT /S %systemdrive%\APPSX86\RegisterSettings.reg
Start /Wait %systemdrive%\APPSX86\MSSE-NL-v1.0.1961.0-X86-UP2DATE.exe
RD /S /Q %systemdrive%\APPSX86
EXIT


X64:
@echo off
REGEDIT /S %systemdrive%\APPSX64\RegisterSettings.reg
Start /Wait %systemdrive%\APPSX64\MSSE-NL-v1.0.1961.0-X64-UP2DATE.exe
RD /S /Q %systemdrive%\APPSX64
EXIT



Called from FirstLogonCommands in autounattend.xml:
            <FirstLogonCommands>
                <SynchronousCommand wcm:action="add">
                    <CommandLine>cmd /C start /wait %systemdrive%\APPSX86\FirstLog.cmd</CommandLine>
                    <Description>FirstLogonScript</Description>
                    <Order>1</Order>
                </SynchronousCommand>                        
            </FirstLogonCommands>



            <FirstLogonCommands>
                <SynchronousCommand wcm:action="add">
                    <CommandLine>cmd /C start /wait %systemdrive%\APPSX64\FirstLog.cmd</CommandLine>
                    <Description>FirstLogonScript</Description>
                    <Order>1</Order>
                </SynchronousCommand>                        
            </FirstLogonCommands>



Hope it works! :)

This post has been edited by Raoul90: 06 April 2010 - 08:06 AM


#16 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 08 April 2010 - 10:44 AM

Lol at this code boxes.

Anyways, it aint working, I am getting kinda frustrated now, since I have no idea on how to install the applications otherwise?

@ maxXPsoft
What switches do you use after the attrib?

#17 User is online   maxXPsoft 

  • MSFN Master
  • Group: Developers
  • Posts: 2,482
  • Joined: 14-November 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 08 April 2010 - 05:51 PM

you did create the folder Dvd\sources\$OEM$\$1\APPSX86 and drop that file there?
Then right after Win is laid down on drive that folder will appear

#18 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 09 April 2010 - 06:30 AM

View PostmaxXPsoft, on 08 April 2010 - 05:51 PM, said:

you did create the folder Dvd\sources\$OEM$\$1\APPSX86 and drop that file there?
Then right after Win is laid down on drive that folder will appear


I mounted image and copied the APPSX86 folder to the systemdrive.

#19 User is online   maxXPsoft 

  • MSFN Master
  • Group: Developers
  • Posts: 2,482
  • Joined: 14-November 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 09 April 2010 - 06:42 AM

no no mount needed
You add them things to your DVD\Sources folder. Dvd\sources\$OEM$\$1\APPSX86

#20 User is offline   Raoul90 

  • Member
  • PipPip
  • Group: Members
  • Posts: 282
  • Joined: 05-February 08

Posted 09 April 2010 - 12:56 PM

View PostmaxXPsoft, on 09 April 2010 - 06:42 AM, said:

no no mount needed
You add them things to your DVD\Sources folder. Dvd\sources\$OEM$\$1\APPSX86


APPSX86 directory is present after installation? But if you say I should use $OEM$ then I will give that a try..

Share this topic:


  • 2 Pages +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2011 msfn.org
Privacy Policy