How to find candidate email Id from a resume (word or pdf file) in asp.net during bulk upload...I am able to extract the email ids using RichEditDocumentServer..But how to get exactly the candidate email id from a CV..Please provide a solution at the earliest..

Dani AI

Generated

Quick summary and a practical approach that complements ’s regex idea and ’s note that you already extract text (with RichEditDocumentServer): extracting every email is easy; picking the candidate email reliably requires context-based scoring plus a safe fallback for low-confidence cases.

Key heuristics to score each found address (combine these into a single numeric score):

  • Position: emails in the first 5–10 lines (document header) get a big boost.
  • Labeling: presence of nearby tokens like email, e-mail, contact, contact info adds weight.
  • Name match: compare the email local-part (before @) against the candidate name (firstname, lastname, initials). Normalize by lowercasing and removing dots/underscores.
  • Phone proximity: if an email appears within the same line or +/- 2 lines of a phone number, boost it.
  • Domain type: prefer personal domains (gmail/yahoo/outlook) or ones that match the candidate name; deprioritize info@, jobs@, or domain names clearly of previous employers mentioned in the same paragraph.
  • Repetition/filtering: ignore exact duplicates, and detect header/footer repeats on multi-page resumes.

Suggested processing steps:

  1. Extract plain text preserving paragraph order (and coordinates if PDF parser provides them).
  2. Run a robust email regex to collect candidates.
  3. For each email collect metadata: line index, nearby words (window +/- 3 lines), nearest phone number, and name-similarity score.
  4. Compute total score using weights for the heuristics above and pick the highest.
  5. If top score < threshold (e.g., 65–75%), save top 3 candidates and mark for manual review. For bulk uploads, auto-insert only when confidence is high.
  6. Store filename, chosen email, confidence score and the raw extracted list in DB for auditing.

Example (very small C# sketch):

var emailRx = new Regex(@"\b[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,}\b", RegexOptions.IgnoreCase);
var emails = emailRx.Matches(text).Cast<Match>().Select(m=>m.Value).Distinct();
foreach(var em in emails) {
  int score = 0;
  if (IsInHeader(em)) score += 40;
  if (HasLabelNear(em,"email","contact")) score += 50;
  if (MatchesName(em,candidateName)) score += 60;
  if (NearPhone(em)) score += 30;
  // choose max score, compare against threshold
}

Troubleshooting notes: scanned PDFs need OCR, some PDFs lose line breaks so use coordinates when available, and resumes often include recruiter/previous-employer emails — keep a manual-review path for ambiguous cases. This approach is practical for bulk processing and keeps false inserts low while still automating the common cases.

Recommended Answers

All 3 Replies

Member Avatar for Member #949455

How to find candidate email Id from a resume (word or pdf file) in asp.net during bulk upload...I am able to extract the email ids using RichEditDocumentServer..But how to get exactly the candidate email id from a CV..Please provide a solution at the earliest..

I don't understand your question. You was to find a email id in ASP.net?

Here is a link of a code you can used to extract email id.

http://aspdotneta-zsolutions.blogspot.com/2012/02/extract-email-ids-from-remote-web-page.html

This is way I get confused, you want to extract info from (Word or pdf file) in ASP.net by email ID? You are asking 2 things to happened at once.

I'm not very familiar with what you are asking. Explain a little more.

I mean how to extract email ids from the word or pdf(resume) file)...I am able to extract..But if there are multiple email ids how can one get the exact candidate email id....Actualy i wish to insert only the candidate email id and filename from the resumes into database
during bulk upload...

Member Avatar for Member #949455

I mean how to extract email ids from the word or pdf(resume) file)...I am able to extract..But if there are multiple email ids how can one get the exact candidate email id....Actualy i wish to insert only the candidate email id and filename from the resumes into database
during bulk upload...

In order to extract the email ids from word or pdf is by strings.

Regarding about how to insert the data:

Read this:

http://www.devmanuals.com/tutorials/ms/aspdotnet/insertdataindatabse.html

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.