View Single Post
  #12   Report Post  
Posted to microsoft.public.excel.misc
SteW SteW is offline
external usenet poster
 
Posts: 293
Default Increasing cell address by a set amount

my e-mail to you has bounced bac . do you have another address?

"Dave Peterson" wrote:

I can't see a pattern to the addresses/rows that receive the formulas and I
can't see a pattern in the cells that send the value.

I think you'll have to provide that layout for me to help.

Receiving address Date Details address
c178 c7
c186 c15
c188 c39
....

Give all the mapping and then say when it starts to repeat. Same with the
column layout.

And how do you know when to stop populating the rows and how do you know how to
stop populating the columns?

stew wrote:

Dear bob

The answer that you gave me works Perfectly for what I needed which was For
the formula to roll on Individual pieces of information on to cells whose
address in crease by 80 every time. However it has worked so well it gives me
another application for it but I cannot quite get it to work Perhaps you or
Bob could Help

This is the page layout for an Itininary that is 300 daily pages long each
cell is repeated in an 49 row increase when the C address changes to an D
Address and then 49 more and then an E Address etc etc. Hope I have
explained myself well enough

In C178 I HAVE ='DATE DETAILS'!C7 IN H178 I HAVE ='DATE DETAILS'!C17
this column runs through to This column runs through to
C186 in which is='DATE DETAILS'!C15 H186 in which is ='date details'!C25
This column then restarts on This column restarts on
C188 in which is ='DATE DETAILS'!C39 H188 in which is ='date
details'!C55
This then runs through to This column runs through to
C202 In which is=DATE DETAILS'!C52 H202 in which is='DATE DETAILS'!C68
This column then restarts on
C208 In which is='DATE DETAILS'!C70
This then runs through to
C220 Inwhich is ='DATE DETAILS'!C82

THANK YOU AGAIN FOR ALL THE HELP YOU HAVE GIVEN

Stew
"Dave Peterson" wrote:

I'm not sure what "and on and on" means, but you could change the lastrow
variable to the row number where you want to stop:

Option Explicit
Sub testme()

Dim iRow As Long
Dim LastRow As Long
Dim FirstRow As Long
Dim myCol As Long
Dim wks As Worksheet

Set wks = Worksheets("sheet1")

With wks
FirstRow = 8
LastRow = 248

myCol = 2
For iRow = FirstRow To LastRow Step 80
myCol = myCol + 1
.Cells(iRow, "B").Formula _
= "='Date Details'!" & .Cells(5, myCol).Address(0, 0)
.Cells(iRow + 2, "B").Formula _
= "='Date Details'!" & .Cells(7, myCol).Address(0, 0)
.Cells(iRow + 3, "B").Formula _
= "='Date Details'!" & .Cells(3, myCol).Address(0, 0)
.Cells(iRow + 6, "B").Formula _
= "='Date Details'!" & .Cells(16, myCol).Address(0, 0)
Next iRow
End With

End Sub

stew wrote:


Dear All

I was orginally helped with a similar problem by Sandy Mann but I have come
to grief again. Can anybody give a formula that can do the Business

In b8 I have ' date details'!c5
In b10 I have 'date details'!c7
In b11 I have 'date details'!c3
In b14 I have 'date details'!c16

In b88 I wan to have ' date details'!d5
In b90 I want to have 'date details'!d7
In b91 I want to have 'date details'!d3
In b94 I want to have 'date details'!d16

In b168 I wan to have ' date details'!e5
In b170 I want to have 'date details'!e7
In b171 I want to have 'date details'!e3
In b174 I want to have 'date details'!e16

and on and on

Thanks in advance for looking

--

Dave Peterson


--

Dave Peterson