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.

6351.

Solve : Concatenate Path (in quotes)and file name?

Answer»

Hi,
I want to BUILD a VC8 soultion from command-line by devenv. I have a path to the solution like
set SOL_PATH="C:\myStuffs\myproject\win\build"

and then I am doing a PUSHD to "C:\Program Files\Microsoft Visual Studio 8\Common7\IDE"

now when i say
devenv %SOL_PATH%\a.sln /build "Debug"
devenv cannot find path to a.sln.

This is because %SOL_PATH%\a.sln evaluates to "C:\myStuffs\myproject\win\build"\a.sln which devenv doesnt understand.

However if I write
devenv "C:\myStuffs\myproject\win\build\a.sln" /build "Debug"
it works fine.

I am looking for a solution to concatenate the path with the filename, and such that "C:\myStuffs\myproject\win\build"\ + a.sln becomes
"C:\myStuffs\myproject\win\build\a.sln". In other words, the filename comes inside the QUOTES too.

Please help.
thanks,
-manirupIt might be easier to use the old 8.3 notation:

set SOL_PATH=C:\myStuffs\myproj~1\win\build

8-)Thanks for the suggestion. But I dont know what the directory name would be. I dont want the path to be hard coded. xxxxx~1 does not suffice because it can be ~2 or ~3 and so on... and you cannot assure that ~1 will work fine..
Quote

It might be easier to use the old 8.3 notation:

set SOL_PATH=C:\myStuffs\myproj~1\win\build

8-)

You can discover for yourself the correct name by running a directory list on the parent directory:

dir /x C:\myStuffs

OR

Use your original method but APPEND the quotes on the program call:

set SOL_PATH=C:\myStuffs\myproject\win\build
devenv "%SOL_PATH%\a.sln" /build "Debug"

8-)


Thanks...
That was a nice solution indeed... I never thought in that direction... apending the quotes on the program call solves my problem... So simple... thanks again to sidewinder
-manirup

Quote
You can discover for yourself the correct name by running a directory list on the parent directory:

dir /x C:\myStuffs

OR

Use your original method but append the quotes on the program call:

set SOL_PATH=C:\myStuffs\myproject\win\build
devenv "%SOL_PATH%\a.sln" /build "Debug"

8-)


manirup,
You will never have this problem when you work without quotes until you need them. I.e.:

CODE: [Select]set SOL_PATH=C:\myStuffs\myproject\win\build
PUSHD "C:\Program Files\Microsoft Visual Studio 8\Common7\IDE"
devenv "%SOL_PATH%\a.sln" /build "Debug"
Hope this helps
6352.

Solve : Run Batch without command window popping up??

Answer»

Hello all,

Is it possible to run a batch file and not have the command window appear, and without using the Windows scheduler?

WinXP

THANKS!
BryanFrom the Start==>Run box you can use:

start /min path\batchfile.bat

Batch files are INTERPRETED by the CMD processor so you at least need an instance running to execute your batch file.

8-)Thanks for the tip.
BryanCorrection:

The START command cannot be run from the Run box. You would have to SHELL out to the processor and start the batch file. Also necessary to include the exit instruction in your batch file.

Ex. In the run box:

cmd /c start /min path\batchfile.bat

Sorry if you were mislead.

6353.

Solve : SET yourname??

Answer»

Is there some way I could have a batch file echo "type your name" and then in another PART of the BATCHFILE it WOULD fill in thier name?:
Code: [Select]@echo off
echo Type your name:
pause
Hi, %yourname% ???????????????????????????????????????????????????????????????????????????????????????????????????You can use this:Code: [Select]@echo off
set /p Name=Type your name:
echo Hi, %Name%thanks, but wat does the /p do?I also figured out this code:
Code: [Select]@echo off
set /p g1=Type a girls name:
cls
set /p g2=Type another girls name:
cls
set /p g3=Type one more girls name:
cls
set /p b1=Type a boys name:
cls
set /p b2=Type another boys name:
cls
set /p b3=Type one more boys name:
cls
set /p l1=Type something you can do to a lemon:
cls
set /p L2=Type something else you can do to a lemon:
cls
set /p l3=Type one more thing you can do to a lemon:
cls
set /p bp1=Type a body part:
cls
set /p BP2=Type another body part:
cls
set /p bp3=Type one more body part:
cls
set /p p1=Type a place:
cls
set /p p2=Type another place:
cls
set /p p3=Type one more place:
pause
cls
echo %b3% and %g2% are %l2%ing each others %bp3% in the %p2%!
pause
cls
echo %b1% and %g3% are %l3%ing each others %bp2% in the %p1%!
pause
cls
echo %b2% and %g1% are %l1%ing each others %bp1% in the %p3%!
pause
cls
echo hahahahahahahahahahahahahaha
pause
exitExcept how could I make it match up randomly like the highlighted area:
Code: [Select]@echo off
set /p g1=Type a girls name:
cls
set /p g2=Type another girls name:
cls
set /p g3=Type one more girls name:
cls
set /p b1=Type a boys name:
cls
set /p b2=Type another boys name:
cls
set /p b3=Type one more boys name:
cls
set /p l1=Type something you can do to a lemon:
cls
set /p l2=Type something else you can do to a lemon:
cls
set /p l3=Type one more thing you can do to a lemon:
cls
set /p bp1=Type a body part:
cls
set /p bp2=Type another body part:
cls
set /p bp3=Type one more body part:
cls
set /p p1=Type a place:
cls
set /p p2=Type another place:
cls
set /p p3=Type one more place:
pause
cls
echo %b3% and %g2% are %l2%ing each others %bp3% in the %p2%!
pause
cls
echo %b1% and %g3% are %l3%ing each others %bp2% in the %p1%!
pause
cls
echo [highlight]%b2% and %g1% are %l1%ing each others %bp1% in the %p3%![/highlight]pause
cls
echo hahahahahahahahahahahahahaha
pause
exitHow could I make it so that it's not always %b2%, %g1%, %l1% %bp1% and %p3% matching up with each other???

6354.

Solve : Change BIOS Logo?

Answer»

Dear Members,

My question related to logo appeared when computer START (TURN on), can I change it? If YES please how.

AfifiTECHWhat computer or motherboard make/model, what BIOS, etc.?

See below.Thanks for your replay, regading to motherboard model its "PCPartner", can i change BIOS Logo

AfifiTECHWhich Bios and Version do you have?
Ami, Phoenix ...?

uliQuote

Thanks for your replay, regading to motherboard model its "[highlight]PCPartner[/highlight]", can i change BIOS Logo

AfifiTECH

I have never HEARD of a PCPartner motherboard. Try running Belarc Advisor (FREE at www.belarc.com) and find out the make and model of the motherboard.U can use this for only "AwardBIOS" (all required info is in...) but is not english

http://www.free.of.pl/b/blackware/blc.exe

or

http://www.softpedia.com/get/Tweak/Video-Tweak/NVIDIA-BIOS-Editor.shtml
6355.

Solve : Access to HDD after booting from floppy??

Answer»

I am trying to set up an OLD 486 Acer pc for some equally old DOS based games. I thought I had enough patience to wipe all the dust, and then this came out almost inmediately: Just after getting the A: prompt, my first impulse was to type C: and all I get is a "Invalid Drive Specification" message. Isn't it supposed that the BIOS should "build" the required paths so that the operating system has access to this drive? What MUST be there in the boot FLOPPY disk to make sure I will be ABLE to change the path to the hard drive after booting from floppy?

:-?Check the BIOS if the HD is known.
If yes
Start Fdisk and check the Partitions.
(Delete them if there are some).
Then make Partition(s) with Fdisk and format it.

hope it helps
uli

6356.

Solve : Question on IF command?

Answer»

can i have a IF statement follow with 2 process after the IF? EXAMPLE like
IF EXIST c:\TEST.txt rmdir c:\abc xcopy c:\def c:\abc
is this working?Quote

can i have a IF statement follow with 2 process after the IF? example like
IF EXIST c:\test.txt rmdir c:\abc xcopy c:\def c:\abc
is this working?

you could actually test your commands out and verify for yourself...
you can also use the & operator.
eg if EXISTS &
There are several ways you could have an IF statement follow multiple processes. Here are some examples:
Code: [Select]if exist c:\test.txt rmdir c:\abc&xcopy c:\def c:\abc\
Code: [Select]if exist c:\test.txt (
rmdir c:\abc
xcopy c:\def c:\abc\
)
Code: [Select]if exist c:\test.txt goto :Label1
rem more code here if necessary
goto :EOF
:Label1
rmdir c:\abc
xcopy c:\def c:\abc\thanks all...
6357.

Solve : Installation of DOS 4?

Answer»

I am TRYING to install DOS 4 on one of my COMPUTERS so I can install Windows 3.0...
The problem is this:
During the installation, you need a "select copy" disk...
This requires a 720KB disk. I have tried to format a 720KB disk, but it still gives me the "Defective Diskett" ERROR message.

Any idea why?

I use Windows 98 to format the 720K disk, and it doesnt work at all. My disks are not all defective...

What is the command in DOS to format a disk to make it a 720K disk?

format (and the syntax for Drive A)Try:
Code: [Select]Format a: /f:720
If you don't have any 720k FLOPPY disks, you can try "tricking" your computer into thinking one of your 1.44 MB floppy disks is 720k by covering up the hole that is not the write protect hole (so that both holes are covered).

6358.

Solve : help with iplist batch file?

Answer»

I want a batch file that will make a list starting at 0.0.0.0 and ending at 255.255.255.255 but when one # hits 255 it needs to ADD 1 to the # on its left? this WOULD make a list of all posible ip address is this corect or would it leave some out?Quote

this would make a list of all posible ip address is this corect or would it leave some out?

A correctly written batch file would indeed cover all 4,294,967,296 of them.

Code: [Select]@ECHO off
set octet1=0
set octet2=0
set octet3=0
set octet4=0

:loop
set /a octet4=%octet4%+1
if %octet4% GTR 255 (
set /a octet3=%octet3%+1
set octet4=0
)
if %octet3% GTR 255 (
set /a octet2=%octet2%+1
set octet3=0
)
if %octet2% GTR 255 (
set /a octet1=%octet1%+1
set octet2=0
)
echo %octet1%.%octet2%.%octet3%.%octet4%
if %octet1%.%octet2%.%octet3%.%octet4%==255.255.255.255 goto :eof
goto loop

Why anybody would need such a thing is beyond me, but hey what do I know :-?
Hey sidewinder, I've always wanted to know, what do "(" do in a batch file???that was like the solution i FOUND, i was just wondering if it would get all of them.Or SIMPLY:

[edit]for /L %%a in (0,1,255) do (
for /L %%b in (0,1,255) do (
for /L %%c in (0,1,255) do (
for /L %%d in (0,1,255) do (
echo.%%a.%%b.%%c.%%d
))))[/edit]

dakota,
If you plan to ping all IP addresses and let's say a single ping takes 1 second and you start your batch script today ([timestamp=1155103143]) then the script will finish on 9/15/2142 which is a Saturday
HAHAHAHAHAHAHAHAHAH
Yes, I think he is/was planning to ping them!!
6359.

Solve : workgroup ??

Answer»

what command can i find out my workgroup ?This MAY WORK on a workgroup network:

net CONFIG workstation

8-)

Note: SHOWS up as workstation domain

6360.

Solve : # of dir's?

Answer»

I want to get the NUMBER of dirs in the current directory that I am in but here is my PROBLEM somtimes there will be a . and a .. in the numbers of dirs so i want to know the number of dirs not counting the . or the .. if they are there. Think you any help is appreciated

dir /A:d | FIND / v /c "#~#"

counts the directories

hope it helps
ulidir /AD | FINDSTR /R /V "\.\>" | find /c ""think you

6361.

Solve : MS Dos Small Program Help?

Answer»

Hi i'm CONSTRUCTING a program that deletes MP3's, WAV's etc from a particular drive.
WHat i want it to do is export what it has deleted to a txt document can you ADVISE the write code to use please this is what i have so far:-

Color 1F

cls

@ECHO Deleting The Following File Types From The Students Home Drives:-
@ECHO MP3, WMA, WAV, EXE, WMV and CDA

@ECHO This Program Will Loop Until Closed

@ECHO OFF
:Start

Start
del /s /q /F Z:\*.mp3
del /s /q /f Z:\*.wma
del /s /q /f Z:\*.wav
del /s /q /f Z:\*.exe
del /s /q /f Z:\*.wmv
del /s /q /f Z:\*.cda

:GOTO Start

:END

EXIT

any help appreciated

Richdel /s /q /f Z:\*.mp3 >>log.txt

should do the job.

hope it helps
uliyou got to modify a bit

Code: [Select]for /f "delims=" %%a in ('dir /s /b /a-d z:\*mp3') do (
del /f %%a
if %errorlevel% EQU 0 echo %%a deleted >> output.txt
)

Do the same for the rest of the file typesthanks, so will this replace or just add to the file for successive file types if repeated?

regards

Richard DaleQuote

thanks, so will this replace or just add to the file for successive file types if repeated?

regards

Richard Dale

using >> will append your results to the output file.for /R z:\ %%a in (*.MP3 *.WMA *.WAV *.EXE *.WMV *.CDA ) do (
del /f %%a
)

does all filetypes in one loop recursive.
(The if statement doesn`t work on my NT4 machine in a for loop.
Seems that I have to call a procedure)that program just deleted everything of my hardrive

Richwow...always do a test first before using del /fQuote
that program just deleted everything of my hardrive

Rich


Strange.
I did a test (with echo); it echoed only the SAID filetypes.

uliQuote
Quote
that program just deleted everything of my hardrive

Rich


Strange.
I did a test (with echo); it echoed only the said filetypes.

uli


probably substitued the "z:\" for "c:\"
6362.

Solve : "(" in a batch file!?

Answer»

What do brackets do in a batch file??Have you lost your Google finger :-?

Here is just one example (scroll down to the MDEL.BAT listing.)

Good luckThe parenthesis '(' and ')' serve different functions depending on where they are used. The most common example I can think of is to group COMMANDS or statements together. Take the following example:
Code: [Select]if ERRORLEVEL 1 (echo There was an error.
echo The ERRORLEVEL is %errorlevel%.
goto :EOF) else echo There was not an error.Typically, when a batch file processes an IF statement, and the IF statement is TRUE, then it will excute 1 command on the same LINE as the IF. Since we have 3 statements surrounded in the parenthesis, it will group them together and execute all 3.
Compare to:
Code: [Select]if ERRORLEVEL 1 echo There was an error.
echo The ERRORLEVEL is %errorlevel%.
goto :EOFIn the 2nd example, the LAST 2 lines of code get executed even when the IF statement is FALSE.

Does that explain it?
yes thnx














































































































































































6363.

Solve : Verfiy DOS Copy?

Answer»

Is there a way to verify a file that was COPIED USING the COPY command

If there is a way what does it verify

File SIZE?
File existance?
etc?

How do you verify a file thhat was just copied?you can check for error using errorlevel, or use the fc command

6364.

Solve : Find string?

Answer»

I figured away around another ISSUE, and this should be simplier.

I am wanting to compare 2 text FILES, each one being on a different directory, each text file will have the word "version" followed by a space and a number like "Version 1"

How would you compare the 2 files together for the same text in an else statement?for COMPARING files , you can use FC command

6365.

Solve : How to force a particular dateFormat for batch.?

Answer»

Hi there:
Is there a MS-DOS command which I can insert into my batch file for
specifying a particular date format to be used during my batch
execution?

The format I would like to use in my batch execution is like this:
Sun 2006/06/25

Currently it defaults to 2006/06/25 (i.e the short date as
pre-specified in my "Regional and Language Options"). But what I would
like to ACHIEVE here is to force a particular date format regardless of
what the "Regional and Language Options" says).

APPRECIATE your help.

Regards,
-David-

So you dont want current date or time? If you want a set date why dont you just echo the date? If you want the current date put

Code: [Select]current date: %date%Hi [emailprotected]:
Thanks for getting back to me.

You are RIGHT, I don"t want the %Date%, as it returns a date format that is not friendly to my batch exe. A %Date% entered on my workstation (running on MS Windows XP Pro) would return a date format of "2006/06/26", but my batch file expects it to return a format of "Mon 2006/06/26" instead.

Here's my batch code:

REM This batch file assumes a standard workstation date format of
rem dayOfWeek yyyy/mm/dd.

for /F "tokens=1-4 delims=/-. " %%i in ('date /t') do (
set DOW=%%i
set MM=%%k
set DD=%%l
set YYYY=%%j
set FDate=%%i %%j/%%k/%%l
set ymd_dt=%%j%%k%%l
set ymd=%%j%%k%%l
set ymd_fmt=%%j/%%k/%%l
)

@echo.
@echo hello David!
@echo This batch file assumes a standard workstation date format of
@echo dayOfWeek yyyy/mm/dd (eg. Sun 2006/06/25)

@echo.
@ECHO Date is %Date%
@ECHO Day of Week is "%DOW%"
@echo Month is "%MM%"
@ECHO Day is "%DD%"
@echo Year is "%YYYY%"
@echo fdate is "%fdate%"
@echo ymd_dt is "%ymd_dt%"
@echo ymd is "%ymd%"
@echo ymd_fmt is "%ymd_fmt%"
@echo.

pause ** press any key to continue **

:finish

A command or something to pre-specify the dateFormat used in an execution would certainly help.
Any thoughts?

Regards,
David.check out this site
http://www.commandline.co.uk/lib/

6366.

Solve : Label Issue?

Answer»

I FINALLY got my batch file to WORK on my pc at home, brought it to work and I ran into a slight issue.
I have got a GOTO COMMAND at the begining of my code and it works if you change what its refering to with no problem. The problem is at the end where the labels reside

I have got at the begining
if not exist Z:\dcal1 goto LostDrive

This is a few lines down
if not exist Z:\dcal1 goto NoDrive


and at the end of my code I have

:NoDrive
echo my message
goto end
:LostDrive
echo my message
:End
Exit
for some strange reason when it gets to the end its readng the label and prompting the message.
I have moved the labels around, and whatever is at the top is where it starts

The colon should keep it from running RIGHT?

Confused!
Prompting what message? I don't understand the problem, but maybe try this instead:

Code: [Select]:NoDrive
echo my message
goto :EOF
:LostDrive
echo my message
goto :EOF

6367.

Solve : catching control characters?

Answer»

HI

Is it possible to catch the control characters like ctrl-D or ctrl-C in the batch file.

Thanxgive an example of what you wanna do...1. I need to do telnet in a batch file just for validation and invoke some 'X' application

2. I can't use languages like perl/vbscript/python/java, except DOS batch script

3. while doing telnet in the batch file if the user types ctrl-D, it is COMING out from the telnet session and
PROCEEDING further. So, if I can suppress(unset) ctrl-D then user can't escape the telnet authentication.

4. User to successfully login to the telnet session then only he can PROCEED further in the batch file.

5. EXAMPLE:

@ECHO OFF
telnet
ECHO %ERRORLEVEL%
pause

...
Actually I am a UNIX guy, I am not familiar with DOS. Please suggest me some ideas keeping in view of my
limited resources.
Thankx
Quote

1. I need to do telnet in a batch file just for validation and invoke some 'X' application

2. I can't use languages like perl/vbscript/python/java, except DOS batch script

3. while doing telnet in the batch file if the user types ctrl-D, it is coming out from the telnet session and
proceeding further. So, if I can suppress(unset) ctrl-D then user can't escape the telnet authentication.

4. User to successfully login to the telnet session then only he can proceed further in the batch file.

5. EXAMPLE:

@ECHO OFF
telnet <host name>
ECHO %ERRORLEVEL%
pause
<invoke some X application>
...
Actually I am a UNIX guy, I am not familiar with DOS. Please suggest me some ideas keeping in view of my
limited resources.
Thankx


1) when you say invoke 'X' application, is 'X' at remote or local?
2) how restricted are you? you can't run WSH/CSRIPT (vbscript) even?
3) u can try setting your batch to telnet to server using automatic login (-a) or (-l)
eg telnet -a host , or telnet -l username host
If all else fails, you can try ftp login using the -s option , if the user has supplied the correct credential and password, he can continue.


Thanks ghost

I can use wsh/cscript. Could U provide me a working example. Inside the script, I just telnet to a Unix server and EXIT from the telnet session and invoke some 'X' application which is a local one NOT a remote one.

The reason for telnetting is just to validate the Unix login. If his password expires, it will force and he can change the password at regular intervals.

ThankX again for ur prompt response.don't know whether it works. you can try it out
http://sourceforge.net/projects/telscript/
6368.

Solve : suppressing password in telnet batch file?

Answer»

Hi
I wrote the following telnet batch file, it is WORKING fine BUT it is DISPLAYING the password on the screen. How to suppress it.

@echo off
echo set sh=WScript.CreateObject("WScript.Shell")>telnet.vbs
echo WScript.Sleep 500>>telnet.vbs
set /p userid=Enter User Id:
set /p password=Enter PassWord:
echo sh.SendKeys "%userid%">>telnet.vbs 'USERID
echo WScript.Sleep 500>>telnet.vbs
echo sh.SendKeys "~">>telnet.vbs
echo WScript.Sleep 500>>telnet.vbs
echo sh.SendKeys "%password%">>telnet.vbs ' PASSWD
echo sh.SendKeys "~">>telnet.vbs
echo WScript.Sleep 500>>telnet.vbs
start /realtime telnet.exe
C:\WINNT\system32\cscript.exe //nologo telnet.vbs
del telnet.vbs

Thanxcls ? right after the pass is displayed ? where is the pass displayed ? top, bottom...do some rearrangingAt the statement set /p password=Enter Password:I'm not aware of any batch method to suppress a password. But since you're using VBScript anyway, this MAY work:

Code: [Select]Set objPassword = CreateObject("ScriptPW.Password")
WScript.StdOut.Write "Please enter your password:"

strPassword = objPassword.GetPassword()
Wscript.Echo
Wscript.Echo "Your password is: " & strPassword


Not all WINDOWS versions ship with a ScriptPW.Password object. If not, there is a way to do this with IE. Let US know. 8-)

6369.

Solve : Having Problem FDISK with newly built system?

Answer»

I have rebuilt a system but I have 2 problems. I'm sure one is easy to fix but the other I am totally confused. First I have a DIFFERENT hard drive in there now and I tried to format using the software from the manufacturer but it wont boot from the CDROM so I decided to go into the BIOS and change the sequence so it will boot from the CD.....BUT..... here's my second issue....when I get to the BIOS, the main PAGE for the motherboard comes up with no problem until I decide to hit enter or something then it askes for a user password. I have no idea! I checked and its a 3rd party password so I cant override it and I cant contact anyone because I DONT know built this system originally. Can anyone tell me how to bypass the password, (I can do sequence in DOS) and last how do i change the drive VALUE again in DOS? so that I can run fdisk... Thanks :-/Sounds like you have a BIOS password set. You can probably clear the BIOS password by changing a jumper position, or by removing the computer battery for a minute or so.If I remove the battery, dont I have to reset the CMOS or realtime clock? I dont know how to do that yet. It will revert to defaults, which you can then change. The clock is easily set in the BIOS. You may have to leave the battery out for 10 minutes or so.

As for using FDISK, if you have XP you shouldn't need that. Just boot with the XP CD. Disk partitioning tools are available, once you solve the other problems so you can boot from CD.And from our vast resources an FDisk simulation page

http://Here

patio. 8-)

6370.

Solve : Compare file date-stamps in a batch file?

Answer»

I have an Excel application with which the user runs a batch file that copies a template from a server to their local drive and then opens the file. I would LIKE to add funtionality that would CHECK the file on the server vs. local disk and if there was no change I would skip the copy function.

Any suggestions would be appreciated.

Thanks,
Joseph [smiley=vrolijk_1.gif]The XCOPY command has that functionality built-in. You can compare the timestamps MANUALLY if you want, but I would use XCOPY to do the work like this:
Code: [Select]xcopy \\Server\Share\Template.xls C:\Local\Path\ /D /YThat should copy the Template.xls file to C:\Local\Path\Template.xls, but only if the network version is newer (or the local copy does not yet exist).Perfect! (and simple)

Thank you,
Joseph [smiley=grin.gif]

6371.

Solve : what is a dos?

Answer»

plz GIVE me answer
what is a dos?At its simplest, the letters dos mean disk operating system

So, it is an operating system (meaning your computer will work and allow you to run programs) that uses a disk filing system (there are OSs that do not use a disk, think of embedded SYSTEMS)

Does this answer your QUESTION, or do you want more explicit INFO on microsofts dos ?

GrahamOr do you mean a DENIAL of Service (DoS)?

http://whatis.techtarget.com/definition/0,289893,sid9_gci213591,00.html

6372.

Solve : Start up computer error??

Answer»

I've got an older laptop and when I start the up and log into windows 98, I get MS-Dos error that comes up and it READS: Microsoft Cabinet extraction tool - version (16) 1.00.603.0
Copyright Mcirosoft Corp 1994-1997 All rights reserved.
ERROR: Cannot open file: 60

What does this mean and what can I do to stop this message from coming up.
Any HELP would be very appreciated! Thanks Does this happen before you get as far as Windows? Or once Windows has loaded? I'm thinking it's either something in your autoexec.bat file or in your Startup folder.This message appears after windows 98 starts up and goes to the desktop. Thanks for the help! I don't know anything about dos... I would just like the message to stop appearing. OKAY; the FIRST place to look is in the Start menu-->Startup folder. What do you see there?

After that it's a trip to the registry and the win.ini files, I'm afraid.ok...in the start menu folder, I have the programs folder, new office document icon, open office documnet icon, windows updat icon and WINZIP icon. I'm not sure what you mean about the win.ini fileDo you have a real Windows CD to reinstall with? That would be a LOT easier and it seems you have little experience with this.unfortunatly, I don't have any cd's or manuals with this laptop. Go to start/run, type in msinfo32 and click OK. From the resulting menu, click tools/system configuration utility. Make sure normal startup is checked and process autoexec.bat and process config.sys is NOT checked. Click apply and close. You will be prompted to restart. Click yes.yep, all those selctions were correct in the system config. utilityGo back into the system configuration utility. Click the starup tab. Post a list of everything that has a check mark.

6373.

Solve : pausing output?

Answer»

This is a *very* simple question from SOMEONE who hasn't used MSDOS for 10 YEARS and THROWN all the BOOKS away!

I am running an .exe file (ATAINF) to FIND out what drives I have on a laptop acquired with no drivers. How do I see the output page by page?Pipe it in "more"

atainf |more

uli

GRRRRREATE!!

Thanks!

Now to try to understand what it all means

6374.

Solve : WIN XP Recycle?

Answer»

hi,

i am just login here mean new guy any WAY could you pls anyone know how can i REACH XP RECYCLE bin using DOS command

thnax Let's FIRST examine why you would WANT to do that. There may be an easier way to get at the result you want.You can access the recycle bin with cd \RECYCLERThat said, the recycle bin is a Windows invention. Keep in mind that most (but not all) of the folders and files are hidden and should not be accessed through the command prompt. Use the facilities provided by Windows.

8-)

Note: There is a recycle folder on each of your drives.

6375.

Solve : NEED TO KHOW N/W CONNECTIVITY?

Answer»
HI all
(NEED SCRIPT)

I am using Windows xp OS and need help on a two simple issues. I'll really appreciate if you can help me.

Issue 1. I want to ping an IP address continuosly and log the ping results as text file. If it is possible, I want to execute both commands(ping and log) in the same line. What would be the correct command syntax? (I MEAN I need to execute both ping and log with one "ENTER")

PS: I have to see the ping REPLY packets on the screen while it is being logged at the same time.

Issue 2. I need to ping 20 IP addresses on 20 command line windows at the same time, log the ping results as well. In other words I need to do Issue one on 20 windows and 20 IP addresses. Could you help me how to create a script about do Issue 2 with one command?

command line window 1: pings and logs 172.17.48.2,
command line window 2: pings and logs 172.17.49.2,
...
...
command line window 10: pings and logs 172.17.48.66

Thank in advance for helping SmileyNot sure I understand all this. Are you using one logfile for all the pings? You want to have 20 separate windows open all running a ping?

You can run one ping and log the results with redirection: ping -n 1 127.0.0.1 >> log.txt

By preceding the ping with a start command, you trigger off many pings all running in separate windows.

Problem: Text files cannot be shared by multiple processes; Once one process opens the log file, all others will be locked out and the each ping will fail.

Perhaps if you could tell us what you're trying to accomplish, we could find another approach. If you want output both on the console and logged to a file, you may need to use one of the Windows scripting languages.

8-)Whats a ping??
For issue 1, I don't know of a way to log to file AND screen without an external utility. You can get the TEE.EXE command from http://unxutils.sourceforge.net/ and then you could use something like:
Code: [Select]ping -t 127.0.0.1 |tee ping.log
For issue 2, you could replace the real IP address in the parenthesis and do something like this in a batch file:
Code: [Select]@echo off
for %%a in (172.17.48.2 172.17.49.2 172.17.48.3 172.17.48.4 172.17.48.5) do (
echo ping %%a ^> Ping%%a.log >%%a.bat
echo del %%0 2^> NUL ^&exit>>%%a.bat
start %%a.bat
)
If all the IP addresses are in a row (or some pattern) you could change your for loop to automate the generation of the numbers.
6376.

Solve : get into the regitery from ms-dos?

Answer»

how do i get into the registery from ms-dos?
if u dont understand : hold START + R > write regedit, and enter.... that regedit, is it possible to get in there via ms-dos?


thnx......if you have XP, you can use regdmp.If you mean standalone MS-DOS, writing to the registry is only with special tools possible.
I don`t think that regedit is availaible for MS-DOS.
Maybe a 3rd party tool exists.

ulihmmm.. don't know what you meant in your previous post.. but you can access the registry through the command line using the reg tool.. just type in reg /? for the options.. and uhm.. i think this is only available in XP.. and 2k? not sure..

anyways, why would you wanna access the registry using dos when you can access it in windows? :-?Quote

hmmm.. [highlight]don't know what you meant in your previous post[/highlight].. but you can access the registry through the command line using the reg tool.. just type in reg /? for the options.. and uhm.. i think this is only available in XP.. and 2k? not sure..

anyways, why would you wanna access the registry using dos when you can access it in windows? :-?

He meant there is no DOS involved. Win2000 and XP have command prompt which is NOT DOS.i need to get into the regedit and delete a file from MS-DOS, im not able to go into it from the other place...


EDIT : its via windows XP Start/Programs/Accessories/Command Prompt? Could it be that easy?ehrm, yes, then u open your cmd but i need to get into regedit from there REGEDIT is a Windows program and will run in Windows whether you launch it from the Run box or the command prompt.

REG runs as console program (no Windows) and uses run-time parameters (user supplied) in batch mode. Usually used in batch files. Scripts use ANOTHER METHOD to access the registry.

Quote
i need to get into the regedit and delete a file from MS-DOS, im not able to go into it from the other place...
Please explain this more. 8-)

I googled a little bit and found a tool called "Erunt".
It can SAVE all registry hives from Windows (NT/W2k/XP)
and also play it back from M$-Dos.

That might be a possible solution. Not elegant to write the complete registry but...
I didn't check it myself.

hope it helps
uli
6377.

Solve : TREE Command?

Answer»

What I want to do is use the tree COMMAND in MS-DOS to make a txt or whatever file with the results of the tree command. I mean I want to make a file that contains the directories' and files' names in a specified directory/drive. If there is ANOTHER command other than TREE, I am open to suggestions....something else : I would like to make a txt file with the tasks/apps/services/processes that are being ran at a CERTAIN moment by XP....but make it with MS-DOS .... nobody COULD TELL me how to do that... http://www.stefysoft.comQuote

What I want to do is use the tree command in MS-DOS to make a txt or whatever file with the results of the tree command. I mean I want to make a file that contains the directories' and files' names in a specified directory/drive. If there is another command other than TREE, I am open to suggestions....something else : I would like to make a txt file with the tasks/apps/services/processes that are being ran at a certain moment by XP....but make it with MS-DOS .... nobody could tell me how to do that... http://www.stefysoft.com

tree graphically displays your folders, is that what you want. ?
you can use dir /S . Check out the dir command help . dir /?
for listing out tasks/process, can try tasklist. Type tasklist /? and see what it offers you.
to "make a txt file", just do an output redirection , eg tasklist >> output.txtI've found what I wanted ghostdog74 ...thanks...
6378.

Solve : Dos Boot disk?

Answer»

Hi all,

I'm pretty dense when it comes to loading dos drivers etc. I have a Compaq Presario 5BW284 with win 98 loaded. I have an ESS Allegro VDM on board sound card.

I'm trying to create a DOS startup disk to be able to play older DOS Games and have made a startup disk using win 98 and when I look at the autoexec.bat and config.sys files I am very confused.

Is there anyway someone could look at my files (I'm attaching them) and show me how to modify them to create a basic boot disk that would load my CD Rom's and sound driver? As best I can tell my sound driver is Es198x.sys and I copied it to my floppy.

Thanks in advance for any help.



Some sound cards do not have DOS drivers. Some older cards/chips will work, but many of the newer ones will never work in true DOS.

So you need to start with doing a GOOGLE search for the specific sound card and DOS drivers.

You can also go to driverguide.com and check. Registration is free.

The search should be for the acutal sound card. If there is an FCC ID# imprinted on it, use that. THe .sys file is of no use in a search.After you have checked for DOS drivers for that card then post your autoexec and config.sys files for editing help...

patio. 8-)I have the autoexec.bat and config.sys attacched in the first post but I'll list it here. This allows me to access my CD Rom's but it really is a win 98 startup disk. I don't know if the sound driver is loaded and can't figure out which of the myriad of sound drivers I find on the internet are for my ESS Allegro WDM sound card or how to list any on the autoexec.bat.

AUTOEXEC.BAT
@ECHO OFF
set EXPAND=YES
SET DIRCMD=/O:N
set LglDrv=27 * 26 Z 25 Y 24 X 23 W 22 V 21 U 20 T 19 S 18 R 17 Q 16 P 15
set LglDrv=%LglDrv% O 14 N 13 M 12 L 11 K 10 J 9 I 8 H 7 G 6 F 5 E 4 D 3 C
cls
call setramd.bat %LglDrv%
set temp=c:\
set tmp=c:\
path=%RAMD%:\;a:\;%CDROM%:\
COPY command.com %RAMD%:\ > NUL
set comspec=%RAMD%:\command.com
copy extract.exe %RAMD%:\ > NUL
copy readme.txt %RAMD%:\ > NUL

:ERROR
IF EXIST ebd.cab GOTO EXT
echo Please insert Windows 98 Startup Disk 2
echo.
pause
GOTO ERROR

:EXT
%RAMD%:\extract /y /e /l %RAMD%: ebd.cab > NUL
echo The diagnostic tools were successfully loaded to drive %RAMD%.
echo.

IF "%config%"=="NOCD" GOTO QUIT
IF "%config%"=="HELP" GOTO HELP
LH %ramd%:\MSCDEX.EXE /D:mscd001 /L:%CDROM%
echo.
GOTO QUIT

:HELP
cls
call help.bat
echo Your computer will now restart and the startup menu will appear.
echo.
echo.
echo.
echo.
echo.
echo.
echo.
echo.
echo.
echo.
restart.com
GOTO QUIT

:QUIT
echo To get help, type HELP and press ENTER.
echo.
rem clean up environment variables
set CDROM=
set LglDrv=

CONFIG.SYS

[menu]
menuitem=CD, Start computer with CD-ROM support.
menuitem=NOCD, Start computer without CD-ROM support.
menuitem=HELP, View the Help file.
menudefault=CD,30
menucolor=7,0

[CD]
device=himem.sys /testmem:off
device=oakcdrom.sys /D:mscd001
device=btdosm.sys
device=flashpt.sys
device=btcdrom.sys /D:mscd001
device=aspi2dos.sys
device=aspi8dos.sys
device=aspi4dos.sys
device=aspi8u2.sys
device=aspicd.sys /D:mscd001

[NOCD]
device=himem.sys /testmem:off

[HELP]
device=himem.sys /testmem:off

[COMMON]
files=10
buffers=10
dos=high,umb
stacks=9,256
devicehigh=ramdrive.sys /E 2048
lastdrive=z
I didn't see the attachment , sorry.
This site suggests there might be some DOS drivers out there but at 8 or so pages i wouldn't venture as guess which one is correct.
DLoad and install Everest Home which will tell you exactly which sound CHIP you have in that machine and post the info here..

patio. 8-)I am pretty much of a novice about tech things but I did download & install Everest Home and I'm not sure what information I was supposed to get. I did find, under devices, this information about the audio device.

If this is not it perhaps you could tell me where in the program to obtain it.

ESS TECHNOLOGY Allegro-1.COMM AudioDrive

Device Properties
Device Description ESS Technology Allegro-1.COM AudioDrive
Bus Type PCI
Bus/Device/Function 1/5/0
Device ID 125D-1988
Subsystem ID 0E11-B19D
Device Class 0401(Audio Device)
Revision 12
Fast Back-to-Back Transactions Supported/DisabledIs there a model number for that card? 1868, etc?

If not, I do not feel you will find joy. Well I'm not sure. There is a Hardware ID that is:

PCI\VEN_125D&DEV_1988SUBSYS_B19D0E11&REV_12,PCI\VEN_125D...

If that is not it then I guess there is no joy in Mudville.
Type thos #'s into Google and hit Enter and see what happens...
BTW the autoexec and config that are being loaded are from a bootdisk.
The optimum way for you to run those DOS games would be to CUSTOMISE your own according to your equipment.

More info will be needed for that.

patio. 8-)

6379.

Solve : launching new excel?

Answer»

hi guys, sorry if i make something wrong. this is my first time here.

I created a batch FILE which copys a file from one location to another and then launch ms-excel.
it does work, but not properly. The problem is that when excel is launched , INSTEAD of opening a NEW blank workbook with 3 blank SHEETS (as std) , it opens a new workbook, with one sheet called as the batch file and shows the content of the batch file.

Code: [Select]echo off copy *.xls d:\ start "c:\....\excel.exe"
could you hlp me , pls?

by the way, the OS is Win 2000, and excell 2003.

thx, max.Quote

hi guys, sorry if i make something wrong. this is my first time here.

I created a batch file which copys a file from one location to another and then launch ms-excel.
it does work, but not properly. The problem is that when excel is launched , instead of opening a new blank workbook with 3 blank sheets (as std) , it opens a new workbook, with one sheet called as the batch file and shows the content of the batch file.

Code: [Select]echo off copy *.xls d:\ start "c:\....\excel.exe"
could you hlp me , pls?

by the way, the OS is Win 2000, and excell 2003.

thx, max.


this is the way i solved the problem.
as i read in the xls help. excel opens a new blank workbook from c:\PROGRAM fils\microsoft\....\xlstart directory.
my batch file was in the same directory. So, i put the batch file in the previous directory (excel).
and MAGIC.......
thx, to all of u . max.
6380.

Solve : cant start dos?

Answer»

Hi new here and I have a quick question. I am trying to open one of my programs and every TIME I do I get a message that states.....

C:\windows\system32\command.com
C:\windows\SYSTEM32\AUTOEXEC.NT. The system file is not suitable for running ms-dos and windows applications. Choose "close" to terminate.

What does this mean? :-? Sorry Im a little slow at computers. How can I get my program to open and run? Thank youIt Means Microsoft put a little line of code in to one of the Files in SERVICE Pack 2 that says You cant use dos stuff any more NA NA NA

Some people made an emulator Called Dos Box
http://dosbox.sourceforge.net/news.php?show_news=1

You can run many dos programs from INSIDE of itAlso there is a Check box in msconfig under System.ini that says

; for 16-bit app support, im not sure what unchecking it doesQuote

It Means Microsoft put a little line of code in to one of the Files in Service Pack 2 that says You cant use dos stuff any more NA NA NA

Some people made an emulator Called Dos Box
http://dosbox.sourceforge.net/news.php?show_news=1

You can run many dos programs from inside of it

Yeah just tried that what a joke, cant figure it out for the life of me. now I know why I hate these frickin boxes of junk so much. All I want to do is click the program and have it open with out having to jump thru hoops. HOW HARD IS THAT? DAM COMPUTERS
We used to have a FAQ on this problem but it seems it has gone missing.

Autoexec.nt

Good luck. 8-)It has been bumped down by less important, though newer stuff. Anyway the above info will get you there. I tried what it and you said. I clicked start, run = cmd box pops up cmd is not a valid win32 app? now what?If there is an error with CMD then you can't run CMD to fix the problem

If the issue continues to occur, copy the Autoexec.nt and Config.nt files from the Repair folder in Windows to the System folder. To do so, follow these steps:

1. Click Start, click Run, type c:\windows\repair, and then click OK.
2. Right-click autoexec.nt, and then click Copy.
3. Click Start, click Run, type c:\windows\system32, and then click OK.
4. Right-click ANYWHERE in that folder, and then click Paste.
5. Right-click the Autoexect.nt file that you just copied, and then click Properties.
6. Click to SELECT Read-Only, and then click OK.
7. Repeat steps 1 through 6 to copy the Config.nt file.

Kudos to Microsoft. 8-)
6381.

Solve : multipule lines as a var?

Answer»

i could have it go only to a file and have my batch file use that file and then out put to a new file and delete the temp file with the file list in it.any help because when i have it go out to a file it goes out as only the first line.Post your code so we can help you troubleshoot the problem.@echo off
:start
::================================================
set fup=fup
set pur=purge
set alt=altpr
set sec=secure
set cod=,code 100
set ccc=,"cccc"
set Infile=temp.dak
set Outfile=purge.jim
::================================================
for /f "tokens=1 delims= " %%a in ('dir /AD ^| findstr /R /V "\.\>" ^| find /c ""') do set dirs=%%a
echo %dirs%
pause
::for /f "skip=%dirs%" %%a in ('dir /B /o:G') do echo %fup% %pur% %%a >testttt.txt& set list=%%a

for /f "skip=%dirs%" %%a in ('dir /b /o:g') do call :sub %%a
set dirs=
goto :eof
:sub %%a
set dirs=%1
for /f "skip=%dirs%" %%a in ('dir /b /o:g') do echo %%a
echo %list%

pause
::for /f "delims=" %%a in ("%list%") do echo %fup% %pur% %%a>>%Outfile%
::echo.>>%Outfile%
::for /f "delims=" %%a in ("%list%") do echo %fup% %alt% %%a %cod%>>%Outfile%
::echo.>>%Outfile%
::for /f "delims=" %%a in ("%list%") do echo %fup% %sec% %%a %ccc%>>%Outfile%
::echo.>>%Outfile%
::pausethe part at the bottom with all of the for loops is for the part wher i add things onto the file or var And what i am trying to do with this is get a list of all the files in a derectory (the one the batch file is in) and have only the files and no directories incluted and it needs to be in the bare format.I don't see anything that outputs to a file that is not commented out. What is the problem with the script? What is it doing, and what do you want it to do?Is there a reason you don't use the command:
Code: [Select]dir /b /a-d
Or to save it to a file, use:
Code: [Select]dir /b /a-d >testtt.txt
Or if you want the list in a semi-colon separated environment variable, use:
Code: [Select]@echo off
set FileList=
for /f "delims=" %%a in ('dir /b /a-d') do call :AppendList %%a
echo FileList is: %FileList%
goto :EOF

:AppendList
set FileList=%FileList%;%1
goto :EOFFor the "save to a file" method and then list them it would be like:
Code: [Select]@echo off
dir /b /a-d >testtt.txt
echo List of files is:
type testtt.txtOk i gust want to start freash. Could you make me a script that will get a list off all the files in a directory (not INCLUDE the dirs) in bear format an output them to a file please.looks like i posted late lolOMG are you serus it is that easy i could never FIGER out what the - was for (prefix meaning not???) <--STILL dont get what that means but think you.Quote

OMG are you serus it is that easy i could never figer out what the - was for (prefix meaning not???) <--still dont get what that means but think you.
i suppose you are taking about dir /a-d ? check out dir /? .. it explains...
Code: [Select]
/A Displays files with specified attributes.
attributes D Directories R Read-only files
H Hidden files A Files ready for archiving
S System files - Prefix meaning not

"-" meaning not... so /a-d means display files, not directories...think you so much i have been working on this 4ever i cant beleav that all i needed was a simple - lol ok think you very very much.
6382.

Solve : Simple Copy Access Database Batch File?

Answer»

Hi,
I am trying to run a simple copy file batch command which copies an Access database from one location
to another - the file is below:

@echo off
echo Copying Live Black Database.....
pause
copy F:\Database\testdatabase.mdb F:\otherlocation\testdatabase_copy.mdb

...this doesnt work when i run it!
Any HELP will b grand

ta

Melpost error messages....there are no error messages.

I figure that it doesnt work because the database is copied to the location specified :-?

I tried copying the code into the MS-DOS prompt, I get a syntax error when I try and run it.When troubleshooting a batch file, your best bet is to turn echo on. This will allow you to see how each STATEMENT is resolved as the file runs.

Just my 2¢ 8-)Try running the MAIN line from a command prompt to see what happens. Like:
copy F:\Database\testdatabase.mdb F:\otherlocation\testdatabase_copy.mdb
Post back any output you get.hello all
Ive managed to get it to work - I needed to put the path LOCATIONS in double quotes - works fine now
Thanks for all ur help

6383.

Solve : A randomizer???

Answer»

Is it possible to make a batch file that gives you random answers? Like if you wanted to choose your lottery #'s or something you could put in all the possible #'s and it gives you a random ONE every time?

Thanks in advance

PS I am just curious!This is version dependent, but for something like Powerball where the pool of numbers is 54, something like this may work:

set /a num=%random%/606

This would include zero in the pool which you would have to filter out.

8-)

Note: Computing each random number is an independent event while the pool remains constant. The user would have to filter out any duplicate numbers.Thanks, it worked!
Could I change it to somthing other than A #? Like months?Quote

Thanks, it worked!
Could I change it to somthing other than A #? Like months?
I was just thinking; is there maybe a way to have a group of variables? Then you could make show a random variable from that group? Or is there another way?Yes, you can do this with months or anything else by setting up an array.

Code: [Select]@echo off
set array=JanFebMarAprMayJunJulAugSepOctNovDec
:loop
set /a num=%random%/2730
if %num%==0 goto loop
call set /a disp=3*%num%-3
call set mon=%%array:~%disp%,3%%
echo %mon%
goto loop

This EXAMPLE has no exit; use CTL-C.

Quote
Or is there another way?
Yes, learn Windows scripting...always use the right tools for the job.

Batch is a command language not a programming language.

8-)Everytime I click on it, it says april!
And I deleted the "goto loop" and changed it to pause!There are two goto loop statements.

In any CASE, the example works as advertised. You break it, you buy it. Quote
Is it possible to make a batch file that gives you random answers? Like if you wanted to choose your lottery #'s or something you could put in all the possible #'s and it gives you a random one every time?

Thanks in advance

PS I am just curious!

In Python,
Code: [Select]>>> import random
>>> random.randrange(1,100) #assume lottery NUMS range from 1,100
50

In Perl
Code: [Select]print int(rand(100));

In windows scripting, an eg here
http://www.microsoft.com/technet/scriptcenter/resources/qanda/may05/hey0518.mspx

In batch,
yes, you can do that in batch too, if you are bored.


This is what I changed it too:
Code: [Select]@echo off
set array=JanFebMarAprMayJunJulAugSepOctNovDec
:loop
set /a num=%random%/2730
if %num%==0 goto loop
call set /a disp=3*%num%-3
call set mon=%%array:~%disp%,[highlight]3[/highlight]%%
echo %mon%
pause
cls
goto loopCan I change the highlighted # to make the words longer???
And if it's not too confusing, could yoyu maybe explain how it werks??If you change the length of the occurances in the array you'd have to make changes in two of the statements (see below). Use either trailing spaces or leading zeroes for padding if necessary. The example was SETUP with equal length occurances. For unequal length occurances you'd have to take a different approach and use a delimiter between each member of the array.

If you change the number of members in the array, you would need to change the divisor for the num calculation.

Code: [Select]@echo off
set array=JanFebMarAprMayJunJulAugSepOctNovDec
:loop
set /a num=%random%/2730
if %num%==0 goto loop
call set /a disp=[highlight]3[/highlight]*%num%-[highlight]3[/highlight]
call set mon=%%array:~%disp%,[highlight]3[/highlight]%%
echo %mon%
pause
cls
goto loop

How does it work? I could never do justice to the simple eloquence of this batch code. Turn echo on in the file. Watch and learn.

A Windows script would be a better choice, but to each his own. 8-)I still don't quite get what #'s to change to change the random word! Like what would be changed if this digit was changed??:
Code: [Select]@echo off
set array=JanFebMarAprMayJunJulAugSepOctNovDec
:loop
set /a num=%random%/2730
if %num%==0 goto loop
call set /a disp=[highlight]3[/highlight]*%num%-3
call set mon=%%array:~%disp%,3%%
echo %mon%
pause
cls
goto loopAnd what would be different if this digit was changed?:
Code: [Select]@echo off
set array=JanFebMarAprMayJunJulAugSepOctNovDec
:loop
set /a num=%random%/2730
if %num%==0 goto loop
call set /a disp=3*%num%-[highlight]3[/highlight]
call set mon=%%array:~%disp%,3%%
echo %mon%
pause
cls
goto loopThis one?:
Code: [Select]@echo off
set array=JanFebMarAprMayJunJulAugSepOctNovDec
:loop
set /a num=%random%/2730
if %num%==0 goto loop
call set /a disp=3*%num%-3
call set mon=%%array:~%disp%,[highlight]3[/highlight]%%
echo %mon%
pause
cls
goto loopQuote
Like what would be changed if this digit was changed??:

The best answer would be for you to turn echo on, change each number and see what happens. Also check out the documentation for the SET statement which explains how to extract a substring from a string.

Hint: the SET statement uses offset and length

Good luck. 8-)

I've noticed many of your posts concerning "DOS". Perhaps a trip to the library for a good reference would be helpful. Online, Allenware can be useful.

Yes, i know it's not DOS!! it's command prompt!
Thanks for all your help by the way!
6384.

Solve : access files 2 level up and 2 level down?

Answer»

Hi,
I am trying to write a DOS command to copy a file from 2 levels down to a folder 2 level up. How do I do it?

For example,
consider the file structure as follows:
C:\Level1\Level2\Level3\ Level4\ Level5\ Level6

if i am at

C:\Level1\Level2\Level3

is there a SHORTER method than USING the following command
copy C:\Level1\Level2\Level3\ Level4\ Level5\test.c C:\Level1\test1.c

is there a way to use the reference from my current directory?

Thanks in advancehow about setting a variable for your current directory..?
then use the variable in your copy command...Ghostdog's method would certainly be self documenting and readable. If you prefer your batch language cryptic and obscure:

Code: [Select]copy Level4\Level5\test.c ..\..\test.c

Personally I prefer your original method as it can be run from any location on the machine. Relative pathing may offer a few SHORTCUTS, but try reading the code six months from now. PC's offer many ways to do the same thing. Use whatever method you're most comfortable with.

8-)

If your DOS version has the subst command, you can use that to assign a drive letter to a directory, then use the drive letter instead of the full path.

6385.

Solve : CMD enabling?

Answer»

Hi there,
ive got a little/big problem with the Zango virus.
i download something on limewire and opened it and it gave me a lot of *CENSORED*
now if i do
START>RUN>CMD
its opening "Dos" and its says cmd.com and it won't load
if i do cmd.exe it won't load so ive a problem can SOMEBODY help me out?
command.com sucks for me i NEED 2 be able 2 copy thing with right click Ohhhh, the joys of p2p....

Have you cleaned your system of malware :-? Are you using anti-virus and FIREWALL :-?

Give us a few details of your pc, like what OS you are using, do you have a full genuine copy of your OS cd, can you get into safe MODE, what have you tried so far :-?

6386.

Solve : Backup Folders!?

Answer»

How can you make a batch file that makes backups of a certian folder EVERY hour or two? And then, if possible, delete all those folders at the end of the day?

Thanks for all HELP!Time for you to do some READING.

http://www.google.com/search?hl=en&q=batch+files+for+backups


<------------------I know how to make a BACKUP!! I just need to know how to start it at a certian time!!Quote

I know how to make a backup!! I just need to know how to start it at a certian time!!
Never mind I just realized I can use task SCHEDULER!!Quote
I know how to make a backup!! I just need to know how to start it at a certian time!!

That was a google link to 7,920,000 hits on how to do what you asked. Did you look? Was that not enough? The first few ones were very clear, but it did require you reading them.
6387.

Solve : Dos-based computer problem?

Answer»

Hi, I have a dos based computer (Vectra by hewlett packard). For some reason, my computer started to print out BLANK pages and appeared to crash. When I turned it back on, the computer remains on the black screen, and I am unable to input commands. Any Ideas on what the problem is?What version of DOS? YOu need to be very specific about what happened prior to this and the exact issue. Were you printing something and a blank PAGE came out, or for no apparent reason your printer INITIALIZED and started SPITTING out paper, or what?

6388.

Solve : statement?

Answer»

I'm for some UNKNOWN reason in a particularly foul MOOD this afternoon and i can't figure out why...

I thought the MSDos FORUM was the perfect spot for this...

I'm ALREADY starting to feel better...

patio. 8-)No sympathy here! I knew it !



(slippin back to foul mood)

patio. 8-)

6389.

Solve : Copy folder to another computer?

Answer»

Hallo,
please, does anybody know how can I make a batch FILE with command to copy one folder to another computer in LAN
Thanks in advanceYou have to map a drive with the target Computer.

for example map drive c: as drive y: on your MACHINE:

net use y: /delete
:: DISCONNECTS y: if it is mapped.

net use y: \\computername\c$

xcopy ..... y:\....

net use y: /delete

hope it helps
uliIf you don't want to map a drive LETTER, you can copy using the UNC path. With the "map drive" or "UNC" method, you will need to make sure that permissions are set properly. Using the previous example, it would be like:

xcopy file.ext \\computername\c$\path\to\dest\

6390.

Solve : Need help creating BATCH file...  Can you help??

Answer»

:-? :-? :-?
I'm not too schooled in batch file creation and I've read around on the NET for help. UNFORTUNATELY the help has really only confused me.... Maybe you can help?

I need a batch process to LOOK at all files within a shared directory. As each file is determined, I need to verify that these files also exist on the local PC. If we're ABLE to also look at file creation date/time that would be GOOD because if there's a difference I need to copy the file from the shared directory into this local folder. Once a file copy is complete I now need to register any .dlls that have been moved.

Sound easy, right?

Any help is appreciated. Thanks!

/me
[smiley=dankk2.gif]

6391.

Solve : Batch File to Copy a File at Fixed Schedule?

Answer»

I want to copy a file called D:\EMPMST1.DBF to C:\COPYBAT every night at 2355 hrs.

Can someone help me prepare a Batch File to do the same?

Will the following work:
========================================
@echo off
echo This is a test batch file
cls
copy d:\empmst1.dbf c:\copybat
========================================

I have tried using the "AT" command in Windows 2000 to run at a specific TIME.

I want the computer to run this batch file everyday and copy and overwrite the file.

Regards,

YpschitaCode: [Select]@echo off
echo This is a test batch file
cls
copy /Y d:\empmst1.dbf c:\copybat

Note: Not sure if W2K has a Y switch (overwrite) for the COPY cmd. If not you can always pipe a Y:

Code: [Select]@echo off
echo This is a test batch file
cls
echo Y | copy d:\empmst1.dbf c:\copybat

To schedule the job something like this MIGHT work:

at 23:55 /every:M,T,W,Th,F,S,Su batchname.bat

Replace batchname with the name of your batch file and add any ADDITIONAL path information as needed.

8-)Or you could simply run it from the task scheduler.
start/programs/accessories/system tools/scheduled tasksDear Sidewinder,

It did not work. I put it for 4:45PM IST and the time has passed but nothing worked.

Any suggestions?

2K_Dummy,

I am trying your solution too.

Regards,When you ran the AT command, did the job get scheduled? ERROR message? Use military time when scheduling jobs with the AT command.

8-)Sidewinder, 2K_dummy,

Thanks it worked. Now I will just check the overwrite thing.

I used Military Time only but still it did not run.

The AT did not work, I went to the Scheduler and started it.

It worked well.

The AT command made it think it has to run WEEKLY and not DAILY.

Thanks a lot!!!!

Regards, I also need to copy a folder at a CERTAIN time, but can I also delete the copyed folder at another time?Create two batch files, one for the copy, the other for the delete. Schedule each job at described above.

8-)thanks!Hey, Sidewinder, Is there a way to just overwrite the same file instead of deleting it?

6392.

Solve : Increasing dos display?

Answer»

Hey hows things,

I am a total newbie, don't know much about dos. I just started working in a computer shop and a fella has BOUGHT two laptops off of us and got me to install a dos program for bar stock sort of a thing. So I got all installed and put the .bat icon on the desktop to open it up and modified the properties to open in full screen with the 80/25 settings so the text within the program also use the full screen. Everything worked a TREAT on the new laptops but he gave me an old dell laptop running windows 98 to reinstall windows on and the program. I have the program working and using the full screen but the text within the program stays small and will not use the full screen unless I leave it for about 20-30 minutes till the screen goes black as if it's a screensaver. then when I move the MOUSE in order to bring the screen back up the text is now using the full screen. Sorry that's a lot too take in but can anyone understand why it's not using the full screen for the text from the start? Really need to get this sorted.

Thanks for the help,

MarcusSelect properties from the .bat files or PROGRAMS shortcut. Select the font tab and adjust to the desired size. Then select the screen tab and check the box to restore settings on startup.nope still comes up small when i restart the machine. Once i leave it for the 20 mins or so and it gets big it will stay big until the machine is restarted even if i keep opening and closing the program. Cannot figure it out at all.I just went into the power options and changed the screen to turn off after 1 minute so if i leave it for a minute the screen turns off and then i touch the mousepad and it comes back in the full screen mode.What happens if you insert cls as the first COMMAND in the .bat file?Try experimenting with the MODE command. Like maybe:
mode con cols=80

6393.

Solve : Merging 2 files,seperated by space not by new line?

Answer»

Hi,

Plz anyone help me in SOLVING this...I know this is simple but I am really NEW to writing batch scripts. I am using Windows 2000 Operating system.

I have 2 files a.txt="ABCD" and b.txt="EFGH". I want to create c.txt as "ABCD EFGH". I want to merge the 2 files separated by space (and not by new line).

Regards,
Moorthy.
I suspect there is more to this, but for what you asked for:

Code: [Select]@echo off
for /f "tokens=1*" %%x in (a.txt) do set f1=%%x
for /f "tokens=1*" %%x in (b.txt) do set f2=%%x
echo %f1% %f2% > c.txt

8-)THANKS for the reply. But my scenario extends in the following way:

I have many text files in my source folder. I want to take the first 2 character of the text files and to create batch file which does some COMMANDS to the source files.

Eg,

Suppose my source folder contains files like
CACS01.txt,
CACQ02.txt,
CAMS03.txt,
SFCS04.txt,
SFCQ05.txt,
SFMS06.txt

I have to create 2 batch files one for CA and other for SF.
The batch file should contain the following commands:

For CA:

fold -w4 CACS01.txt>>converted files\CACS01.txt
fold -w6 CACQ02.txt>>converted files\CACQ02.txt
fold -w8 CAMS03.txt>>converted files\CAMS03.txt

Similarly, other batch file for SF.

The 'fold' command will seperate the records from the source file(which is continuous file) by the given width and populate it into the target converted file(which is organized). I mean, the records will be seperated in the converted files while it is continuous in source file.

Note that, the width varies by 4,6,8 for corresponding CS,CQ,MS(3rd and 4th character of source files).
For all my CS files, the records should be seperated by width 4
For all my CQ files, the records should be seperated by width 6
For all my MS files, the records should be seperated by width 8.

Please guide me in CREATING batch files.

Regards,
Moorthy.Not really sure what you're expecting, but this will do what I interpreted you wanted

Code: [Select]@echo off
setlocal enabledelayedexpansion
for /f "delims=, " %%i in (filename.txt) do (
set var=%%i
set col12=!var:~0,2!
set col34=!var:~2,2!
Call :MakeFile %%i !col12! !col34!
)
goto :eof

:MakeFile
if %3==CS set width=4
if %3==CQ set width=6
if %3==MS set width=8
echo fold -w%width% %1^>^>converted files\%1 >> %2.bat

You can really help yourself by learning a Windows script language. VBScript and JScript are already installed on your machine. Batch coding is a command language not a programming language.

8-)
Thank you for your idea.....I got the logic what I expected.......


Thanks!!!!!!!!!

6394.

Solve : Vista?

Answer»

Has anyone tried the Beta of WinVista? If so, I have a question that has been burning through my head: Does the OS have a command prompt that still accepts the same DOS commands as WinXP and SIMILAR OS's?Idk i have hade the beta even before it whent to public beta but i never put it on my pc but i know some people that are running it now and i will ask them. Yes, same command shell and same commands as Windows XP.Really? Then what's this MONAD I'm hearing about?MONAD is new shell by MS that is supposed to be very powerful. I downloaded a beta of MONAD a few months ago, but it was VERY different from CMD.EXE, so quickly went BACK to CMD.EXE until I have time to re-visit the new shell (which I haven't yet). I think you can download it, but I didn't notice it at all in Vista. It MAY be an option for Vista, but I know that when you click on the "Command Prompt" icon, you get the good old CMD.EXE with the same syntax and commands as XP.Here is INFO on MONAD and the page also contains a download link if you want to give it a try:
http://www.microsoft.com/windowsserver2003/technologies/management/powershell/default.mspx
Quote

It may be an option for Vista, but I know that when you click on the "Command Prompt" icon, you get the good old CMD.EXE with the same syntax and commands as XP.

What a relief. I have MONAD and I'm not thrilled with it; it has a few new commands, but I noticed that COPY CON is unavailable. Not a good start, since I despise EDLIN. But that's just me.
6395.

Solve : two MS-DOS 6.2 questions?

Answer»

Allright, I know it can be done, with I *think* one command, but I can't seem to find it anywhere. I need to beable to be in root, and do a search for one word and have it look in all files and directories for that word. and no the command I'm thinking of isn't find.

Second thing: Is there any way, without getting any extra programs to encrypt a file? Any encryption will do, I've been looking for a few days now and all I get is other programs that will do it in DOS

Thank you in advance for and advice/help/comments you guys leave!It has been a long time since I had anything to do with "true DOS" so this might be inaccurate.

1. Other than "Find", I can't think of anything at the moment.

2. To my knowledge, and to Google's knowledge, there is no real method of encrypting files in DOS. The best solution I can find would be to make the file Read-only, but even then that allows people to ACCESS the file. So I don't think so. DOS wasn't designed in the days of hackers running rampant (since the Web wasn't very, um, there. The only viruses people could get was disk to disk.)A pretty good DOS resource PAGE can be found here...

http://www.opus.co.tt/dave/indexall.htm

patio. 8-)hmm ok I was half wrong, it was half the find command just USEING it as a filter the command I was looking for was
dir C:\ /s /b | find "text"
and YA, there is NOTHING for encryption/compression in dos... I'm going to try to use back up as I need to fool the above command. if you guys have any other suggestions on fooling the command I listed other than compressing the file im more than open to suggestions.

6396.

Solve : After rebooting PC .bat not work?

Answer»

Hello agian,

START.bat
md c:\windows\Installer\System-Installer
xcopy Files c:\windows\Installer\System-Installer /s /e /h

REGEDIT /s runonce.reg
this .reg file is:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run]
"setup.bat"="c:\\windows\\Installer\\System-Installer\\Setup.bat"

shutdown -r -f -t 10

the setup.bat file:
files\setup.exe


The problem:
I run start.bat and it runs fine. After the pc reboots the setup.bat file auto run (FORM the .reg file) all the echo stuff comes up, but the setup.exe trys to load and "Windows XP" said "PLease go to the Control Panel to install and configure system components" so it fails. But rigth after that I can goto the System-Installer folder that was just CREATED folder and run the same setup.bat file and it run fine. Oh yea, the setup.exe is a screensaver.

Any ideas

Thanks
Tom

P.S. How do you get that nice looking code box in your post for the code?
It could be a timing issue. Maybe try adding a pause to your SETUP.BAT file, like:

Code: [Select]ping -n 15 localhost >NUL
files\setup.exe

The box to post code is the # symbol (mouse-over says "insert code") near the middle of the top formatting bar.GuruGary,

I tryed putting ping -n 15 localhost >NUL (and 60 to) at the start to slow it down but same THING happened. And right after I click close on the cmd window I can start the setup.bat file (thats is the xcopy copyed to the folder) and its file Grrrrr.

Thx tho,
Tom

Maybe try INCLUDING full paths to all files, and add quotes.

Start.bat:
Code: [Select]md c:\windows\Installer\System-Installer
xcopy "C:\Files" "c:\windows\Installer\System-Installer" /s /e /h
Setup.bat:
Code: [Select]"C:\files\setup.exe"

6397.

Solve : How do you pass value from output to input and verify?

Answer»

Could SOMEONE assist me in figuring out how to grab the DAYS value from the systeminfo command, so that it could be tested to be less than 15. And if greater than 15 execute a shutdown -r to reboot the computers/servers???

I want to add this to my scheduled tasks to run daily vs having to manually tell it to execute on specific dates, since the only options are Daily, Weekly, Monthly, in the Task Scheduler of XP Pro and there was no option for bi-weekly which is what I need.

Reason for this scheduled reboot is that the POS software ( POINT Of Sale ...not the other POS meaning ) .... we are running has some sort of memory leak, which causes problems to show up on around the 18th day. And I would rather not reboot the servers daily as this may overstress them, since they run best when running 24/7, but not 24/18 ha ha, so I want them to run 24/15 and reboot to clear the leak.

Below is an output snippet from the systeminfo command that I think would work best for passing the triggering value to the IF command of a batch to test for a value less than 15, THEN shutdown -r if equal to or greater than 15. This would then cause the system/servers to reboot on the 15th day, when the daily scheduled task would run and test this.

I dont know how to grab this value, not sure if the whole output has to be passed to an array, then searched for DAYS in which it would grab the value before it and test with the IF command???

Thanks ... Dave

---------------------------------------------------

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

C:\Documents and Settings\dlembke>systeminfo

Host Name: FRANKENSTEIN
OS Name: Microsoft Windows XP Professional
OS Version: 5.1.2600 Service Pack 2 Build 2600
OS Manufacturer: Microsoft Corporation
OS Configuration: Member Workstation
OS Build Type: Multiprocessor Free
Registered Owner: cfs
Registered Organization: cfs
Product ID: 76487-015-4615084-22789
Original Install Date: 7/29/2006, 7:06:44 AM
System Up Time: 16 Days, 2 Hours, 14 Minutes, 33 Seconds
System Manufacturer: MICRO-STAR INTL, CO.,LTD.
System Model: MS-7037
System type: X86-based PC
Processor(s): 2 Processor(s) Installed.
[01]: x86 Family 15 Model 4 Stepping 1 GenuineIntel ~
3000 Mhz
[02]: x86 Family 15 Model 4 Stepping 1 GenuineIntel ~
3000 MhzCode: [Select]@echo off
set maxupdays=15
REM 1. Filter the line containing "Up Time" out of
REM systeminfo output & put it in a text file
systeminfo | @find "Up Time" > %temp%\uptime.txt

REM 2. extract first token in comma delimited STRING
for /F "delims=," %%a in (%temp%\uptime.txt) do set string=%%a

REM 3. strip out the characters from the 15th onward
set d=%string:~15,-4%

REM 4. strip leading spaces
call :strip %d%

echo updays=%updays%

REM 5. perform comparison
if %days% GTR %maxupdays% (
echo uptime more than %maxupdays% days
REM etc
REM etc
)
goto :EOF




:strip
set updays=%*
goto :EOF



Contrex's code looks good, EXCEPT I think there might be problems using quotes in the GTR comparison. You may want to change line:
Code: [Select]if "%days%" GTR "%maxupdays%" (to:
Code: [Select]if %days% GTR %maxupdays% (
Also, you CAN add a reboot (SHUTDOWN.EXE) to your scheduled tasks. Choose "Weekly", then it will give you an option to run every X weeks, and you can choose 2 weeks. Or you can choose "Daily" and choose every 15 days.Quote from: GuruGary on May 25, 2007, 03:26:20 PM

Contrex's code looks good, except I think there might be problems using quotes in the GTR comparison.

I got in the habit of using quotes for IF comparisons, I don't seem to have encountered any problems so far. What sort do you envisage? (Always glad to pick up tips). Do you mean because the data is numerical?

I tried that code with dummy data from 1 to 999 and they all worked fine.
Contrex: I might be wrong, and I can't remember for sure. But I think it was something like using quotes (or anything non-numeric) in a numeric comparison (GTR, GEQ, etc.) changes the comparison to text / alphabetical comparison instead of a numeric comparison. If that was the case then 10 < 2 because 1 < 2. Does that make sense?

Let me know if I didn't explain it well, but basically I think it is an ASCII vs numeric comparison issue.Quote from: DaveLembke on May 25, 2007, 10:41:53 AM
....there was no option for bi-weekly which is what I need.

I thought there is? you choose weekly task, then on the next screen, there's option for you to specify how many weeks and which day. but correct me if i am wrong though..
Quote from: GuruGary on May 25, 2007, 03:26:20 PM
Also, you CAN add a reboot (SHUTDOWN.EXE) to your scheduled tasks. Choose "Weekly", then it will give you an option to run every X weeks, and you can choose 2 weeks. Or you can choose "Daily" and choose every 15 days.
Quote from: GuruGary on May 25, 2007, 07:30:33 PM
I think it is an ASCII vs numeric comparison issue.

Code: [Select]c:\>set num1=10

c:\>set num2=2

c:\>if %num1% GTR %num2% echo %num1% is greater than %num2%
10 is greater than 2

c:\>if "%num1%" GTR "%num2%" echo %num1% is greater than %num2%

c:\>

Exactly right. Thanks for the hint.
Streamlined version, no temp file, no labels, shutdown in 10 seconds, force running apps to close
without warning.

You may want to modify shutdown behaviour, add more lines, etc, this is just an example
Code: [Select]set maxupdays=14
for /f "tokens=2,3,4* delims= " %%a in ('systeminfo ^| @find "Up Time"') do set updays=%%c
if %updays% GTR %maxupdays% (
shutdown -r -t 10 -f -c "Scheduled restart in 10 seconds"
)






Many Thanks Contrex!!!

This works well. I also edited my shutdown to be more specific like you suggested, just in case something wants to STAY open hanging the reboot.

Dave
6398.

Solve : kernel help?

Answer»

hey everyone i am having PROBLEM with my pc (WIN98 SE), when it boots it say kernel error reinstall window. i went in dos and i renamedd the kernel32.dll 2 kernel32.ch . but i need 2 extract the kerenel32.dll from he win98 cd. i dont have any cd 4 the computer ,is there any WEBSITE where i can get them, or is there any oher way 2 fix it.What about reinstalling Windows as suggested? Is that apossibility? You MAY have multiple other problems as well. What preceeded this?Re-installing is probably the best SOLUTION, but I don't KNOW of a way to legally get a CD other than buying one.

And I don't know of anywhere that you can download the kernel32.dll file. Do you have any other computers running Windows 98 SE?

6399.

Solve : IF statement with variable?

Answer»

Hello,
I am TRYING to create a bat file that will do something based on the last octet of the ip of the MACHINE. I have already MADE something that gets the ip (from the registry) takes the last three digits and stores it as a variable (ip). Now I am having trouble with the IF statements. To make it easier I just STARTED at the highest group of ips, used greater than (GTR) and worked my way down. In the labels I exit the script after it does what I need so it is only possible to enter one IF statement. Each if statement sends it to the appropriate label to do what I need that computer to do.

IF %ip% GTR 200
GOTO group1
END

IF %ip% GTR 190
GOTO group2
END

......and so on......

group1:
......do stuff.......
EXIT

group2:
.....do stuff........
EXIT

I am PRETTY sure that my problem is with the IF statements, but I am not sure what I am doing wrong. Thank you in advance for reading through this and I look forward to any guidance anyone can offer.Quote from: fjwolz19 on May 29, 2007, 06:38:56 AM

I am pretty sure that my problem is with the IF statements, but I am not sure what I am doing wrong. Thank you in advance for reading through this and I look forward to any guidance anyone can offer.

Your problem is, that code is not batch language. It is some other language maybe not yet invented.

There are 2 problems. The IFs and the labels.

(1) IF statements in batch are usually like this on one line. You don't have "END".

IF %ip% GTR 200 goto group1
IF %ip% GTR 190 goto group2

(2) You got the labels back-to-front. The colon goes BEFORE the label name

:group1
.....do stuff....
EXIT

:group2
.....do stuff....
EXIT

It is not compulsory to put *anything* in a batch file in capital letters.

If you want a multiline if, use braces (parentheses) like this

if %ip% gtr 200 (
echo it was more than 200
echo another line
goto group1
)

:group1

Or use & like this

if %ip% gtr 200 echo more than 200 & echo some more text & goto group1

6400.

Solve : path question???

Answer»

my bro share out a movies name spiderman and i know that he put it in the f:\movies that he share out

so here my question is there a way to make a batch that will directly go to folder instead of click start/my NETWORK place/movies/spiderman/spiderman.avi

here is my command seem didnt work ... keep saying the network path was not found

start /max \\192.xx.xx.xx\movies\spiderman\spiderman.avi

im USING window xp SP2

any1 can help me outYou don't need /max to open a video file but I don't think you can open a file over a shared network. Where are you getting that ip address from?
Anyways...hang tight and someone might have an answer.well im currently sharing a modem with my bro so that where the ip come from anyway thx for the /max command Well, I'm sharing a modem with my brother, but that doesn't mean I have access to his files!

You have to SET up a shared connection first. Have you done that?

Anyway, the way I'm seeing this is that your code could work in your bro's main drive was F:.


I'd try something like this (don't really know if it will work, but just try it.
Code: [SELECT]start \\192.xx.xx.xx\F:\movies\spiderman\spiderman.avi

But I'm just thinking the problem is that you aren't in a network. Try setting up on, because just being physically connected by a modem won't do anything.well i did try like what you did but no luck it didnt work it just poping out the network path was not found

well anyway thx for the helpJust a quick question before you go, have you set up a shared connection? If you haven't, that's probably the problem (I tried this with my brother, and because we don't have a shared connection, it showed the message also).Quote from: Dark Blade on May 29, 2007, 12:50:24 AM

Just a quick question before you go, have you set up a shared connection? If you haven't, that's probably the problem (I tried this with my brother, and because we don't have a shared connection, it showed the message also).

well we did have a share conection if not i wont be able to go into his pc searching for movies

after my 1 hour hard work i finally made it
i share it with you

for LAN
start \\urfrenorbrotherip\thefoldernametheyshareout



for example
start \\192.xx.xx.xx\spiderman\spiderman.avi