Hi guys

I've never worked with script before and I'm not sure but I think the solution around my problem will be in script but don't take in mind that yet as I said I've never worked with script.

I have a DVD+RW I want to burn or embed a program inside the disc that will be able to determine or detect the type of player(device) the disc is inserted in, I have these list which I want the script or the program as a disc manager to handle these devices differently but there will be two types of handling one is to copy a folder inside this disc not the program but the folder because there will be a folder too that will be added to the disc, so the 1st handling will be copying a folder to a temporal file in 'C:/temp' (this will be the handling of a CD/DVD Rom or writer ie a computer) and the 2nd handling will be temporary unlock a file so that the contents inside can be used by a DVD player device ie home theater,playstation , and car stereo this can do it like this:

While the folder is temporary unlocked if the power on a device run out then it should get back to default and lock the folder,

If the user eject the disc then it should lock by default the folder, this can be like destroying the temporary unlocked folder so that it will remain the locked folder, I have now the locker and unlocker just need to do this device or player device type detector only.

Anyone with a help or suggestion on how I can do this?

Recommended Answers

All 4 Replies

I am unsure, but if I understand what you are asking - you may be implying that hardware and software are synonymous.

If you wish for a program to run off the disk only, then create an autorun to install the software, but point to the disk for resources. As for locking/unlocking on a car stereo - you will have to know what type of code the stereo can execute. (Guarantee that not .NET will not be available for a VERY large amount.)

The better question would be: Why are you locking/unlocking the folder so much?

Why not just force the user to use the CD if they want use your application.

The reason why I'm locking the folder is that I don't want the user to manually have access to the contents of the disc so let say if the user insert the disc into a stereo so the program will not function because the stereo doesn't have the capability to execute the programs so the contents in stereo will not be locked so that the stereo can read the contents but a minute a user inserted in to a computer the program will then lock the files so that the user will not be able to manually use this or view the contents in the disc so there will be a program installed in a computer that will be the only program that will have the permissions to access the contents inside the disc.

You could store the files as serialized files and use your application to serialize/deserialize them as needed.

Have a look at this.

Hi, I think this is a piece of code you could use, it checks for drives being present (Fixed, Network, NoRootDirectory, Ram, Removable, Unknown) In the code I use it to get the driveletter of a Removable device if present.

Dim drv As DriveInfo
For Each drv In DriveInfo.GetDrives
    If drv.IsReady Then
        If drv.DriveType = IO.DriveType.Removable Then
             MsgBox(drv.RootDirectory.FullName)
        End If
    End If
Next
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.