How can I create a RAM disk programmatically?
How can I create a RAM disk programmatically? I am not looking for a code that invokes a command line utility, which does the trick. I am actually interested to know the API used to create a RAM disk. EDIT Motivation: I have a third party library which expects a directory name in order to process the files in that directory in a certain way. I have these files zipped in an archive. I wish to extract the archive into a RAM disk and pass the third party the path to the respective directory on that RAM disk. As you can see, memory mapped files are of no use to me . If you really consider RAM disk , there is no such CreateRAMDisk function in Windows. I think you need to look at how to create a driver for a disk, but the disk is redirected to RAM. However, if you want to simply redirect files to memory, then using memory-mapped file will do the task. – minjang Jan 1 '12 at 9:36 ...