Explore topic-wise InterviewSolutions in .

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.

1451.

Solve : Delete Duplacaites?

Answer»

Hi There

Theres One Prob I Have To Battle With Every Day  And That Is Duplicated Tracks On My Mp3
Player

Is There Such A Thing As A .Bat File That Can Find And Destroy Duplicates


As Allways Any Help Will Be Greatly AppreciatedWhy do you have to battle this every day? Do your tracks get copied every day? Do the tracks have the same name? Do they begin with Copy of...?I Change My Tracks Everey Day And Use All Different Programs EVEN Windows Explorer

And I End Up With Copy's QUOTE from: Helpmeh on August 21, 2010, 12:10:47 PM

Do the tracks have the same name? Do they begin with Copy of...?
Same NamesDifferent folders? Different EXTENSIONS? Something has to be different, or Windows Explorer won't allow it.Hey hi

 Since the tracks r getting repeated WAT u can do here is u can format ur MP3 and copy it once and Scan with the antivirus !!!
    Ignore the above POST.
1452.

Solve : Someone can help me? Urgent..?

Answer»

Create a batch file that will copy all exe files in C:\Windows into a C drive directory specified by user in the command line and then print the directory’s contents into C:\Dir.txt. You should write commands to check whether the specified directory appears. If the specified directory does not appear, create a new directory with the specified name before copying C:\Windows exe files into the directory else just directly start with the copy process...

Can someone help me ?You could have rewritten your HOMEWORK question a bit. We don't generally help with school work. You could try posting what efforts you have made.


Homework should at least be researched first. Or would you prefer someone else to GET YOU through school.

I agree with Salmon, What efforts have you made??Personally, I won't help with homework at all. Your first and only POST here is a request for help with a homework assignment. Pass.Sry guys, i really need help. Because i basic in java programming, but tutor suddenly give me a MS DOS homework without lecture and i haven't learn it before, i really need helps. PLZ..... That's between you and your tutor. No help to be found here.he just broke world record .

Google

Research Quote from: kovacs on August 03, 2010, 11:06:03 AM

Create a batch file that will copy all exe files in C:\Windows into a C drive directory specified by user in the command line and then print the directory’s contents into C:\Dir.txt. You should write commands to check whether the specified directory appears. If the specified directory does not appear, create a new directory with the specified name before copying C:\Windows exe files into the directory else just directly start with the copy process...

Can someone help me ?

i will help you. On the command prompt, type

move /?
mkdir /?
dir /?
if /?
for /?
copy /?
1453.

Solve : Batch problem. (xcopy)?

Answer»

I wrote a short batch file in windows xp, who needs to copy from one directory to the other and from the other one to this one (updating all the filles from one to another):

xcopy %1 %2 /d /e /i /f /y /g /EXCLUDE:Exclude.txt
xcopy %2 %1 /d /e /i /f /y /g /EXCLUDE:Exclude.txt
pause

(I sent parameters [%1,%2] using c#)
All the copying PROCESS went well exept for the excluding, if the exclude file contains paths with spaces it won't exclude them, and those files will be copied.
Another bug that happens from time to time (not always) - the first path in Exclude.txt is copied normaly.
I read all the articals about xcopy and non of them helped me (neither using slashes or short paths ect.).
I have tried using " " for files containing spaces, I.e. like "c:\program files\whatever".

Thanks, Dan. XCOPY can be one of the most helpful utilities but the Microsoft documentation can be a bit obtuse.

The exclude file is used for PATTERN matching so short file names, slashes(?) and quotes will make a match more unlikely.

I cannot duplicate your file path problems with embedded spaces, nor with the first path in the exclude file being included in the output.

Please post your exclude file otherwise we're just stumbling around in the dark.

 


I tried it again with another exclude file and i found that the sapces are not the problem, the problem is that many of my file's name's are in hebrew (=a language), and it messy with batch files (it becomes gyberish).
Is there any way to create a batch file that supports other (non latin) alpha-bet?

Thanks, Dan.You can install Hebrew language support by going to Control Panel==>Language and Regional Options. Click on the Languages tab and then check the Install file for complex scripts and right to left languages box. You will need your Windows XP installation disk.

Once installed, you can use the character map (Accessories==>System Tools) to select the Hebrew font and then select and copy characters to the clipboard where they can be pasted into the editor you're using for the exclude file.

Just to be safe, I highly suggest you make a restore point before installing the Hebrew language support.

Good luck.  I did all you have written, it's still the same problem...
maby it can't be solved.

Although, thanks! Quote from: lo12p on July 11, 2010, 01:02:47 AM

maby it can't be solved.

Of course it can be solved. You need to use an editor that can save the exclude file with Unicode encoding. (Notepad works fine).  With all the select and copy from the character map and the pasting into Notepad, it is a painstakingly slow process but given enough time and effort this can be done.

Hint: You can select all the characters in sequence for a single file from the character map and then copy the entire string to the clipboard for pasting into notepad. This way you build the exclude file line by line instead of character by character.

Note: Test just one excluded file and use the XCOPY /L switch. This will list out the files that would be copied but no actual file copying takes place. Remove the /L switch when you're ready for the real thing.

Good luck.  I tried it (the unicode save) and it worked.
But haw can i save a text file (with this unicode thing) using c#?
Is there a function that saves a file and get's arguments? ect.
(because im writing to the exclude files using c#)I'm not a C# programmer, but it looks suspiciously like VB.Net

This may help. Check out Write a Text File (Example 2).

 

Thanks!! Quote from: Sidewinder on July 11, 2010, 11:01:27 AM
I'm not a C# programmer, but it looks suspiciously like VB.Net

C# is nothing like VB.NET Syntax wise, only framework-wise.

Anyway, if I understand the requirement, is the intention to open an ASCII file and save it as a Unicode? Because that's pretty easy. The sample referenced looks old- it doesn't use the now recommended "using" construct, and instead wraps everything in a try...catch...finally.


Anyway, I took this as a small project and came up with a small program that simply opens a file using ASCII encoding, and WRITES it to another file that it opens/creates for Unicode.

Code: [Select]using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
namespace writetest
{
    class Program
    {
//note, I had to wrap the following constant in order to prevent the post from looking huge horizontally
        private const string helptext = "ASC2UNC help summary\n\nSYNTAX:\nASC2UNC <sourcefile>
<destfile> [/a]\n\nASC2UNC opens the source file (using ASCII encoding)
and directly copies the stream to the destination file (using unicode). of /A os specified, the destination file is opened for appending.";
        static void showhelp()
        {


            Console.WriteLine(helptext);



        }

        static void Main(string[] args)
        {
            //takes two arguments: args[0] is the source filename, args[1] is the destination filename.

            if (args.Length < 2)
            {
                Console.WriteLine("Error: Insufficient number of arguments.");
                showhelp();

                return;
            }
            String sourcefile = args[0];
            String destfile = args[1];

            if (!Path.IsPathRooted(sourcefile))
                sourcefile = Path.Combine(Environment.CurrentDirectory, sourcefile);
            if (!Path.IsPathRooted(destfile))
                destfile = Path.Combine(Environment.CurrentDirectory, destfile);
            bool DoAppend = args.ToList().Exists((w) =>(w.Equals("/A", StringComparison.OrdinalIgnoreCase) ||
                                        w.Equals("-A", StringComparison.OrdinalIgnoreCase)));
            try
            {
                using (StreamReader Ascinput = new StreamReader(sourcefile, Encoding.ASCII))
                {
                    using (StreamWriter Uncoutput = new StreamWriter(destfile,
                                                                     DoAppend,
                                                                     Encoding.Unicode))
                    {
                       

                        Uncoutput.Write(Ascinput.ReadToEnd());


                    }

                }


            }
            catch (IOException e)
            {
                Console.WriteLine("Exception:" + e.Message);


            }
        }
    }
}


to test, I created a sample text file in Notepad and saved it using ASCII encoding. I then used the program and created a file, "unicode.txt" which, while I was able to use "type" and other PROGRAMS to view the file just fine, was twice the size of the ASCII file I created it from (suggesting unicode was in fact properly used).

Of course I really have no idea wether this is even close to what is desired, but I would imagine it's closer then the sample. Also if the ability to go the other way is required, it shouldn't be too DIFFICULT. One could simply store the Encoding enumeration values in variables and change them if you find specific switches.

... oh yeah and sorry about the lambda expression... I remember how confusing those were for me but now they are second nature.
1454.

Solve : Some help!!!?

Answer»

Hello people: this bat runs with another cmd box, please check the screen shot. I dont know whats up with that. Is their any way to GET around this. Or is this how bat file works.
?



echo off
c:
cd\Program Files\Ahead\Nero StartSmart
NeroStartSmart




[recovering disk space - old attachment deleted by admin] CODE: [SELECT]start "" "NeroStartSmart"Thanks: you guys are great: but may i know what's WRONG with the bat file.
       I got it to learn from a BAT TUTORIAL SITE: that has the same cmd to run an application.There is NOTHING wrong with it - it does what it is supposed to do. It is a simple demonstration batch file. It runs the program and waits for it to finish. If you want to start a program and return immediately you use the START command like I showed you.

1455.

Solve : Cd rom driver?

Answer»

Hi i'm new to dos and i just installed it on a 90 Mhz computer and I need to know were to GET the cd-rom DRIVER and how to installl it so i can install windows 3.1 on my computer I am running dos 6.22

any help would be great.Do a search for Oak- Rom CD DRIVERS for DOS...-I read some online forums and I want to ask will the windows 98 boot disk work as the driver?

1456.

Solve : rename file to date and timstamp?

Answer»

I have a batch script as follows.
Now i want to rename the *.csv FILE to *.csv_processed_mm/yy/yyyy  format.

The current rename is coming in the format of mm/dd/yy

and also, I want to APPEND the timestamp in this.

Any help on this would be greatly appreciated









d:

echo cd data\Scripts


for %%f in (D:\data\DELIVERY_NOTE\*.csv) Do (


sqlldr USERID=config/config control=D:\data\Scripts\loaddata_del.ctl skip=2 data=%%f

(
echo conn config/config;
echo exec DELIVERY_NOTE_PKG.PopNote_stage;
)| sqlplus -s /nolog


move %%f D:\data\Processed_Delivery\
cd D:\data\processed_Delivery\
rename *.csv *.csv.processed_%date%
cd d:\data\scripts\
echo #############
echo PROCESSED THE FILE %%f AT %data% %time%
echo ############


)
C:\test>type  bang.bat
Code: [Select]echo off
rem cd D:\data\processed_Delivery\
cd  c:\test
rem dir  /b  > csvfiles.txt
set MM=%date:~4,2%
set DD=%date:~7,2%
set YYYY=%date:~10,4%
echo MM=%MM%
echo DD=%DD%
echo YYYY=%YYYY%
for /f %%i in (csvfiles.txt) do (
copy  %%i csv_processed_%MM%%DD%%YYYY%
dir /b csv_processed_%MM%%DD%%YYYY%
rem *.csv

echo PROCESSED THE FILE %%i AT %date% %time%

rem  *.csv_processed_mm/dd/yyyy  format.
)
Output:C:\test>bang.bat
MM=06
DD=29
YYYY=2010
        1 file(s) copied.
csv_processed_06292010
PROCESSED THE FILE timefile1.csv AT Tue 06/29/2010 13:07:29.42
        1 file(s) copied.
csv_processed_06292010
PROCESSED THE FILE timefile2.csv AT Tue 06/29/2010 13:07:29.42
        1 file(s) copied.
csv_processed_06292010
PROCESSED THE FILE timefile3.csv AT Tue 06/29/2010 13:07:29.42
        1 file(s) copied.
csv_processed_06292010
PROCESSED THE FILE timefile4.csv AT Tue 06/29/2010 13:07:29.42

C:\test> Quote from: bang_dba on June 29, 2010, 09:01:14 AM


"Now I want to rename the *.csv file to *.csv_processed_mm/dd/yyyy  format.
Also, I want to append the timestamp in this.
Any help on this would be greatly appreciated"

The above post (reply 1) did not include the original file name as part of the final file name.
The following code corrects that mistake.

___________________________________


C:\test>type  bang.bat
Code: [Select]echo off
rem cd D:\data\processed_Delivery\
cd  c:\test
rem dir  /b  *.csv > csvfiles.txt
set MM=%date:~4,2%
set DD=%date:~7,2%
set YYYY=%date:~10,4%
echo MM=%MM%
echo DD=%DD%
echo YYYY=%YYYY%
for /f %%i in (csvfiles.txt) do (
copy  %%i %%i_processed_%MM%%DD%%YYYY%
dir /b %%i_processed_%MM%%DD%%YYYY%
rem   del  %%i

rem cd d:\data\scripts\

echo PROCESSED THE FILE %%i AT %date% %time%

rem  *.csv_processed_mm/dd/yyyy  format.
)
Output:

C:\test>bang.bat
MM=06
DD=29
YYYY=2010
        1 file(s) copied.
sdate.csv_processed_06292010
PROCESSED THE FILE sdate.csv AT Tue 06/29/2010 19:31:04.06
        1 file(s) copied.
stime.csv_processed_06292010
PROCESSED THE FILE stime.csv AT Tue 06/29/2010 19:31:04.06
        1 file(s) copied.
txtfile.csv_processed_06292010
PROCESSED THE FILE txtfile.csv AT Tue 06/29/2010 19:31:04.06

C:\test>

p.s.  I was unable to edit the above post ( reply one). HelloHi marvinengland,

Thanks for the update.

It works.

I have one more problem.

I am generating log file with the sqlloader.

ie.,

sqlldr USERID=config/config control=D:\data\Scripts\loaddata_del.ctl skip=2 log=d:\log\log01.log data=%%f

Now for every loop, there is log01.log file getting GENERATED, and hence it is getting overwritten.

So, I tried to rename it to  log01.log__.


(I am using SIMPLE command
copy *.log *.log.%DATE:/=%_%time::=%.processed
del *.log
)

But,  For every loop iteration.,  ie., once the loop starts the TIME STAMP remains constant for all the loop items.

How can i handle this ?

thx.




C:\test>type   bang.bat
echo off
rem echo. > time.log
rem dir /b > csvfiles.txt
rem cd D:\data\processed_Delivery\
cd  c:\test
set MM=%date:~4,2%
set DD=%date:~7,2%
set YYYY=%date:~10,4%
echo MM=%MM%
echo DD=%DD%
echo YYYY=%YYYY%
for /f %%i in (csvfiles.txt) do (
copy  %%i %%i_processed_%MM%%DD%%YYYY%
dir /b %%i_processed_%MM%%DD%%YYYY%

call  :mklog %%i
rem del %%i

)
echo time.log
type  time.log
goto :eof

:mklog %1
sleep  6
rem echo PROCESSED THE FILE %1 AT %date% %time%
echo PROCESSED THE FILE %1 AT %date% %time%  >> time.log


rem   C:\Program Files\Windows RESOURCE Kits\Tools\sleep.exe
rem  If a time delay is needed for each timestamp,  use ping or sleep
rem The %time% variable will only change with a call to a label or another batch

Output:

C:\test>bang.bat
MM=07
DD=01
YYYY=2010
        1 file(s) copied.
timefile1.csv_processed_07012010
        1 file(s) copied.
timefile2.csv_processed_07012010
        1 file(s) copied.
timefile3.csv_processed_07012010
        1 file(s) copied.
timefile4.csv_processed_07012010
time.log

PROCESSED THE FILE timefile1.csv AT Thu 07/01/2010 10:39:26.15
PROCESSED THE FILE timefile2.csv AT Thu 07/01/2010 10:39:32.17
PROCESSED THE FILE timefile3.csv AT Thu 07/01/2010 10:39:38.19
PROCESSED THE FILE timefile4.csv AT Thu 07/01/2010 10:39:44.21

C:\test>Don't use sleep or ping.  There is at least 1/100 of a second between each timestamp.
When there are many *.csv files,  the batch will run much faster

C:\test>type   bang.bat
echo off
echo. > time.log
rem dir /b  *.csv > csvfiles.txt
rem cd D:\data\processed_Delivery\
cd  c:\test
set MM=%date:~4,2%
set DD=%date:~7,2%
set YYYY=%date:~10,4%
echo MM=%MM%
echo DD=%DD%
echo YYYY=%YYYY%
for /f %%i in (csvfiles.txt) do (
copy  %%i %%i_processed_%MM%%DD%%YYYY%
dir /b %%i_processed_%MM%%DD%%YYYY%

call  :mklog %%i
rem del %%i

)
echo time.log
type  time.log
goto :eof

:mklog %1
echo PROCESSED THE FILE %1 AT %date% %time%  >> time.log


rem The %time% variable will only change with a call to a label or another batch

Output:
C:\test>bang.bat
MM=07
DD=01
YYYY=2010
        1 file(s) copied.
timefile1.csv_processed_07012010
        1 file(s) copied.
timefile2.csv_processed_07012010
        1 file(s) copied.
timefile3.csv_processed_07012010
        1 file(s) copied.
timefile4.csv_processed_07012010
time.log

PROCESSED THE FILE timefile1.csv AT Thu 07/01/2010 15:53:36.94
PROCESSED THE FILE timefile2.csv AT Thu 07/01/2010 15:53:36.95
PROCESSED THE FILE timefile3.csv AT Thu 07/01/2010 15:53:36.97
PROCESSED THE FILE timefile4.csv AT Thu 07/01/2010 15:53:36.98

C:\test>
1457.

Solve : batch file to set a datestamp & run a html page a year later?

Answer»

Hello

Im looking for help to create a batch file which runs at startup from task scheduler that can set a datestamp in the file when it first runs and then runs a html page but only after a year has passed. So i suppose that the file would need to compare the inital date every time it runs and do an IF command. Im am struggling to find the best way to begin with so any help would be greatly apprieciated, thanks in advance!   You should be able to use the task scheduler to schedule the job annually. On the schedule TAB choose monthly, then click select months and unclick all the months except one. This will be the month the job runs. Use the schedule tasks monthly to choose the absolute day of the month or the relative day of the month (ex: second Tuesday of the month)

Not sure what you mean about setting a timestamp in the file. To run a HTML page use iexplore and pass the http address as the first parameter.

Good luck.  many thanks for your reply,

The HTML idea comes from the need to inform USERS that their laptops need returning for its  annual health check etc (as i work in a school with lots of laptops) and wanted to be able to put the batch file in the laptop image so that when the image/OS is first run on each individual laptop the file looks at the current date, adds 365 days ( & checks this date every time the laptop is started) finally after the year has passed the HTML will pop up with the message prompt.
Hope this makes sense and thanks again
 If you can put a small VBS file in the startup folder then this will be a breeze. Once the computer's annual check is complete, place a file called "timestamp" in C:\annualcheckup\ on each computer. It doesn't have to contain anything, except maybe a message saying something along the lines of "DO NOT MODIFY", etc. Then, place the following code inside a .vbs file (name it anything you want) and place it in the users' startup folder.

Set objFS = CreateObject("Scripting.FileSystemObject")
strFolder = "C:\annualcheckup"
Set objFolder = objFS.GetFolder(strFolder)
Set strfile = objFolder.Files("timestamp")
if datediff("d",strFile.DateLastModified,Now) >= 365 Then
   'NOTICE on year
   msgbox "Your computer is due for its yearly check."
If DateDiff("d",strFile.DateLastModified,Now) >= 355 Then
   '10-day notice before year
   msgbox "Please remember to return your computer for a yearly check soon."
end if


The code will check to see if the file is 365 days old, then tell them they're due for a checkup, and if it's later than 355, then tell them to remember that their yearly check is soon.Batch code is terrible at date math, so I took a different approach by using the creation date of the Windows directory as the base date (this can be changed). By using the creation month and day and appending the current year, it became easy to calculate the next date the reminder should DISPLAY.

Code: [Select]echo off
setlocal enabledelayedexpansion

for /f %%v in ('dir /a:d /tc c:\ ^| find /i "windows"') do (
  set filler=%%v
  set baseMon=!filler:~0,2!
  set baseDay=!filler:~3,2!
  set currYear=%date:~10,4%


set nextDate=%baseMon%/%baseday%/%currYear%
set currDate=%date:~4,10%

if %currDate% EQU %nextDate% (
  iexplore "pointer to HTML page goes here"


The snippet uses a date format of dow mm/dd/yyyy. If your machines are different, the snippet will need to be tweaked.

What happens if the next run date falls on a weekend?

Change the line where IE is launched to point to the HTML page to display.

Good luck. 

Thanks helpmeh your solution seems to work the best in this situation although i have integrated the HTML option into it as there are more options to make it look pretty! (logo's etc) just one THING that i need further help with. Is there a way to hide the .vbs & still make it run as ammending the file attribute to hidden stops the script from running at all.

Here is the script i have so far 

Set objFS = CreateObject("Scripting.FileSystemObject")
strFolder = "C:\annualcheckup"
Set objFolder = objFS.GetFolder(strFolder)
Set strfile = objFolder.Files("timestamp.txt")
if datediff("d",strFile.DateLastModified,Now) >= 365 Then
   'notice on year
 
Dim IE
Set IE = CreateObject("InternetExplorer.Application")

With IE
        .left=200
        .top=200
        .height=400
        .width=800
        .menubar=0
        .toolbar=0
        .statusBar=0
        .navigate "About:Blank"
        .visible=1
End With

With IE.document
        .Open
        .WriteLn ""
        .WriteLn "CNS"
        .WriteLn ""
        .WriteLn "Message Please return your laptop etc etc"
        .WriteLn ""
        .WriteLn ""
        .Close
End With

Set IE = Nothing
WScript.Quit(0)
end ifIs it in the startup folder? I'm not sure why making the file hidden is preventing it from running.

Maybe you should put it in the HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run
registry key.
It was in the startup folder & would not run with a hidden file attribute - however i did as you suggested & it worked a treat! thanks - I am however still looking for a way to now change the file creation date (automatically) for the timestamp file when windows is first run, as the windows system date is generated from the bios date after the image is pulled down from the image server. This would mean that no alteration of the timestamp.txt would be needed as it would always be the date that windows was first run - which would be perfect

1458.

Solve : Font Colour?

Answer» PLEASE can anybody advise - How do I change the colour of the font in DOS?Check out the COLOR command (NOTE the US SPELLING)
COLOR /?
1459.

Solve : Connect/disconnect from internet.?

Answer»

Hi guys, I need your to make a batch that discnnects me from the network then reconnect. (Because I have dynamik IP and want to change it fast)
I want to disconnect from my broadband network not from LAN/LOCAL Area Connection if possible. I searched on google and found nothing that can help me, doesn't matter if it disconnects me from LAN or broadband and reconnect me, just do to it!
Thank you!Ipconfig /?

Try:
ipconfig /release
ipconfig /renew

Is that what you want?Nope, didn't work. Typed what you said, it worked 1 minute on ipconfig /renew (the LAN was showing "accuiring network address") and then this:

[SAVING space, attachment deleted by ADMIN]You're using Hamachi? I think there's a way to disconnect/reconnect from there. It also may be the reason why it's not reconecting via iponfig.  I disabled TeamViewer VPN and hamachi, and i forgot to tell you, when i connect directly with the cable i get that error, when i connect from the wireless router it works, but renews my LAN ip not client.
I need a way to disable from the broadband not local area connection, or disable/aneble local area connection, not renew my ip, disable and ENABLE (thats how it works :|)Try creating a .bat or .cmd file with following 2 lines:
net stop WZCSVC
net start WZCSVC

It will restart the Wireless Zero Configuration service, which should solve your problem, provided that you: 1. use XP (I can SEE that you do), 2. connect to internet wirelessly (you do, if I understand correctly), 3. you don't use 3rd party software for wireless (you let Windows manage the connection).
Oh, and in case you switched to Win7, use Wlansvc instead of WZCSVC (and you must run the bat file as Administrator).

1460.

Solve : DOS won't boot without the disk?

Answer»

I loaded MS-DOS6.2 onto a blank scsi hdd but it won't boot me into DOS. At the start up it says 'disk error, insert system disk and press enter'. I followed all the install directions on this site and it said if I did everything right, I should be able to get to the dos prompt without any disks in the computer.  How do I get the OS to boot up without using a boot disk in the computer? Is there missing code involved with the Autoexec.bat or Config.sys files that causes it not start or do I need to construct the proper boot.ini file before I get results? 
There is no other OS on this drive and I am using an old Asus mobo (P4T) and Intel 2.0gh processor and Award bios. And I recall that when I first opened Autoexec.bat, it displayed:
echo
MSCDEX.EXE \D:banana  \L:R


At start up it says:

driver version: V340
Device Name: banana
Firmware version:1.73
MSCDEX version: 2.23

I would reall like to find out how to get it to boot automatically without the boot disk.
I looked for an answer on the forums boards but didn't find it. That's why I am making this query here.
How did you "load" MS-DOS 6.2 onto the blank hdd? Did you use the SYS command? Or did you just copy the files?

Oh, the SYS COMMAND!!! Ok, so I merely reinstall the app using the sys command and then Dos will self boot? Well, mistakes are how you learn stuff. If that's really true, then I should be the world's greatest genius. And I just know you got to have a brother named Moby *censored*, right?If you want to make a DOS volume bootable, boot from a floppy which has (among others) command.com, io.sys, msdos.sys, format.com and sys.com on it, then format it with the /s option e.g. format c: /s and then install the files or if the disk is already formatted run the SYS command e.g. sys c:

You may also need to add the appropiate lines for thew SCSI drivers as well...Yes, there were a couple of hidden files but all the files you named were copied into C: drive. Now the computer boots into C:\DOS without needing the MSDOS boot diskette. The only hitch is that at the start up config.sys window there are THREE lines that read:"Bad or missing command or filename." How do I get rid of those lines and is it all that important to the overall integrity of the system? I set up the config.sys and autoexec.bat files according to the models available on this site but I don't have mouse action or the cdrom code in those files yet. I tried but it wouldn't work so I erased them. Post the files. I suspect that the error messages are being generated by lines in autoexec.bat, but without seeing the files, we are just guessing.

Here are the files sitting on C:\ drive. Using this set up, the computer boots me into C:\ where I have access to the the DOS files. With this configuration, Windows displays no error messages. It just says MS-DOS is starting and then PUTS me into the C: drive.

[CONFIG.SYS]
DEVICEHIGH=C:\HIMEM.SYS/test:off
DEVICEHIGH=C:\EMM386.EXE NOEMS
DOS=HIGH.UMB
FILES=30
STACKS=0,0
BUFFERS=20

[AUTOEXEC.BAT]
echo off

I found some DOS files on an old floppy I had laying around and forgot where they came from so I opened them on the A:\ drive. The folders are named A:\SETUP.BAT and SETUP.EXE.
When I try to run SETUP.BAT Windows says: "Cannot find the first MS-DOS 6.22 StepUp archive file. This archive file is named 1MS-DOS62.EXE.
ECHO is OFF
To work properly, the SETUP.BAT file and archive files must be located in the same directory. (Do not place these files in the same directory that contains your MS-DOS 6.x files.)"
When I open the A:\SETUP.EXE folder, Windows says:
"The directory C:\DOS does not contain your MS-DOS files. To install DoubleSpace conversion in that directory anyway, type Y. (Note: doublespace conversion might not work properly if you do.)"

I am pretty much lost here. Can someone kindly bail me out of this one?   

Those disks are MS-DOS 6.22 Step-Up which updates your system from MS-DOS 6, 6.2 or 6.21 to MS-DOS 6.22. They are no use on their own.
Ok, so I already have MS-DOS6.22. What about installing the applicable scsi files? How do I accomplish that? I mean where do I find them and which ones might I need?
Patio mentioned it so that got me STARTED. Quote from: PunkAss on February 20, 2010, 03:07:19 PM

[CONFIG.SYS]
DEVICEHIGH=C:\HIMEM.SYS/test:off <-----(a) is HIMEM.SYS present in C:\? (b) there should be a space after SYS
DEVICEHIGH=C:\EMM386.EXE NOEMS <----- is EMM386.EXE in C:\?
DOS=HIGH.UMB <---------- after HIGH there should be a comma, not a dot
FILES=30
STACKS=0,0
BUFFERS=20
Quote from: PunkAss on February 20, 2010, 03:54:23 PM
What about installing the applicable scsi files? How do I accomplish that? I mean where do I find them and which ones might I need?
Patio mentioned it so that got me started.

If drive C: is a SCSI drive, and you are booting into it, why are you worrying about that? I have both files {EMM386.EXE; HIMEM.SYS} in the C:\ drive. I also found smartdrv.exe and oakcdrom.sys that I didn't have before. Techadvice.com is a good place to search for errant files for any system. They had the oakcdrom.sys file that was a free download. Now I want to install the mouse driver. If I type in mouse.com at the prompt, windows INSTALLS the driver and the mouse works only for that boot up but I don't know the code lines for it in autoexec.bat and config.sys windows to get it to load automatically. The code I tried from this site would not work at all. Thanks for all the help so far; it's been a bonus. Quote from: PunkA on February 21, 2010, 05:08:00 PM
If I type in mouse.com at the prompt, windows installs the driver and the mouse works only for that boot up but I don't know the code lines for it in autoexec.bat and config.sys windows to get it to load automatically.

Make the last line of autoexec.bat:

mouse.com

Yeah, I did that and everything works except I don't have the edit.hlp functional. Here are my CODES for your inspection.

Config.sys////

DEVICEHIGH=C:\HIMEM.SYS /testmem:off
DEVICEHIGH=C:\OAKCDROM.SYS /D:mscd001
DEVICEHIGH=C:\EMM386.EXE /NOEMS
DEVICEHIGH=C:\MOUSE\MOUSE.COM
DOS=HIGH,UMB
FILES=30
STACKS=0,0
BUFFERS=20
LASTDRIVE=Z

Autoexec.bat/////

ECHO OFF
SET TEMP=C:\
SET TMP=C:\
SET PATH=A:\
LH MSCDEX.EXE /D:mscd001 /L:D
C:\MOUSE.COM
DOSKEY /INSERT
SMARTDRIVE
CLS

I am learning a lot from this site and the great people who run it together with the posters themselves.
1461.

Solve : %1 is carried over to other batch file?

Answer»

For some reason, when I run one batch file, with a path as %1, for some reason when the second batch file is run by:
start cmd.exe /k "%cd%\controller.bat"

controller.bat gives a 'T:\Documents' (the beginning of the path from %1 in the original batch file) is not recognized as an internal or external command, operable program or batch file.

I really don't know exactly why %1 is carrying through, when the second batch file is in a separate instance of the command prompt, but I need to prevent the error. Could you POSSIBLY provide the code of the batch files?
Well in the first batch file, the second batch file get's started on the first line (after echo off), so I don't think the problem lies there, but here is the code for the second batch file. BTW, it runs normally if %1 doesn't exist.

Code: [Select]echo off
mode con cols=22 lines=2
title CONTROLLER
echo Type in EXIT to exit.
pause > nul
cls
echo Press ENTER to skip.
pause > nul
:looper
cls
set input=skip
set /p input=
if /i not "%input%"=="exit" (tskill mplayer2) else (del music.files &AMP; tskill mplayer2 & tskill cmd)
goto looper
I'd still like to see the first batch file.
Here you go!
Code: [Select]echo off
start cmd.exe /k "%cd%\controller.bat"
echo %1
for /f "tokens=*" %%A in ("%1") do set pth=%%~dpA
setlocal enabledelayedexpansion
if exist music.file* del music.file*
dir /b  "%pth%\*.mp3" > music.files.temp
set counter=1
for /f "delims=" %%a in (music.files.temp) do (
echo !counter! %%a >> music.files
set /a counter+=1
)
del music.files.temp
set lastsong=
:loop
set /a mus=%random%%%counter%
for /f "tokens=1*" %%b in (music.files) do (
if %%b==!mus! if "%%c"=="!lastsong!" goto loop
if %%b==!mus! start /min /wait "" "C:\Program Files\Windows Media Player\mplayer2.exe" /play /close "!pth!\%%c" & set lastsong=%%c
)
goto loop... and finally, how do you call this first batch? From the command line? And how does the mysterious %1 parameter get created?  Is that typed after the batch name?
Quote from: SALMON Trout on February 21, 2010, 08:27:22 AM

... and finally, how do you call this first batch? From the command line? And how does the mysterious %1 parameter get created?  Is that typed after the batch name?

GUI, drag a music file onto the first batch file.Why don't you just do this?

set pth="%~dp1"

Quote from: Salmon Trout on February 21, 2010, 09:03:45 AM
Why don't you just do this?

set pth="%~dp1"


I did that at one point in time...I just can't quite remember why I changed it...anyway, did you figure out why controller.bat is crashing? Quote from: Helpmeh on February 21, 2010, 09:06:06 AM
I did that at one point in time...I just can't quite remember why I changed it...anyway, did you figure out why controller.bat is crashing?

Not yet. But I wonder why you are doing this

Code: [Select]start cmd.exe /k "%cd%\controller.bat"
specifically why you are using %cd%\ ? (%cd% is the current directory and if controller.bat is in the current directory you can use just its name)

Try

Code: [Select]start "" "cmd /k controller.bat"
Make the alterations I have suggested & report back
'controller.bat" ' is not recognized as a ... you know the rest. Quote from: Helpmeh on February 21, 2010, 09:20:35 AM
'controller.bat" ' is not recognized as a ... you know the rest.

is controller.bat in the same folder?
Yes. The first file is called random_music.bat and the second is controller.bat . They are both in the same folder.doesn't

start "" "controller.bat"

WORK?
This time, instead of getting a cmd.exe error message, I get the

"Windows can not find 'controller.bat'. Make sure you typed the name correctly, and then try again. To search for a file, click the start button, and then click search."

I changed it to "%cd%\controller.bat" and it still can't find it.
I copied controller.bat and renamed the new VERSION 123.bat and it still can't find it.
1462.

Solve : Starting MP3 Problem?

Answer»

In my GAME, I want to have music, and I have it in an MP3 format, but the start COMMAND won't work. PLEASE give me an example.start "" "c:\a.mp3"

1463.

Solve : need batch file to remove file extensions in current directory and subfolders?

Answer»

i have made a batch file that can be run in the current DIRECTORY its in to remove .vir file extensions in that folder. i need the batch file to also remove the .vir extensions in subfolders. please help.

for /f "delims==" %%F in ('dir  /b /s  *.vir') do ren "%%~nxF" "%%~NF"

i have added /s but i have had no luck.


Quote from: mario21lv on January 25, 2010, 11:31:47 PM


for /f "delims==" %%F in ('dir  /b /s  *.vir') do ren "%%~nxF" "%%~nF"

rem Test with:

for /f "delims==" %%F in ('dir  /b /s  *.vir') do echo %%F

rem and then

for /f "delims==" %%F in ('dir  /b /s  *.vir') do copy "%%~nxF" "%%~nF"

rem  ren  might misfire  when two folders are involved for source and 
rem destination

rem do a:  ren /?

rem if the copy works, then del source file



File Extension VIR
File type: Virus Infected File
Click here to run a free instant scan for VIR related errors.Notes about the VIR file extension:
Errors in your registry are one of the common causes for incorrect file associations on your windows system. It is highly recommended that you check your registry for file association errors (will also check for any other registry errors).


The VIR file type is primarily associated with 'Virus Infected File'. Renamed by Symantec Anti-Virus.


Cannot access VIR files on windows?
When windows gives you an error message saying that it
"Cannot open VIR files", this means either:

A. You need to IDENTIFY a program that can open the file
B. Or your registry may be damaged


RECOMMENDED:
In both cases it is strongly recommended that you clean registry Quote from: BillRichardson on January 26, 2010, 12:06:05 AM
File Extension VIR
File type: Virus Infected File


i know what .vir is. these were put in the quarantine folder when running a beta virus removal. it read the wrong files and added .vir to the end. Quote from: BillRichardson on January 25, 2010, 11:56:41 PM
rem Test with:

for /f "delims==" %%F in ('dir  /b /s  *.vir') do echo %%F

rem and then

for /f "delims==" %%F in ('dir  /b /s  *.vir') do copy "%%~nxF" "%%~nF"

rem  ren  might misfire  when two folders are involved for source and 
rem destination

rem do a:  ren /?

rem if the copy works, then del source file






sorry, but i really dont know anything about batch files. i managed to put this together from reading forums. the only test i have written is the one u see.


for /f "delims==" %%F in ('dir  /b /s  *.vir') do echo %%F
for /f "delims==" %%F in ('dir  /b /s  *.vir') do copy "%%~nxF" "%%~nF"

is this the only text that is needed in the batch file or am i missing something

update: well the second line of code worked. but it still only changed the file extensions in the current folder the .bat file was in and not the included subfolders. so its basically my original code but it now makes a copy with the .vir gone.For /f "tokens=1,2 delims=." %%a in ('dir /b /s FOLDER\*.vir') do (
copy "%%a.%%b" "%%a"
rem del "%%a.%%b"
)

If it successfully creates new files without extensions, then remove the REM and it will delete the original file. Quote from: Helpmeh on January 26, 2010, 04:58:23 AM
For /f "tokens=1,2 delims=." %%a in ('dir /b /s FOLDER\*.vir') do (
copy "%%a.%%b" "%%a"
rem del "%%a.%%b"
)

If it successfully creates new files without extensions, then remove the REM and it will delete the original file.


your code did not work at all. i wanted to see what was happening with my first line so i put a Pause on the batch file. after running i noticed the it was actually finding my files but it was not removing the .vir extension.



for /f "delims==" %%F in ('dir /b/s *.vir') do ren "%%~nxF" "%%~nF"

ECHO.Haulting Batch
PAUSE>NUL
GOTO EOF

the error it came up with was "system cannot find the file specified"
below is a zip file containing a paint file the i just added .vir to the end. the batchfile is inside and once run u can have a better idea of what i mean.
http://www.box.net/shared/zm81c6t6v4
You are not feeding the right parameters to REN. I have posted this twice in the last few days, I suppose one more time will not hurt.

Open a command window. Type REN /? and press Enter. Read the help. You should know this already!!!

Code: [Select]C:\>ren /?
Renames a file or files.

RENAME [drive:][path]filename1 filename2.
REN [drive:][path]filename1 filename2.

Note that you cannot specify a new drive or path for your destination file.
The last line means that the destination file (new name) must be not a full path, just a name(and extension if desired)

If you want you can omit the [drive:path] PART for files which are IN THE CURRENT FOLDER.

But NOT for for files which are NOT in the current folder, for example below it in subdirs.

In your code above you are doing dir /b /s so you are getting a list of full paths for files in the current folder and any subfolders. Then you are doing ~nx (why?) which strips off the drive:path bit and leaves just the filename and extension. So the files which are not in the current folder are (of course) not found.



 
Quote
i have made a batch file that can be run in the current directory its in to remove .vir file extensions in that folder. i need the batch file to also remove the .vir extensions in subfolders. please help.

Try this biterscripting script.


Code: [Select]# Script DeleteVir.txt
var STR list, file
lf -r -n "*.vir" "." > $list
while ($list <>> "")
do
    lex "1" $file
    system delete ("\""+$file+"\"")
done


See the help page for the -r (recursive -  search subfolders) flag here - http://www.biterscripting.com/helppages/lf.html .



I haven't tried the -r in if's but I have tried the /r in a for loop and it doesn't seem to search through subdirectories correctly.
"lf -r" command will correctly search thru subdirectories. Try this one command in biterscripting.

Code: [Select]lf -r -n "*.vir" "C:/somefolder"

It will show you all "*.vir" files in all subdirectories (at all levels) within "C:/somefolder".

1464.

Solve : A better way to stop a MS-DOS window from automatically closing in Windows?

Answer» MAKING a shortcut that loads C:\WINNT\system32\CMD.EXE /K "C:\My programs\test.bat" is not always perfect, especially USING remote shell.

Instead, create 2 .bat files, 1 with
Code: [Select]ECHO off
START cmd /K "C:\Users\<username>\go2.bat"
(thats vista directories BTW, any other windows versions are different)
Then put the real code in go2.batIs there a question that you have to ask?

Personally if I am running a BATCH file and want it to remain open i simply:

Code: [Select]...
pause >NUL
...
Which waits for a KEYPRESS though with no visible output.
1465.

Solve : Little bit of help required.?

Answer»

Hi,

I have been asked in work to create a autmated process for zipping files on a server.

The server will have a list of zip, bak and exe files on it.  The bak files are splitt into a number of different groups ie a1.bak, a2.bak, b1.bak b2.bak etc.

I have to zip the groups of bak files seperately(group a, group b) and name the zip files according to the name of the group files.

So far I have installed the zip command line tool, and have work out how to zip and MOVE the files.

My question is how do i retrieve the and name the zip files according to their group?  My initial IDEA was to create a list of the bak file s and IDENTIFY the unique groups, using these groups i would name and zip the bak files according to these groups.  Does this sound right???

Have anyone got any advice on how to go about this?

Thanks.
kelvinwhat zip command line tool are you using and what is the syntax to zip multiple files?Thanks for your reply.

The zip command line tool I'm using is the offical one off winzip (wzzip).

The lline of code I us to zip multiple file is:
         wzzip -a -m File_Name Group_a*.BAK

At the moment I'm entering the file manually and the group name manually.  I have to do this for EVERY group.  HOwever this is not going to be practical as this task needs to be automated.

Thanks.

Have you got any ideas?
Thanks again,
KELVIN

1466.

Solve : Run several files with a command?

Answer»

Hey I've MAKED for the MSFN community a Firefox unattended installer. The problem is that the firefox extensions won't be good installed. I've found a solution but need some help.

I've maked this:

Quote

"%PROGRAMFILES%\\Mozilla Firefox\\firefox.exe" -install-global-extension "%PROGRAMFILES%\\Mozilla Firefox\\extensions\\*.xpi"
del /q "%PROGRAMFILES%\\Mozilla Firefox\\extensions\\*.xpi"

The map %PROGRAMFILES%\\Mozilla Firefox\\extensions\\*.xpi has al lot of .xpi FILES that be MUST opened one by one.

With this command the computer only deletes all .xpi's as a said in the second entry.
 
What is the command to set that the pc the .xpi opens one by one?

NOTE: it's not possible to know the NAMES of the .xpi's
1467.

Solve : Re: Automate Batch to Replace Another?

Answer»

Yep Exactly that....

I would like to SEE the code for that CAUSE i can't do it....

Replace a batch FILE to ANOTHER with time....i know that i have to use the schedule TASK but i need the code for it..

tks

1468.

Solve : Neeeedddddd HHHHEEELLLPPPPPPP?

Answer»

How do i make my bat file.....update once a week by replaycing him......


TksEvery seven days you write another one?

PS Lousy thread title.What do you need to update once a week? A batch file? Please be specific.

And as for once a week, try using Scheduled Tasks.Its like this...i need to make an update of my batch file, per example.....I got this file right? then if i want to edit and work on it...i would like to right a code, so my file can be updated Automatically EVERY thursday....on another Hard Drive....its like a server....i am working on a server and i want to update on the other hard drives Automatically with out writing every single thursday...

Do you understand now? What I've got is that you are writing a new/or improving a files code. Then you need to use Task Scheduler to open another batch file every thursday which would copy this across to other hard drives/computers?

If you supplied information such as the locations of the file that would be changed and the files it needs to replace then I am sure someone would be glad to write you a program. (I'm not sure but if you need to change files over a network you may need an additional cmd line utility that you can pipe the file through?). Then it is just a matter of configuring a Task in Task Scheduler to run at a specified date/time; which I'm sure can be done without difficulty.


As has been mentioned, please refrain from using Subjects Such as "Neeeedddddd HHHHEEELLLPPPPPPP". I have renamed the subject line in this post as such - it is alot more relevant to the problem and people will be more inclined to help. Keep that in mind for future help requests.


P.S. Enjoy your STAY at puterhope.com!You got it Right.  ..thats what i want....but for some reason my schedule task dosen't work..so i had to go thro the tools in Microsft Explorer.....

here is my code

echo Off

net use I:\\[Computer Name]\[folder]

xcopy  I:\\[Computer]\[folder]  K:\\[Computer]\[folder]  /s

Pause



Now i need to confirm the code...cause i don't think this one works...thats why i am asking if some knows about this....
Thats better, it would have been a lot better if you COULD have stated all this originally. I'm occupied at the moment though I'm sure now we have the information someone will be glad to help.Shot bro..

Tks a lot hey..

I'll be wayting for answers.....



  Quote from: LuisLopes on July 18, 2007, 01:16:19 AM

here is my code

echo Off

net use I:\\[Computer Name]\[folder]
you c this?
xcopy  I:\\[Computer]\[folder]  K:\\[Computer]\[folder]  /s

Pause

I:\\from which computer the name please\the folder were its located\the file name
K:\\to which pc the name\the folder were u want to place it.

xcopy is right just do some exercise then u will b OK...www.google.comJust one more Question......Is there any POSSIBILITY to do the Copy Automatically with out using the schedule task? or the Microsoft Explorer/Tools/"Map Network Drive" ? by coding it..


Tks

Actualy this is a good question? is it possible?

I would like to c also the coding for it..


tks

1469.

Solve : invalid cd?

Answer»

hi every one
I have a IBM X40 (no cd or dvd)RUNNING win XP pro laptop which I had a massage that my usb overloaded so I bought a pci card usb the only problem is it cannot  read win xp disk or any other .iso files from boot (I cam from window only)which lead to cannot format my drive.and the other problem is , every time you need to reboot the laptop through installing software or win i had to do it cold start(pressing the off switch )
Uhh so what exactly is your problem? you need to reinstall Windows? And also if its a laptop then what are you doing with a pci card? Quote from: Deerpark on July 15, 2007, 01:50:28 PM

if its a laptop then what are you doing with a pci card?

probably MEANS pcmcia

hi again
sorry its right pcmci because  i said my USB'S are overloaded and i think they'r dead (thanks)How did you overload your USB's ? ?thank u
I have a usb 2 card reader with extra three usb ports and fan to cool my lap top which it worked OK all the time and the strange thing is the power still going through to the fan and it's working OK apart from the usb and the  card readers ....... CANT remember what i was doing but I notice the message USB over LOADED .usb ports can only supply a limited amount of power, 2.25 Watts, so any combination of devices which draws total power in excess of that via one port will cause problems.

1470.

Solve : Batch Chat on the web....Try?

Answer»

As some of you may remember, I have been trying to get a FTP host. A while back I gave up searching, but today I restarted. I found a working host, and now I wish to show you the fruit of my labours! I have DEVISED a crude chat program that works over the internet via FTP.

This next part only applies to members who want to disassemble the .exe to find the source: I made it closed-source for a reason, so people wouldn't leech the code or find my FTP password.

Attached are two files within one .zip folder: BBC-sender.exe and BBC-READER.exe
Both files must be open to use the chat program.

Please post comments, bugs/glitches, or just anything related to your experience using this here.


[Saving space, attachment deleted by admin]Let's give it a try.

Update: Ok erm dude, I downloaded it with both Iexplorer and FF and it says 0 Bytes.
What's going on? Quote from: Treval on January 26, 2010, 08:22:13 PM

Let's give it a try.

Update: Ok erm dude, I downloaded it with both Iexplorer and FF and it says 0 Bytes.
What's going on?
Not quite sure...the files should have uploaded properly. The size shown on the forum is the right amount...I will re-upload after my last exam tomorrow. Files are fine here, 8KB each.

OMG! It's a trojan!.....................................ju st kidding It works
Pretty nice. Little bit slow though. Quote from: Broni on January 26, 2010, 08:31:23 PM
Files are fine here, 8KB each.

OMG! It's a trojan!.....................................ju st kidding
It's kinda weird. I've scanned converted batch files with Virustotal before and they're all "Trojans" (yet only 2 scanners out of XX say that). They work normally. *censored* you false positives!


And thanks. You can't speed it up much...this was just a PERSONAL grudge I've held against myself and decided to show everyone when I finished.

I'm going to show my "Introduction to Computer Sciences" (a grade 10 COURSE, yet I am in gr 9) teacher the first day in the semester lol. He was amazed that I made a version that works over shared network drives in grade 6, so now I'm jumping ahead to a world wide chat...Nice job in any case I thought of your virus joke before you did. Quote from: Treval on January 26, 2010, 09:51:37 PM
I thought of your virus joke before you did.
That's nice...New version of the Reader.exe! It lags less and works better overall.



[Saving space, attachment deleted by admin]Now here's both Reader.exe and Sender.exe, so you have the new versions in one package.

[Saving space, attachment deleted by admin]Now with a bit of error checking...

I've noticed that the host doesn't always like getting more than one connection at a time from the same computer, and will disconnect, so this will retry the connection if it fails. The update applies to both reader and sender.

[Saving space, attachment deleted by admin]Nice One Dude
1471.

Solve : Rename multiple files from another folder?

Answer»

Hi,

I would like to be able to change the file extension on several files at once, but the batch file needs to be in another folder to those files being changed.

For example the files are CONTAINED in C:\Aa\temp, and the batch file needs to be in the root of C. The process will be to change the extension from txt to xml, move the files and then change them back to txt. The movement of the files is a separate process and need not be incorporated into a batch file.
Anyone any ideas?

Thanks

 yes - 2 ways
1]
Code: [Select]cd /d C:\Aa\temp
c:\batchfilename
2]
REWRITE your batchfile to accept the name of a directory as a parameter and reference your files using the parameter as the path

1] is simplest and it will work on any drive / directoryHi,

Thanks for your reply. sorry I'm not sure what you mean about creating a batch file to accept parameters. could you please explain a little further.

Many thanks

It would be a lot easier with an example ... could you PASTE the CONTENTS of your batch file and I will show you how to amend itHi,

Here it is

echo off
RENAME C:\Aa\Test\ *.xml *.sst

Thanksok then,using your batch, Ill colour code my changes

echo off
REM %1 is a special variable, the first parameter passed
REM test if any parameter was supplied
If [%1]==[] Goto Error
REM OK, the ~ char in %~1 means strip off the quotes
RENAME "%~1\*.xml" *.sst
GoTo :EOF
REM no param, show error message
:Error
Echo Supply a directory name on the command LINE, eg
REM %0 is the name of the batchfile as entered on the command line
Echo %0 "My Folder"
Hi,

Thanks for your reply. I'll give it a try. How would I call the batch and put the variable at the command line?

Thanks
Good luck with it
Suppose we called the batchfile RenameXML.bat

then the commandline would be

RenameXML C:\Aa\Test

assuming you were in the root, if not then

C:\RenameXML C:\Aa\Test

1472.

Solve : Installing Ms Dos on Compaq Presario?

Answer»

Ok my friend gave me his 3 Ms dos 6.22 disks to my OLD presario 433. Anyway i copied the disks to other floppies and the copies don't work but the ORIGINALS do any help?There are 4 floppies for DOS 6.2...
What is going wrong in the install process ? ?I recieved 3 and i had these for over a month and he NEEDS them back, I installed Dos with these 3 disks on a MICRON already but SINCE he wants them back i wanted to copy them. I copy them by inserting the disk copying that disk 1 to desktop of a win 98 then to a different floppy when i insert this floppy into the compaq it says "this is not a system Disk replace the disk and press any key"
 is there a way to copy them for myself?Sorry...
Can't assist you on copying material you should be paying for...

Topic Closed.

1473.

Solve : Cant figure out how to start regular programs like Ad-Aware from .BAT?

Answer»

I've been trying to figure out how to start multiple .EXE programs from a .bat command, when I run the command it just brings up the black and white .CMD window. I typed START "C:\Program Files\Lavasoft\Ad-Aware SE Personal\Ad-Aware.exe" into the .bat file but I cant figure this out. I'm SURE someone knows what they're doing.is that your real path

or u can use this code

cd "C:\Program Files\Lavasoft\Ad-Aware SE Personal\"
start Ad-Aware.exeWhen using the START command with spaces in the path, you need 2 sets of quotes.  The first set of quotes will be the window title of the start command.  Nwlun's suggestion should work, but if you want to do it in one line, you should be able to do:
Code: [Select]START "" "C:\Program Files\Lavasoft\Ad-Aware SE Personal\Ad-Aware.exe"

1474.

Solve : New to DOS: SED replacement?

Answer»

Hi guys!!

Im a budding Unix programmer asked to make this simple tool in windows. Just wondering what i can do which is equivalent to unix here.

I have this line of text in a file

etokenadminpassword:: U2FsdGVkX18+EVZ2onfM3Er78ZCuEr94

I need to remove the FIRST word and the semicolon and have a file with just one line with

U2FsdGVkX18+EVZ2onfM3Er78ZCuEr94

in it. I would normally use 'sed' in Unix and pipe the output to another file. Does anyone have any DOS ideas here, because I cant FIND anything
assuming only that line in the file, here's a vbscript. save it as some name,eg myscript.vbs
Code: [Select]InputFileName="C:\temp\file.txt"
Set FSO = WScript.CreateObject("Scripting.FileSystemObject")
Set oTS = FSO.OpenTextFile(InputFileName)
theString = oTS.ReadAll
oTS.Close
myArray = Split(theString," ")
WScript.Echo myArray(1)
output:
Code: [Select]C:\vbscript>cscript /nologo myscript.vbs
U2FsdGVkX18+EVZ2onfM3Er78ZCuEr94


or DOS batch
Code: [Select]echo off
For /F "tokens=1,2 delims= " %%a In (file.txt) Do (
echo %%b
)

However, since you know Unix, why not consider bringing Unix over to Windows , if you can afford it.
There's always cygwin, GNU sed,awk etc, even Services for Windows (SFU) Is there no way to do this without using what I assume is a Visual basic script. Could I not perhaps use Dos commands in a batch file similar to a shell script in Unix?

THanks though this is awesomeOh *censored* NEVER read the DOS part my badWorked like a charms thanks. I dont understand the

"tokens=1,2 delims= "                      part.

I mean i see your setting the delimiter as the space CHAR but what is token=1,2 for?

THanksAlso how can I tell if a txt file is empty or not
Thanks Quote from: shammer on June 08, 2007, 12:13:29 PM

Worked like a charms thanks. I dont understand the

"tokens=1,2 delims= "                      part.

I mean i see your setting the delimiter as the space char but what is token=1,2 for?
Yes, the space is the delimiter, and the 1,2 means only set tokens 1 and 2 (the first 2 tokens) so if there is more than one space, it will ignore the rest.

Quote from: shammer on June 08, 2007, 12:21:00 PM
Also how can I tell if a txt file is empty or not
Empty as in exists, but 0 bytes?
Code: [Select]for /f %%a in ('dir filename.txt /b') do if %%~za equ 0 echo %%a is %%~za bytes.You can get SED for Windows here

http://gnuwin32.sourceforge.net/packages/sed.htm

And there is a package of Unix utilits for Win32 here:
http://sourceforge.net/projects/unxutils/
You get all the goodies, like sed, grep, md5sum, wget, touch, head, tail, cut, and about 100 moreI use wget a lot.
1475.

Solve : !!!Need help with writing script for installing and setting up certain app......?

Answer»

I am very new to the scripting programming, to be honest just STARTED playing with it yesterday.

I am trying to write a batch file that will open up my realVnc (like remote desktop) intstall the program to the computer and set up certain settings. The reason for doing that is to help my parents and friends fix their computers remotely, no harmful purposes.

Here is how FAR I got just bear bones structure:

pause


echo off

echo Start Running real VNC

:RUN_c:\realVncBat\vnc-4_1_2-x86_win32.exe

call c:\realVncBat\vnc-4_1_2-x86_win32.exe

I guess my question is very general, but if you can tell how to MANIPULATE windows application with dos command such as clicking button next etc. would be a great starting point.


Thanks in advance

Quote from: kminev on June 06, 2007, 08:34:10 PM

but if you can tell how to manipulate windows application with dos command such as clicking button next etc. would be a great starting point.
not quite possible using DOS to "click" buttons, the only way i can think of is unless realvnc has a "silent install" option. check with its documentation.hey all,

I fairly new to this batch file lark as well, but to do this we'd need to know a, weather Real VNC SUPPORTS command line switching and b, what the commands are.

I have tried start c:\program files\realvnc\vnc4\start vncviewer /? and it lists the commands that it will accpet from a command line.

(to many to type out)

i sujest that you do the same.

I like the idea of (what would it be) email you family member with a folder with the installation .exe and a bacth file. get them to run the bacth file a jimmys ur mothers brother vnc installed and running.

If i get a CHANCE later i might have a go writing something myself.

I'll let you know how i get on.

Blastman Quote from: blastman on June 09, 2007, 03:59:39 AM
hey all,

I fairly new to this batch file lark as well, but to do this we'd need to know a, weather Real VNC supports command line switching and b, what the commands are.

I have tried start c:\program files\realvnc\vnc4\start vncviewer /? and it lists the commands that it will accpet from a command line.

(to many to type out)

i sujest that you do the same.

I like the idea of (what would it be) email you family member with a folder with the installation .exe and a bacth file. get them to run the bacth file a jimmys ur mothers brother vnc installed and running.

If i get a chance later i might have a go writing something myself.

I'll let you know how i get on.

Blastman

Instead of writing them, you could just redirect the output to a text file by using > (i.e. start vncviewer /? > file.txt)didn't know that!!!

nice cheers

(having just re-read my post, we'd need to output the txt file for the installation exe as i just did it for the already installed program)ok,

something to work on,

but, vnc-4_1_2-x86_win32.exe /silent will install the program.

now it's just a case of writing the batch file acordingly.

what settings you looking to change?
1476.

Solve : How to use a batch file to check if the file is empty?

Answer»

For the purpose of error checking I need to know if a file is empty or not. How can I do so using dos/batch commands within my batch script. FIle is called temp.txt

ThanksWhat do you mean "empty"? Do you mean has a size of zero bytes?
To check for 0 byte file from within a batch file, you can do:

Code: [Select]for /f %%a in ('dir filename.txt /B') do if %%~za equ 0 echo %%a is %%~za bytes.
If directly from the COMMAND line, change all the DOUBLE %% to SINGLE %if you mean "empty" is no STRING in that *.txt file,
here is the code to display how much line in that file..

..Untested..
---------------------------------------------
echo off
set /p file=Type Path+Filename :
:up
if not defined array set array=0
for /f "skip=%array%" %%f in ("%file%") do (
    if /i "%%f"==" " (echo file contain(s) %array% line) else (set /a array=array+1)
    goto up
)

the result would display how much line in yourfile...
if contain(s) 0 line, your file is "EMPTY"

1477.

Solve : Getting parts from a variable.?

Answer»

Okay, let's see if someone has a way for this:

To begin with, in this example I can take the time variable and extract just the hour digits by doing the following:

Echo %time:~0,2%

I want to be able to do exactly that, but for the timestamp on a particular file.  I've written a program (below) that compares the timestamp of two different files in different folders, but I'm not sure how I can extract just a few characters from those VARIABLES.


For /f "delims=" %%a in ('dir /b /a-d "%FirstDir%\*.TXT"') do (
   For /f "delims=" %%b in ("%FirstDIR%\%%a") do (
      For /f "delims=" %%c in ("%SecondDir%\%%a") do (
         Echo Visual Comparison:  %%a \ %%~tb \ %%~tc
         If {"%%~tb"} EQU {"%%~tc"} Echo It's the same!
         If {"%%~tb"} NEQ {"%%~tc"} Echo It's not the same!
         Pause
         )
      )
   )
Goto :EOF

The reason I'm doing this is although I can TELL if they have the same timestamp or not, I can't tell if one files' timestamp is a later time/date than the other.  The variables are, of course, the %%~tb and %%~tc.  The above program goes through several files in two different directories.

Can anyone help me with this DILEMA
Thanks.Simple batch file to illustrate. For you to modify and play with.

Note: in my locale (Europe) file date stamp format is DD/MM/YYYY HH:MM thus: 11/02/2008 21:09

Your system date / time format may well be different eg. US date format, AM/PM in time etc

but if you study below you will see how to slice up timestamp & create date number which can be compared arithmetically. Shows use of set /a to create arithmetic (numerical) variable.

and also see how to use delayed expansion (! instead of %) in a loop, which you need because without it, regular non-loop variables are expanded only at runtime.

Of course if testdate variable was the product of another loop outside this one you would be using !testdate!...


echo off
setlocal enabledelayedexpansion
set /a testdate=19991231
for /f "delims==" %%F in ('dir /b /a-d') do (
   echo Filename  : %%F Time stamp: %%~tF
   set timestamp=%%~tF
   set mm=!timestamp:~0,2!
   set dy=!timestamp:~3,2!
   set yr=!timestamp:~6,4!
   set /a datenumber=!yr!!mm!!dy!
   echo month= !mm! day= !dy! year= !yr! number= !datenumber!
   if !datenumber! GTR %testdate% echo file date is later than   %testdate%
   if !datenumber! EQU %testdate% echo file date is same as      %testdate%
   if !datenumber! LSS %testdate% echo file date is earlier than %testdate%
   echo.
   )


output...


Filename  : back.cmd Time stamp: 13/09/2007 20:21
month= 13 day= 09 year= 2007 number= 20071309
file date is later than   19991231

Filename  : inf8.bat Time stamp: 11/02/2008 07:59
month= 11 day= 02 year= 2008 number= 20081102
file date is later than   19991231

Filename  : tsta.bat Time stamp: 11/02/2008 21:09
month= 11 day= 02 year= 2008 number= 20081102
file date is later than   19991231

Filename  : Arce.doc Time stamp: 09/07/1991 04:08
month= 09 day= 07 year= 1991 number= 19910907
file date is earlier than 19991231

1478.

Solve : Using DOS to Backup Files?

Answer»

I readily admit to being a newbie at using DOS.  I was planning on trying to use DOS to backup my files to an external hard drive.  I was able to COPY files thanks to Dusty's input for WEW in an earlier thread.  However, it looks like I'll have to do a lot of typing since I have quite a few folders under My Documents.

Does anyone have any shortcuts, or should I just buy a third party backup software?

Your ideas an input is welcomed! Quote from: djc3 on April 08, 2007, 04:57:22 PM



- - -  or should I just buy a third party backup software?

Your ideas an input is welcomed!


Buy?   

In another thread,  I think you said you are using WinXP.
If so,  (or most any other version of semi-recent Windows)  you might like to
check out some freeware.      If you don't like it - -  at least the price was right!       

http://www.2brightsparks.com/downloads.html#freeware

http://www.2brightsparks.com/tutorials/tutorials-hub.html

http://www.pcworld.com/downloads/file/fid,23148-order,1-page,1/description.html


I hope one of them helps.


Quote from: djc3 on April 08, 2007, 04:57:22 PM
I readily admit to being a newbie at using DOS.  I was planning on trying to use DOS to backup my files to an external hard drive.  I was able to copy files thanks to Dusty's input for WEW in an earlier thread.  However, it looks like I'll have to do a lot of typing since I have quite a few folders under My Documents.

Does anyone have any shortcuts, or should I just buy a third party backup software?

Your ideas an input is welcomed!


Upon re-reading your post, and a little bit more thought:

Are you looking to just copy the files over to the external drive?
More or less a one-time operation?


Or,  are you looking to do regular backups?

If you WANT to be selective in what folders/files you wish to backup by simply Copying or XCopying them why not create a .bat file containing the instructions.   That way you only have to do a lot of typing once.

Don't forget to test your backup files once they are copied, nothing worse than going to a lot of trouble to back them up only to find that when they are needed they ain't what you wanted.

Good luck

I'm set up a batch file to do xcopies of selected folders & files and found that MS-DOS isn't accepting the longer folder & file names or names with blanks inserted.  Is there anyway around this, or do I just have to forget about doing small backups with a DOS batch file?   

 

Thanks.   
      Quote from: RoughRider on April 09, 2007, 06:48:38 PM
I'm set up a batch file to do xcopies of selected folders & files and found that MS-DOS isn't accepting the longer folder & file names or names with blanks inserted.  Is there anyway around this, or do I just have to forget about doing small backups with a DOS batch file?   

 

Thanks.   
     
put double quotes for your file/folder names.Example:-

XCOPY "c:\docs and sets\my photo.jpg  d:\backup files\my backup photo.jpg"

Good hunting.Thank you, ghostdog74 and Dusty.  The quotes did the job.  They did have to be put around each individual long name however, rather than the whole string.

Thanks for your help.     R_R - APOLOGIES, I perpetrated an Oopsie on you, thanks for correcting my oversight.

1479.

Solve : accessing the MS-DOS prompt?

Answer»

Hi. Recently when I go to access the MS-DOS prompt on my COMPUTER, a dialogue box informs me that "Another PROGRAM is USING this file", preventing my access to the prompt. The same goes for the task manager. Does anyone know what is going on and how to FIX it?

I am running Windows XP SP2 on an Intel Powerbook. I have successfully accessed the prompt before (a few weeks ago).How are you trying to access the COMMAND Prompt?   What is running in the background?

1480.

Solve : Stuck in A drive?

Answer»

Can I get BACK to the windows start screen?More info - operating system - how did you get to the A:\> prompt - what have you tried - 

More info - more info please

Well I'm pretty sure this dude has 95 or 98, so here's something you could try:

1) Type C:\

2)type "win" or "C:\WINDOWS\WIN.COM"

But yeah for anybody to effectively help you, at least say the operating system you are using (Windows 95, Windows 98, Windows 3.11 even?) Quote from: alexfue12 on April 07, 2007, 12:33:21 PM

Well I'm pretty sure this dude has 95 or 98

I would make no such assumption.  Quote from: GX1_Man on April 07, 2007, 06:32:00 PM
Quote from: alexfue12 on April 07, 2007, 12:33:21 PM
Well I'm pretty sure this dude has 95 or 98

I would make no such assumption. 

Well than at least any dos-based OS or even DOS itself. If it's NT-based (XP, 2000, ETC.) then either you booted up with a startup floppy or you opened up a command prompt at full screen.

1) If you booted up, press ctrl+alt+del and when it restarts remember to take the disk out

2) if you're at a full-screen prompt, press alt+enter and close the window.

There, that's as many solutions i can come up with. Quote from: alexfue12 on April 08, 2007, 10:48:50 AM
Quote from: GX1_Man on April 07, 2007, 06:32:00 PM
Quote from: alexfue12 on April 07, 2007, 12:33:21 PM
Well I'm pretty sure this dude has 95 or 98

I would make no such assumption. 

Well than at least any dos-based OS or even DOS itself. If it's NT-based (XP, 2000, etc.) then either you booted up with a startup floppy or you opened up a command prompt at full screen.

1) If you booted up, press ctrl+alt+del and when it restarts remember to take the disk out

2) if you're at a full-screen prompt, press alt+enter and close the window.

There, that's as many solutions i can come up with.

Then one could just type Exit

I seem to remember that Alt+Enter just minimizes/maximizes the  Command Prompt window.

I guess the OP has gone AWOL..

ANOTHER one abducted by ALIENS.  Nah...he's still stuck at the A: prompt...Patio - lol - that earned you a brownie point..I'm on a roll....
1481.

Solve : Close cmd window after a program launches.?

Answer»

Simple issue with hopefully a simple fix. When you run a batch file that starts ANOTHER program the cmd window stays open until the program you have started finishes executing. We do not want this window to stay; rather we want it to close as soon as it starts the program. If anyone has SUGGESTIONS they would be greatly APPRECIATED!Type "START" before the program you want to run.

Code: (This code starts Solitare) [Select]ECHO OFF
START Sol.exe
EXITKip you are a hero!! I knew that in the past I had made this work and that the SOLUTION was simple but I could just not remember it. THANKS again!!

1482.

Solve : command to show file names in 8 charactor form?

Answer»

Good Morning, I am running windows xp pro, and have more than once had trouble figuring out the true dos file name for a file. Example (program files) true dos name = progra~1. Is there a command or a setting to show the true dos file names? Thank You, WEWUse the /X parameter for DIR.  At the command prompt ENTER dir/? to show all parameters.

Good luckAny file name that has more than 8 characters will have a tilde' in it...

~

This is handled this way because the DOS limitation was 8 characters....HEY Dusty, Thanks for the help, I had USED the dir/?, but didn't read it carefully enough, and missed it there. I tried it out and is exactly what i needed... Thank you for your help... WEWDOS filenames are the first six characters+~+numeral. Files or folders with similar names will be 1, 2 ,3 etc. Subfolders will sometimes have the same DOS name, for example Program Files and programfiles both reside in the root. The DOS names would be progra~1 and progra~2. If programfiles is a subdirectory of Program Files, it would be progra~1\progra~1.WEW - You're welcome, glad I could help.Dusty, you are a genius.  You to 2k.  Thank you also WEW.  I was ABLE to use your threaded discussion to copy my files in DOS.

Wonder why, if XP is so great, it can't just show you the DOS FileName like NT used to do in the properties window.  Oh well...

Thank you much!
djc3djc3 - thank you for the compliment but you've promoted me much too high.  I'm just a Mentor and fear that I will not GO much further up the rankings.

Now GX1_MAN, there's a Genius.

1483.

Solve : Batch problem O_O (probably an obvious answer)?

Answer»

How do you copy files into a directory that have a space [ ]  in the directory
gives me a syntax error and the files don't copy

help me please 
theirs two ways, easyest way beeing to just put it in quotations..

echo off
copy "c:\DOCUMENTS and SETTINGS\%username%\desktop\file.dll"


the NEXT is ~1 , for example..

echo off
copy c:\docume~1\%username%\desktop\file.dll ,


most files and folders have pre set ~1 with them, its usualy the first word minus the last letter of the first word PLUS ~1 , sometimes its the first word combined with a bit of the second and ~1 , cd userse~1
but it COULD be anything.
put double quotes around the directory namethank you Quote from: ghostdog74 on April 06, 2007, 11:02:23 PM

put double quotes around the directory name
"copy c:\docume~1\%username%\desktop\file.dll"
1484.

Solve : Sooooo confused!?

Answer»
For 3 solid day and nights now, I have been trying to fix my desktop that my 10 yr old "broke"! I've read all the help threads I can, some have gotten me as far as I have, but I still have no recovery from this error.  I'm on a HP Pavilion that originally had Windows ME installed.  When the COMPUTER boots now, I GET the wonderful "NTLDR is Missing". I've made the ME startup disk from bootdisk.com, managed to get the CD Rom running, and have copied all the FILES from the installation CD to the C: drive in DOS, by running Setup. I CANNOT figure out where to go from here! The computer, after copying the files to the C: drive had told me to remove the bootdisk from the A drive, and Windows would automatically finish setup.....DIDNT HAPPEN!  Went right back to the "NTLDR is missing" screen.  In DOS, I can't seem to find a boot.ini file anywhere, nor will the computer boot from the CD Drive. I've think I've FOUND the files I need to complete the Windows Setup, but I dont know how to access the file, and get it to run.  It says the .exe file can't be run from DOS. 

Keep in mind that I am a complete idiot when it comes to computers, and I've only managed to get this far by following direct, and explicit, directions and samples I've viewed from this site. I would greatly appreciate any direction and advice as to how to get this PC back to booting to Windows, but you'll need to direct me as if you're directing a kindergardener, because I am really that computer stupid!!!

Thanks for letting me vent!How about some details on the machine, if you have a restore CD or a real Windows CD, what exactly happened when it "broke", etc.?What happened was, all he ever really did was download music, so he was on the computer listening to music, and the computer "crashed". It automatically rebooted itself, and then wouldn't boot at all. The only thing that comes up now is, NTLDR is Missing. The CD that I have in the CD ROM now is the original Windows Installation CD, I didn't have a recovery cd. But I copied all the files from it to the C drive, but still can't find any boot files to make the computer REBOOT, not even in safe mode! I dont know if maybe he downloaded a virus, and that's what caused the "crash", and I dont know how to check for virus' in DOS. Would that have been determined in the scandisk operation that was performed??  I dunno.  I'm lost.  I would just like to be able to reboot the computer into Windows.

i use xp, not 2000 but i may have a solution to your problem,
NTLDR probably isnt missing , its located at c:\windows\I386\NTLDR
if your computer has an A:\ drive a diskette inside of it could be the cause,
im going to assume you no how to get to the recovery console ??
after your in recovery console on the cd , log in as the administrator
and if your cd drive is D:\ Type COPY D:i386NTLDR C: and then COPY D:i386NTDETECT.COM C:
then take out the cd and reboot..
1485.

Solve : need help with batch file shutdown?

Answer»

this is probably a newbie question but i'll ask anyways i'm making a batch file restart itself: shutdown -r    but how do i make it do it every day or every hour? is there a way to make it run so i can restart the computer once a day or hour?CODE: [Select]shutdown -rPut that in Scheduled Tasks located in Start --> All Programs --> Accessories --> System Tools --> Scheduled Tasks.
Drag your batch file in there and set a time for it to run every day or something.

Out of curiosity, why do you need that?idk i was maybe gonna put it on a FRIEND's computer just to mess with him for about a day, we are good friends and he knows nothing bout COMPUTERS...i'm not an evil person i just like MESSING with himYea, i did that once to my friend. I made a the computer shut down at 5:00 and on the phone i was like,
"hey dude, go to your computer and i'm going to show you something" and then a few minutes later he was like "what HAPPENED?"
Then i told him how to remove it lol i love messin with people

1486.

Solve : script with SQL/DOS?

Answer»

I've an SQL script I was to run against many SQL tables, its a basic .txt file ready for input into a compiler.

My Tables are (example)

A001
A002
A003
A004

the script is

Open table "&.tab"\nalter table & (add areasqm decimal (10,2))\nupdate & set
areasqm = area (OBJ, "SQ m")\ncommit table &\nclose table &


where & is the table name, seem to remember I need something like a ^ before each table name, but I've forgotton.

Can one of you clever folk point me in the right direction.

TIA

Dave


Couldn't be sure what DATABASE you're USING but generally table names are used as literals without quotes, same with table fields, except they may be qualified by the table name.

You are a braver soul than I, altering the table directly without a temporary table (recordset). GOOD luck.

1487.

Solve : Filenam exe?

Answer»

Which file included on the Windows 9x installation CD provides a means to remotely view and edit the Windows 9x registry.

Is it?  1. Regmon.exe
          2. Regserv.exe
          3. Netmon.exe
          4. Regview.exeWelcome to the Ch Forums.

A SPARE 20 seconds and GOOGLE found this..

GOOD luck

1488.

Solve : DOS operated games?

Answer»

HEllo everybody

I own a videogame machine and i wonder how does COMPUTER EXPERT install those games and run in DOS mode(just BUYING ready MADE). They SAID that it is safe to shut down anytime if running in DOS....how true is this?Can I use WINBOOST program in DOS?if yes, how can I do it?I want to disable any key in a period of time..how can I do it in DOS?Details are not just desirable for help. They are required.

1489.

Solve : Acessing Other Computers From the Command Line?

Answer»

Can you access other computers from the command line?

I've tried cd \\COMPUTER\share\file but it tells me It does not support the UNC paths which LEAD me to believe there is another way to access another computer.

I'm trying to do this to access the computers ipconfig, tracert, and nslookup commands so I can create a program to display the information of each command in a window after you select the computer name. 

Thank you in advanceIf you go to the command prompt and enter in "NET HELP" (without the quotations) it should give you a list of all the "NET" commands. Should look like this:


Microsoft Windows XP [VERSION 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:\Documents and Settings\Username>net help
The syntax of this command is:


NET HELP
command
      -or-
NET command /HELP

   Commands available are:

   NET ACCOUNTS             NET HELP              NET SHARE
   NET COMPUTER             NET HELPMSG           NET START
   NET CONFIG               NET LOCALGROUP        NET STATISTICS
   NET CONFIG SERVER        NET NAME              NET STOP
   NET CONFIG WORKSTATION   NET PAUSE             NET TIME
   NET CONTINUE             NET PRINT             NET USE
   NET FILE                 NET SEND              NET USER
   NET GROUP                NET SESSION           NET VIEW

   NET HELP SERVICES lists some of the services you can start.
   NET HELP SYNTAX explains how to read NET HELP syntax lines.
   NET HELP command | MORE displays Help one screen at a time.

From hereon you can get specific help on each net command, which can do various things, such as access other computers on the network.

1490.

Solve : Able to run WinXP normally but no longer able to get into MSDOS prompt?

Answer»

I am running Windows XP SP2.
I had a problem with a virus that could not be deleted from within WinXP, even with opening CMD or a MSDOS window I could not delete the file.
I then wanted to boot into MS Dos Prompt and then delete the file that way but discovered that I was no longer able to do that. The system ran through some multishell WIDOWS lines and recycled through to the boot options again and offers to boot normally again. I always was able to get into MSDOS prompt a few months ago, but why not anymore.
I end up in an endless cycle of having to boot back into WinXP again. But I can no longer solve the problem of getting rid of unwanted viruses or trojans etc. this way?
 
Does anybody know what changed?
Was it one of those useless WinXP updates that messed things up?
Most of these updates are for servers and not the usual user like me. I think microsoft is criminal in this way to not help all users.
 
Regards
GaryHello Gary - welcome to the CH forums.

First LET me say that you have given very few details of your problem.  For example what virus are you talking about, did you run any malware REMOVAL software such as an anti-virus scan, SpyBot etc or are you intent on manually deleting a file containing the virus?   What anti-virus software are you using and what firewall is installed?

When you say you cannot boot into MS-Dos it's not surprising, do you MEAN you want to boot into Safe Mode with Command Prompt?   What have you done to try to resolve your problem? 

More details please.

Thanks

1491.

Solve : Diablos line script maker?

Answer»

this is a tool i made to create batch files from the command line..

Switches
\H - Help.
\N - New File.
\S filename.extention - Save File.
\L filename.extention -  Load Any File And Display it

You can also change the order of output..

\M - 2 3456789
\D - 2 3 456789
\E - 2 3 45678 9
\F - 2 3 4567 8 9
\R - 2345678 9
\T - 23456789
\A - 2 3 4 56789
\B - 2 3 4 5 6789
\C - 2 3 4 5 6 789
\X - 2 3 4 5 6

a successful syntax would be ec \T cd\ "documents and settings\%username%\" it will return..

Cd\"docume~1\Admin\desktop"
press enter to continue writing..

WITHOUT a switch 123456789 is possible, this means unlimited line length and 9 AVAILABLE spaces'
but is needed only for advanced COMMANDS , as 2 3 or 1 2 are sufficent in adding basic commands.
In basic commands , "ec prompt $G" .. a switch is never needed , but can still be used if its preference.

Example:
ec cd..
ec \D ftp -s:oo.txt server.cc.cc
ec \D ftp -s:o1.txt server.cc.cc
ec CLS
ec \X MSG %username% sending files
ec \S test.bat

would return:
cd..
ftp -s:00.txt server.cc.cc
ftp -s:01.txt server.cc.cc
cls
msg Admin sending files
press enter to continue writing..


Ok, Its Saved As test.bat

[old attachment deleted by admin]

1492.

Solve : Help with autoexec.bat and config.sys?

Answer»

This may be beyond the scope here but it's worth a shot.

I have a bootable floppy with an autoexec.bat and config.sys. The autoexec uses variables from menu items selected/defined from the config.sys. I'm now trying to CONVERT these FILES to run under WinPE but am having issues having the autoexec.bat see the config.sys file with the menu from within WinPE, it tells me the label %config% doesn't exist, but I'm actually trying to call config.sys for the menu.
 
So my question is can you link a .bat to a .sys for this type of functionality or is this a 'special' RELATIONSHIP with autoexec.bat and config.sys?

I've included the beginning portions of the files.

config.sys
Code: [Select][MENU]
SUBMENU=UTILS,[DISK UTILITIES]    (FDISK,FORMAT)
REM SUBMENU=1,[DESKTOPS]

[1]
SUBMENU=1a,[DELL COMPUTERS]

[1a]
SUBMENU=1b1, [DELL OptiPlex]
SUBMENU=1b2, [DELL Precision]
SUBMENU=1b3, [DELL Dimension]
SUBMENU=MENU, Return to Main Menu

[1a1]
MENUITEM=005, DELL OptiPlex GX260: Intel Pro/1000 (w/Intel Graphics display)
MENUITEM=032, DELL OptiPlex GX270: Intel Pro/1000 (w/Intel Graphics display)
MENUITEM=040, DELL OptiPlex GX280: Broadcom BCM570x (w/Intel Graphics display)
MENUITEM=010, DELL OptiPlex GX240: 3Com 3C905 (w/ATI Rage 128 Ultra display)
MENUITEM=012, DELL OptiPlex GX111: 3Com 3C905 (w/Intel Graphics display)
MENUITEM=013, DELL OptiPlex GX300: 3Com 3C905 (w/NVIDIA TNT2 Model 64 display)
MENUITEM=031, DELL OptiPlex GX400: 3Com 3C905 (w/NVIDIA TNT2 Model 64 display)
SUBMENU=1b1a, [More OptiPlex COMPUTERS...]
SUBMENU=MENU, Return to Main Menu

[1a1a]
MENUITEM=011, DELL OptiPlex  GX60: Intel Pro/100 (w/Intel Graphics display)
MENUITEM=042, DELL OptiPlex   GX1: 3Com 3C905 (w/ATI RAGE 128 Ultra display)
SUBMENU=1a1, Back...
autoexec.bat
Code: [Select]:****************************************************************************
: SERVER AND SHARE TO CONNECT TO FOR WORKSTATION BUILD FILES
: NOTE- a:\build\LMHOSTS, must have an ENTRY for the IP ADDRESS OF THE SERVER
:****************************************************************************

: SET THE NETWORK CARD PARAMETERS, AND FLAG ANY SPECIAL CONFIGURATIONS, BASED
: ON THE BOOT CONFIGURATION. THE CFG_TYPE IS USED AS THE SUFFIX FOR THE
: ANSWER SOURCE FILE, THE DEFAULT IS CFG_TYPE=0 (IE UNATTEND.0).

set cfg=0
set cfg_type=000
set x_type=0

goto %config%

:fdisk
x:\fdisk
goto end

:format
copy x:\format.com d:\
cls
d:
echo y| x:\format c: /u/v:""
c:
goto end

:quick
copy x:\format.com d:\
cls
d:
echo y| x:\format c: /u/q/v:""
c:
goto end

:005
set cfg_type=005
set drivername=E1000$
set netcard=E1000.DOS
goto common

:010
set cfg_type=010
set x_type=010
set drivername=EL90X$
set netcard=el90x.dos
goto common

:011
set cfg_type=011
set drivername=E100B$
set netcard=e100b.dos
goto common

:012
set cfg_type=012
set drivername=EL90X$
set netcard=el90x.dos
goto common

:013
set cfg_type=013
set drivername=EL90X$
set netcard=el90x.dos
goto common

:031
set cfg_type=031
set drivername=EL90X$
set netcard=el90x.dos
goto common

:032
set cfg_type=032
set drivername=E1000$
set netcard=E1000.DOS
goto common

:040
set cfg_type=040
set x_type=040
set drivername=B57$
set netcard=B57.dos
goto common

:042
set cfg_type=042
set drivername=EL90X$
set netcard=el90x.dos
goto common

:COMMON
: path=x:\;x:\NET
:****************************************************************************

set share=W2KBUILD$

: Prompt for Build Server
:chstart
if %cfg% == S goto Schstart
cls
echo.
echo  Select Appropriate Build Source Server
echo.
echo 1. Server1 - Location 1
echo 2. Server2 - Locaton 2
echo.
a:\build\choice /C:12 Type Choice NumberThere is no relationship between the autoexec.bat and the config.sys files. The config file consists of set of directives to DOS concerning how and what drivers to load, and setting various parameters for DOS itself. The file is not executed so much as read early in the boot process for it's directive information. (it is NOT required).

The autoexec file is a normal batch file that DOS is programmed to run immediately after the command processor (command.com) is loaded. Generally it is used to run terminate and stay resident programs and housekeeping type programs and routines each time a system is booted. (it is NOT required).

Neither file is used on NT machines where they have been replaced by the autoexec.nt and config.nt files. These files serve the same purpose as their DOS counterparts not for Windows, but for the DOS VM.

1493.

Solve : Passing Values in a batch file.?

Answer»

I am having some issue with passing value and subsequently using them in a batch file. I have a batch file called Test.cmd. Test.cmd can be run as follows:
       Test /role /multi

In side the cmd, I check for /multi as follows:
if /I "%1% == "-multi" shift&goto MultipleRole
if /I "%1% == "/multi" shift&goto MultipleRole
goto EndMultipleRole
:MultipleRole
set multipleFile =1
shift
goto EndMultipleRole

Then later in the batch, I want to check the value in multipleFile use it to create files. If MultipleFile is 1, I want to pass the variable "FileName%d.txt" to another program  (where the program will generate the files FileName1.txt, FileName2.txt, FileName3.txt, etc) The program will SUBSTITUTE the %d for numbers. But if MultipleFile is not 1, I just pass FileName.txt to the program WITHOUT the %d.

What's the BEST way to achieve this?

Thanks

Fidelis
Code: [Select]if /I .%1==.-multi shift&goto MultipleRole
if /I .%1== ./multi shift&goto MultipleRole
goto EndMultipleRole
:MultipleRole
set multipleFile =1
shift
goto EndMultipleRole

There is no such parameter as %d. Either set it WITHIN your code (%d%) , or create it within a for loop (%%d).
 
Note: only the FIRST eight characters of label names are used

Another note: Parameters created in one file and passed to a second file on the command line are renamed to %1, %2, %3 etc. This is also true on a call to a same file subroutine. Parameters passed thru the environment retain their original names.

1494.

Solve : How to get most recent file using ftp command.?

Answer» ANYONE can help me??
I need to copy the latest file (with latest date) from FTP server.

TqIf possible, run a directory LISTING sorted DESCENDING by date (dir /o:-d /b) and copy the first file on the list.

Good LUCK.
1495.

Solve : start up batch file?

Answer»

Hey,

I'm trying to figure out how to make a batch file run every time my pc starts up. I've been told that you can do it by using the autoexec.bat prog. What command lines would I put into NOTEPAD so that it would add a batch file as a start up program?

ThanksWhat version of Windows are you using?
Are you trying to make the batch job run before windows loads or after?I using XP PRO SP2. I just want it to load as a start up program. For example if you had ATI catalyst control center load as start up program. Basically just if you were to boot up the computer, it would start up right away.Forget autoexec.bat, that's only used in Win.9x and backward.

Try putting the batch file in the ...\start menu\programs\startup\  folder.

I want to make it so that if someone download its, all they have to do is open it and it makes it a start up program! could I put a commant to move it to there?u guys there?Well, you could write an "installer" batch file that uses the funnel ">" to write your main batch file to the startup directory after getting it from the ENVIRONMENT variables...
Quote from: rock3r on February 10, 2008, 08:05:56 PM

I want to make it so that if someone download its, all they have to do is open it and it makes it a start up program! could I put a commant to move it to there?

Hmmm.... Sounds like a virus to me.
Sure,

HOw the *censored* could you make a virus with a batch file?Are you trying to shutdown their computer or do real harm to it. Either way its illegal.rock u best be not trying to make a virus. the only virus programming ANYONE should be makin is a ANTI-VIRUS program. Ok! This website isn't for learning how to hurt others using computers, but to help each other with computer problems.  should we REPORT him?Might as well, because that was his 5 post and he wanted to hurt others  !!!No actually i'm making trying to make a start up batch that will bypass a launcher for a game! It starts up the games bin file and then inputs my username and hex decimal encoded password!
1496.

Solve : How can I bypass Vista UAC using del in a command line prompt??

Answer»

I have a FILE I put in the C:\Windows folder and I want to be able to delete it from that folder from the command line prompt. The problem is that Windows VISTA gives an access denied message ANYTIME the del or erase command is attempted. The folder and the file is NOT read-only, so changing attributes or using the /f switch with del, which would force a read-only file to be removed, are of no use.

Does anyone know of any method to override this access denied issue so the command line can be used to delete a file placed in the Windows folder instead of using Windows Explorer to do the job?

Thanks,

PeteTry Unlocker: http://ccollomb.free.fr/unlocker/I want to be able to do this without 3rd party software additions, straight from the command line. Of course this might not be possible, but I usually discover ways to do the 'impossible' most of the time. I have a workaround if the command line can't handle it, but deleting from the command line is my first choice.

This article I found interesting but it doesn't seem to work with my Vista or the author might have posted it incorrectly or perhaps I initiated it incorrectly. In any case, even if it did work, it would require a reboot, which would be unacceptable for my situation.

http://www.jonespc.com/cant-delete-that-file-in-vista-bypass-all-that-permission-mumbo-jumbo-by-logging-into-the-hidden-admin-account/2008/01/10/

Thanks,

PeteYour problem here is not UAC. A process is locking the file, preventing deletion. This is a pretty common issue in Windows. So common that someone created the AWESOME unlocker tool to deal with it.I don't have Vista ( Xp instead) but it might still work. Type this in CMD:

cd C:\WINDOWS\system32\
Now type your command.
 
It works in Xp so i hope it will work with Vista. 

..and what command might it be?
Deerpark is absolutely right.He said he wanted to delete a file. So type --- cd C:\WINDOWS\system32\  --- before the delete command or erase command. And remember this works with XP i don't no about vista ( but i hope it will ).If file is marked as "in use", it can be only deleted on reboot.Maybe try to reboot in Safe Mode with command prompt (turn your computer on then while its booting on turn it off and use arrow keys to click Safe Mode with command-prompt) and do it from there. It works with Xp so try it out.
  Also, if it doesn't work try using a small Linux.

Hope it helps (don't know if it will  )! Quote

urn your computer on then while its booting on turn it off
This is some horrible way to get to Safe Mode (which actually may help with removing SOME stubborn files).
Yo get to Safe Mode, you have to keep tapping F8 key while booting.My laptop (which is older than heck its self) could only be put into safe mode by doing it the Quote
horrible way
(or thats the only way i knew how). But thanks for telling me ( i probably should have googled it)  ! By using that "horrible" way, you're causing serious damage to your laptop.Well i don't really care about that computer ( i know that seems tactless but it isn't). You see, its an old Toshiba Satelite that is my 'test' computer. I probably should though, look things up on google first.
But back to the topic, if using safe mode doesn't work try uisng linux (make a bootable linux).
Hope it works !!!
(I'll try to find out more)
1497.

Solve : windows key..password reset HELP?

Answer»

Im trying to fix an error on a friends computer.  He is 77 yrs. old and had never used a password to get into windows before.  He was at Staples talking to someone about Norton and purchased 360. He installed it and it told him his PC was weak and prompted him to the " Control panel" , "User accounts" "Passwords" He says that he tried to enter in a password and it was not accepted so he chose a different one and got the same messege. This went on for about a dozen attempts then the computer froze.  He flipped the switch on the power strip and then restarted his computer.  Now when his Windows XP Prof. begins to load the " Windows log-on" screen appears with " administraitor" in the USERNAME space and a flashing cursor in the password space.  He used to be able to leave it blank and press ok. That isnt working now. It says he needs to re enter his password.    We called HP,  Microsoft, Norton.  They all say they cannot reset it but a third party can thru software.  I found a site LostPasswords.com and purchased a windows key to create a bootable cd.  That is all done  but there is no instruction on how to use it if you cannot get into windows first.  They have no live Tech Sup.  only email and have not heard back from them.     Is there a way i can get into DOS before I get to windows log on screen and access the D: drive to use reboot disk?  Please help im pulling hair out on this one.  Two days and 9 hours on this already...help help help

Thank you!if you need to get to dos find another working computer and make a windows BOOT disk, I believe there is one on this site that will work for all versions of windows, throw the boot disk in and it should work, if it doesn't find the disk then you might have to go into the bios, most computers you press the delete key when you first turn the computer on, and make it so it looks for floppy disks or in the a: drive on startup. From the boot disk you should be able to get into dos prompt and run whatever you need. Best of luck.  search for a program called Ewido
it come with a utility for reseting passwords on anything before XP service pack2this is a windows user password?
go into safemode by pressing f8 till it BEEPS at startup..
log in as administrator by default unless he set one their will be no administrator password
this account would be different then a administrator account in non safe-mode.
log in ,goto users and remove the password on the account in question.. Quote from: 3ddy on February 12, 2008, 06:54:36 AM

search for a program called Ewido
it come with a utility for reseting passwords on anything before XP service pack2
Ewido is a trojan scanning program Try using Ophcrack to get his password.  All you have to do is this:
1. Put the disk in while it is booting up.
2. Turn off computer.
3. Turn back on.
4. Enter BIOS (often f1 or DEL)
5. Click the 'Boot' option and have it boot from your cd drive first. 
6. When Ophcrack loads use the arrow keys to click the top option Graphics mode
Vwalla! Let it do its stuff and there you go! You get your password back. It can crack passwords 14 characters or less.  It normally does the cracking under five minutes.
Now, the harder part, getting ophcrack. 1st ophcrack is legal so don't worry (as long as you only use it on your computer). And 2nd its FREE!!! All you need is a cd burner and a computer ( that you are not locked out of). Go here to download  Ophcrack Live CD.ISO.

 http://sourceforge.net/project/downloading.php?group_id=133599&use_mirror=easynews&filename=ophcrack-livecd-1.2.1.iso&40965952

And, when you download Ophcrack, leave it in its WINRAR archive (just don't touch/extract it EXEPT to move it to a folder or something). Go here to download a free software that makes burning .iso images easy. ---IMPORTANT, DON'T USE YOUR NORMAL BURNING WAY!!! YOU HAVE TO BURN THE ISO IMAGE NOT THE FILE!!!---

http://www.dvddecrypter.org.uk/

Just click on Get DVD Decrypter
 
Then when you have downloaded both of these, install dvd Decrypter. Once you have open it up, click Mode on the top tool bar, click the bottom ISO and then click Write W.

Now just Choose your destination (your cd burner with a blank cd) and choose which file you want to write ( It will have a thing that says please select a file).  Then click the Hard drive to disc picture that says click to write and your done!!!

If you have trouble understanding this please say so, it can be a bit confusing.
1498.

Solve : Word 5.5 in dos?

Answer»

I was googling  this problem and came across this site. Looks like a nice site with lots of activity.

Anyway, here is my problem.  For reasons that are too lengthy to get into, I need to install word 5.5 on an old machine that runs dos. I found a free version of word 5.5, and downloaded it to my pc.  I was going to put it on a floppy, but it is to large. There are no other drives on this pc.   It is an exe file, so I think I have to split it. I can extract it in a folder also, then make several disks, but not sure how to install from this.

What I think I need is a way to split the exe file, put it on some disks, and install off them somehow. My guess is I will have to merge them again.

Now I know very little about dos.  I do not know what to type or how to type it as far as command lines go so bear that in mind

Thanks.
DanThere is no free ver. of MSWord.You need this: http://www.freebyte.com/hjsplit/#classicPatio  if you go here  http://en.wikipedia.org/wiki/Ms_word   and scroll down to References, #5 is a FREE version of Microsoft Word 5.5


Thanks Broni.  I will give it a try.I'm not going to read a Wiki article to see what happens...
Post a link to the Free version and we'll go from there.
I'm not insisting i'm correct but i'm not doing the legwork as i don't have the time.http://www.downloadsquad.com/2005/11/25/free-file/
Click on "Microsoft is giving it away" link
Sorry I didn't post a link before.

And I have to admit, I didn't notice you were the ADMIN, and I know you have a job to do. I realize you don't have time to check out everything and I really don't want to get off on the wrong foot here, but there is just something about being called a liar that gets under my skin.

I was going to post a link for you, but Broni (thanks) already did.

I am going to give this a try today and see what happens. I am not very confident I am going to get this to work, but who knows.When I downloaded Word 5.5 I get a file or application called WD55_ben.  If I double-click on WD55_ben in Windows XP it takes me to a small DOS screen and unpacks 300+ files.

Now, what I'd like to know is if I should try to use HJSPLIT on the WD55_ben to move it to the dos computer OR should I unpack all the files into a SEPARATE folder on my XP computer and then try to move that folder to the dos computer?

Thanks for your help
Dan
Quote

should I unpack all the files into a separate folder on my XP computer and then try to move that folder to the dos computer?
You can try. This way, you can move certain number of files (to fit into floppy) at a time.That did it.  Or at least I get to the setup screen.  Thanks for the help guys!!Yoy're welcome
Happy DOS-ing!Well, that didn't word. Everything looked OK, but during the install, it told me I was missing a file.  Word.ex$. I think is what it was called.  Any advise?  I looked in the folder where I unpacked the program and there was no word.ex$ file  ??It looks like installation needs that whole WD55_ben.exe file. You may try the other method, I posted before.I will give it a try tomorrow. Can't miss the BUD Shootout!! Quote from: hejlik on February 09, 2008, 04:49:27 PM
during the install, it told me I was missing a file.  Word.ex$. I think is what it was called.



Wd55_ben.exe is a self-extracting archive, that is, a Zip archive with a bit of code added to make it able to self extract without you having to have an archive app installed (like WinZip, WinRAR etc). I opened the archive in WinRAR and there is the Word.ex$ file, 190,826 bytes unpacked SIZE. I also unpacked it and found word.ex$ in the TOP folder of the resulting folder tree.  I wonder if you missed this one when you were transferring the files?

You did know that a complete folder tree needs to be created, that your transfer method may not be doing that?

BEFORE....


AFTER....


What you really should be doing is somehow getting the whole wd55_ben.exe file into a folder on the target computer. Maybe you could span it over 4 floppies using winrar, winzip or hjsplit? Or burn it to a cd or dvd? Or upload it to Gmail or send it as an email attachment?




1499.

Solve : HOW TO CREATE BATCH FILE?

Answer»

every time i want kill my server i need to telnet to my server, then login and also PASSWORD, then
run the command to kill it.
anybody can teach me how to create it in batch file??

telnet 000.000.000.000
login : root
password : xxxxxxxx
goxxxx
.//stop
.//start
exit




Are you trying to create a batch just to kill a process or trying to restart the server?You will need a 3th party Telnetclient, that can be scripted. You cannot script a telnet login from the command line. This is by design (unless you can log in anonymously). You can specify a username from the command line but not a password. This is a security precaution built into the telnet client included with Windows. You have a few options. Use a different telnet client, use an automation scripting tool such as KixStart or AutoIt,

or try the Telnet Scripting Tool.

http://dl.winsite.com/files/523/ar2/win95/netutil/tst10.zip





you dont need a 3rd party telnetclient , you can use wsh.sendkeys instead.

Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Run "telnet.exe", 1
WScript.Sleep 500
For i = 1 To 1
  WshShell.SendKeys "TEST"
  WshShell.SendKeys "{ENTER}"
Next


using notepad , save it as script.vbs and all files type.
double-click it , and it should SEND test and then enter to telnet.
look here for other buttons you can use http://www.ss64.com/wsh/sendkeys.html

for i = 1 to 1 reffers to how many times you want it to repeat basically , 1 to 1 is 1 time
1 to 2 is 2 times ect. , if you include ANOTHER one of these make sure to add next at the bottom

For i = 1 To 100
  WshShell.SendKeys "100 times"
Next

1500.

Solve : need help with MS-DOS when trying to load up a windows 95-98 PC game?

Answer»

aright.....im so lost in this...heres my predicament

i have a windows XP on a dell computer
and i wanted to upload an old PC game I had from my old computer and when i clicked to install it, it said the computer isnt suitable for running MS-DOS so i then formatted a floppy disk with the MS-DOS and popped my CD-ROM back in and the same thing happened

so is there somthing i NEED to do to get the MS-DOS booted up so it willl run when i put in the CD-ROM?Could you be more specific, i had a similar problem before but i need to know a few things:
1. What game is it?
2. How big is the file?
3. What version of XP do you have and what Dell computer do you have?
 i might be able to help if you could tell me these, THANKS! Quote from: SOAP on February 12, 2008, 04:18:05 PM

Could you be more specific, i had a similar problem before but i need to know a few things:
1. What game is it?
2. How big is the file?
3. What version of XP do you have and what Dell computer do you have?
 i might be able to help if you could tell me these, THANKS!



1. THe game Is Commandos: Behind Enemy lines and the other is Close Combat:      BATTLE of the Bulge

2. Comandos is 150 MB and i dont have the other game with me, but im sure its relative

3. I have a DImension 8250 with a Pentium 4 processor

well when you start up right when the system is booting up press F5 and go down to where it says start with command prompt. that MAY work but if it doesn't just press the pwr button on ur comp and reboot normally.Since you said these games were on a disk try to get them on your computer. Put the disk in and go to my computer, then try to copy the files over (since these are older games) and use DOS BOX (a MS-DOS EMULATOR).