Código:
Lo marcado en rojo es la linea de error.Dim con As New ConexionesBD.datosSQL
Dim dt As DataTable = con.DevuelveDT("PA_Enlaces")
Dim ds As New DataSet
If dt.Rows.Count > 0 Then
For Each dr As DataRow In dt.Rows
Dim dtN As DataTable = dt.Clone
If ds.Tables(dr.Item("Nombre")) Is Nothing Then
dtN.TableName = dr.Item("Nombre")
ds.Tables.Add(dtN)
End If
Dim drN As DataRow = dtN.NewRow
drN("URL") = dr("URL")
drN("Titulo") = dr("Titulo")
drN("Def") = dr("Def")
CType(ds.Tables(dr.Item("Nombre")), DataTable).Rows.Add(drN)
Next
For Each dtN As DataTable In ds.Tables
Dim rpt As New Repeater
rpt.ItemTemplate = Me.rptPlantilla.ItemTemplate
rpt.HeaderTemplate = Me.rptPlantilla.HeaderTemplate
rpt.FooterTemplate = Me.rptPlantilla.FooterTemplate
rpt.SeparatorTemplate = Me.rptPlantilla.SeparatorTemplate
rpt.DataSource = dtN
rpt.DataBind()
Me.pnlEnlaces.Controls.Add(New LiteralControl("<div class='verde' align='center'><b>· " & dtN.TableName & " ·</b></div>"))
Me.pnlEnlaces.Controls.Add(rpt)
Next
End If
Gracias y un saludo.

