+ Reply to Thread
Results 1 to 2 of 2

Macro or formula to copy data based on criteria

  1. #1
    MT
    Guest

    Macro or formula to copy data based on criteria

    Does anyone know how I might be able to do the following problem. I
    have a workbook broken down with multiple sheets by player position
    (QB, RB, WR, etc)

    Ex - QB Page
    ColA ColB ColC ColD-F ColG
    FirstNm LastNm Team Various LTeam

    ColG is a drop down list of teams to assign the player. When I make
    this selection I would like to have ColA, ColB, and ColC copied to the
    appropriate section of another sheet which would look like this

    LTEAM (static)
    ColA ColB ColC ColD ColE ColF
    QB1 <firstName Last Name> <Team> RB1 <first,last> Team
    QB2 RB2
    QB3 RB3
    RB4

    The above sheet would be broken down by LTeam and the player selected
    would be populated in the next available slot.

    Can anyone help? Thanks


  2. #2
    Registered User
    Join Date
    08-24-2005
    Posts
    33
    You need to set up a macro that copies across the right code depending on what you choose.

    Set up a variable for the choice -

    dim choice as string


    then maybe use a select....case clause (look it up) to choose which thing to do according to the choice. Each case refers to each choice you make

    Under each case record the appropriate copy and paste and then it'll do it itself.

    oh - and make the macro run when you change the choice. or on click event or something. Depends on which excel version you are using. Might just be right click, assign macro in 97 for example.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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