+ Reply to Thread
Results 1 to 4 of 4

Targeting Fields and Counting Up or Down Into Other Pre-determined Fields

  1. #1
    Registered User
    Join Date
    04-23-2013
    Location
    USA
    MS-Off Ver
    Excel 2007
    Posts
    3

    Targeting Fields and Counting Up or Down Into Other Pre-determined Fields

    I need to have the sheet search through one predetermined field and move up or down based on a positive or negative number. If it reaches the top or bottom of the first predetermined field, I need it to move up or down into the next field and continue counting. It cannot use the top or bottom field to begin counting. Another option would be to have it cycle within the same field (so, it reaches the top and then begins counting at the bottom, or reaches the bottom and begins counting at the top...like a wheel).

    A2 is the identifier (#1). I need A3 to find this in the 0-9 fields in the center (numbers in green). A1 is the counter (#-3). In this case, I need it to count up into the 0-9 fields at the top. If it were a positive 3, it would need to count down to 4 in the green numbers. If it were a positive 12, I would need it to count down and cross into the bottom 0-9 field to find the 3 down there.

    The code cannot reference any specific data within the 3 0-9 fields, as the data can change frequently. It has to reference the spots only.

    This is really beyond my Excel skills. Any help would be most appreciated. Thank you!

    Book4.xlsx

    So, I have it set up this way[A3 is the spot I need code for]:
    A1 | -3
    A2 | 1
    A3 | ...?

    C2-C31:
    0
    1
    2
    3
    4
    5
    6
    7
    8
    9
    0
    1
    2
    3
    4
    5
    6
    7
    8
    9

    0
    1
    2
    3
    4
    5
    6
    7
    8
    9

  2. #2
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,578

    Re: Targeting Fields and Counting Up or Down Into Other Pre-determined Fields

    Is your base Green numbers always going to be in C12:C21? If not, how would Excel know where you're "Green Numbers" are? I named C12:C21 "Base" and then worked from there using OFFSET

    In A3,
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    If that's not going to work for you, I guess I need a clearer explanation.
    ChemistB
    My 2?

    substitute commas with semi-colons if your region settings requires
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
    If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  3. #3
    Registered User
    Join Date
    04-23-2013
    Location
    USA
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Targeting Fields and Counting Up or Down Into Other Pre-determined Fields

    WOW! Amazing!! That did it! Thank you so much!

  4. #4
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,166

    Re: Targeting Fields and Counting Up or Down Into Other Pre-determined Fields

    Based on your last post in this thread, its apparent that you are satisfied with the solution(s) you've received and have solved your question, but you haven't marked your thread as "SOLVED". I will do it for you this time.

    In future, to mark your thread as Solved, you can do the following -
    Select Thread Tools-> Mark thread as Solved.

    Incase your issue is not solved, you can undo it as follows -
    Select Thread Tools-> Mark thread as Unsolved.

    Also, since you are relatively new to the forum, i would like to inform you that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post which helped you. This adds to the reputation of the person who has taken the time to help you.
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

+ 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. Copy Excel data to Word fields and retain fields
    By GCW esq in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 06-06-2012, 10:31 AM
  2. How to Disable automatic fields in pivot table like total and count on fields
    By anushka in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 09-24-2009, 07:53 AM
  3. Differentiate between column fields and data fields in a pivot table
    By whiteheadw in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-12-2009, 01:59 PM
  4. Changing numbes in text fields into numbers in number fields
    By freaksareus in forum Excel General
    Replies: 4
    Last Post: 10-23-2008, 05:47 AM
  5. Excel SHOULD NOT AUTO-CHANGE formated text fields to DATE FIELDS!
    By PSSSD in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 08-08-2006, 04:35 PM

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