Help with program for a newbee!
Posted: Wed May 28, 2003 12:01 am
Hi there im trying to write a simple program that will copy files accross a network from one dir to another.
It is a simple menu base program.
I am having trouble with the copy part of the program I have put my code below.
CLS
LOCATE 3, 35
PRINT "SOFTWARE COPY"
LOCATE 4, 35
PRINT "_____________"
LOCATE 10, 35
PRINT "1.SINGLE ZONE"
LOCATE 12, 35
PRINT "2.DUAL ZONE"
LOCATE 15, 35
INPUT "ENTER SELECTION (1-2):", number
SELECT CASE number
CASE 1
CLS
LOCATE 10, 35
INPUT "INPUT DRIVE LETTER:", drive$
IF drive$ = "c" THEN
SHELL "copy d:\tmp\*.* c:\tmp"
END IF
END SELECT
when I run the program it tells me that there is invalid data if there is a file in the first dir.
This is the beging of the program so it is not sorted out yet.
I also need to find some way of choosing the drive it copys to so for example the dir path would be set but i woulde enter the drive my self so it would prompt me with enter driveleter and i would hit c,d ,e or f and so on.
can any one help me with this i just need help with the copy part at the moment.
Thank You!
It is a simple menu base program.
I am having trouble with the copy part of the program I have put my code below.
CLS
LOCATE 3, 35
PRINT "SOFTWARE COPY"
LOCATE 4, 35
PRINT "_____________"
LOCATE 10, 35
PRINT "1.SINGLE ZONE"
LOCATE 12, 35
PRINT "2.DUAL ZONE"
LOCATE 15, 35
INPUT "ENTER SELECTION (1-2):", number
SELECT CASE number
CASE 1
CLS
LOCATE 10, 35
INPUT "INPUT DRIVE LETTER:", drive$
IF drive$ = "c" THEN
SHELL "copy d:\tmp\*.* c:\tmp"
END IF
END SELECT
when I run the program it tells me that there is invalid data if there is a file in the first dir.
This is the beging of the program so it is not sorted out yet.
I also need to find some way of choosing the drive it copys to so for example the dir path would be set but i woulde enter the drive my self so it would prompt me with enter driveleter and i would hit c,d ,e or f and so on.
can any one help me with this i just need help with the copy part at the moment.
Thank You!