473,659 Members | 3,605 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Runtime error 2105

1 New Member
Hi everybody

I have a database created in access 2007. In one form I created a button with the following VBA code (on click event)

DoCmd.GoToRecor d , , acNewRec
A_S = Nz(DMax(“A_S”, “Table1”)) + 1

Because it’s a multiuser form I want every time someone clicks that button, to refresh the form, show any new records (if there are) that have been created from other users, and create a new record to write.
I used the following code

Me.Requery
Me.Refresh
DoCmd.GoToRecor d , , acNewRec
A_S = Nz(DMax(“A_S”, “Table1”)) + 1

With the above code when I click the button I get the 2105 error on the 3rd line.
Mar 2 '10 #1
0 2017

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

Similar topics

0
1502
by: anguo | last post by:
hi, everyone. i use mysql server version: 3.23.33. when i insert one line in a table, it can insert normaly. but then it display : null discard 9/udp sink null systat 11/tcp users daytime 13/tcp daytime 13/udp netstat 15/tcp
8
5155
by: swathky | last post by:
I've tried mutiple things but no go -- (sorry this is so long) I'm collecting a 5 digit number in an input box function and all works fine until a number is passed that doesn't exist in the database. I can't figure out where/how to check that the number exists before I get the error code 2105. Here's my function to get the number that I run when a command button is clicked to open the frmEditLoans form: Public Function...
5
15111
by: Nathan Bloom | last post by:
Hi, I have a secured database that runs fine on the computer the database is installed on. I have several workstations with access runtime installed that also need access to the database. Access runtime runs fine when accessing an unsecured version of the database. However once the database was secured it generates a runtime error after asking for the user and password and won't open. The shortcut to the secured database is: "path...
1
4071
by: samotek | last post by:
Can i avoid the appearance of the Run time error 2105? I have a function that performs well,but at the end the Run time error 2105 appears :" You cant go to the specified record" However when i click "End" on the window, i go to the desired place and my function will be perfect if i can
0
755
by: Kirk | last post by:
I'm trying to use a Web Service to be a Remoting client of an existing ..NET 2.0 server. But I get the following error when I try to use System.Runtime.Remoting.Channels.Http in my WebService. The same code works fine in a standalone app. I have inspected System.Runtime.Remoting.dll with ildasm, and I can see the ....Channels.Http namespace there. I verified that the virtual directory is configured to use v2.0.50727 (the error message...
7
2218
by: David01 | last post by:
When I run some code behind a button i get a runtime error message. The strange thing is that the code run perfectly some months ago. Can some one help me ! Some additional information: The company I work for upgraded the citrix enviremont. Here is the code: Private Sub knptoevoegen_Click() On Error GoTo err_knptoevoegen_click Dim filid As Variant Dim beursid As Variant Dim fout As Integer
1
3111
by: Gilberto | last post by:
Hello, in several forms i have a NEXT, PREVIOUS and SAVE command buttons which were working perfectly...no errors showing...nothing!!! i had to convert my DB to 2003 so i could create the .mde. I did the conversion and now my forms give me a run-time error 2105 or 2499 every time i reach the first/last record and try to go one more previous/next record. Im new with access and dont want any fancy error handler i just need to AVOID the error and...
3
3621
rsmccli
by: rsmccli | last post by:
Using AC2002 Hello. I am working with an existing DB that has "Add New" command buttons on two forms. When I, an Admin, click the buttons, they work properly, and a new, blank form is created, ready for data entry. When one of my users from the "Update Data" workgroup clicks the button, they get an "Error 2105: You can't go to the specified record" error, and no new row is created. Each of these are just supposed to add a new row in...
1
3286
by: Steed | last post by:
Hey all, this is hopefully so simple you want to laugh me off the forum but it would Really Really help if you could...well help me! I've got this 'browse' form to allow user to go through records one by one, but when I get to the end of the data two things happen: First, it goes to a blank page (to make a new record I assume) - This is fine. One more click after that I get a "2105" Which states "You can't go to specified record"....
11
14603
by: scottbouley | last post by:
I'm new at adding VBA to Access 2007 and could really use some help. I have two forms used to gather data to go into a datasheet subform. The following code on the second of the two forms populates the subform: Private Sub OK_Click() If ( > ) Then MsgBox "Sales Quantity cannot exceed Quantity In Stock", vbOKOnly .SetFocus Exit Sub Else
0
8428
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...
1
8531
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8628
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
7359
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
6181
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...
0
4175
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 last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4335
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1978
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1739
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.