LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Select empty column & paste - Help please


Hi All,
Here is my problem:

I am copying a range (say A1:C150 ) then I am activating another
workbook and
selecting a sheet (sheet1) and find first empty column and paste.

Can someone please help.

Here is my code:

Sub test3()
Dim lastcolumn As Range
Range("A1:E150").Select
Application.CutCopyMode = False
Selection.Copy
Windows("DataAll.xls").Activate
ActiveWindow.WindowState = xlNormal
Sheets("Sheet2").Select
ActiveSheet.lastcolumn = Cells(1, Column.count).End(xlLeft).Column
Cells(lastcolumn + 1, 1).PasteSpecial Paste:=xlValues _
, Operation:=xlNone, SkipBlanks:=False, Transpose:=False

End Sub

the above code doesn't work

thanks
Syed


--
saziz
------------------------------------------------------------------------
saziz's Profile: http://www.excelforum.com/member.php...fo&userid=6350
View this thread: http://www.excelforum.com/showthread...hreadid=494770

 
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
VB help SELECT COLUMN / PASTE FORMULA'S XLtest Excel Discussion (Misc queries) 0 January 23rd 10 12:14 PM
Select first empty row in a column Tdungate Excel Discussion (Misc queries) 9 February 5th 09 05:28 PM
How to set macro to Paste Special Value to next empty column [email protected] Excel Worksheet Functions 9 May 5th 08 11:57 PM
What is function to select only not empty cells in a column (like SHIFT+END+ArrowDown or UP) [email protected] Excel Programming 3 November 11th 05 01:43 PM
Find Empty Column and paste cell values Mike Excel Programming 6 December 28th 03 08:31 PM


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

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

About Us

"It's about Microsoft Excel"