G
Gojavid
Good morning,
It has probably been asked before and it is definitely a
beginner's question, but any response it greatly appreciated.
I have a series of label boxes on a form and I need to set the caption
on each of them equal to a cell in the spreadsheet. I know how to do
this the long way:
label1.caption = cells(1,1)
but I was wondering if I could use a for loop and make this process a
little easier for the future... something like:
for i = 1 to 14
dim lbltest as object
set lbltest = "userform1.label" & i
lbltest.caption = cell(i +1,1)
next
any ideas?
It has probably been asked before and it is definitely a
beginner's question, but any response it greatly appreciated.
I have a series of label boxes on a form and I need to set the caption
on each of them equal to a cell in the spreadsheet. I know how to do
this the long way:
label1.caption = cells(1,1)
but I was wondering if I could use a for loop and make this process a
little easier for the future... something like:
for i = 1 to 14
dim lbltest as object
set lbltest = "userform1.label" & i
lbltest.caption = cell(i +1,1)
next
any ideas?