473,320 Members | 1,976 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

binding datalist to dataset with two datatables

I built a dataset with two datatables and added the relation. The example in
the help text for datatable class seemed sufficient. Binding a datalist
using the dataset for datasource and the parent datatable name as the
datamember does not work for me.

Columns from the child (or second) datatable in the dataset are not found.

Using vb.net for code-behind. The binding statement for a control looks
like this:
Text='<%# DataBinder.Eval(Container.DataItem, "CallTypeCode") %>'

I can see in debug that there are two tables in the dataset and the row
counts are correct.

What have I missed?

Thanks, Alex

Nov 19 '05 #1
2 4403
Did you remember to do a Page.DataBind() in the Page_Load Event ?
"Alex S Moore" <Al********@discussions.microsoft.com> wrote in message
news:FE**********************************@microsof t.com...
I built a dataset with two datatables and added the relation. The example
in
the help text for datatable class seemed sufficient. Binding a datalist
using the dataset for datasource and the parent datatable name as the
datamember does not work for me.

Columns from the child (or second) datatable in the dataset are not found.

Using vb.net for code-behind. The binding statement for a control looks
like this:
Text='<%# DataBinder.Eval(Container.DataItem, "CallTypeCode") %>'

I can see in debug that there are two tables in the dataset and the row
counts are correct.

What have I missed?

Thanks, Alex

Nov 19 '05 #2


"Mr Newbie" wrote:
Did you remember to do a Page.DataBind() in the Page_Load Event ?


I have never used that, so I will look into it.

Thanks, Alex

Nov 19 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: neverstill | last post by:
So I thought I had a solution to my problem using DataRelations with the DataSet. I need to display hierarchical data. I have a DataList nested into another DataList. My datasource is a...
0
by: lc | last post by:
At design-time, a datalist is hooked up to a dataset and it would work as expected at run-time. Then I added code for paging (with) PagedDataSet but the paging wouldn't work until I removed...
0
by: lc | last post by:
I know this is the 3rd post, sorry about this. This may be a lame question but it drives me nuts. At design-time, a datalist is hooked up to a dataset and it would work as expected at run-time....
1
by: Laura K | last post by:
Can someone tell me where I went wrong. This is my code for binding data to a datalist. <script language="vb"> Sub Page_Load(Src As Object, e As EventArgs) Dim Con As New...
3
by: bbernieb | last post by:
Hi, All, Is it possible to access a variable inside of a data binding, without the variable being out of scope? (Note: On the DataBinder line, I get an error message that says "Name 'i' is...
2
by: Andrew Robinson | last post by:
Is there any way to accomplish two way data binding in a Details View with a DataSet or DataTable as the DataSource. All I want is to get an updated DataSet or DataTable back from the...
0
by: | last post by:
I have a question about spawning and displaying subordinate list controls within a list control. I'm also interested in feedback about the design of my search application. Lots of code is at the...
9
by: =?Utf-8?B?RGljaw==?= | last post by:
I have a function that creates a DataSet, populates its many DataTables and then returns the DataSet. I want to bind separate controls to each of the DataSet's DataTables, e.g. a separate...
8
by: TimVtoo | last post by:
Hi all and thanks for looking. I need to make the move from ASP to ASP.NET, and as my sister has aked me to knock up a website for her, I thought this could be a nice starter project to help me...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.