+ Reply to Thread
Results 1 to 10 of 10

Tranferring data between worksheets depending on a couple of variables

  1. #1
    Registered User
    Join Date
    01-24-2015
    Location
    United Kingdom
    MS-Off Ver
    2010
    Posts
    6

    Tranferring data between worksheets depending on a couple of variables

    Hi

    I have been trying to get the below to work for a little while now but no luck at the minute, perhaps one of you guys may have better ideas that me?

    I have attached a copy of the workbook for reference. What I am trying to do is to populate 'page per pole' with work items in 'field sheet' when the pole number on the 'page per pole' matches the pole number on 'field sheet'. I have allowed 12 lines on 'page per pole' as this is a max I should need. Just need to get the code right to get it working!

    Once this is working, I then need to write a macro to create seperate 'page per poles' based on pole numbers in 'field sheet'.

    Any help or ideas welcome!

    Cheers

    Mark
    Attached Files Attached Files

  2. #2
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Tranferring data between worksheets depending on a couple of variables

    Hi bartonMark,

    Welcome to the Forum!

    Try this:

    Please Login or Register  to view this content.
    Directions for running the routine(s) just supplied

    If you haven't used macros before you'll need to go to:
    File- options - trust center -trust center settings - macro settings ,
    the second option down (disable all macros with notification)

    Then - Copy the code to the clipboard

    Open your Workbook

    Press ALT + F11 to open the Visual Basic Editor.

    Select "Module" from the Insert menu

    Type "Option Explicit" then paste the code under it

    With the cursor between Sub and End Sub press F5 (F8 to Single Step)

    OR

    Press ALT + Q to close the code window.

    Press ALT + F8 then double click on the macro name

    *Rename Page per Pole as BlankPole and delete Column B

    Nevermind - here it is:PolePages().xlsm
    Last edited by xladept; 02-02-2015 at 06:20 PM.
    If I've helped you, please consider adding to my reputation - just click on the liitle star at the left.

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~(Pride has no aftertaste.)

    You can't do one thing. XLAdept

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~aka Orrin

  3. #3
    Registered User
    Join Date
    01-24-2015
    Location
    United Kingdom
    MS-Off Ver
    2010
    Posts
    6

    Re: Tranferring data between worksheets depending on a couple of variables

    Hi XLAdept

    Your code got me loads further than I was! Thank you very much for your help, its very much appreciated!

  4. #4
    Registered User
    Join Date
    01-24-2015
    Location
    United Kingdom
    MS-Off Ver
    2010
    Posts
    6

    Re: Tranferring data between worksheets depending on a couple of variables

    Hi XLAdept

    Your code got me loads further than I was! Thank you very much for your help, its very much appreciated!

  5. #5
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Tranferring data between worksheets depending on a couple of variables

    You're welcome and thanks for the rep!

  6. #6
    Registered User
    Join Date
    01-24-2015
    Location
    United Kingdom
    MS-Off Ver
    2010
    Posts
    6

    Re: Tranferring data between worksheets depending on a couple of variables

    Hi XLAdept,

    When inputting on the sheet, if I put in a number on the same line for say poles 1,2,3,4,5,6 and 7 - when this is transferring over, the code is summing up all the numbers and putting them in the column instead of displaying the qty in the line under the pole number in the sheet (if that makes sense?). Any ideas how to achieve this?

    Cheers

    Mark

  7. #7
    Registered User
    Join Date
    01-24-2015
    Location
    United Kingdom
    MS-Off Ver
    2010
    Posts
    6

    Re: Tranferring data between worksheets depending on a couple of variables

    Hi XLAdept,

    When inputting on the sheet, if I put in a number on the same line for say poles 1,2,3,4,5,6 and 7 - when this is transferring over, the code is summing up all the numbers and putting them in the column instead of displaying the qty in the line under the pole number in the sheet (if that makes sense?). Any ideas how to achieve this?

    Cheers

    Mark

  8. #8
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Tranferring data between worksheets depending on a couple of variables

    Hi,

    Yeah, I did that on purpose - I'll try to figure another way

    Try this:

    Please Login or Register  to view this content.
    Last edited by xladept; 02-03-2015 at 09:41 PM.

  9. #9
    Registered User
    Join Date
    01-24-2015
    Location
    United Kingdom
    MS-Off Ver
    2010
    Posts
    6

    Re: Tranferring data between worksheets depending on a couple of variables

    Hi XLAdept

    You my friend are an absolute legend!!

    Cheers

    Mark

  10. #10
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Tranferring data between worksheets depending on a couple of variables

    Awww Shucks!

+ 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. Insert formula depending on cells depending of variables
    By elmexicano87 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 01-29-2014, 01:22 PM
  2. Selecting data from tables depending on variables
    By ninja20007@gmail.com in forum Excel General
    Replies: 0
    Last Post: 04-26-2012, 02:50 PM
  3. Cannot understand the meaning of a couple of variables
    By rasmus1166 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-09-2011, 07:14 AM
  4. Tranferring Data on given date
    By redondo5 in forum Excel General
    Replies: 0
    Last Post: 03-31-2010, 12:59 PM
  5. Replies: 2
    Last Post: 04-13-2006, 07:25 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