472,962 Members | 2,787 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

Async dataset populating.....


Windows C#

I have some search screens in my app which can, with certain search params,
bring back thousands of rows, and can take ages to populate. So I am trying
to find a better way of them operating. One idea is to batch the results up.
So I could go and get the 1st 50 rows and populate the datagrid with those,
then when they scroll to the last of these 50 it goes and gets the next 50.

That got me thinking asynchronous. Would it be possible to fire off a
process that went to get all 10000 rows for example, but return them every 50
or so when it had them. So the process would fire off, and return the first
50, the user is free to peruse those while the process is busy in the
background getting the rest of the records, spitting them into the datagrid
every 50.

Is any of this possible? How?

Cheers

Steve
May 22 '06 #1
1 1633
Steve,

The method you ask for is in my idea "Paging". It is not assynchronous. For
ASPNet it is a part of the datagrid methods. For windowsforms we have some
samples on our website, but the name of that website is VB-Tips, so I assume
that you understand that there are no C# samples.

Cor

"Steve" <St***@discussions.microsoft.com> schreef in bericht
news:92**********************************@microsof t.com...

Windows C#

I have some search screens in my app which can, with certain search
params,
bring back thousands of rows, and can take ages to populate. So I am
trying
to find a better way of them operating. One idea is to batch the results
up.
So I could go and get the 1st 50 rows and populate the datagrid with
those,
then when they scroll to the last of these 50 it goes and gets the next
50.

That got me thinking asynchronous. Would it be possible to fire off a
process that went to get all 10000 rows for example, but return them every
50
or so when it had them. So the process would fire off, and return the
first
50, the user is free to peruse those while the process is busy in the
background getting the rest of the records, spitting them into the
datagrid
every 50.

Is any of this possible? How?

Cheers

Steve

May 22 '06 #2

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

Similar topics

0
by: Juan | last post by:
When populating a dataset I get an error if the data being retrieved includes a string field with a Null value: "Not valid store type: DBNull". What kinf of data type can i define in the dataset to...
0
by: amber | last post by:
I've been trying to figure out how to get 2 datasets to populate a report/subreport - and I think I'm on the right track...just having a few problems somewhere... I have created a dataset (.xsd)...
0
by: tonywn | last post by:
Hello, I have a problem outputting a dataset from a sp to an excel spreadsheet. I am looping through the dataset and populating the spreadsheet cell by cell. foreach ( DataRow dr in...
2
by: Robert | last post by:
I'm sure this is a fairly basic question, but I've been looking all over the web for days for suggestions on how to do this. I've got a datagrid that's bound to a dataset on my form. It includes...
1
by: tony | last post by:
Hello, I have a problem outputting a dataset from a sp to an excel spreadsheet. I am looping through the dataset and populating the spreadsheet cell by cell. foreach ( DataRow dr in...
1
by: Sheldon Penner | last post by:
I have been trying to build a web form using the SQL Data Adapter Configuration Wizard to create a dataset based on a parameterized stored procedure. I find that if I select "Use existing stored...
2
by: Anand | last post by:
Hi Season Greetings, I'm trying to implement client call backs in my page. i'm using user controls (composite controls) and these are placed in my master page. I'm implementing...
5
by: John | last post by:
Hi all, I'm sorry I'm reposting this but the original was urgent and I do need closure on this. I'm calling a stored proc which does 4 "selects" and then I populate a dataset looping through...
1
by: mike11d11 | last post by:
For some reason I'm getting no data populating in my crystal report. I built my crystal report off my dataset in my project, and I fill the dataset when opening the main form, and count the...
4
rizwan6feb
by: rizwan6feb | last post by:
I am working on an application in VB.NET and MySql. I am getting a duplicate entry for key 1 error. My application goes through the following steps. 1. Populate my DataSet from the database. 2....
0
by: Aliciasmith | last post by:
In an age dominated by smartphones, having a mobile app for your business is no longer an option; it's a necessity. Whether you're a startup or an established enterprise, finding the right mobile app...
0
tracyyun
by: tracyyun | last post by:
Hello everyone, I have a question and would like some advice on network connectivity. I have one computer connected to my router via WiFi, but I have two other computers that I want to be able to...
2
by: giovanniandrean | last post by:
The energy model is structured as follows and uses excel sheets to give input data: 1-Utility.py contains all the functions needed to calculate the variables and other minor things (mentions...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
3
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be using a very simple database which has Form (clsForm) & Report (clsReport) classes that simply handle making the calling Form invisible until the Form, or all...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
0
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be focusing on the Report (clsReport) class. This simply handles making the calling Form invisible until all of the Reports opened by it have been closed, when it...
0
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...
2
by: GKJR | last post by:
Does anyone have a recommendation to build a standalone application to replace an Access database? I have my bookkeeping software I developed in Access that I would like to make available to other...

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.