How do you install a factory.wim with imagex after the pc has been reformatted?

I am attempting to restore a pc back to factory default with the factory.wim file located in the Recovery partition

.I copied the recovery partition to an external drive with the factory.wim file.I then reformatted the HD as it was infected and could not get it to boot.  I could access the HD if it was slaved to another pc.

 I installed a copy of vista home but want to restore to factory default. I try to install the .wim with imagex but it tells me the user does not have the correct priveledges. This is the only user account on the pc as it is a fresh install.  I created two partitions one for a fresh copy of Vista Home and one for the recovery partition.

I installed the WAIK per Microsoft instructions. I also installed the WIM filter per the instructions

This is what I type on the command line:

 imagex /mount d:\dell\image\factory.wim c:

I am in the c:\program files\Window AIK\tools\x86>

The WIM file is located on the D Drive at  D:\dell\image\factory.wim

Melinda Burnscomputer supportAsked:
Who is Participating?
rindiConnect With a Mentor Commented:
You won't be able to restore into the same partition as the one your current OS is running from. Either remove the HD from the PC and connect it as a 2nd disk to another PC and run the restore on on there, or build a WinPE CD or DVD (that should be one of the options in the WAIK) and boot your PC from that CD/DVD and then restore from there.
Melinda Burnscomputer supportAuthor Commented:
Created a WinPE DVD and booted to that . Everything is copying over now. Had a little trouble with the correct syntax but finally got it.

Melinda Burnscomputer supportAuthor Commented:
Just  to elaborate on my situation.

Image file was located on my D: Partiton at D:\Dell\Image\Factory.wim

Booted to WinPE DVD and typed this at command prompt

X:\>D   (This changes it to the D: drive where imagex is and the .wim files are
D:\> cd tools
d:\tools\> imagex /apply d:\dell\image\factory.wim 1 c:

You will be able to see the progress.

ImageX Tool fo Windows
Copyright (C) Microsoft Corp. All rights reserved.

Thank you Rindi
Progress:  ##%.  #.## mins remaining   ( Where # is numbers )

Hope this helps someone.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.