473,503 Members | 7,214 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Access 2000 - Requery problem...(ADO)

2 New Member
Hi there!

I'm having problem when requerying my main form of my application.

Here's the story...

I open a pop-up form using my main form to edit some values. When I return to my main form after requerying the dataset (to update the fields to the new values) I want to return the the record I was at before requerying...

In its basic sense, my code is this:

================================================== ==
Public Function frm_requery(f As Form)

Dim varbookmark As Variant

varbookmark = f.Bookmark

f.Requery

f.Bookmark = bm

================================================== ==

As you can see, I set the bookmark before requerying, requery the data, then I go back to the bookmark.

I've figured out that the problem occurs because the records in the form (it's an ADO recordset btw) haven't finished loading by the time the pointer is set to the bookmark, so for lower records in the recordset this works fine but for later records I get the dreaded '2757' error. If I click 'Debug' and then click the 'Play' button to resume the code, the code works fine.

Basically, is there any way that I can check to see whether the records in the form have fully loaded before I try to go to the bookmark?

Many thanks for any help you can give as I'm currently tearing my hair out over this.

Paul
Sep 26 '06 #1
1 3349
PEB
1,418 Recognized Expert Top Contributor
Why do not get the record number and the return to the respective record number?

I do it with statements like this

curr = Forms!Elements.[Element_info Subform].Form.CurrentRecord
Me.Requery
DoCmd.GoToRecord , , acGoTo, curr
Sep 26 '06 #2

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

Similar topics

3
1747
by: John | last post by:
Hi I have an access app that runs fine on access 2000 on a windows 2000 pc. I installed access 2000 on a second win xp pro pc with ms office xp small business already installed. When I run the...
3
2373
by: pbbriggs | last post by:
I will try to be as descriptive as possible, but this error has me stumped and I am not sure what relevant info to include.... I am running Access XP on a Windows XP machine. I initially began...
2
2353
by: aaj | last post by:
Hi all I have a continuous bound form and on each record is a tick box. The user ticks the boxes and these boxes define the batch. for future operations before they leave the page I count...
3
1560
by: Rebecca Smith | last post by:
I’ve been using the code below in Access 97 for years now without any problems at all. Unfortunately, I now have to convert this db to Access 2000. I tried using the conversion feature and that was...
2
2017
by: David C. Barber | last post by:
upsized an MDB to ADP/SQL Server 2000 under Access 2000. All the DAO code that I've changed to ADO code is working fine, HOWEVER the form Record Source itself does not seem willing to return data....
4
3497
by: James | last post by:
I have a VB windows forms application that accesses a Microsoft Access database that has been secured using user-level security. The application is being deployed using No-Touch deployment. The...
7
2464
by: Karen Hill | last post by:
Hi. I need to use transactions to make sure data is consistent. I have a combo box that when changed to a new value updates a table. I then have a DoCmd.RunSQL statement following that in the...
10
6985
by: WannaKatana | last post by:
I am just wondering why, with nothing else running and executing an update query against a very large table, does Access seem to be causing less than 10% processor usage. Then it says "There is not...
0
1317
by: adstheman | last post by:
Hi all, I am maintaining a group of applications which share Access databases. In the newer version of the software products we have upgraded from DAO to ADO and also implemented routines to...
0
7357
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...
1
7012
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7468
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
5598
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,...
1
5023
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...
0
4690
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3180
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3171
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
402
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...

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.