Quantcast
Channel: VBForums - ASP, VB Script
Viewing all articles
Browse latest Browse all 688

Populating Labels

$
0
0
I feel like this should be simple but... I can't make it work. I am trying to create a subroutine to populate objects and below is the simple example I could come up with any help would be great! I am using VS2013

Thanks Scott

Public Sub PopulateLabels()
Dim I as integer
for I = 1 to 10
call PopulateL("Label" & I , I)
next

end sub

Public Sub PopulateL(LabelName as string, Cnt as integer)
dim ALabel as label = CType(Me.FindControl(sLabel), Label)
ALabel.text = cnt


end sub

Viewing all articles
Browse latest Browse all 688

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>