You having a wim file which is given to you for factory resetting your laptop by the company like dell,lenovo.etc but how to you don't know. Don't worry,Here is how to
Lets Start:
If any help YOU needs just reply here
First make a recovery disk,or you can use windows7 disc/usb ,because we will need the command prompt for doing it.
or
if you didn't have then you can do this by
after switching on your PC/laptop when the windows loading boot screen comes,just switch off your PC/laptop at same time
then follow the screenshot given
few seconds later
start up repair will start
just
cancel it
then
System Recovery Option will be displayed

now go to
System image Recovery => select a system image =>
next
click
advanced =>
install a driver =>
click OK =>
go to computer
then
note the drive where your dsimagex.exe file is,in my case its in D drive. after that click cancel
and head to system recovery option. download it and place it any drive(not in any folder,for simplicity) you can also place it where your wim file is stored.
extract it to any drive,not within any folder(for simplicity)
Now go to
command prompt from System Recovery Option,then type commands
A: (A any drive name where You have placed) in my case it was in D drive
write then hit enter button
d:
dsimagex.exe
after hitting enter a imagex window will open,
now go to =>
apply menu =>
source => browse the wim file

now => destination(most case C dive) => choose c drive or where
your operating system is located.
after that click
apply. :) & wait for completion

and that's you have done now let it to complete,
after completion
close everything &
just exit and click restart your PC/laptop.

congrats :) your PC/laptop restored to factory settings.
regards
Admin