+ Reply to Thread
Results 1 to 4 of 4

Macro to import data based on 2 criteria

  1. #1
    Registered User
    Join Date
    03-29-2014
    Location
    England
    MS-Off Ver
    Excel 2007
    Posts
    32

    Macro to import data based on 2 criteria

    Hello,

    What I need is a macro which will copy and paste data into different places depending on the corresponding information in the same row.

    e.g. 1. Sheet "Data" Row "3" contains:


    A
    B
    C
    D
    E
    F
    1
    10:00 AM
    THE NUT JOB 2D
    U
    11:36 AM
    SA,SU


    The 2 deciding factors are in column "A" (screen number) and "F" (week day)

    this means that in Sheet "Organised": "E9" & "E13" need to contain "THE NUT JOB 2D", "C9" & "C13" need to contain "10:00 AM" and "D9" & "D13" needs to contain "11:36 AM"

    This is because Column "A" indicates which screen header it should be under and Column "F" decides which days it need to be beside (SA = Saturday etc)

    I am completely open to any ideas, if you think this could be achievable with formulas, I am happy to try that.

    Many thanks!
    Attached Files Attached Files
    Last edited by jimbobakoo; 12-10-2014 at 08:51 AM.

  2. #2
    Registered User
    Join Date
    03-29-2014
    Location
    England
    MS-Off Ver
    Excel 2007
    Posts
    32

    Re: Macro to import data based on 2 criteria

    Just in case you need another example to clarify things further, Sheet "Data" Row "4" contains:

    A
    B
    C
    D
    E
    f
    7
    10:00 AM
    THE PENGUINS OF MADAGASCAR 2D
    U
    11:57 AM
    SA,SU


    This means that in Sheet "Organised": "W9" & "W13" need to contain "THE PENGUINS OF MADAGASCAR 2D", "U9" & "U13" need to contain "10:00 AM" and "V9" & "V13" needs to contain "11:57 AM"
    Last edited by jimbobakoo; 12-10-2014 at 08:50 AM.

  3. #3
    Registered User
    Join Date
    03-29-2014
    Location
    England
    MS-Off Ver
    Excel 2007
    Posts
    32

    Re: Macro to import data based on 2 criteria

    Its the fact that I have 2 criteria to sort by which stumps me. this makes 133 different variables which the days could be and 12 variables the screens could be, which would 1596 different possible outcomes if something like 'IF' statements were used. I'm guessing some form of 'LOOKUP' will have to be used, or first create an array with the data?

  4. #4
    Registered User
    Join Date
    03-29-2014
    Location
    England
    MS-Off Ver
    Excel 2007
    Posts
    32

    Re: Macro to import data based on 2 criteria

    Don't want to sound needy, but is this even possible? Usually my posts get answered pretty sharpish on here.

    Thanks again all.

+ 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. Import the Data based on Specific Filter Criteria
    By mvinay in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-09-2014, 12:05 AM
  2. Replies: 4
    Last Post: 01-08-2013, 12:37 PM
  3. import data based on matching criteria
    By jamminz1 in forum Excel General
    Replies: 1
    Last Post: 06-21-2012, 06:57 AM
  4. Import data range based on specific criteria
    By pdmkh in forum Excel General
    Replies: 4
    Last Post: 10-14-2009, 02:07 AM
  5. [SOLVED] Import data from one xls file to another based on criteria
    By Hardhit in forum Excel General
    Replies: 0
    Last Post: 02-15-2006, 04:10 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