开发者

Retrieve resume in asp.net

开发者 https://www.devze.com 2022-12-27 17:46 出处:网络
In my visual st开发者_StackOverflowudio 2005 I just created new folder for resume uploading. I just uploaded some resumes in this folder...Now I want to retrieve the resume for particular user..How ca

In my visual st开发者_StackOverflowudio 2005 I just created new folder for resume uploading. I just uploaded some resumes in this folder...Now I want to retrieve the resume for particular user..How can I achieve this? Is there any need to create table for storing path name and retrieve? ...Just explain if possible provide code for retrieve resume from folder in vs 2005 in asp.net.


I prefer to store path in database, but it isn't necessarily. You can save files with id in name: resume[id].txt. For example: resume1.txt.

using System.IO;
using System.Text;

...

string folderName = "resume";
int resumeID = 1; //userID
TextReader textReader = new StreamReader(Request.PhysicalApplicationPath + foldserName+@"\resume"+resumeID+".txt",Encoding.UTF8);
string resume = textReader.ReadToEnd();
textReader.Close();
0

精彩评论

暂无评论...
验证码 换一张
取 消