Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Copying formulas in a column

If the formula is not already in C2, then

Sub EstablishFormula()
Dim rng as Range
set rng = Range(cells(2,1),cells(rows.count,1).End(xlup))
rng.offset(0,2).Formula = "=A2+B2"
End Sub

--
Regards,
Tom Ogilvy

"bay" wrote in message
...
Hi

I am a total newbie in programming so this might seem an easy question,
still needs an answer though.

I am tring to set up macros for certain tasks. I have a list in a sheet

with
row 1 being the headers, and the data from row 2 to row 100. What I need

to
do is copy a formula (ie =A2+B2) in column C, from c2 to c100. Because i

need
to use this macro on other sheets as well that have lets say 150, or 200

rows
I need the macro to "understand" and copy the formula only down to where

the
list ends, (ie the last non-blank cell of column A)

Any ideas?

Thank you,

bay



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
Copying row formulas to a column? Skip Excel Worksheet Functions 5 January 30th 09 03:04 AM
Copying formulas into column from row information suzilea Excel Discussion (Misc queries) 2 November 4th 08 04:29 PM
copying formulas but changing the column # lynnydyns Excel Discussion (Misc queries) 2 September 6th 08 03:18 AM
Copying formulas to end of Column kippers Excel Discussion (Misc queries) 3 January 31st 07 07:03 PM
Copying Formulas From One Column To Another?? Leslie M Excel Worksheet Functions 10 November 2nd 06 08:34 PM


All times are GMT +1. The time now is 01:56 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"