473,413 Members | 1,795 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,413 software developers and data experts.

Lazy Load Nested DataLists when scroll position changes

Greetings,

i have a UserControl, that contains a DataList. That DataList contains
as items other DataLists.

example:

DataList A Row 1
Nested DataList 1
Row 1
Row 2
Row 3
DataList A Row 2
Nested DataList 2
Row 1
Row 2
Row 3

DataList A is populated with a list of Categories, and the "Sub-
DataLists" are assigned a DataTable that contains a list of products
for the category, the "Parent-DataList" is assigned to.

The subdatalists are created dynamically by assigning a DataTable to
the DataSource-Property of DataList A:
DataSource='<%# GetDataSource(Container.DataItem("CategoryID"))%>'

The problem with this scenario is, that the amount of data is very
large and the product lists contain pictures, so that the whole page
needs too much time to load.

What i want to do now, is to bind the "sub-datalists" only when the
user scrolls to the sub-datalists location. PageFlow is no option,
since all products have to be visible.

How can i accomplish this? I realize i have to implement some kind of
javascript functionality or Ajax enable this control. But how do i
assign the datasources to the subdatalists and bind them from
clientside when the subdatalist is scrolled to.

Any suggestions appreciated.

Thanks in advance
Ole

Mar 15 '07 #1
2 2372
in my last post, there's a little error
The subdatalists are created dynamically by assigning a DataTable to
the DataSource-Property of DataList A:
DataSource='<%# GetDataSource(Container.DataItem("CategoryID"))%>'
It has to be:

The subdatalists are created dynamically by assigning a DataTable to
the DataSource-Property of the Sub-DataList:

DataSource='<%# GetDataSource(Container.DataItem("CategoryID"))%>'


Mar 15 '07 #2
I'll try to do it like this:

I'll Define javascript functions that fetch xml data from the
webserver on demand, that is processed and transformed using xsl/xslt.
Demand occurs, when a user scrolls the document and the current
viewspace of the browser contains the subdatalist that is to be
displayed.

Post any comments or suggestions on how to improve what i am planning
to do, if you like.

with regards
ole


On 15 Mrz., 11:14, "Ole V.-M." <o.viaudmu...@googlemail.comwrote:
in my last post, there's a little error
The subdatalists are created dynamically by assigning a DataTable to
the DataSource-Property ofDataListA:
DataSource='<%# GetDataSource(Container.DataItem("CategoryID"))%>'

It has to be:

The subdatalists are created dynamically by assigning a DataTable to
the DataSource-Property of the Sub-DataList:

DataSource='<%# GetDataSource(Container.DataItem("CategoryID"))%>'

Mar 16 '07 #3

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

Similar topics

2
by: GrantS | last post by:
I am trying to convert the VB.Net code example povided by http://authors.aspalliance.com/JimRoss/Articles/MaintainScrollPos.aspx into C# (ASP.Net)without success. No errors are thrown in the VB...
1
by: JC | last post by:
I'm sure you've all seen the save scroll position from 4 guys from rolla which can be found here > http://aspnet.4guysfromrolla.com/articles/111704-1.aspx BUT try to get that to work AND still be...
0
by: schapopa | last post by:
I have two nested datalists and I am using percentage to make the width of the row: So my header of the parent datalist looks like this... <table><tr> <td width = 5%> <td width = 12%>...
1
by: TheHach | last post by:
Hi. (For information, i'm working in VB.NET) In our company, we have material that is divided into 3 parts : - a system - a batch - an article In each system are different batches, and in...
7
by: Lit | last post by:
Hi, How can I capture the vertical scroll bar position for a Listbox. I have a Listbox of 100 items + when I click on it I post back remove the item selected. After returning to the client...
2
by: =?Utf-8?B?SmVzcGVyLCBEZW5tYXJr?= | last post by:
Hi, I have a somewhat long calculation report printed out in a RichTextBox. To find or monitor a particular value, users scroll down to the location of the data in the RichTextBox. However, when...
0
by: vivajay | last post by:
I'm trying to do a parent/child relationship in nested datalists I have created. I do not want to repeat the contract number for each asset that falls within that contract number when I display each...
1
by: wmbrae | last post by:
I trying to make a javascript document reader in 2 frames. The left frame displays the document, the right frame shows a list of document links. This is as far as I got ...
12
Frinavale
by: Frinavale | last post by:
I think I'm trying to do something impossible. I have a <div> element with a overflow style set to "scroll". In other words my <div> element allows the user to scroll the content within it. ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
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,...
0
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,...
0
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...
0
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...
0
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,...
0
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...

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.