We help IT Professionals succeed at work.

Create A file but not a physical file

jj819430
jj819430 asked
on
386 Views
Last Modified: 2010-04-15
Is there a way in C# to create a file, but never actually write it to disk. Just to create a small temporary file that would only be held as an object within the application. (I know this is a strange one) but it would make an application of mine much faster as I need to pass small files frequently, and it has to be files.
Comment
Watch Question

Commented:
Yes, you can use the System.IO.MemoryStream class that stores the information in memory and not in a file.
Commented:
Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION

Author

Commented:
Awesome. I won't get around to plugging this in for another 12 hours or so, but sounds like a reasonable answer so will give you the points.
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a sample view!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.