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: Need help testing my script

23 Mar 2010   #11
Product FRED

Windows 7 Enterprise 64-bit
 
 

The one thing I learned from this is how to have fun with VBS-generated popups

Also you might find this tiny little command line app useful: http://www.soft32.com/download_194850.html

Check this out:




Attached Files
File Type: vbs Game.vbs (48 Bytes, 9 views)
My System SpecsSystem Spec
.
23 Mar 2010   #12
Phrosen

Windows 7 Professional x64
 
 

Quote   Quote: Originally Posted by Arc View Post
Quote   Quote: Originally Posted by Phrosen View Post
Hi.

All you need to do is to unzip the .rar file (attached to this post), and double-click on 'RunMe.bat', and tell me what happens.
The script should take care of the rest.
Downloaded and unrared. Ran runme.bat
Know what happened then ?
I got screwed, man
It said thet the operation is complete. Now you manually restart your computer. After manually restart, It's all black screen with the mouse pointer only.

Do have any fix for the issue?
I'm sorry.
I have no idea what happened.

I once managed to screw myself over (not using this script, though).
I just started in fail safe mode and did a system restore, and everything worked nicely.

I figured people using this script would read the command lines and take precautions before testing everything (even though it should be safe.)

Like some people already mentioned my script saves a backup file of explorer.exe
It is stored as: "C:\explorer_backup.exe"


Quote   Quote: Originally Posted by Kari View Post
Phrosen, download and install Windows Virtual PC and the free 90 day trial version of Windows 7 Enterprise. Install Seven Enterprise to a virtual machine, and make a copy of vhd.

You can then test as much as you want, and if something happens, you just delete the virtual machine, mount the copied vhd and carry on.

Lycka till!

Kari
I will test this out and see if it helps.
Thanks. =)



Quote   Quote: Originally Posted by Product FRED View Post
The one thing I learned from this is how to have fun with VBS-generated popups

Also you might find this tiny little command line app useful: Download Vbs To Exe 1.1 - VBScript to Exe Converter

Check this out:

Yea, it's great. :P

I will check it out, thanks for the tip. =)

EDIT: Lol, the game.
I always win the game, btw. Good try, though.
My System SpecsSystem Spec
23 Mar 2010   #13
Arc

Microsoft Community Contributor Award Recipient

Microsoft Windows 10 Pro Insider Preview 64-bit
 
 

Thanks to Fred and Prisoner for their friendly feelings I solved it within a few minutes. I had a few earlier backups of explorer I made to change windows frames etc, and I have a ubuntu installation in my machine, not as dual boot. I opened Ubuntu, and first deleted explorer, and then renamed a backup to explorer

I have a system Image backup, and restore points are created off and on. I may use any of them, too. But the thin I tried worked nice.

Yes, mine is a 32 bit system. Phrosen, you should have mentioned it

Finally , thanks to Kari for the Windows 7 in windows 7 suggestion. I'll try it.
My System SpecsSystem Spec
.

23 Mar 2010   #14
gladson1976

Windows 7 Ultimate x64 (XP, 98SE, 95, 3.11, DOS 7.10 on VM) + Ubuntu 10.04 LTS Lucid Lynx
 
 

Quote   Quote: Originally Posted by Product FRED View Post
You forgot one very important thing: The explorer version must match the installation version. I'm assuming you provided a 64-bit version. Arc, are you on x64 or x86?

Anyways, to fix it, start in Safe Mode with Command Prompt and just type:

Quote:
ren C:\explorer_backup.exe explorer.exe
copy /y C:\explorer_backup.exe C:\Windows\explorer.exe
The first command renames the backup to "explorer.exe", the second command tells it to overwrite the unwanted one. The /y tells it to overwrite without confirmation.
@pf
shouldn't the syntax be just,
copy /y C:\explorer_backup.exe C:\Windows\explorer.exe

'cos once you rename C:\explorer_backup.exe as explorer.exe, you can't copy C:\explorer_back.exe

My System SpecsSystem Spec
23 Mar 2010   #15
Product FRED

Windows 7 Enterprise 64-bit
 
 

You're absolutely right. I editted my post and forgot to fix the second command.
My System SpecsSystem Spec
24 Mar 2010   #16
Phrosen

Windows 7 Professional x64
 
 

I managed to get a print screen of my script in-action.
Apparently it's failing on some points.

I have added a line of command, the 'DEL' -one.
Here's what my script currently looks like: (without the numbers.)

1. TAKEOWN /F C:\Windows\explorer.exe
2. COPY /Y "C:\Windows\explorer.exe" C:\explorer_backup.exe
3. TASKKILL /F /IM explorer.exe
4. DEL /F /Q C:\Windows\explorer.exe
5. COPY /Y explorer.exe C:\Windows\
6. START /D C:\Windows\ explorer.exe
7. START notice.vbs

The print screen displays that the script is working from point 1 to point 3.

Then point 4 fails: "Access denied"
Point 5 fails: "..the file is used by another process" (even though point 3 works.)
Point 6 fails as well: "..something about the path being wrong.."

Point 7 works.

Any ideas on how to make point 4,5 and 6 work?
Why does point 5 state that explorer.exe is being used by another process, when I killed explorer.exe in Point 3?
My System SpecsSystem Spec
24 Mar 2010   #17
Generator

XP Pro SP3 x86/Vista SP2 x64/Win7 x64 Triple-boot
 
 

4. maybe failing because explorer hasn't been 'killed' properly just yet from point 3, taskkill isnt instant. Also you shouldn't really need to delete it, you could just overwrite the existing one. I get around these problems by killing anything needed first thing then make ppl 'press a key to continue' by using the 'pause' command

5. same as above, explorer still shutting down maybe?

6. has a gap in the path just before explorer.exe, yours says "START /D C:\Windows\ explorer.exe" where it should be "START /D C:\Windows\explorer.exe"


also, you have hard-coded the drive letter into your script, try using %SYSTEMDRIVE% instead of the actual drive letter or even %windir% for the actual Windows folder. This will make sure it runs on dual-boot systems etc, for example, on my PC c:\ is for my XP install, my Win7 is on drive F!

hope this helps.
My System SpecsSystem Spec
24 Mar 2010   #18
Phrosen

Windows 7 Professional x64
 
 

EDIT:
It seems to be working now. Thanks everyone for your help.

Now I want you to try the new script.
Read this first:


-Apparently this only seems to be working on Windows 7 x64 systems. Do not attempt to use this script on x86 system, unless you know what you're doing.
-Make sure you create backups, before running the script. (System restore points, etc.)
-Read the ReadMe.txt file carefully before running the script.


I would appreciate if someone with a virtual machine could test this script on an x86 system, and see if it works or not.

Thanks in advance.
My System SpecsSystem Spec
24 Mar 2010   #19
Product FRED

Windows 7 Enterprise 64-bit
 
 

It only works on x64 because you included a 64-bit explorer executable. Make a separate archive with the same script, but include the x86 explorer.exe instead and it should work fine.
My System SpecsSystem Spec
24 Mar 2010   #20
Phrosen

Windows 7 Professional x64
 
 

Quote   Quote: Originally Posted by Product FRED View Post
It only works on x64 because you included a 64-bit explorer executable. Make a separate archive with the same script, but include the x86 explorer.exe instead and it should work fine.
Good idea, thanks.

Are you sure it will work on all Windows 7 64-bit systems, though?
Home Basic, Home Premium, Enterprise, Ultimate, whatnot.

I need someone who runs a 32-bit system to make one for me, btw.
I didn't get the virtual machine thingie to work. =/
My System SpecsSystem Spec
Reply

 Need help testing my script




Thread Tools




Similar help and support threads
Thread Forum
PSU Testing
Here is a rewrite of the PSU Test. https://www.sevenforums.com/vip/257690-psu-how-test-3.html#post2130086 Before attempting the following PSU test, power system off and pull the power plug or flip the PSU switch off, whichever applies. Do not open the PSU's case! It can carry a lethal dose of...
Hardware & Devices
Testing
Does it always take approval of a mod to get your post posted? when do you get elevated so it instantly posts? edit- i posted in the crash portion but it didnt get posted yet. is there different policy for each topic area? or is it because i am new?
Chillout Room
testing
just testing to see if i did this sig right or not
Chillout Room


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 07:15.
Twitter Facebook Google+ Seven Forums iOS App Seven Forums Android App