Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: Cannot get into Windows desktop. Stuck on black screen, DWM.exe crash

09 Nov 2019   #1
Andarthiel

Windows 7 Ultimate 64-bit
 
 
Cannot get into Windows desktop. Stuck on black screen, DWM.exe crash

I am having problem where I am unable to even get to the desktop. It started after I used Autoruns tool to remove iCloud and a few other unnecessary apps from running during startup (nothing system related).
I can get to the login screen but once I enter my password, it takes an extremely long time to process everything. Eventually after about 1 hour it gets to a black screen and I get an error message saying DWM.exe has crashed. I've tried waiting even longer but it just gets stuck there. I've even tried pressing Ctrl+Alt+Del, sometimes it works but sometimes I get the error message saying unable to open security options. When I can get those options, I can open up task manager but it's very slow to respond and pushing the Services button does nothing and neither does trying to close explorer.exe(or restart it via new task) does nothing.
I can't even get into Safe Mode as it automatically restarts itself once it reaches a certain part of the safe mode logon process.
I even tried running Startup Recovery but the automatic tool can't fix the problem and I don't have any Systen Restore points to go back to
My Windows version is Windows 7 Ultimate 64 bit SP1
Are there any suggestions on how to fix this without reinstalling Windows or formatting my system HDD?
I suspect it could be a malware/virus but I can't even get to the desktop to run any antivirus/diagnostics.


My System SpecsSystem Spec
.
09 Nov 2019   #2
FreeBooter

Windows 10 Pro x64
 
 

Please boot your computer with Windows Setup Media and from Windows Recovery Environment start the Command Prompt.

Please type below command into Command Prompt and press Enter key.

The following command scans integrity of all protected Windows system files and repairs files with problems when possible.

Code:
Sfc  /Scannow   /OFFBOOTDIR=D:\   /OFFWINDIR=D:\Windows
Please replace partition letter D: with Windows installed partition letter. When computer boots into Windows Recovery Environment (WinRE) environment the drive letter assign to Windows partition may not be C: drive letter because Windows 7, 8 , 8.1 and 10 creates a separate system partition when it's installed from scratch. The system partition contains boot files WinRE assigns the system partition the C: drive letter and the Windows installed partition will be assign any other drive letter usually D: drive letter is assign to Windows installed partition. The Bcdedit /enum | find "osdevice" command can be use to find out the drive letter of the Windows installed partition the output of the Bcdedit command is similar to this osdevice partition=D:. The drive letter after partition= is the drive letter of the Windows partition.




If SFC command wont resolve the issue Windows Vista/ 7/8/8.1 keep a regular backup of the registry handy in case you need to overwrite a corrupted registry. By default, the RegIdleBackup task runs every 10 days, so that’s as far back as you would lose if you replaced the current registry with the automatically backed-up files. You can find the backed-up registry files in \Windows\System32\config\RegBack folder.


Please boot your computer with Windows Setup Media and from Windows Recovery Environment start the Command Prompt.

Please type below command into Command Prompt and press Enter key.

Code:
 Dir C:\Windows\System32\config\RegBack
Above command will list files stored within RegBack folder and there file size, make sure files are not zero size if they are do not follow below instructions.



Please replace partition letter C: with Windows installed partition letter. When computer boots into Windows Recovery Environment (WinRE) environment the drive letter assign to Windows partition may not be C: drive letter because Windows 7, 8 , 8.1 and 10 creates a separate system partition when it's installed from scratch. The system partition contains boot files WinRE assigns the system partition the C: drive letter and the Windows installed partition will be assign any other drive letter usually D: drive letter is assign to Windows installed partition. The Bcdedit /enum | find "osdevice" command can be use to find out the drive letter of the Windows installed partition the output of the Bcdedit command is similar to this osdevice partition=D:. The drive letter after partition= is the drive letter of the Windows partition.

Please type below commands into Command Prompt and for each command you have typed press Enter key.



Code:
Replace C:\Windows\System32\Config\RegBack\*     C:\Windows\System32\Config
As files are replaced, the Command Prompt displays their filenames on the screen.

This procedure assumes that Windows Vista/7/8/8.1/10 is installed to the C:\ partition. Make sure to replace C:\ drive letter to the appropriate Windows OS installed partition drive letter if it is a different location.


Above commands renames the registry files at their existing location, and then copies the registry files from the RegBack folder to the C:\Windows\System32\Config folder.
My System SpecsSystem Spec
09 Nov 2019   #3
SIW2

Microsoft Community Contributor Award Recipient

Vista x64 / 7 X64
 
 

If the already suggested sfc scan doesn't work:

Use boot media to look in your windows partition windows\system32\config\regback folder

If that has hive backups, then rename the existing hives in windows\system32\config folder to software.bok, system.bok, etc

Then copy the backup hives from windows\system32\config\regback into windows\system32\config

Boot media:
win7x86:
17514x86.iso
win7x64:
17514x64v15.iso
win10x64:
183x64.iso

Extract the iso to usb stick using usb7ice, or rufus, or similar
Usb7ice.zip

THen boot from the usb stick.


My System SpecsSystem Spec
.

09 Nov 2019   #4
SIW2

Microsoft Community Contributor Award Recipient

Vista x64 / 7 X64
 
 

Regback folder on your windows partition should look something like this - the files with no extensions are the hives.

In this picture there are backup hives of DEFAULT, SAM, SECURITY,SOFTWARE and SYSTEM dated 5/11/19. ( you can ignore any log and ms-regtrans files)

I usually don't bother replacing the sam and security hives.

Cannot get into Windows desktop. Stuck on black screen, DWM.exe crash-regback.jpg

Even if you have no shadow copies (and therefore no restore points), you have probably got hive backups.


My System SpecsSystem Spec
3 Weeks Ago   #5
peterm1981

Windows 7 Home Premium x64
 
 

It didn`t work. My main problem is that my old partition wont let me rebuildbcd and it say bootmgr missing.
I created a new partition on the remaining space after i split it with partition assist. And installed the same windows on that partition after i made it active.
Now my old partition still has all the files intact and i see windows folder too, but i cant boot it. Is there no way to add any working boot from the new partition windows to the old one that doesnt work?
Even the windows repair cant repair it. I downloaded and made a bootusb with that handy ISO file with all the tools, thats great. Any other ideas? Or should I just accept it and reformat it loosing all my data.

Also another question came up yesterday, my external harddrive that has numerous photos and textures for my work doesnt want me to access them on the other laptop running Windows 10.
I tried takeownership and also the elevated command takeown and icaclss , it ran through all my files saying success but in the end, i still cant open my jpg files and tiff files. I cant even set it with security tab and inherit permissions in Win 10.

Any ideas on these? Thank you
My System SpecsSystem Spec
3 Weeks Ago   #6
FreeBooter

Windows 10 Pro x64
 
 

Please boot your computer with Windows Setup Media and from Windows Recovery Environment start the Command Prompt.

Please type below commands into Command Prompt and press Enter key.

Following commands will repair Master Boot Record (MBR), Boot Sector and BCD Store.


Code:
Bootrec /FixMbr

Bootrec  /FixBoot

Bootrec /scanos

Bootrec  /RebuildBcd












If above Bootrec /RebuildBcd command wont work follow below instructions:


Since the BCD store exists and lists a Windows installation, you'll first have to "remove" it manually and then try to rebuild it again.

At the Command Prompt, type below command as shown and then press Enter:

Code:
C:
At the Command Prompt, type below command as shown and then press Enter:

Code:
bcdedit /export C:\bcdbackup
The bcdedit command is used here to export the BCD store as a file: bcdbackup. There's no need to specify a file extension.

The command should return the following on screen:
The operation completed successfully.

Meaning the BCD export worked as expected.


At this point, you need to adjust several file attributes for the BCD store so you can manipulate it. At the prompt, execute the attrib commands exactly like this:

Code:
attrib c:\boot\bcd -h -r -s
What you just did with the attrib command was remove the hidden, read-only, and system attributes from the file bcd. Those attributes restricted the actions you could take on the file. Now that they're gone, you can manipulate the file more freely - specifically, rename it.

To rename the BCD store, execute the ren command as shown:

Code:
ren C:\boot\bcd   bcd.old
Now that the BCD store is renamed, you should now be able to successfully rebuild it.

Try rebuilding the BCD again by executing the following, followed by Enter:

Code:
bootrec /scanos
bootrec /rebuildbcd
Restart your computer after rebuilding the BCD store.
My System SpecsSystem Spec
3 Weeks Ago   #7
peterm1981

Windows 7 Home Premium x64
 
 

Will try this thanks.
My System SpecsSystem Spec
.
3 Weeks Ago   #8
peterm1981

Windows 7 Home Premium x64
 
 

Ok, so on bcdedit /export C:\bcdbackup it says, like most other times i try something that:

The store export operation has failed.
The requested system device cannot be found.

So im stuck here.

bootrec /fixmbr, fixboot and scanos worked. it saw both my windows installs on each partition including the new one. But once i hit yes, to the old windows install it said the same thing:

The requested system device cannot be found.

So this is where i am stuck.
My System SpecsSystem Spec
3 Weeks Ago   #9
SIW2

Microsoft Community Contributor Award Recipient

Vista x64 / 7 X64
 
 

Might be it can't find the system partition. Are you using bios boot or efi?

according to this post, it is bios Cannot get into Windows desktop. Stuck on black screen, DWM.exe crash

You could try deleting the boot folder from the root of your active partition. Then see if you are able to recreate it and contents using bcboot command.

If your windows partition is D and your active partition is also D it goes like this:

first delete the folder D:\boot

then at cmd prompt type:

bcdboot d:\windows /s d:

That should copy all the relevant files from d:\windows\boot to D:\boot and the bootmgr to d:\

it should also put in the correct bcd entry to point bootmgr at winload

In addition, you could also use bootice to rewrite both the mbr and the pbr and double check the active flag is set to the correct partition.

What is supposed to happen is bios finds the active flag in the partition table. The mbr executable code passes control to the pbr code on the active partition, which then expects to find bootmgr on the root, wakes it up and bootmgr has a look in the bcd store to see where he is supposed to be going to find winload.

It is a chain which all needs to be working.
My System SpecsSystem Spec
3 Weeks Ago   #10
FreeBooter

Windows 10 Pro x64
 
 

Open Command Prompt and type following commands to display a list of volumes:


Code:
Diskpart


List Volume

Use Dir command for each listed drive letters to find out which partition holds BCD file.


Code:
Dir /a C:\Boot

Now replace C: drive letter for below commands with BCD file located drive letter:




Since the BCD store exists and lists a Windows installation, you'll first have to "remove" it manually and then try to rebuild it again.

At the Command Prompt, type below command as shown and then press Enter:

Code:
C:
At the Command Prompt, type below command as shown and then press Enter:

Code:
bcdedit /export C:\bcdbackup
The bcdedit command is used here to export the BCD store as a file: bcdbackup. There's no need to specify a file extension.

The command should return the following on screen:
The operation completed successfully.

Meaning the BCD export worked as expected.


At this point, you need to adjust several file attributes for the BCD store so you can manipulate it. At the prompt, execute the attrib commands exactly like this:

Code:
attrib c:\boot\bcd -h -r -s
What you just did with the attrib command was remove the hidden, read-only, and system attributes from the file bcd. Those attributes restricted the actions you could take on the file. Now that they're gone, you can manipulate the file more freely - specifically, rename it.

To rename the BCD store, execute the ren command as shown:

Code:
ren C:\boot\bcd   bcd.old
Now that the BCD store is renamed, you should now be able to successfully rebuild it.

Try rebuilding the BCD again by executing the following, followed by Enter:

Code:
bootrec /scanos
bootrec /rebuildbcd
Restart your computer after rebuilding the BCD store.
My System SpecsSystem Spec
Reply

 Cannot get into Windows desktop. Stuck on black screen, DWM.exe crash




Thread Tools




Similar help and support threads
Thread Forum
Windows 7 stuck on Black Screen After Completing Installation
Hello every1 i got a prob with my Win7 after the installation n the first reboot,and Starting Up Services, it comes on Completing Installation screen when it ends, it doesnt reboot, neither turn off, it just stays on black screen for hours. with the computer working, and the mouses`s cursor...
Installation & Setup
PC crash to black screen and stuck
hello sometimes my windows stuck and only hard reset help. i saw in windows history crushed logs that "Service_KMS.exe" stop working what i need to do? (win 7)
General Discussion
window 7 ultimate sp1 crash & boot at black screen but no desktop
Dear Experts, I have make few changes in registry to gain space from a ghost backup and then system crashes. When i try to restart it, after window logo, there is a black screen with mouse button. Did not start even in safe mode, same black screen. Tried every method: repair, restore,...
General Discussion
Black screen with cursor stuck after windows load
I have windows 7 64 bit. I left my computer on over the weekend (was running a mine craft server from it) and I left to go on a trip. Sometime that night the server went offline. When came back today, I found m computer at the windows 7 recovery manager. I have no clue what happened, my...
BSOD Help and Support
Windows Stuck on Black Screen with Cursor....
Hi there, I'm having troubles with my netbook that has never happened before. Lately it's been acting up. The netbook sometimes seems to go to a black screen with my cursor showing but cannot get out of the black screen at all. This happened a couple times now, and I'm forced to shutdown the...
Performance & Maintenance


Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 21:11.
Twitter Facebook