Hyperlink array?

  • Thread starter Thread starter Ty
  • Start date Start date
T

Ty

I'm trying to make a array of Hyperlinks but keep getting errors.

Dim objLink As HyperLink
objLink = New HyperLink()
objLink(intIndex).Text = objdatareader(0)

Ty
 
Ty said:
I'm trying to make a array of Hyperlinks but keep getting errors.

Dim objLink As HyperLink
objLink = New HyperLink()
objLink(intIndex).Text = objdatareader(0)

'Dim Links(0 To <Count - 1>) As HyperLink'

If 'HyperLink' is a reference type, you'll have to initialize the array
elements:

\\\
For i As Integer = 0 To Links.Length - 1
Links(i) = New HyperLink()
Next i
///
 
'Dim Links(0 To <Count - 1>) As HyperLink'

If 'HyperLink' is a reference type, you'll have to initialize the array
elements:

\\\
For i As Integer = 0 To Links.Length - 1
    Links(i) = New HyperLink()
Next i
///

Thanks for the helped. Worked great.

Ty
 
Back
Top