Hi Folks!

Maybe some one can give me a hand with this problem:
I'm building one asp.net page that reads data from the table and builds the
table and the controls dinamically, I create a dataset and fill it with all
the tables needed.

All works fine displaying the info but I have problem with the Databinding
since it works different in Vb.NET and ASP.NET, the databindings doesn't
exist in ASP.NET it only accepts the Databinder.eval.

I call the Sub and pass the Table to draw and which panel to display using
DrawTable("FinInfo_Income", 1)

The line that display the current value is marke {**}, I tried to use the
Databinder.Eval without any luck..

Does anyone know the right form to bind the control ...?

TIA for any help!



Public Sub DrawTable(ByVal Tablename As String, ByVal TableNumber As
Integer)
Dim numrows As Integer
Dim numcells As Integer
Dim i As Integer
Dim j As Integer
Dim r As TableRow
Dim c As TableCell
Dim CatSum As Integer
Dim Colname As String

CatSum = 0

For j = 1 To DS.Tables(Tablename).Columns.Count - 1
r = New TableRow()

For i = 1 To DS.Tables(Tablename).Rows.Count
Dim box As New System.Web.UI.WebControls.TextBox()
Dim lbl As New Label()
c = New TableCell()

lbl.Text =
DS.Tables(Tablename).Columns(j).ColumnName.ToString

If DS.Tables(Tablename).Rows(0).ItemArray.GetValue(j) Is
System.DBNull.Value Then
box.Text = ""
Else
{**}box.Text =
DS.Tables(Tablename).Rows(0).ItemArray.GetValue(j)

If DS.Tables(tablename).Columns(1).DataType.ToString =
"System.Decimal" Then
CatSum = CatSum +
DS.Tables(Tablename).Rows(0).ItemArray.GetValue(j)
End If
End If

c.Controls.Add(lbl)
c.Controls.Add(box)
r.Cells.Add(c)
Next i
'This code adds the columns to the Panel

Select Case TableNumber
Case 1
TableFI.Rows.Add(r)
Case 2
TableFH.Rows.Add(r)
Case 3
TableFFC.Rows.Add(r)
Case 4
TableFLE.Rows.Add(r)
Case 5
TableFR.Rows.Add(r)
Case 6
TableFS.Rows.Add(r)
Case 7
TableFT.Rows.Add(r)
Case 8
TableFOE.Rows.Add(r)
End Select
Next j
End Sub