Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > bind a dynamically created dataTable to a repeater

Reply
Thread Tools

bind a dynamically created dataTable to a repeater

 
 
Frank
Guest
Posts: n/a
 
      07-15-2003
Hi alll,

How can I bind a dynamically created dataTable to a repeater? I do not know
the number of columns and the column names at design time. I try to do the
same thing as for datagrid:
Repeater1.DataSource = values;
Repeater1.DataBind();
but it does not return anything.

Thanks.
Frank


 
Reply With Quote
 
 
 
 
William F. Robertson, Jr.
Guest
Posts: n/a
 
      07-15-2003
The datagrid should work.

DataGrid1.AutoGenerateColumns = true;
DataGrid1.DataSource = values;
DataGrid1.DataBind();

Make sure you set the autogeneratecolumns to true.

bill

"Frank" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hi alll,
>
> How can I bind a dynamically created dataTable to a repeater? I do not

know
> the number of columns and the column names at design time. I try to do the
> same thing as for datagrid:
> Repeater1.DataSource = values;
> Repeater1.DataBind();
> but it does not return anything.
>
> Thanks.
> Frank
>
>



 
Reply With Quote
 
 
 
 
Frank
Guest
Posts: n/a
 
      07-15-2003
Maybe I did not make it clear. It works for datagrid, but not work for
repeater.

Thanks a lot.
Frank

"William F. Robertson, Jr." <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> The datagrid should work.
>
> DataGrid1.AutoGenerateColumns = true;
> DataGrid1.DataSource = values;
> DataGrid1.DataBind();
>
> Make sure you set the autogeneratecolumns to true.
>
> bill
>
> "Frank" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
> > Hi alll,
> >
> > How can I bind a dynamically created dataTable to a repeater? I do not

> know
> > the number of columns and the column names at design time. I try to do

the
> > same thing as for datagrid:
> > Repeater1.DataSource = values;
> > Repeater1.DataBind();
> > but it does not return anything.
> >
> > Thanks.
> > Frank
> >
> >

>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Affecting a dynamically created drop down from another dynamically created drop down. msimmons ASP .Net 0 07-16-2009 03:17 PM
DropDownList refusing to data bind in dynamically created ascx, help! =?Utf-8?B?Sm9obiBDcm93bGV5?= ASP .Net 3 02-01-2006 12:37 PM
Managing ViewState of a dynamically created Custom Composite Server Control -(where the original is also dynamically created) dickster ASP .Net Building Controls 0 12-08-2005 09:32 AM
ViewState and dynamically created control in repeater John Crowley ASP .Net 0 01-14-2004 10:41 PM
Adding DataTable Rows To another DataTable J. Babe ASP .Net 1 08-15-2003 05:04 PM



Advertisments