+ Reply to Thread
Results 1 to 5 of 5

How to extract a 15 or 16 digit number from an email.

  1. #1
    Registered User
    Join Date
    02-21-2014
    Location
    USA
    MS-Off Ver
    Excel 2013
    Posts
    2

    How to extract a 15 or 16 digit number from an email.

    Hi there

    I am new to this forum. I have been assigned a task at work for which i need your help.

    I have a cell containing body of an email.How can i check for 15 or 16 digit number in the text and extract it. Basically i am checking for a credit card number in the email and if it is there then i need to extract it to adjacent colum.

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 2000/3/7/10/13/16/365
    Posts
    52,239

    Re: How to extract a 15 or 16 digit number from an email.

    Hi and welcome to the forum

    Almost impossible to answer this without seeing a sample of what you are working with

    Please post a few MADE_UP examples of your data
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    02-21-2014
    Location
    USA
    MS-Off Ver
    Excel 2013
    Posts
    2

    Re: How to extract a 15 or 16 digit number from an email.

    Hi there i have uploaded a sample worksheet. What i need is to extract a 15 or 16 digit credit card number.
    Attached Files Attached Files

  4. #4
    Valued Forum Contributor
    Join Date
    10-14-2012
    Location
    Netherlands
    MS-Off Ver
    Excel 2019
    Posts
    343

    Re: How to extract a 15 or 16 digit number from an email.

    This is my VBA solution....
    Attached Files Attached Files
    Kind regards,
    Piet Bom

  5. #5
    Forum Moderator daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,676

    Re: How to extract a 15 or 16 digit number from an email.

    Cross posted here
    Audere est facere

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Extract Exact 6 Digit Number From String
    By tt388 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-11-2013, 12:51 PM
  2. Extract 9 digit number from string
    By Jbentley in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 11-16-2011, 07:02 AM
  3. pull 8 digit string (number) from the body of email
    By Kreiz in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-07-2011, 05:24 PM
  4. Extract 10 digit number from string
    By R. Choate in forum Excel Programming / VBA / Macros
    Replies: 20
    Last Post: 10-27-2005, 06:05 PM
  5. [SOLVED] Extract 2, 3, 4 or 5-digit number from string
    By Jim in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-07-2005, 10:22 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1