Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Pasting on next empty cell

How do I tell my macro to look for the next empty cell before pasting

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 38
Default Pasting on next empty cell

Byron,

Use the End Property. Here's the description from HELP:

Returns a Range object that represents the cell at the end of the region
that contains the source range. Equivalent to pressing END+UP ARROW,
END+DOWN ARROW, END+LEFT ARROW, or END+RIGHT ARROW. Read-only.

Syntax
expression.End(Direction)
expression Required. An expression that returns a Range object.
Direction Required Long. The direction in which to move. Can be one of the
following XlDirection constants: xlToLeft, xlToRight, xlUp, or xlDown.
-------------
So, you can get to the last EMPTY cell in the current column by doing:
Cells(ActiveCell.End(xlDown).Row + 1, ActiveCell.Column).Paste
-------------
On 4/15/04 17:21, in article
, "Byron"
wrote:

How do I tell my macro to look for the next empty cell before pasting.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
adding rows, pasting values then empty sheet misscharliebrown Excel Worksheet Functions 2 October 30th 08 03:07 AM
Leaving an empty cell empty GRL Excel Discussion (Misc queries) 4 April 22nd 06 05:47 PM
why a reference to an empty cell is not considered empty Nicoscot Excel Discussion (Misc queries) 10 March 10th 06 05:36 AM
Pasting data top 1st empty cell in range wfcmark Excel Discussion (Misc queries) 4 December 8th 05 10:46 AM
Selecting and pasting to an empty cell Craig from MI Excel Programming 1 March 7th 04 06:36 AM


All times are GMT +1. The time now is 06:08 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"