View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
jimmy jimmy is offline
external usenet poster
 
Posts: 59
Default how to wright this formula in VBA code

Hello,

I would need help to "translate" one thing in VBA code.

In fact i have to diiferent columns in a excell sheet:
Column A: each row represents a week day in 2008:
Column B: must have a value related for each day;
Example:
Column A: 01/01/2008 Column B: 2.95
Column A: 02/01/2008 Column B: 2.96
Column A: 03/01/2008 Column B: 2.97
Column A: 04/01/2008 Column B: 2.98

When writing this on VBA code i´m doing like this:
Range("b1").select
Activecell.formular1c1="2.95"
Range("b2").select
Activecell.formular1c1="2.96"
Range("b3").select
Activecell.formular1c1="2.97"
Range("b4").select
Activecell.formular1c1="2.98"

Is there a way to make it easier?

Thank you for your help.

jimmy