This section includes InterviewSolutions, each offering curated multiple-choice questions to sharpen your knowledge and support exam preparation. Choose a topic below to get started.
| 3051. |
Solve : how I can shutdown a service (process) ??? |
|
Answer» Some BODY how I can SHUTDOWN a service (process) from WINDOWS 2000 with a BATCH file? Thank you for your time and HELP. to stop the service, Use the command Net Stop "Service Name" |
|
| 3052. |
Solve : no boot filename found? |
|
Answer» can you help me solve this PROBLEM...and my ibm laptop says ` operating system not found` |
|
| 3053. |
Solve : removing periods from directory names? |
|
Answer» Well I'm just stumped. I've written plenty of batch files, but can't for the life of me figure this one out. |
|
| 3054. |
Solve : DOS command for yesterdays date? |
|
Answer» I want to create batch file which will create directory with name as 'yesterdays date' every day. |
|
| 3055. |
Solve : trim the leading string from the parm? |
|
Answer» Hi all. |
|
| 3056. |
Solve : How to check a file size using DOS command?? |
|
Answer» How to check a file size USING DOS command? |
|
| 3057. |
Solve : Absoulte referencing? |
|
Answer» How to display files with a certin EXTENSION in a directory using ABSOLUTE referencingI may be reading this request in too SIMPLE a FORM. I don't understand the term "Absoulte Referencing". |
|
| 3058. |
Solve : Display a message in config.sys similar to echo? |
|
Answer» Is there any way to show a message from the config.sys FILE after or before the menu items. Similar to echo in a BATCH file??? PLEASE help really stumped here.Try using Rem or ; PRECEEDING the comment you want displayed. |
|
| 3059. |
Solve : need help,want to use dos to open network file? |
|
Answer» i NEED to get into WINDOWS 2000 NETWORK neighbor and CHANGE the settings, my logon doesn't work for windows |
|
| 3060. |
Solve : how to use Xcopy? |
|
Answer» :oHow do I use xcopy to transfer operating system to slave HDD so can transfer to ANOTHER computer If you have xcopy AVAILABLE, you COULD type: |
|
| 3061. |
Solve : Formatted windows 98 having trouble booting? |
|
Answer» I've formatted my drive and when I start up, with a start up/ boot disk in A: I get an error MESSAGE "invalid system disk" Replace disk, and then press any key. ...I just typed in format c: ... Correct command is format c: /s You have formatted but not transferred the Operating System (the "/s"). Try sys c: which transfers the OS after formatting or reformat with /s option. honee......I'm still not 100 % clear on what you did .....You used the old "startup/bootdisk" in the floppy drive before you removed win 98 ........by .....at the A: prompt typing " Format C: followed by Enter .......and you GOT the warning about losing all the data....do you want to continue and you anwsered yes......then it proceeded to REMOVE all contents of the hard drive. Were there any partitions on your hard drive ? Then with the "start/bootdisk" still in the floppy drive you rebooted and the bootdisk loaded and you got an A: prompt...... Please clarify .....because it doesnt sound like you have the correct boot disk ? let us know dl65 after the format c did you use the fdisk command...if you are have problems.....go into the bios...when your pc is booting....press the ctrl or del key and change the boot sequence by using the arrow keys...boot from cdrom....the install disk should do the rest...if not have a look here>http://www.windowsreinstall.com/win98/install98cd/index.htm |
|
| 3062. |
Solve : What if? |
|
Answer» What would HAPPEN if C:\windows\system32\CMD.exe gets deleted? Me and my FRIEND are having a bet.You try it and let us know.Will the computer even boot up windows without CMD? |
|
| 3063. |
Solve : Upgrade from 95 to 98???? |
|
Answer» I normally work with XP/2000 and am not sure but is it possible to upgrade from Win 95 to 98? |
|
| 3064. |
Solve : problem? |
|
Answer» i dont have atoexec any more, but i have XP cd , how i can get it and where to i have to but itNot sure i fully understand what you're saying. If you're trying to install xp from DOS the command is |
|
| 3065. |
Solve : DOS Programs screw up in win2k? |
| Answer» OKAY, so I have this program that was made for windows 95-98, and when I run it in Win2k, it starts the program up, but the CURSOR gets stuck in the top left-hand quarter of the screen. It's KIND of ANNOYING. | |
| 3066. |
Solve : Sharing? |
|
Answer» does SOMEBODY know the command to SHARE a FILE in a network?I KNEW that command but i FORGOT it |
|
| 3067. |
Solve : Error Running Program? |
|
Answer» Hi...I'm really confused. |
|
| 3068. |
Solve : Boot disc? |
|
Answer» I need a bootdisc (98 or xp home )with Format and Fdisc. I have been to |
|
| 3069. |
Solve : Automatically closing dos window after batch run? |
|
Answer» Hey All, |
|
| 3070. |
Solve : updating dos from 4.10.2222 to version 6.22? |
|
Answer» i need 6.22 for MS-dos. i have 4.10.2222 and i was WONDERING where i can update ms dos?4.10.2222 is DOS 7 from Windows 98. DOS 6.22 is the DOS from Windows 3.1. GET BOOTDISK here: http://www.bootdisk.com/ |
|
| 3071. |
Solve : screen size? |
|
Answer» when i open up dos command prompt only from WINDOWS 98 start up menu it only uses about 60% of the screen and i can't FIND out how to increase the area to use the FULL screen which i really need would really like help on this problem as i have tried everything i can think of but being quite a NOVICE that is probably not a lot thanks in advanceAlt-Enter will size to full screen.tried ALT-ENTER but nothing happened any other suggestions anyoneRight CLICK MSDos prompt. Select properties, select screen tab. Set to full screen, set initial size to 50 line mode.2k Dummy tried that still have small screen dont know if it matters that it's a dell laptop would'nt have thought so but some thing should be possible |
|
| 3072. |
Solve : I lost my xp disk and I have a missing dos file? |
|
Answer» I can't PLAY my "Lemmings" game or INSTALL my photoshop program. I get an error mssg. as FOLLOWS: |
|
| 3073. |
Solve : how do you wildcards in IF statements?? |
|
Answer» Is there a way I can put wildcards into this STATEMENT... |
|
| 3074. |
Solve : $NtUninstall$ files? |
|
Answer» Can the $NtUninstall$ files in the windows dir be DELETED from DOS COMMAND line?? They don't need to removed from a command prompt but you can do it that way... |
|
| 3075. |
Solve : For loop with incrementing variable? |
|
Answer» Hey guys, im trying to create a batch file that will create 5 different folders. heaps of tmie To make five folders? I just made five e folders in 13 seconds. By hand. And I am slow How much time did you save? From the time you did the post until you got five folders.Quote from: Geek-9pm on October 25, 2009, 09:01:51 PM the only difference is, you don't want to do that , say OP's requirement is to make 5 everyday. you are definitely not going to do that by hand every day.or maybe to make 5 every 20 minutes?... that's definitely a candidate for automation.Excatly right, and SOMEDAYS the number can increase, its just sooooo much easier, thanks again guyz, you have definetly made my work days 10X easier xD |
|
| 3076. |
Solve : Batch program for auto detection....? |
|
Answer» Can we write a batch program to auto detect the USB device that is when connected to computer ? Bill, The Original poster has selective hearing "auto detect the USB device" "auto detection of a USB device" means the operating system automatically detects that a device has been been plugged into a USB port. auto does not mean "audio" A USB port is not a drive. Your VBS code does nothing that the operating system has not covered. ----------------------------------------- "USB is Short for Universal Serial Bus, an EXTERNAL bus standard that supports DATA transfer rates of 12 Mbps. A single USB port can be used to connect up to 127 peripheral devices, such as mice, modems, and keyboards. USB also supports Plug-and-Play installation and hot plugging." Troll Bill is active again.... Quote from: Salmon Trout on October 24, 2009, 05:23:04 PM Bill is active again.... Please Salmon Trout I'm not trying to cause any trouble Please tell me what is wrong with my post and I will rewrite or delete. Thanks for your help. ------------------------------------------------ What is wrong with any of the following? : "auto detection of a USB device" means the operating system automatically detects that a device has been been plugged into a USB port. auto does not mean "audio" A USB port is not a drive. Your VBS code does nothing that the operating system has not covered. BillRich: read the original post. Then read your first reply. State what relevance it has. It has none. BFC answered the question he posed Re: detecting a USB drive when it is plugged in Quote "auto detection of a USB device" means the operating system automatically detects that a device has been been plugged into a USB port. Yes. Very GOOD. have a cookie. Quote auto does not mean "audio"the relevance of this being? BFC was stating that you, or more precisely, observing that you read "auto-detection of USB device" and instantly went about composing a random solution involving USB, without reading the full question. Quote A USB port is not a drive. Again, congratulations on stating the obvious. Oh. here's a tip!: a piece of gum is not a weasel! BFC never said anything about drives... or ports, for that matter. Quote Your VBS code does nothing that the operating system has not covered.Yes. It does. Does the operating System notify Batch Files when a USB device is inseted removed? No. Batch does not lend itself to that. So he scrounged up a VBS that does. The Operating System handles it but the request was for a way to detect when this happened.thank you for your post bc but my abbr. name is BFB not BFC Quote from: BatchFileBasics on October 25, 2009, 10:47:55 AM
So it is... Hi dudes........ What I'm asked ? What are you doing ? I knew when a usb device is connected to the port the operating system will automatically detect it, but i didn't asked about it. I asked you people is that write a "manual batch program" to automatically detect the usb when connected. But you are...............Quote from: Vikram Varaprasad on October 26, 2009, 11:56:01 PM Hi dudes........ BFB provided this. It is IMPOSSIBLE via a pure batch file.Thank you , then where we can write that must support my question ? BatchFileBasics' Post answers your question the best it is possible.ok, I'l try it. If any other solutions found please intimate me. Thanks |
|
| 3077. |
Solve : Find and Replace (Encryption)? |
|
Answer» I THINK i will not CONTINUE with this project, but I have learned a few THINGS, THANK you everyone. |
|
| 3078. |
Solve : Help with set command variable subsitution? |
|
Answer» Hi guys am a little stuck with my little batch script basically i need to replace all the spaces with %20's of a filename string ( %~n1 ) |
|
| 3079. |
Solve : D-E-A-D (REALMS OF *censored* 2) Death Eternity And Dieing (BATCH GAME)? |
|
Answer» Just announcing a new version of my batch game, called (DEAD) Death Eternity And Dieing.. its not GOING to be completely new, it will be the current version of Realms of *CENSORED* which i havent released yet, version G8 but with these added features alot of which are already completed... |
|
| 3080. |
Solve : Multiple processes in ms dos? |
|
Answer» Hello every one can any one tells me how to handle multiple processes in ms dos shell How are you accomplishing this? Both the cmd and command shell programs are single threaded. Seems more likely you have multiple shell programs, each running a process that requires the same file. You can develop a batch file to run your tasks sequentially and prevent the file conflicts. Quote Seems more likely you have multiple shell programs, each running a process that requires the same file. I invoke the processes by the help of make -j . by the way make -j1 , solves the problem in some limites.For a very brief time I thought you had managed to get MS Dos to multitask. You're certainly not using an MS Dos shell, I suspect you are using XP Cmd.exe. The GNU Make manual says it all... Quote GNU `make' knows how to execute several commands at once. Normally,Quote You're certainly not using an MS Dos shell, I suspect you are using XP Cmd.exe. correct I m using xp amd.exe, so is multiprocessing wroking on xp cmd.exe? but not on ms dos? You will understand that cmd.exe in XP is not MS-Dos or any other Dos version. Cmd.exe is not Dos, it is a dos-emulator program which runs in the Windows environment. What you see when you start cmd.exe is a window. Although Cmd.exe will accept commands which look like Dos commands they are not Dos commands but Windows XP command line commands which are shown here... Multiprocessing (multitasking) is not allowed in either the XP Command Processor or in MS-Dos. However multiple XP Command Processor windows can be opened. GNU Make can process more than one command simultaneously but this processing is being done by GNU Make not by Dos or the Dos emulator. Start cmd.exe and enter the command VER - you will probably see a display such as:Quote Microsoft Windows XP [Version 5.1.2600]This is the Windows XP version being used. If you enter VER whilst running Dos you will see the Dos version being used. Hope this helps.I don't think the POSIX subsystem implemented by XP has the fork() method, which is likely used by GNU make for this feature.Quote GNU Make can process more than one command simultaneously but this processing is being done by GNU Make not by Dos or the Dos emulator. Dusty , Yes its true , now I try to USE win bash shell for using multitasking in win32 . Thanks for ur help and KNOWLADGE sharing. |
|
| 3081. |
Solve : RE:urgent doff? |
|
Answer» try to use doff utility to run batch script. fail |
|
| 3082. |
Solve : Is there any command to check if the batch file has completed successfully?? |
|
Answer» I am a beginner to MS DOS batch file programming. |
|
| 3083. |
Solve : Setting an environment for a user login? |
|
Answer» Hi Viewer, |
|
| 3084. |
Solve : moving script in dos with different file type? |
|
Answer» i would like moving bacth script to move the file with DIFFRENT TYPE and different folder name. |
|
| 3085. |
Solve : file comparison or checklist? |
|
Answer» Code: [SELECT]@echo off |
|
| 3086. |
Solve : return the nth character of a string? |
|
Answer» Hello again, for /l %%i in (%n%,1,%n%) do (it can be simpler: Code: [Select]for %%i in (%n%) do call set bit=%%a:~%%i,1%% THANK you Prince_ |
|
| 3087. |
Solve : required to work on stop and start services in a sequential order? |
|
Answer» I need to stop services in the FOLLOWING order |
|
| 3088. |
Solve : display an exclamation mark? |
|
Answer» Hello there, |
|
| 3089. |
Solve : Networking 98se/DOS with Microsoft 2003 server? |
|
Answer» I am having problems with DOS networking it will SEE the network in windows 98se but when I GO into DOS it LOSES the network connection. |
|
| 3090. |
Solve : realms of *censored* batch game new version G7 *UPDATED*? |
|
Answer» improvements |
|
| 3091. |
Solve : Create user defined directory and copy file to it? |
|
Answer» HELLO, I have the following case and would like to know if this can be solved using a batch file. we have a lot of computers that are MOUNTED into trucks. EVERY now and then I would like to have a backup of the eventlog. But to save the eventlog into a specified directory the user needs to create a directory, with the registration number of the truck. Is it possible to have a batch file that can first ask the user wich name the directory needs and after that copy the eventlogs to the map with the name that has just been specified by the user? REGARDS, RonaldCode: [Select]@echo off set /p Dir=Enter directory name: :check if exist \%Dir% goto blocked md \%Dir% ::COPYING goes here goto exit :blocked cls set /p Dir=Directory already exists. Enter new directory name: goto check :exit Ok, that asks for the directory name, then makes it at the root directory (most likely C:\, but you can change where it's going to be saved). It also checks if that directory is already made, and if so asks for a new name. The ::copying goes here is where your copy code goes. I don't know where your eventlogs are located, but just write: Code: [Select]copy "your eventlog location" \%Dir%Hello Dark Blade, Thanks for the answer. This is working perfect Regards, Ronald |
|
| 3092. |
Solve : using FIND instead of FINDSTR? |
|
Answer» Hi, |
|
| 3093. |
Solve : Batch File To Open Internet Windows? |
|
Answer» Hi all, |
|
| 3094. |
Solve : Deleting Files, Folders, and subfolders(Solved!)? |
|
Answer» I am having a bit of trouble deleting a files and folders(with files in them) and the primary target folder with my batch code. The file structure and code is below. |
|
| 3095. |
Solve : network administrator? |
|
Answer» i want to LEAN how to control the local AREA networking WOAH! INFORMATION overload! Hey guys, let's let this guy shut down our SERVERS and domains . |
|
| 3096. |
Solve : Can I force my batch file to open at same spot all the time?? |
|
Answer» When my client turns on her computer it automatically launches a batch file that I created but the batch file opens up at random spot on her computer. This looks UNPROFESSIONAL. Is it possible to force a batch file to open up at a specific spot all the time when it is launch, like bottom left corner of the screen? She uses window XP. |
|
| 3097. |
Solve : If not defined statement not working.? |
|
Answer» Okay, in one of my batch files. If the user does not put an input I WANT it to go to the same question. So here's what I'm doing. Duh, why wasn't I thinking of this before In the first post you were trying to find out if a variable existed, the second you are dealing with the value of a variable. Your first post works with this syntax: Code: [Select]if not defined variable goto question Well, I just heard of using defined in an if statement. I was thinking it did a completely different thing. |
|
| 3098. |
Solve : Using the FOR command? |
|
Answer» Hello, with just ten lines of code more or less. How about one? command does "that sort of thing" very well. It was designed for it. It LOVES chewing up csv files. Took me 7 minutes. And 5 of those I was MAKING coffee. Presuming the answer to my question above is "yes"... Code: [Select]@echo off set inputfile=input.txt set outputfile=output.txt if exist "%outputfile%" del "%outputfile%" for /f "tokens=1-2* delims=," %%A in ( ' type "%inputfile%" ' ) do echo %%~nxB>>"%outputfile%" input.txt: Code: [Select]00000,,\6442\Vol002\001\00000.tif,Y,,,0 000001,,\6442\Vol003\001\002\000001.tif,Y,,,0 000002,,\6442\Vol003\001\000002.TIF,Y,,,0 000003,,\6442\Vol003\005\004\000003.TIF,,,, output.txt: Code: [Select]00000.tif 000001.tif 000002.TIF 000003.TIF AAwwkk ! I have a headache! It took your 7 Mins. It will take me 7 days to try and understand that! for /f TREAT the dataset (what is in the brackets) as a series of one or more lines "tokens=1-2* delims=," Treat each such line as being split (by commas) into at least 2 tokens (chunks) %%A Assign the first chunk of each line to the explicit loop variable %%A. The second chunk will therefore be the implicit loop variable %%B. The asterisk in the tokens/delims block means that all of the rest of the line (if there is any) will be the implicit loop variable %%C. in ( ' type "%inputfile%" ' ) The dataset is the output of 'type inputfile'. do echo %%~nxB Take the second chunk of the line, (a path and filename), and extract just the file name and extension, and echo it... >>"%outputfile%" ... to the output file and repeat until no more lines left. Quote from: Geek-9pm on February 02, 2009, 03:27:52 PM If it's any help, that's what Perl does to me. Dias DE verano, Yes you are right on your first assumption. I will put it to the test on a very large file that I have. I very much appreciate your speedy reply to my post today. thatguy.It works great. Sorry for the confusion. Thanks so much! |
|
| 3099. |
Solve : running programs form batch files? |
|
Answer» Yep. You need to USE quotes around the filename. UNLESS you already did... |
|
| 3100. |
Solve : Batch file that creates a schedule job? |
|
Answer» I created a batch file that deletes the CONTENTS of a folder but I need a batch file that creates a schedule job for this to run once a day without the user on the pc having to do anything. Can anyone help me. I looked at the forum and saw the AT command but I don't this this will help me because I can't have the user do anything. SCHTASKS /parameter [arguments]This looks really good and probably just what I need. Just for an FYI I work in the IT dept at a home OFFICE and we have computers at different sites and they are locked down with deep freeze and people in these offices cannot delete files and our help desk guy was having to log in and delete files for people and this was taking a lot of time. I suggested that we write something that would delete the contents of a folder automatically and he thought it was a great idea but told me to do it. I am NOT a programmer but I have been trying to play with this. I was able to write the batch to delete the folder contents but now he wants me to make a batch that creates the folder, then creates the schedule job. I didn't know what I was getting myself into when I made the sugestion. Thanks for the help but I will probably need more. |
|