473,662 Members | 2,593 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

datatsource depending on other datasource (in datacontrol)

Hi all,

I have a list containing objects. Each object also contains a list of
objects.
e.g.:
A1: B1 - B2 - B3
A2: B1 - B2 - B3 - B4
A3: B1 - B2 -
A4: B1 - B2 - B3

I want to use a datacontrol (repeater, datagrid, ..) to display the
datasource (A) and the list inside the A datasource. What control do I
best use and how can I make this databinding?

Thanks in advance
Stijn

Oct 20 '06 #1
1 1136
Stijn,

It's hard to answer what control is the best to use for your sitution. Here
are some guidelines though. If you're simply displaying the information and
don't have a need to page or edit the results, use a Repeater control,
otherwise, look into a DataGrid or DataView control. Once you've chosen the
appropriate control, you can use a databinding syntax to databind the child
controls:

<asp:Repeater id=testRepater runat=server>
<ItemTemplate >
<tr><td>
Column Name
<asp:Repeater id=childRepeate r runat=server DataSource="<%#[Syntax
to retrieve child recods]%>">
<ItemTemplate>. ..</ItemTemplate>
</asp:Repeater>
</td></tr>
</ItemTemplate>
</asp:Repetaer>

http://msdn2.microsoft.com/en-us/library/aa478959.aspx

Hope that helps.

e

<ta******@gmail .comwrote in message
news:11******** *************@h 48g2000cwc.goog legroups.com...
Hi all,

I have a list containing objects. Each object also contains a list of
objects.
e.g.:
A1: B1 - B2 - B3
A2: B1 - B2 - B3 - B4
A3: B1 - B2 -
A4: B1 - B2 - B3

I want to use a datacontrol (repeater, datagrid, ..) to display the
datasource (A) and the list inside the A datasource. What control do I
best use and how can I make this databinding?

Thanks in advance
Stijn

Oct 20 '06 #2

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

Similar topics

0
4596
by: Brian Takita | last post by:
Hello, I am trying to Implement a DataSource property for a custom control using a ListView. This DataSource should be like all other DataSource properties for data bound controls in .NET. The DataSource accepts an object that eventually points to an IEnumerable. So far, I am able to extract the IEnumerable object from the DataSource.
0
1016
by: John A Grandy | last post by:
in ASP.NET 2.0 , what is the best WebForm DataControl to bind to a Hashtable ?
1
1552
by: Maruthi Seshidhar | last post by:
The datacontrol available in vb6 toolbox is not available in vb.net toolbox. where can I find it.
7
1650
by: bernadou | last post by:
How do I (or is this even possible) get the total number of records from a datasource control in ASP.NET 2.0? I’ve messed around with getting the row count from the grid that the datasource is bound to, but, that control uses paging and it appears that the count is only for the page that is in view. I’m guessing that this is pretty simple, but, I’m flummoxed. Thanks for any help you can offer.
2
1605
by: H5N1 | last post by:
Hi there First of all excuse me posting such simple (I guess) question, but I didn't find the answer in tutorials. I have a formView presenting records from some table. one of the fields is a Category ID, which is a foreign key. in edit template I replace it with dropdownlist, which is gets this ID, and displays corresponding name, by getting information from other datasource.
7
1741
by: =?Utf-8?B?UHVjY2E=?= | last post by:
Hi, I'm using vs2005, .net 2 for windows applciation. I have a form with 1 datagrids whose datasource comes from 2 dataview that are based on 2 dataset datatables(depends on the stat of the application then one of the dataview will be selected as datasource for the grid). Both dataview have only 2 columns but one of the columns name is different. Depending on the state of the application, I would need to change the datasource to be...
2
2229
by: =?Utf-8?B?Q2h1Y2sgUA==?= | last post by:
I need to put some embedded xml within a web page. It has to be in the webpage. Is their a way I could use this xml as a datasource for an extended Ajax cascading dropdown and not have postbacks (preferred) or just for some cascading DDLs. dropdownlist one: CarManufactures dropdownlist two: Models
0
1525
by: jackvel | last post by:
Hi Dudes... I want to connect the Access database with VB 6.0 without using DataControl and ADODC.. Which option should i use.? Plz send me the detailed procedure of doing the same.. Plz help me, i need it urgently.. Thanks..
1
2195
by: Medardo | last post by:
I'm writting a program in VBA, to add some advanced Macros to a word document, and I need to read and manipulate some data from an Access database. So I created a form but I can't find the Datacontrol, I found the Datalist, the DBList, the Datalist, but not the Datacontrol. Even when I'm writing code the Database and Recordset types are not recognoised when I'm defining variables. Please help...
0
8432
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8344
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8857
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8764
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8633
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7367
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6186
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
1
2762
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1752
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.