+ Reply to Thread
Results 1 to 7 of 7

Help to move value into first empty cell and adjacent cell please

  1. #1
    Registered User
    Join Date
    04-16-2013
    Location
    Canada
    MS-Off Ver
    Excel 2010
    Posts
    3

    Question Help to move value into first empty cell and adjacent cell please

    Hi,

    Hoping someone can help me with this. I've got a basic knowledge of macros and vba code, and this is a little beyond my knowledge.

    I have a chart with columns B-P, and rows 2-300 on worksheet 1. There are values in cells A1 & A2 on worksheet 2. I want a macro code to do the following:

    1. Scan column B, rows 2-300 on the chart on worksheet 1, and find the first empty cell;

    2. Input the value from cell A1 from worksheet 2 into the cell adjacent to the first empty cell in column B on worksheet 1 (eg. if first empty cell is B10, excel to input value from cell A1 into column C10 on worksheet 1); and

    3. Input the value from cell A2 from worksheet 2 into a corresponding cell in column P (eg. if it entered the value in A1 into cell C10, excel would put the value from cell A2 into cell P10).

    Would someone be able to help with the excel vba code?

    Thanks & Happy New Year,

    Sus

  2. #2
    Valued Forum Contributor fredlo2010's Avatar
    Join Date
    07-04-2012
    Location
    Miami, United States
    MS-Off Ver
    Excel 365
    Posts
    762

    Re: Help to move value into first empty cell and adjacent cell please

    Can you attach a sample?

    thanks

  3. #3
    Forum Expert
    Join Date
    11-28-2012
    Location
    Guatemala
    MS-Off Ver
    Excel 2010
    Posts
    2,394

    Re: Help to move value into first empty cell and adjacent cell please

    Happy New Year to you too!!

    change the primary and other values to match your worksheets

    Please Login or Register  to view this content.

  4. #4
    Forum Expert
    Join Date
    12-24-2007
    Location
    Alsace - France
    MS-Off Ver
    MS 365 Office Suite
    Posts
    5,066

    Re: Help to move value into first empty cell and adjacent cell please

    Try
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by PCI; 01-01-2014 at 12:39 PM. Reason: Typo

  5. #5
    Valued Forum Contributor fredlo2010's Avatar
    Join Date
    07-04-2012
    Location
    Miami, United States
    MS-Off Ver
    Excel 365
    Posts
    762

    Re: Help to move value into first empty cell and adjacent cell please

    my code

    Please Login or Register  to view this content.
    Happy New Year!!!

  6. #6
    Registered User
    Join Date
    04-16-2013
    Location
    Canada
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: Help to move value into first empty cell and adjacent cell please

    Thanks everyone - much appreciated. I'll give them a shot!

  7. #7
    Registered User
    Join Date
    04-16-2013
    Location
    Canada
    MS-Off Ver
    Excel 2010
    Posts
    3

    Smile Re: Help to move value into first empty cell and adjacent cell please

    The code works great. Thank you all so much - really appreciate it!!

    Sus

+ 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. User form to display adjacent cell value and move to next blank cell
    By Ketel in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-21-2008, 03:15 PM
  2. Replies: 1
    Last Post: 02-06-2008, 08:23 AM
  3. Finding Adjacent empty cell
    By s1ip in forum Excel General
    Replies: 1
    Last Post: 07-14-2006, 03:55 PM
  4. Replies: 0
    Last Post: 05-29-2006, 07:25 AM
  5. How to Automatically Move Cell datato adjacent cell..
    By cardingtr in forum Excel General
    Replies: 1
    Last Post: 10-16-2005, 10:59 PM

Tags for this Thread

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