I have written a program that I have to save large data in the variables. how can I use files instead of memory? like virtual memory (page file)
Asked
Active
Viewed 441 times
1 Answers
1
You can leverage Memory Mapped Files for this. In .NET Framework this nice feature is available since version 4.0
.
See Non-persisted memory-mapped files
Non-persisted files are memory-mapped files that are not associated with a file on a disk. When the last process has finished working with the file, the data is lost and the file is reclaimed by garbage collection. These files are suitable for creating shared memory for inter-process communications (IPC).

sll
- 61,540
- 22
- 104
- 156
-
Thanks for your interest.I have seen this before,but I have to use .Net 3.5.is there an alternative method? – Javad Ahmadzadeh May 28 '12 at 16:06