Howdy all,
I'm trying to build my "ChildSheet" dynamically based on data from the "ParentSheet". Data from columns in the ParentSheet will be copied to areas of the ChildSheet with headers and such added in between on the fly.
Here's an example of the copy portion. Please note the two different reffernece styles.
The effect of skipping the ParentSheet header and the three ChildSheet rows is what I want - the kludgy implmentation isn't.
1) How do I clean up the refferences to use just Cells()?
2) Are there proper names for the two types of refferences?
3) How do I clean up the for loop to be less lame?
4) Have I been slightly more clear than mud?
Thanks!
I'm trying to build my "ChildSheet" dynamically based on data from the "ParentSheet". Data from columns in the ParentSheet will be copied to areas of the ChildSheet with headers and such added in between on the fly.
Here's an example of the copy portion. Please note the two different reffernece styles.
Code:
With ChildSheet
For i = 2 To LastRow
.Cells(i + 2, 2) = "='" & ParentSheet & "'!D" & i
Next i
End with
' i=2 to skips the header on ParentSheet plus one row on ChildSheet
' Cells(i+2,2) skips two additional rows on ChildSheet
The effect of skipping the ParentSheet header and the three ChildSheet rows is what I want - the kludgy implmentation isn't.
1) How do I clean up the refferences to use just Cells()?
2) Are there proper names for the two types of refferences?
3) How do I clean up the for loop to be less lame?
4) Have I been slightly more clear than mud?
Thanks!