Home > Archive > Programming with dBASE > November 2005 > copying to CD drive









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author copying to CD drive
Otto

2005-10-17, 1:26 pm

I use a dB2K program to back up my files to a re-writable CD using:
run xcopy c:\MyDirectory\*.* M:\Backup\*.* /s /v
(where M: is the CD drive).

This worked fine until I upgraded from Windows Me to Windows XP. Now nothing
is copied.

Thanks for your help

Otto


Ronald de Vries

2005-10-17, 1:26 pm

with whole folder
see code below
Ronald de Vries

#define ISDIR(cDir) .Not. Empty(funique(cDir+"\isdir???.???"))
RegKey =
& #91;HKEY_CURRENT_USE
R\Software\Microsoft
\Windows\CurrentVers
ion\Explorer\Shell
Folders\CD Burning]
WshShell = new OleAutoClient("WScript.Shell")
try
cDir=WshShell.RegRead(RegKey)
catch(exception e)
cDir=""
endtry
doeldir = cDir

if empty(cDir)
msgbox("Windows CD-rom burning not found...!","Copiëer naar CD-rom")
return
endif

c_mydir=set("directory")

doeldir = doeldir + "\" + "manager3000"
If not ISDIR("&doeldir")
mkdir "&doeldir"
endif

_app.SourceDir = c_mydir


try
afiles = new Array() // Array for the files to be copied
temp = afiles.dir(_app.SourceDir + "\*.*") // any files in this
directory
for i = 1 to temp // copy the files to the target dir
fname = upper(afiles[i,1]) // i = No in array, Integer 1 =
filename, see OLH DIR
sname = _app.SourceDir + "\" + fname
tname = doeldir + "\" + fname
new File().copy(sname, tname)
next i
catch (exception e)
msgbox("An error occured while attempting to copy the files",
"Error", 16)
endtry




http://www.manager3000.nl/index.html
"Otto" < otto_slembeck@rogers
.com> schreef in bericht
news:X6ihm%23q0FHA.1236@news-server...
> I use a dB2K program to back up my files to a re-writable CD using:
> run xcopy c:\MyDirectory\*.* M:\Backup\*.* /s /v
> (where M: is the CD drive).
>
> This worked fine until I upgraded from Windows Me to Windows XP. Now

nothing
> is copied.
>
> Thanks for your help
>
> Otto
>
>



Linda C. Baker

2005-11-10, 8:23 pm

I tried this and it displays the error "CD Rom burning not found" even though I have an entry in my registry for this HKEY_CURRENT_USER\So
ftware\Microsoft\Win
dows\CurrentVersion\
Explorer\Shell Folders\CD Burning

It seems like it is not reading the registry field. What am I doing wrong? Thanks.

Ronald de Vries Wrote:

> with whole folder
> see code below
> Ronald de Vries
>
> #define ISDIR(cDir) .Not. Empty(funique(cDir+"\isdir???.???"))
> RegKey =
> & #91;HKEY_CURRENT_USE
R\Software\Microsoft
\Windows\CurrentVers
ion\Explorer\Shell
> Folders\CD Burning]
> WshShell = new OleAutoClient("WScript.Shell")
> try
> cDir=WshShell.RegRead(RegKey)
> catch(exception e)
> cDir=""
> endtry
> doeldir = cDir
>
> if empty(cDir)
> msgbox("Windows CD-rom burning not found...!","Copiëer naar CD-rom")
> return
> endif
>
> c_mydir=set("directory")
>
> doeldir = doeldir + "\" + "manager3000"
> If not ISDIR("&doeldir")
> mkdir "&doeldir"
> endif
>
> _app.SourceDir = c_mydir
>
>
> try
> afiles = new Array() // Array for the files to be copied
> temp = afiles.dir(_app.SourceDir + "\*.*") // any files in this
> directory
> for i = 1 to temp // copy the files to the target dir
> fname = upper(afiles[i,1]) // i = No in array, Integer 1 =
> filename, see OLH DIR
> sname = _app.SourceDir + "\" + fname
> tname = doeldir + "\" + fname
> new File().copy(sname, tname)
> next i
> catch (exception e)
> msgbox("An error occured while attempting to copy the files",
> "Error", 16)
> endtry
>
>
>
>
> http://www.manager3000.nl/index.html
> "Otto" < otto_slembeck@rogers
.com> schreef in bericht
> news:X6ihm%23q0FHA.1236@news-server...
> nothing
>
>


Linda C. Baker

2005-11-15, 8:23 pm

I found my problem on reading the registry key. I had a misspelling.
It seems to be working now. Thanks.

Linda C. Baker Wrote:

> I tried this and it displays the error "CD Rom burning not found" even though I have an entry in my registry for this HKEY_CURRENT_USER\So
ftware\Microsoft\Win
dows\CurrentVersion\
Explorer\Shell Folders\CD Burning
>
> It seems like it is not reading the registry field. What am I doing wrong? Thanks.
>
> Ronald de Vries Wrote:
>
>


evilaro

2005-11-16, 8:23 pm

Ronald:

Has any body told you.... you are a genious...
....

Its perfect...

Could you clarify...

Here you are using a default copier-driver from MS...
In some computers I do not have it (and its a XP)

In such cases what would be the solution to use another driver...
still I have put the registry of other burners that I got.. and it tells me
that the burnin driver is not found???

Any Ideas...

IThanks.

Emilio


"Ronald de Vries" < adviesgroepfriesland
@home.nl> escribió en el mensaje
news:6bZl3Nu0FHA.1044@news-server...
> with whole folder
> see code below
> Ronald de Vries
>
> #define ISDIR(cDir) .Not. Empty(funique(cDir+"\isdir???.???"))
> RegKey =
>

& #91;HKEY_CURRENT_USE
R\Software\Microsoft
\Windows\CurrentVers
ion\Explorer\Shell[c
olor=darkred]
> Folders\CD Burning]
> WshShell = new OleAutoClient("WScript.Shell")
> try
> cDir=WshShell.RegRead(RegKey)
> catch(exception e)
> cDir=""
> endtry
> doeldir = cDir
>
> if empty(cDir)
> msgbox("Windows CD-rom burning not found...!","Copiëer naar CD-rom")
> return
> endif
>
> c_mydir=set("directory")
>
> doeldir = doeldir + "\" + "manager3000"
> If not ISDIR("&doeldir")
> mkdir "&doeldir"
> endif
>
> _app.SourceDir = c_mydir
>
>
> try
> afiles = new Array() // Array for the files to be copied
> temp = afiles.dir(_app.SourceDir + "\*.*") // any files in this
> directory
> for i = 1 to temp // copy the files to the target dir
> fname = upper(afiles[i,1]) // i = No in array, Integer 1 =
> filename, see OLH DIR
> sname = _app.SourceDir + "\" + fname
> tname = doeldir + "\" + fname
> new File().copy(sname, tname)
> next i
> catch (exception e)
> msgbox("An error occured while attempting to copy the files",
> "Error", 16)
> endtry
>
>
>
>
> http://www.manager3000.nl/index.html
> "Otto" < otto_slembeck@rogers
.com> schreef in bericht
> news:X6ihm%23q0FHA.1236@news-server...
> nothing
>
>[/color]


Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com