TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
sanjay ch
NA
24
5.1k
How to import resume and Display in text fields in MVC
Oct 10 2014 1:34 AM
I have one file upload control in Asp.net or MVC,
When i am uploading a resume to the control, the content in the resume like Name, Mobile Number, Email
should be display in the text fields, for example, while a resume of a employee is uploaded, employee details
like Name, Email, Mobile Number etc., from the resume should be display in the resume.
Is it possible in Asp.net or MVC, with any open source tool.
I have tried with Open XML SDK like
using (WordprocessingDocument doc = WordprocessingDocument.Open(path, true))
{
MainDocumentPart mPart = doc.MainDocumentPart;
XmlDocument xmlDocument = new XmlDocument();
using (StreamReader reader = new StreamReader(mPart.GetStream()))
{
Document document = new Document();
document.Load(mPart);
document.Save(mPart);
System.Diagnostics.Process.Start(path);
// Value of operation attribute.
XDocument xDocument = XDocument.Load(XmlReader.Create(reader));
XNamespace w = "http://schemas.openxmlformats.org/wordprocessingml/2006/main";
// the elements we will be looking for data.
XName rPr = w + "pPr";
XName p = w + "p";
var query =( from element in xDocument.Descendants(p)
select new DocumentModel
{
ItemProperty = element.Element(rPr) != null ?
((from sElement in element.Descendants(rPr)
select new ItemProperty
{
Style = sElement.IsEmpty == false ?
(sElement.Element(w + "pStyle") != null ?
sElement.Element(w + "pStyle").Attribute(w + "val").Value :
string.Empty) : string.Empty,
Lang = sElement.IsEmpty == false ?
(sElement.Element(w + "lang") != null ?
(sElement.Element(w + "lang").Value ?? string.Empty) :
string.Empty) : string.Empty
}).First<ItemProperty>()) : null,
Text = element.Value == string.Empty ? "<br/>"
: element.Value
}).ToList();
model.EMP_NAME = query.ElementAt(0).Text.Trim(); // Getting Candidate Name
model.PHONE = query.ElementAt(1).Text; // Getting Candidate Mobile Number
model.EMAIL = query.ElementAt(2).Text.Trim(); // Getting Candidate Email
}
}
}
But, How can Search and Validate the Content with List, or in any other tool.
Please help me someone. Thanks in Advance.
Reply
Answers (
8
)
How to get Container.ItemIndex+1 in textbox control
ASP.Net Datagrid Get Column Index from Column Name