By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,528 Members | 1,375 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,528 IT Pros & Developers. It's quick & easy.

How to show groups of 10 records on a continuous form?

P: 11
I want to show a table on a continuous form 10 records at a time. I want to be able to update a single field in the currently displayed group of records, and then scroll to the next group.

I'm not sure where to start. Can you help?

Thanks,

Gerry Goldberg
Jul 9 '10 #1
Share this Question
Share on Google+
5 Replies


nico5038
Expert 2.5K+
P: 3,072
The "easy" way is to use a subform 10 rows in hight. By clicking in the scroll bar below the "ruler" the subform will jump 10 rows down, etc.

When you want this controlled by code it's a bit more work...

Nic;o)
Jul 9 '10 #2

P: 11
I think that will work ok. Now, if I want to update the same field (with the same value) on each of the records that are showing, how do I do that with VBA?

Thanks,

Gerry Goldberg
Jul 9 '10 #3

nico5038
Expert 2.5K+
P: 3,072
No VBA needed, just an UPDATE query will do the trick like:

Expand|Select|Wrap|Line Numbers
  1. UPDATE tblTest SET Columnfield1 = 1
  2.  
Nic;o)
Jul 9 '10 #4

P: 11
Thanks for your quick response!

Your example shows an Update query to update the data in my continuous subform. Since I only want to update those records currently being displayed, I wondered if the query would limit itself to those records, or try to update the entire table. I need to affect only the records being displayed.

Thanks
Jul 9 '10 #5

nico5038
Expert 2.5K+
P: 3,072
This will be harder and will require some VBA coding.

I've attached a sample that's holding code that shows how selected rows on a datasheet can be processed (the sample shows the fields at the bottom and can be transformed to an UPDATE query with a WHERE clause).
Looks to me more versatile to be able to select a range instead of all rows of the subform, but that decision is up to you :-)

Let me know what you think of this.

Nic;o)
Attached Files
File Type: zip Sample-Listbox-Selection2000.zip (64.6 KB, 168 views)
Jul 9 '10 #6

Post your reply

Sign in to post your reply or Sign up for a free account.