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: 173
Default loop code needed

Hi, I need a piece of code that copies a range, ie B10:K100 plus. This range
would vary in size depending on the amount of data. I then need this data to
be copied and pasted values onto a different tab (Database) and inserted
below the previous data. I can do most of the code apart from where it looks
for the previous data and drops it below the last occupied cells. Below is my
poor attempt

Sub Macro2()

Application.ScreenUpdating = False

Dim iRow As Long

Application.Goto Reference:="Data"

Selection.Copy

Sheets("Database").Select

iFreeRow = Cells(Rows.Count, "B").End(xlUp)

Selection.PasteSpecial Paste:=xlPasteValues

Sheets("Input").Select

Range("B6").Select

End Sub

Any help, greatly appreciated

Regards

John

 
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
simple loop needed please Alan Excel Discussion (Misc queries) 1 May 5th 10 06:33 PM
Loop for VBA code? paulinoluciano Excel Worksheet Functions 5 December 28th 05 01:30 PM
How to get my code to loop Dominique Feteau[_2_] Excel Programming 5 December 17th 04 01:35 PM
Urgent Help needed on! Copy and Paste a Formula as Values using a Loop statement Edward S Excel Programming 4 June 26th 04 10:01 PM
help needed with timer / loop wendy_ia Excel Programming 0 June 17th 04 06:06 AM


All times are GMT +1. The time now is 06:20 AM.

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"