Content Type
Profiles
Forums
Events
Everything posted by gunsmokingman
-
Batch Script Tips and Tricks for XPCDs
gunsmokingman replied to DarkShadows's topic in Unattended Windows 2000/XP/2003
Please do not let the size of this bother you almost 1/3 of the lines are for asking if you want to keep or delete the the file. This is not a batch file but a VBS script it will list all instances of a file named win51ip regardless of extention. Save This As Seekwin51ip.vbs Red Is The Question To Either keep Or Delete The File. This Can Be Removed From The Script Green Is The File It Searches For And This One Is Where You Type The Name Of The file You Would Like To Search For. Save As UserSeekFile.vbsPurple Is The User Input That Get The Name, Plus A Part That deal With Quiting And Continuing On with The script. Red Is The Question To Either keep Or Delete The File. This Can Be Removed From The Script -
Special char. "Ø" in .cmd file
gunsmokingman replied to BoardBabe's topic in Unattended Windows 2000/XP/2003
You can run a Vbs From The Cleanup.cmd I use Vbs to do my clean up Place this in the cleanup.cmd What I Use Edit To Give A Example echo off && CLS && Mode 55,5 && Color f1 && Title Check For CD Set Drvs=(C: D: E: F: G: H: I: J: K: L: M: N: O: P: Q: R: S: T: U: V: W: X: Y: Z:) Goto 004 :004 for %%i in %Drvs% do if exist %%i\SETUP.exe set CDROM=%%i && goto 001 for %%i in %Drvs% do if not exist %%i\SETUP.exe goto 002 :001 CLS && Color F2 && Title Confirm The CD echo. && echo Confirm The Cd Is %CDROM%\ ping -n 3 127.0.0.1>nul Goto Work :002 CLS && Color Fc && Mode 55,3 && Title Missing The Correct CD Echo. && Echo Missing The Cd && ping -n 3 127.0.0.1>nul Goto 003 :003 ClS && Mode 50,9 && Color 5e && Title Continue Or Exit Echo. && Echo %UserName% Would You Like To Quit Or Continue && Echo. Echo Yes To Continue && Echo. && Echo No To Exit && Echo. SET Choice= SET /P Choice=Would You Like To Quit Or Continue : IF NOT '%Choice%'=='' SET Choice=%Choice:~0,4% IF /I '%Choice%'=='YES' GOTO YES IF /I '%Choice%'=='NO' GOTO Uquit IF /I '%Choice%'=="%Choice%" GOTO OPS :OPS Echo. && Echo Not A Valid Reply ping -n 2 127.0.0.1>nul goto 003 :Uquit Cls && Color F2 && Mode 62,4 && Title Quiting The Cleanup && Echo. && Echo %UserName% Has Selected To Exit ping -n 4 127.0.0.1>nul Goto Quit :Yes Cls && Mode 55,5 && Color f2 && Title Continue With Clean Up && Echo. && Echo %UserName% Make Sure This Is The Correct CD! Echo Preparing To Re Check For The Correct CD ping -n 4 127.0.0.1>nul Goto 004 :Work echo Start work Ping -3 127.0.0.0.1>nul SET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx REG ADD %KEY%\170 /VE /D "Preparing Final Clean up ..." /f REG ADD %KEY%\170 /V 1 /D "%CDROM%Apps\SilentUaC.exe" /f Clean up Templates Thread SilentUac Download -
Special char. "Ø" in .cmd file
gunsmokingman replied to BoardBabe's topic in Unattended Windows 2000/XP/2003
Try This Is This The Correct Name That You Need Save As Name.Vbs Also Try The Vbs Script If This Doesnt Work. -
Special char. "Ø" in .cmd file
gunsmokingman replied to BoardBabe's topic in Unattended Windows 2000/XP/2003
Try This And Save As MoveFile.vbs Or Whatever Name You Need.The Orange Line Can Be Removed , You Will Not Get Any Error Messages Without it in there. It Serves Only as The Error Message If The File Is Not There. The Green Is In Case The Spaces In The Path Cause A problem remove the ' from the start of the line And Place A ' before this Fso.MoveFile(Loc1),(Loc2) -
Take out your sound card and then see if you can go to those sites with out it rebooting. If you can go to those sites then it was your sound card. I have a cheap pci sound card that used to cause the same type of problems, for me it would just reboot for no reason or freeze up the computer. I took the pci card out and enable the on board sound card and that seemed to stop the rebooting problem and freeze problem.
-
Short batch file question!
gunsmokingman replied to Fascix's topic in Unattended Windows 2000/XP/2003
You could also use a vbs file to delete the stuff. Things In Green Are The Part Of The Script That Perform The Action Things In Orange Are Safe To Remove From Examples Things In Blue Are The Objects Needed For Various Task, These Are Like Cmd Promt Ping Dir Tree, But Are More Powerful Than Cmd Promts. Example One This Runs A Check Then Will Delete Example 2 On Error Resume Next = If This Is Not There Then You Will Not Get A Error Message Example 3 This Will Work Only From The Drive That The Script Start From EG If This Script Was Started From E and Windows Is On C Then It Would Produce A Error. If The Script Is Ran From The Same Drive That Windows Is Installed On Then It Will Work. Example 4 Same As Example 3 But Has A Error Control -
Easiest way to copy i386 dir to HD during UAI
gunsmokingman replied to aspenjim's topic in Unattended Windows 2000/XP/2003
Here is a script that I use. 1\ Check to see if the XPCD is on %systemdrive% 2\ If it not there then it build the work directory 3\ If It is then it checks to see if XP is in the CD drive 4\ If it not there then it gives the option to quit or it ask to place the XP Cd In the CD Drive 5\ If the work directory is there and it the correct CD then it start the copy. The ping cmd is a way to pause the script with out using Sleep.exe Echo Off CLS && Color 1F && Mode 65,5 && Title Ua Build Directory And Copy for %%i in (C: D: E: F: G: H: I: J: K: L: M: N: O: P: Q: R: S: T: U: V: W: X: Y: Z:) do if exist %%i\SETUP.exe set CDROM=%%i if exist %systemdrive%\XPCD\ goto 000 if not exist %systemdrive%\XPCD\ goto 001 :000 CLS && Color F1 && Mode 55,5 Echo. && echo The Work directory Was There ping -n 2 127.0.0.1>nul goto CopyCd2HD :001 CLS COLOR A0 ECHO Make Work Directory PING -N 3 127.0.0.1>NUL mkdir %systemdrive%\XPCD\$OEM$\ mkdir %systemdrive%\XPCD\$OEM$\$1\ mkdir %systemdrive%\XPCD\$OEM$\$1\Drivers mkdir %systemdrive%\XPCD\$OEM$\$1\Drivers\002_graphics mkdir %systemdrive%\XPCD\$OEM$\$1\Drivers\004_sound mkdir %systemdrive%\XPCD\$OEM$\$1\Install mkdir %systemdrive%\XPCD\$OEM$\$$\Fonts mkdir %systemdrive%\XPCD\$OEM$\$$\Media mkdir %systemdrive%\XPCD\$OEM$\$$\Resources\Themes mkdir %systemdrive%\XPCD\$OEM$\$$\System32 mkdir %systemdrive%\XPCD\$OEM$\$$\Web\Wallpaper mkdir %systemdrive%\XPCD\Apps mkdir %systemdrive%\XPCD\i386 ECHO Completed Building The Work Directory! ping -n 3 127.0.0.1>NUL goto CopyCd2HD :CopyCd2HD If exist %cdrom%\setup.exe goto CopyCd If Not exist %cdrom%\setup.exe goto User :User CLS && Color 4f && Mode 65,8 && Title User make A Selection? Echo Please Insert The XP Cd To Continue Echo. Echo Type Yes To Continue && Echo Type Quit To Exit echo. SET Choice= SET /P Choice=Type Yes Or Quit and press Enter: IF NOT '%choice%'=='' SET select=%choice:~0,9% IF /I '%choice%'=='Yes' GOTO CopyCd IF /I '%choice%'=='Quit' GOTO end2 IF /I '%Choice%'=='%Choice%' GOTO OPS :OPS CLS && MODE 55,3 && COLOR 9F ECHO. && ECHO NOT A VALID SELECTION ping -n 3 127.0.0.1>nul GOTO User :Missing CLS && MODE 55,3 && Color 9e Echo. Echo Please Insert The Cd ping -n 3 127.0.0.1>nul goto User :CopyCd If Not exist %cdrom%\setup.exe goto Missing cls mode 97,5 color 0e ECHO Begin The Copy? ping -n 2 127.0.0.1>nul xcopy %cdrom%\...\...\ %systemdrive%\XPCD\ /S /E /W /F /I /v cls && mode 55,3 && color f9 && Title Copy Completed! ECHO. && ECHO Copy To Hard Drive Completed! echo. PING -N 4 127.0.0.1>NUL goto End1 :End1 CLS && Color f3 && Mode 55,3 && Title Completed Copy echo. && Echo Goodbye The Script Is Completed! ping -n 4 127.0.0.1>nul goto EOF Exit :end2 CLS && Color f3 && Mode 55,3 && Title User Selected To Exit echo. && Echo User Has Selected To Quit This Script && Ping -n 3 127.0.0.1>nul goto EOF Exit -
I agree with jaclaz in his statement. You did the same thing in a post about a Vbs code I posted, but yet you could not produce any thing except a childish remark hinting at my code being big. Yet you could not produce no code what so ever. So if you dont like what I post or anyone else maybe you should ignore it. If it is not correct then add to the post by correcting it, with out trying to be little some one who took the time to post it. No where does it say that this is the best all I said is what I have used for the last couple of years, on 3 diferent computers, this was ment only as a reference for other no more or less.
-
Simple VB Script
gunsmokingman replied to ryancooper's topic in Programming (C++, Delphi, VB/VBS, CMD/batch, etc.)
That script does a loop for Pete, Phil, Ryan They Have To Input The Right Number For Each User As To Location You Have To Make Sure They Are Correct As I Used Only The First Post As My Template To Make My Script. There Are 4 Function That The Input Box Controls A Error Or Cancel Function And A Function For Each Of The Above Listed Users. -
Simple VB Script
gunsmokingman replied to ryancooper's topic in Programming (C++, Delphi, VB/VBS, CMD/batch, etc.)
Try This I Dont Know If It What You Want I have added a Inputbox for the User To Selection -
How come my RunOnceEx.cmd file isn't working?
gunsmokingman replied to Sgt_Strider's topic in Unattended Windows 2000/XP/2003
It might have to do with the desktop top not being loaded up when the script runs this is only a guess. Since this is a cleanup it might be better to do the install make sure the desktop is loaded up, reboot have the cleanup.cmd start after that reboot. Hope this helps. -
Work from my desktop
-
How come my RunOnceEx.cmd file isn't working?
gunsmokingman replied to Sgt_Strider's topic in Unattended Windows 2000/XP/2003
Changing colors is for apperance only or did you not know that. It just to make it look better than the standard black and white. If it not to hard you could take out this line Color F1 but that might require some thinking on your part. I am just in the habbit of adding it to my Cmd scripts. -
I tried both from my desktop and it didnt work. the test files I made where New.log Document.log Text.log New Text Document.log newTextDocument.log This Vbs I ran From My Desktop and it worked. It is a re edit of the earlier vbs it was late here for me and the first one i forgot some things.
-
Here A VBS File That Should Remove What You Need And Leave What You Want On My Test it Left All Log File With W in Windows Save As RemoveLog.Vbs For The Cdrom you need to set the varible for itHere are 2 different ways to do it,
-
How come my RunOnceEx.cmd file isn't working?
gunsmokingman replied to Sgt_Strider's topic in Unattended Windows 2000/XP/2003
This is how my Cleanup.cmd file looks like Here is one I corrected for youIt was missing some stuff. You Need To Have " These At The Begging And End" Changed The Cmd Screen To Be Smaller Change The Background To White Change The Text To Dark Blue Added A Title -
Help for VB or VBS
gunsmokingman replied to CrescendoBEAt's topic in Programming (C++, Delphi, VB/VBS, CMD/batch, etc.)
I am a self taught on VBS no courses or nothing,Here is the spot I go to learn about VBS scripting. I am glad I could help on this. Hey, Scripting Guy! -
I have used this setting for the last couple of years with no problem max = 384 and min = 384 on my C drive. I dont Install any thing on C:\ other than my page file. I have My Os installed On D:\ I have used the same setting on these computers P2 256 ram Amd 1.7 256 ram P4 2.8 512 ram There is not any real rules on this but only general guide lines. Article To Read 1
-
The dll host should not be running WMP Player Does Seem High
-
I have been in the beta for it.
-
Rename File With Current Date? (Batch File?
gunsmokingman replied to phillyman2004's topic in Windows XP
NLSFUNC I use this from what i read so it work in other langauges. I have never been able to figure out exacly what it does, It doesnt cause any erors so I left it in. As to windows 2000 I am not sure if it will work, but since it a cmd file, it in therory should work. Maybe some of the more gifted members can explain this NLSFUNC function better then I can. -
Here is my desktop MyDesktop
-
You cannot have the Luna style task bar using W2k theme files, you can only have the classic taskbar using a w2k theme.
-
Including own custom shell32
gunsmokingman replied to Scubar's topic in Unattended Windows 2000/XP/2003
This is the latest version of the shell32.dll for XP SP2 I forget which update changes it from the version you have, v6.0.2900.2180 VALUE "ProductVersion", "6.00.2900.2620" shell32.dll -
W2k themes only work as Classic in XP because W2k does not have the same theme support as XP.