+ Reply to Thread
Results 1 to 2 of 2

Macro Formula

  1. #1
    Corey
    Guest

    Macro Formula

    All of my macros to date are for formatting, so I'm running into a bit of a
    problem for a formula macro. I tend to use this formula often when using
    pivot tables, as I need the left most column of the pivot table to poplulate
    on every row. For example, the pivot table will result the following:

    John Green 2
    Red 3
    Brown 4
    Julie Green 1
    Red 2
    Brown 3

    I really need it to list the names on each row. So I tend to copy the table
    and paste it as a value, then use the following formula in the immediate
    column to the left of the table data to populate:

    =IF(G22="",IF(F21="",G21,F21),G22)

    Of course this must be relative to the copied cells position. How can I
    write the macro for this and still keep the cell referencing correct?

    Any help is much appreciated. Thanks!





  2. #2
    Corey
    Guest

    RE: Macro Formula

    Nevermind....I figured it out.

    "Corey" wrote:

    > All of my macros to date are for formatting, so I'm running into a bit of a
    > problem for a formula macro. I tend to use this formula often when using
    > pivot tables, as I need the left most column of the pivot table to poplulate
    > on every row. For example, the pivot table will result the following:
    >
    > John Green 2
    > Red 3
    > Brown 4
    > Julie Green 1
    > Red 2
    > Brown 3
    >
    > I really need it to list the names on each row. So I tend to copy the table
    > and paste it as a value, then use the following formula in the immediate
    > column to the left of the table data to populate:
    >
    > =IF(G22="",IF(F21="",G21,F21),G22)
    >
    > Of course this must be relative to the copied cells position. How can I
    > write the macro for this and still keep the cell referencing correct?
    >
    > Any help is much appreciated. Thanks!
    >
    >
    >
    >


+ 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