titanium111
New Member
- Joined
- Aug 10, 2010
- Messages
- 1
Hi all,
I am using Excel 2003
I want to write a VB command that will repeat the same command for each value on the cells from B5 to B11
for each cell gcapplication should be equal to lcsheetname.
Her eis what i have done
Sub repeat()
Dim lnEssSheets As Integer
Dim Cube As Integer
Dim rnumber As Integer
dim gcapplication as string
For Cube = 1 To application.WorksheetFunction.CountA("B5:B100")
rnumber = Cube + 4
lcSheetName = Worksheets("Control").Cells(rnumber, 2).Name
gcApplication = lcSheetName
End Sub
Would be glad if anybody can help
Thanks
I am using Excel 2003
I want to write a VB command that will repeat the same command for each value on the cells from B5 to B11
for each cell gcapplication should be equal to lcsheetname.
Her eis what i have done
Sub repeat()
Dim lnEssSheets As Integer
Dim Cube As Integer
Dim rnumber As Integer
dim gcapplication as string
For Cube = 1 To application.WorksheetFunction.CountA("B5:B100")
rnumber = Cube + 4
lcSheetName = Worksheets("Control").Cells(rnumber, 2).Name
gcApplication = lcSheetName
End Sub
Would be glad if anybody can help
Thanks