
Smiley357
MemberContent Type
Profiles
Forums
Events
Everything posted by Smiley357
-
Some software must be run with the administrator logged on. Doing runas will not always work for an install. There is freeware killpol - Temporarily remove policy restriction for the current user. You can try this but my guess is that if you’re unable to install with runas you will not be able to install with this either. You will need an administrator password also. If you want the software installed without giving the user an admin password you will need some kind of WMS (windows management system) or SMS (system management server) to push the .msi to the machine or group of machines.
-
User Menu Select and Run
Smiley357 replied to JayDogg's topic in Programming (C++, Delphi, VB/VBS, CMD/batch, etc.)
You might want to check out AutoIt (http://www.autoitscript.com/) Its free and very easy to use. There are examples you can view to learn from. If you want to stick with command line and use a bat file or cmd file for XP. Then you can start out with this. Echo 1. Install Echo 2. Move Echo 3. Copy Echo 4. QUIT PROGRAM Echo. Echo. SET /P choice=Type In Your Reply Then Press Enter ^> IF "%choice%"=="1" (GOTO ONE) IF "%choice%"=="2" (GOTO TWO) IF "%choice%"=="3" (GOTO THREE) IF "%choice%"=="4" (GOTO QUIT) ELSE (GOTO ERROR) -
Copy text string to ini file
Smiley357 replied to sentinel1705's topic in Programming (C++, Delphi, VB/VBS, CMD/batch, etc.)
You can put an echo at the end of the scrip to let you know it’s finished. I’m guessing you don’t want a pause after every profile so you will need to remove the pause from the function. @echo off dir C:\test\*.* /b -o:d | find /v "." > c:\dirs.txt for /f "tokens=*" %%a in (c:\dirs.txt) do call :search "%%a" del C:\dirs.txt Echo script has finished pause goto EOF :search >>"C:\Test\%~1\windows\profile.ini" Find /i "string1"<"C:\Test\%~1\windows\profile.txt" >>"C:\Test\%~1\windows\profile.ini" Find /i "string2"<"C:\Test\%~1\windows\profile.txt" >>"C:\Test\%~1\windows\profile.ini" Find /i "string3"<"C:\Test\%~1\windows\profile.txt" Another option is to have it echo "script has finished" and wait x amout of time and then finish. All you have to do is replace the pause with this: Echo script has finished ping 127.0.0.0 -n 10 >nul This will wait for 10 seconds before it continues and in this case end. -
Thx Joe i will have to check them out.
-
I'm looking for a job (in the IT field). Where do you guys suggest looking?
-
Copy text string to ini file
Smiley357 replied to sentinel1705's topic in Programming (C++, Delphi, VB/VBS, CMD/batch, etc.)
This should work for you. Just change string1-3. I have tested this and it worked. So Yzowl code works. If it dont work for you check the file locations or the string your trying to look for. BTW you owe me a beer for the script. LOL @echo off dir C:\test\*.* /b -o:d | find /v "." > c:\dirs.txt for /f "tokens=*" %%a in (c:\dirs.txt) do call :search "%%a" del C:\dirs.txt goto EOF :search >>"C:\Test\%~1\windows\profile.ini" Find /i "string1"<"C:\Test\%~1\windows\profile.txt" >>"C:\Test\%~1\windows\profile.ini" Find /i "string2"<"C:\Test\%~1\windows\profile.txt" >>"C:\Test\%~1\windows\profile.ini" Find /i "string3"<"C:\Test\%~1\windows\profile.txt" -
Humm.. thats a good question. I'm not sure how to rename files that are already archived without extracting them.
-
Copy text string to ini file
Smiley357 replied to sentinel1705's topic in Programming (C++, Delphi, VB/VBS, CMD/batch, etc.)
Im not eactly sure what you are looking for but here is a batch file that can find a string "setting#" and append it to the file.ini @echo off FOR /F "skip=2 tokens=*" %%i IN ('find /i "Setting1" D:\Profiles\User1\windows\profile.txt') DO echo %%i >> D:\Profiles\User1\windows\profile.ini FOR /F "skip=2 tokens=*" %%i IN ('find /i "Setting2" D:\Profiles\User1\windows\profile.txt') DO echo %%i >> D:\Profiles\User1\windows\profile.ini FOR /F "skip=2 tokens=*" %%i IN ('find /i "Setting3" D:\Profiles\User1\windows\profile.txt') DO echo %%i >> D:\Profiles\User1\windows\profile.ini -
7ZIP can be used in a batch file to archive files to .zip. It is freeware. Here is a very simple example of how to archive all files in the directory to .zip. @echo off for %%i in (*.*) do "C:\Program Files\7-Zip\7z.exe" a -tzip %%i.zip %%i -r this is a very simple example and will even archive the batch file since it has to be in the directory it is searching.
-
The users most likely don’t have write access to the %systemroot%.
-
If you dont want to replace a file all you have to do is check to see if the file exist. If so skip it. IF EXIST File GOTO EOF If you want to add time to the file name here is how to remove the ":" and "." Im sure someone is going to come along with a better way.. jaclaz.. but this answers your question just like my last code did. LOL Set FileTime=%Time::=% (this removes the ":" from time and saves it in FileTime) Set FileTime=%FileTime:.=% (this removes the "." from FileTime and saves it in FileTime)
-
I think this is what you are looking for. Save this as a bat or cmd file. @echo off xcopy /I /E /H d:\ e:\ cd "e:dir of files to be renamed" for %%i in (*.*) do Call :rename "%%i" :rename set oldname=%~1 Set FileDate=%date:/=% set newname=%FileDate%-%oldname% ren "%oldname%" "%newname%" If you dont want the day of the week in your file name change the set newname to this: set newname=%FileDate:~4%-%oldname%
-
no one has any ideas?
-
What is your source? XP? SP1,2,3? 2003? SP? XP SP2 What is your USB device? Hard disk? USB stick? How did you format it? What file system? USB device is a USB hard disk. It was formatted with the HP USB disk storage format tool v2.0.6 What do you mean "1) Nothing happens"? Nothing from what you expected, or nothing indeed? This is the most interesting part. The only thing that happens is the screen clears and I see the prompt but unable to type anything and it just sits there. is to start grub4dos, from it you can launch whatever else you want, including, not only Vista. 2 3 memory test When I chose 4 I get several options. Option 2 and 5 start the corrupted XP from Hard drive. And for the rest of the options I get this error: “Warning: MBR cylinders(4864) is not equal to the bios one(16383). Warning: MBR heas(255) is not equal to the bios one (16). Filesystem type is ntfs, partition type 0x7 chainloader (hd0,0)/bootmgr Warning: MBR cylinders(4864) is not equal to the BIOS one(16383). Warning: MBR heas(255) is not equal to the BIOS one(16). Error 17: File not found Press any key to continue..” And here is the simple question. How to you insert a quote? LOL
-
OK this is what I got. I ran the USB_MultiBoot_8.cmd I set the usb and cd drive. Click yes to all the prompts. That seemed to work fine. Now when I boot to the usb I get 4 options. 5 if I do the bart PE. 1) txt mode setup windows xp… 2) GUI mode setup windows XP, continue setup+ start XP from HD1 3) Start windows xp form hd2 4) Start grub4dos menu… 1- This does nothing as expected 2-I get this error. “Windows could not start b/c the following file is missing or corrupt: <windows root>\system32\hal.dll 3-I get this error. “Windows could not start b/c of a computer disk hardware configuration problem. Could not read from the selected boot disk. Check boot path and disk hardware. Please check the windows documentation about hardware disk configuration and your hardware reference manual for additional information.” 4-I think this is for vista and the options don’t work. OK so what am I doing wrong?
-
here is the link on how to make a ghost boot disk. http://service1.symantec.com/SUPPORT/sunse...57?OpenDocument
-
It’s been awhile since I did it. But, when you boot from the floppy an app (ghost.exe) should start up if not just call the ghost.exe file. To do this just go to the floppy drive if your not already there. Normally A: by typing “a:” then type “ghost.exe” if ghost.exe is in a folder then you have to type “folder/ghost.exe” and when I say folder I mean the name of the folder not the word folder. From there you just follow the steps. Here are the steps I would use to restore from USB. I believe my Ghost boot disk’s are from Ghost 2003. So might be a little different for you. I had to have 2 disk’s. Insert USB and Floppy disk 1, then boot the computer up. 1. Enter choice: 1 (this computer was started from a ghost boot disk) 2. Insert “Ghost boot disk 2” when prompted 3. select Local>Disk>from image 4. At dropdown box select “usb drive” 5. Select “Your image.GHO” file a. Select drive 1 if there is the option of 2 drives b. Click “ok” c. Click “ok” d. Click “yes” e. Restart computer when clone is completed successfully
-
You can restore from your cd/dvd Norton ghost. I believe you can also make a boot floppy that can restore your backup. Just do a search on Symantec website. There you will find step by step instruction on how to restore your back up. Here is the link to restore from your cd. http://service1.symantec.com/SUPPORT/sunse...4e?OpenDocument
-
He said that he doesn’t want to make changes to the proxy so im guessing he has one. So if you go to the clients machine and open up the browser go to tools>internet options>connections>lan settings>advanced and enter the url in the exceptions. Site will not be accessible. Simple, easy and cheesy. LOL
-
Well, a cheesy way to block a site/url is to add the site to the user’s proxy settings exceptions. This will cause the browser to look for the site locally and give the user a page cannot be found. Easy to do and can be pushed down from server next time user logs on.
-
I hate to ask this but did you burn it to a dvd-rom and you have a cd-rom in the other computers? It sounds like the new computers are not reading the format of the cd. When you made the CD did you make a image or did you just copy files to the cd/dvd-r
-
www.Whatsmyip.org is a lot nicer then .com but how would you use that in a bat file? Redhatcc : Why are you trying to find your IP in a bat file? B/c of the FTP site you are making?
-
I don’t have satellite but friends do and when I send them to that site for there IP it will give a incorrect IP. So I just walk them through the steps of logging into there router to find there ip.