realbasic-nug
[Top] [All Lists]

Re: How can I determine if my program CD is in the drive ofa Win32 mach

To: REALbasic Network Users Group <realbasic-nug at lists dot realsoftware dot com>
Subject: Re: How can I determine if my program CD is in the drive ofa Win32 machine?
From: Karl Holmes <karlh at nh dot com dot au>
Date: Fri, 28 Jun 2002 22:58:56 +1000
George Clark wrote:

> On 6/28/02 08:18, Karl Holmes wrote:
>
> > I tried
> >
> > n=volumeCount-1
> > for i = 0 to n
> >   s= volume(i).name
> >   f=getfolderitem(volume(i).name).child("SFDev409") //SFDev409 is a
> > file on top level of CDROM
> >   if not(f =nil) then
> >     if f.exists then
> >       statictext1.text = "CDROM found"
> >     end if
> >   end if
> > next
> >
> > but couldn't get this to work even on a Mac, f was always nil.
>
> There are probably Windows routines that can find the CD for you, but in the
> meantime, try using volume(i).child("SFDev409").
>
> George

Thanks George but when I replace
 f=getfolderitem(volume(i).name).child("SFDev409")
with
f=getfolderitem(volume(i)).child("SFDev409")

I get a type mismatch error

Have I got the syntax correct?. It  is getting late here in Australia and I'm
getting tired.

Karl Holmes



<Prev in Thread] Current Thread [Next in Thread>