+ Reply to Thread
Results 1 to 4 of 4

How do I extract specific lines of data and import them into a new sheet?

  1. #1
    Registered User
    Join Date
    07-13-2017
    Location
    London, England
    MS-Off Ver
    2013
    Posts
    12

    How do I extract specific lines of data and import them into a new sheet?

    Hi there everyone,

    I'm looking for someone who can help provide some code that will do the following:

    -Extract specific rows from a long list of data that has a number in a column
    -Extract these rows into a new sheet (it inserts a new sheet into the workpaper which has the extracted rows)

    To give a bit of background so the above makes sense:
    - There is a long list of data (various amounts of figures)
    - A program runs that selects a sample (ie: it may pick 5 rows out of 100 to sample) and puts a number (in this case, 1-5) in a separate column to alert the user of which rows have been selected
    - This VBA code then runs, and extracts those 5 rows and inserts them into a new sheet in the same workpaper

    NB: Of course, the number of samples will vary use to use

    IE:

    Amount: Sample
    45 1
    2395
    284 2
    392 3
    39

    ^^So in this case, out of the 5 entries, 3 of them have been selected and have a number placed in an adjacent column (these numbers could be the criteria to extract the data?)

    Hope someone can help me, and appreciate and responses!

    PS: I should note I already have the code to pick the sample and assign the numbers to the specific data, I just need help to extract those specific rows into a new sheet
    Last edited by nathan488; 09-06-2017 at 06:03 PM. Reason: Moderator request per breaking Rule 1

  2. #2
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    Win10/MSO2016
    Posts
    12,994

    Re: Extract certain data into a new sheet

    title updated.
    Last edited by protonLeah; 09-07-2017 at 03:14 PM.
    Ben Van Johnson

  3. #3
    Registered User
    Join Date
    07-13-2017
    Location
    London, England
    MS-Off Ver
    2013
    Posts
    12

    Re: Extract certain data into a new sheet

    Quote Originally Posted by protonLeah View Post
    Your post does not comply with Rule 1 of our Forum RULES. Your post title should accurately and concisely describe your problem, not your anticipated solution.

    Use terms appropriate to a Google search. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will be addressed according to the OP's experience in the forum: If you have less than 10 posts, expect (and respond to) a request to change your thread title. If you have 10 or more posts, expect your post to be locked, so you can start a new thread with an appropriate title.

    To change a Title go to your first post, click EDIT then Go Advanced and change your title, if 2 days have passed ask a moderator to do it for you.

    Want to get your question answered quickly?
    • Ensure your question is not too vague. Don't assume anyone is familiar with your problem. While you can upload small attachments, describe your problem in the body of the post. We are fortunate to have several Excel gurus, but few mind-readers.
    • On the other hand, skip irrelevant details. Be descriptive and concise. Short, direct, and to-the-point questions with apt thread titles are almost always answered promptly.
    • Keep the scope reasonably narrow. Questions like, "How do I set up an accounting system in Excel?" might be a long time waiting.
    • Explain what you've already tried. ("Calculation is set to automatic, but formulas still don't compute") so helpers don't waste your time or theirs.
    • Post a WORKBOOK. Nobody wants to type data from a picture or paste text from your post into a spreadsheet as a prelude to helping. To attach a file, push the button with the paperclip (or scroll down to the Manage Attachments button), browse to the required file, and then push the Upload button.
    • If your question has not been answered within a day, consider adding another post with any additional information you believe is relevant. If you think your post is good as is, just reply to your own thread with the words "Bump no response", which will bring it to the top of the forum.

    (This thread should receive no further responses until this moderation request is fulfilled, as per Forum Rule 7)

    Is the title change okay?

  4. #4
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    Win10/MSO2016
    Posts
    12,994

    re: How do I extract specific lines of data and import them into a new sheet?

    Please Login or Register  to view this content.


    (How to) Upload a Workbook directly to the Forum
    (please do not post pictures or links to worksheets)
    • Click Advanced next to Quick Post button at the bottom right of the editor box.
    • Scroll down until you see "Manage Attachments",
    • Click the "Choose" button at the upper left (upload from your computer).
    • Select your file, click "open", click "upload"
    • Once the upload is completed the file name will appear below the input boxes in this window.
    • Close the Attachment Manager window.
    • Click "Submit Reply"
    Note: Please do not attach password protected workbooks/worksheets
    Ensure to disable any Workbook Open/Autorun macros before attaching!
    Last edited by protonLeah; 09-10-2017 at 08:16 PM.

+ 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. Replies: 3
    Last Post: 07-24-2016, 05:33 AM
  2. Replies: 3
    Last Post: 03-25-2016, 10:59 AM
  3. Extract specific Data to new sheet !
    By Idontunderstandexcel in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-22-2014, 07:06 AM
  4. Extract specific column data from specific sheet from multiple files in a folder
    By piggyfox in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 05-31-2013, 11:51 AM
  5. Macro to extract data from multiple workbooks, specific sheet, specific cells
    By crissandraauree in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-29-2012, 03:54 PM
  6. Function needed to extract data from one sheet and import sequentially on to another
    By privateryan in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-19-2009, 07:12 AM
  7. [SOLVED] import data from txt to specific col & rows in sheet
    By programmer in forum Excel General
    Replies: 0
    Last Post: 07-21-2005, 12:05 PM

Tags for this Thread

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