?
Solved

How to upload a file to memory instead of to the server file system?

Posted on 2008-11-06
2
Medium Priority
?
189 Views
Last Modified: 2010-04-21
Hi friends,

I need to upload a file to a server but I dont want to allow the client to access the server file system. I just want to upload it to memory, loop through it and save the records in a DB.
I dont need the file to be stored.

Is there a way in ASP.NET?

thanks.
0
Comment
Question by:ahll
2 Comments
 
LVL 4

Accepted Solution

by:
BToson earned 900 total points
ID: 22900639
Hi,
You can get the file stream using something like UploadContol.PostedFile.InputStream and get the text contents using a StreamReader.
0
 
LVL 3

Author Closing Comment

by:ahll
ID: 31515048
Thanks BToson,

That actually gave me the direction where to look. I finally figured it out.
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today is the age of broadband.  More and more people are going this route determined to experience the web and it’s multitude of services as quickly and painlessly as possible. Coupled with the move to broadband, people are experiencing the web via …
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
This video shows how to quickly and easily deploy an email signature for all users in Office 365 and prevent it from being added to replies and forwards. (the resulting signature is applied on the server level in Exchange Online) The email signat…
Loops Section Overview
Suggested Courses

807 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question