+ Reply to Thread
Results 1 to 1 of 1

Assign values for2 ranges in both directions with slight difference

  1. #1
    Forum Contributor
    Join Date
    10-08-2019
    Location
    Singapore
    MS-Off Ver
    2016
    Posts
    326

    Assign values for2 ranges in both directions with slight difference

    Hi

    I have the following situation, of i think i need 2 very similar codes probably with a slight differentiation.
    (pls see att sample wb)

    Pink fills and beige fills are blanks or unused ranges.

    Sheet1a - situation a upward direction
    assign the values in the ranges D:E, AD:AJ of the last-used row (italic) to their corresponding ranges in immediate row above (beige fill). Then, clear contents of the source ranges.

    Sheet1b - situation b upward direction
    same situation, only here there could be more than 1 blank range between last-used row and second last filled row (pinks fill), but still just assign the values in the ranges D:E, AD:AJ of the last-used row (italic) to their corresponding ranges in immediate row above (beige fill). Then, clear contents of the source ranges.

    Sheet1c – situation c downward direction
    assign the values in the ranges D:E, AD:AJ of the second last-used row (italic) to their corresponding ranges in immediate row below it (beige fill). BUT, for downward assign, do NOT clear the contents of the source ranges.


    I've gotten stuck at first code for sheet1a & 1b, and pratically no idea for the code for sheet1c.

    Appreciate if anyone can offer any help,


    Stewart
    Attached Files Attached Files

+ 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. [SOLVED] Altering macro for slight difference in data
    By rodeam in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-20-2016, 11:16 AM
  2. [SOLVED] Vba to assign ranges to a variable
    By andikeep2580 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 01-08-2016, 10:33 PM
  3. [SOLVED] Counting Unique Values - Slight variations do not seem to work properly
    By Karroog in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 04-29-2014, 01:07 PM
  4. [SOLVED] Number difference involving ranges with a mix of positive and negative values
    By coasterman in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-17-2013, 02:34 PM
  5. fomatting cells based on difference between values of cells two ranges.
    By KATIEexcel in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-05-2013, 04:08 AM
  6. Replies: 4
    Last Post: 02-27-2013, 05:51 PM
  7. *** VBA Assign Value From Text and Value Ranges ***
    By Backroads23 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-22-2012, 03:01 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