The Scripting Series: Unattended Install of Visual Studio 2005 SP1 on Windows 7 x64 and Vista x64

How to install Visual Studio 2005 on Windows 7 x64 the Unattended way

  1. Extract your Visual Studio installation files to c:\VS2005
  2. Download Visual Studio 2005 SP1 and place it in c:\VS2005_Resources
  3. Download Visual Studio 2005 SP1 Update for Windows Vista and place it in c:\VS2005_Resources
  4. Create a new VS2005.ini Unattended answers file by running the following from a cmd prompt
    1. C:\vs2005\setup\setup.exe /createunattend c:\VS2005.ini
    2. Select the options you want to have installed during the unattended install and complete the wizard
      1. Keep in mind that the unattended file you create will only be usable on machines that have the exact same OS and architecture (x86 or x64)
  5. Copy and paste the following into a new bat file (c:\InstallVS2005.bat):

:Variables
SET VisualStudio2005FilesPath=c:\VS2005
SET VisualStudio2005ResourcesPath=c:\VS2005_Resources</code>

echo.
echo Install Visual Studio 2005
echo -Install Prequisites
"%VisualStudio2005FilesPath%\WCU\64bitPrereq\x64\vs_bsln.exe" /Q
"%VisualStudio2005FilesPath%\WCU\DExplore\dexplore.exe" /q:a /c:"install.exe /q"

echo -Install Visual Studio 2005
"%VisualStudio2005FilesPath%\setup\setup.exe" /unattendfile "c:\VS2005.ini"

echo -Install Visual Studio 2005 SP1
"%VisualStudio2005ResourcesPath%\en_visual_Studio_2005 SP1 (VS80sp1-KB926601-X86-ENU).exe" /q

echo -Install Visual Studio 2005 SP1 for Windows Vista
"%VisualStudio2005ResourcesPath%\en_visual_studio_2005 SP1 Vista (VS80sp1-KB932232-X86-ENU).exe" /q


Once you have done all that run the c:\InstallVS2005.bat file from a cmd prompt with Administrator priviledges. Towards the end of the initial Visual Studio 2005 install windows 7 will prompt you with a warning about Visual Studio 2005 being a an application that it has trouble running. Dismiss the warning and allow the installation to continue.

Once the bat file is finished you should have a working Visual Studio 2005 installation.

Advertisements

4 thoughts on “The Scripting Series: Unattended Install of Visual Studio 2005 SP1 on Windows 7 x64 and Vista x64

  1. helen says:

    It’s not unattended if you have to dismiss the warning

  2. helen says:

    You are suppose to slipstream sp1 and Studio 2005 Service Pack 1 Update for Windows Vista to get rid of the Program Compatibility Assistant warning

    http://blogs.msdn.com/heaths/archive/2006/12/16/slipstreaming-visual-studio-2005-service-pack-1.aspx

    But this didn’t work for me so i disabled the Program Compatibility Assistant warning using VBscript for Windows 7:

    Dim WshShell
    Set WshShell = WScript.CreateObject(“WScript.Shell”)

    WshShell.RegWrite “HKCU\Software\Policies\Microsoft\Windows\AppCompat\DisablePCA”,00000001,”REG_DWORD”
    WshShell.RegWrite “HKCU\Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\{5f66dbae-cad3-468a-83d0-77ace8abc1f6}”,00000004,”REG_DWORD”

    ‘the last line was in the registry after checked Don’t show this message again see kb931709

    • obligatorymoniker says:

      Thank you for your feedback, when I have a chance I will update my original to include the additional things you have included so that it will be a truly unattended install.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: