Over 1 million tech questions and answers.

MS Access: Captureing the Record number of a record.

Q: MS Access: Captureing the Record number of a record.

How can i capture the record number of a record into a text box on a form?

When i talk about record number i mean the number that appears on the navigation buttons toolbar when in form view.

Thanks 4 the help.

Preferred Solution: MS Access: Captureing the Record number of a record.

I recommend downloading and running Reimage. It's a computer repair tool that has been proven to identify and fix many Windows problems with a high level of success.

I've used it in the past to identify and fix everything from blue screens (BSOD's), ActiveX errors, corrupt files and processes, dll/exe/sys errors, recover lost memory, Windows update problems, defragging, malware removal etc.

You can download it direct from this link http://downloadreimage.com/download.php. (This link will automatically start a download of Reimage that you can save to your computer.)

A: MS Access: Captureing the Record number of a record.

Hello agian, try thei in the form's on Current event procedure to see the result -

MsgBox Me.CurrentRecord

to put it in a text box use

me.fieldname = Me.CurrentRecord

where fieldname is the name of your text box

Read other 2 answers

I want to use the GoToRecord command to go to a specific record in a form. The problem is this uses an offset or record number. How can i find the record number of a specific record?

What i plan to do is use some code similar to this:

docmd.GoToRecord acDataForm, "FrmComputer", acGoTo, expression

where the expression is the record number of the record 'Computer01' for example.

A:Access. Find the record number of a record (For forms and queries)

Read other 13 answers

Hello Everyone:

I am having a little problem with my Access database. I have a master form with a subform in it, there are two sets of record numbers, one for the entries in the subform and another for the master forms. The subform record number behaves fine but the master form record number is a bit malfunctioning; it doesn't count the total number of master forms, instead it counts the total number of subform entries in all master forms.

For example: if I have 3 master forms, with 3, 2 and 1 subform entries in them, respectively, then I want the record number for the master forms to show that there are 3 records total. Currently, however, the master form record number would show that there are 6 records total. When I click on "next record', the same master form is still displayed until I get to record 3 of 6, then when I click "next record" it goes to the next master form.

Any insight would be appreciated, if my wording is confusing please let me know, I will try to clarify and upload screenshots if necessary. Thanks in advance.

A:Access 2007 record number.

Record numbers should be based on a primary key not some arbitrary number based on how many sub forms are showing. It sounds like you really need to redesign your tables and forms or you will have even bigger troubles down the line.

Read other 2 answers

I am using Access 2010. I have a main form and a subform. I select a record in the mailform (via ComboBox) and see the corresponding records in the subform (master-details style).

I would like to duplicate the "record number box" on the bottom of the form by displaying the "nn of mm" records in a TextBox. I cab find the current record, but how do i find the number of records in the recordset.

I havve used the command "F_rcTB = Me.Form.CurrentRecord & " of " & Me.Form.Recordset.RecordCount" on the "current" event of the subform. The command works great, once i go to the second record or anywhere after that, but it will not display the corrrect counts on selecting the "master" selection criteria.

If i use the debugger, then the correct numbers show up.
What am i doing wrong or is there a better method of retrieving the data?

I dont see the "RecordCoun" property explaind in the help files for Access 2010. Does it still exsist?

Read other answers

I have a form which has a subform called SearchMainSub with displays data from the following:

Me![SearchMainSub].Form.RecordSource = MyRecordSource
'If no records match criteria, display message and move
'focus to Clear button
If Me![SearchMainSub].Form.RecordsetClone.RecordCount = 0 Then
'MsgBox "No Maintenace Records Found", 48, "No Records Found"
'Enable control in detail section

The problem that I am having is that it only displays the first record. I have tired all of the options in the data field for RecordSet Type. It still only displays the first record. Anyone have any ideas? I hope this one is as easy as the other question I asked.

A:Solved: Access 20007 Record Display 1st record only

Read other 6 answers

Hello All,
I have this database I built for all my music CDs. It is searchable by artist, date recorded, venue, city , state, notes and track title. The search works fine but I have one issue. I use a subform for all the track titles and it displays the correct songs for the CD. However, I get a record for each song. So if one CD has 16 songs I get 16 records for that CD. In my sample dB I have 7 CDs but it shows 117 records because that is the sum of all the songs on those 7 CDs. I want it to show only the 7 CD records and not a record for each song and still be searchable. I can make it show the way I want but then I can't search by song title. I attached my condensed database version to look at in case my description seems a bit convoluted. Thanks.

A:ACCESS: Form shows record for each record in subform

Read other 6 answers

What audio software can I use to simply record *what I hear* from the computer? Record what comes through the speakers.

A:What audio software can I use to simply record *what I hear* from the computer? Record what comes through the speakers.

Audacity should do what you want.

Read other 3 answers

I have a table which consists of date, time, odometer reading as fields. i want to calculate mileage of my vehicle by having query in Microsoft access 2007 which subtracts odometer reading from previous record with current record. can i get the mileage between the customized date and time?

this should take care if the odometer is reset and starts a fresh readings. should have the provision to enter manually the fuel quantity whenever odometer is not working properly.
any suggestion to build a query will be appreciated. thanks in advance.

A:How to create a querry to calculate difference between prev record and current record

Read other 10 answers

Hello.After upgrading my PC to Windows 10 i cannot open MS Access .mdb extension database.The error message: Bad record numberSo i uninstalled it and reinstalled Office and same thing. What's wrong? Is there a way to open my database?

A:Bad record number

Thank you for your message.Are you trying to access files created in a previous version of Access?Have you completed all Windows updates?What is the version of office suite installed?For my records, please click on my Dell username & send a private message with the service tag, registered name & email address.

Read other 1 answers


I've created a form in Access-2013 and placed record navigation buttons (using the button wizard) in the footer to allow the user to scroll through the records. They are the usual buttons and function as you would expect:

<< | < | > | >>[/FONT]

Problem is that when a user is on the last record in the table and clicks the ''right" button (in red above), the form displays a blank record. This is normal behavior for Access (as far as I know) and as long as a user enters NO DATA in ANY field, Access does not write the record to the table.

Given that users may be less than astute , I would like to eliminate the possibility of them creating a "blank" record in the table.

Is there anyway to stop this default behavior in Access?


A:Solved: Stopping a form from going past the last record when using record navigation

Read other 10 answers

Rog: You should love this one.


A:Record Number of Viruses??

Read other 6 answers

ASP using an access db. I have create a recordset that will return a single record and I'm trying to retrieve that record. When I try to get the record it won't retrieve that value. This is only happening when it is one record in the recordset. The recordset is not at BOF or EOF. Do anyone have any solutions or other alternatives. Need help ASAP, I have been working on this for several days. Below is the code:

Set rsHotFix2 = Server.CreateObject("ADODB.Recordset")
rsHotFix2.ActiveConnection = MM_AMT_DTS_STRING
rsHotFix2.Source = "SELECT Max([CID]) AS LastCID, SID FROM TCO_Contractors Group By LastCID, SID HAVING (TCO_Contractors.SID= "&rsHirerachy__MMColParam&")"
rsHotFix2.CursorType = 0
rsHotFix2.CursorLocation = 2
rsHotFix2.LockType = 1

if rsHotFix2.bof and rsHotFix2.eof then

response.write "Recordset Is Empty"
response.write "Recordset Is Not Empty"
response.write rsHotFix2.Fields(0) & "<BR>"
response.write rsHotFix2.Fields("LastCID") & "<BR>"
response.write rsHotFix2.Fields.Item("LastCID") & "<BR>"
response.write rsHotFix2("LastCID") & "<BR>"
end if
This is what's display on the page
Recordset Is Not Empty

Notice it does display the CID value.

A:ASP - Cannot Retrieve record from a 'single - record' recordset

Read other 8 answers

have an issue.

last night when i shut my computer off it kind of restarted by itself. this happened a few nights ago but i didnt think much of it, i just shut it down again.

but last night it shut down, started again but got stuck on the windows screen. this one

that blue bar just kept moving across. after about 5 minutes i switched the power off.

this morning i got that screen about windows not shutting down properly and so tried to boot in safe mode. i came back 5 minutes later and i was on that blue screen (the one you see when you install updates upon shutting down) and it was filled with "file record segment 3631 is unreadable".

there have also been a few lines like "inserting an index entry into index $0 of file [number]" or "deleting an index entry into index $0 of file [number]" as well as "12 percent complete"

its not finishing doing whatever it is doing so i cant do much right now so im just looking for some general help and advice on what to do afterwards. can someone explain whats going on? talk of $0 is worrying me a bit cause this is a register right?

edit: ok, it finished and got stuck on the same loading screen as before (image above) so now i need some active advice on what i should do

Read other answers

Currently got a letter mailing from a large database in Access 2003

In the letter, you have the choice of using criteria to choose certain records depending on search facilities

I have done this and it all prints well - but I would like to insert the ORIGINAL record number from the large database mentioned.

I did try it, but ended up with the record number of the SEARCH CRITERIA starting at 1.....

Any ideas ?

A:Insert record number into Mail Merge

The record number does not correspond to the primary key in general if you are ever deleting records there can be gaps in a sequence. Inserting the primary key would be simple.

Read other 3 answers

I am currently running Access 2007 on an Acer Aspire computer running Windows 7. I also use a recent HP desktop running Windows XP Professional and Access 2007 at work. I am setting up a database that has 830,031 records & 100 + fields in the main data table. Presently, the table has no unique record ID that could be used as a primary key. I want the table to be sorted in a specific (chronological) order, which I can easily do with a simple query. I have added a new empty field called D_Rec_ID, and I want to fill this field with the record number for each record in the sorted order. Once the database is completed, the number of records will not change. How can I populate this field with sequential record numbers? The only thing I can get to work is to set up an Excel spreadsheet with blocks of 8,000 sequential numbers, copy each block of numbers, and paste it into the Access table in the appropriate location. I can only do 8,000 at a time without exceeding the MaxLocksPerFile on my work computer (set at 9,500), which I can’t change. This is an extremely tedious process and prone to mistakes. Any suggestions would be greatly appreciated.

A:Solved: Sequential numbering of records with record number

DigitalDoc4, welcome to the Forum.

I assume this "database" is only going to be used for Searching?

To do what you want Copy the Table and Paste - Structure Only.
Set your new field to Autonumber.
Now create the the Query and sort it in the order that you want.
Convert the query to an Append query and select the new table as the table to be appended to.
Save and Run the query.
The records should now be entered in the new table in the order that you want with new ID numbers in that order.

Read other 2 answers

Microsoft on Tuesday patched a record number of security holes in its Windows operating systems and other software, a haul that included at least one security flaw that was already under attack in the wild.

Microsoft's Patch Tuesday fixes record number of flaws ? The Register

Read other answers

I have created a form in Microsoft Access, but I only have one record and it will not allow me to create new records in the form. Is there any way I can fix this problem without creating a new form? Thanks in advance.

A:New Record in Access

Read other 8 answers


We have an Access application that holds employees' table. When new employee comes, the email stating the name of a new employee and the link to this Access app. being sent to a supervisor. When supervisor starts the app, it opens the list of all new employees for a supervisor to choose from.
What my boss wants is, that access will open a new employee record by itself, depending on the name from the email. In other words, he wants to open the specific record by the link from email.

Is it possible to do this?


A:Solved: Access 2003 - Opening specific record in Access table via link in Outlook

Read other 16 answers


I am trying to record changes in the price increase in a products table of a Database

Basically, i make a percentage increase in the price in the products table, but i need to keep a record of the changes, i don't need to keep a record of the original price, just a record of the product, the date the change was made and % increase.

i'm using a query to update the table with the increase, so i'm not sure if i should be using this to read to another table with the updates or if i should create another table linked to the products table.

Any help will be much appreciated.

A:Keeping a record of changes in Access

Read other 9 answers

Hi all, I got this code type from one of the helpers in a group. It's a long story as to why I'm doing this so I really don't want to waste time stating it again. The original code works fine; however, I needed to use the same type when allowing users to Search and Edit. Using MS's "next" controls at bottom caused problems, so I created my own buttons to go to next. But, using the code given me...I can't get the form to move to the next record after all needed fields are input. Will someone please help me??? Here's what I have....

Private Sub cmdNextRec_Click()
On Error GoTo Err_cmdNextRec_Click

For Each ctl In Me.Controls

If Me.SEContractType = "Construction" Then
If ctl.Tag = "*" Or ctl.Tag = "***" Or ctl.Tag = "*##*" Then
If ctl = "" Or IsNull(ctl) Then

MsgBox "Data Required for '" & ctl.Name & "' Field."

Cancel = True

Exit Sub
Exit For
End If
End If
End If

If ctl Is Not Null Then
DoCmd.GoToRecord , , acNext
End If

Exit Sub

Resume Exit_cmdNextRec_Click

End Sub

A:Solved: Access 03 - Next Record

Have you tried moving this

If ctl Is Not Null Then DoCmd.GoToRecord , , acNext

to here

For Each ctl In Me.Controls

If ctl Is Not Null Then DoCmd.GoToRecord , , acNext
If Me.SEContractType = "Construction" Then

Read other 1 answers


Using Access 2002, Both Databases are in Access 2000 format.

We are currently running 2 databases, both located on the server and being accessed by multiple PCs. In regards to 2 people going into the same record...

Database 1: Will allow both users into the same record and will allow both to type. User 1 saves the record then when user 2 tries to save the record they will get a message giving the options to Save their changes and lose the User 1s changes or dropping their own changes. This will usually work but occasionally one of the fields will be marked as Deleted and can not be typed in until a Compact and Repair has been completed.

Database 2: This will allow both users into the same record but as soon as 1 user starts to type it will stop any other user from typing. This is the ideal that we would like to happen on Database 1.

I have checked "Tools" - "Options" - "Advanced" and these match for both databases. I have also tried all the options for "Default record locking" without effects.
"Tools" - "Options" - "Advanced" settings.

DDE Operations = Enable
Command Line is blank
OLE/DDE Timeout = 30
Refresh interval = 60
Number of update retries = 2
ODBC refresh interval = 1500
update retry interval = 250
Default file format = Access 2000
Default open mod... Read more

A:Access - Record Locking

Default Record locking has 3 levels
No Locks
All records
Edited Record

have you tried "Eited record"?

Read other 3 answers

Does anybody know how to change the ordering of fields/records when programmatically entering them into a DAO record set - Fields appear vertically and records horizontally.

A:Access Record set ordering

Read other 8 answers

I'm trying to delete a record in my Access Database and it will not allow me to delete or modify the record. I'm getting an error that reads "Reserved Error (-1601) there is no message for this error"
I tried in Forms and in the Datasheet view. No go! Any ideas?

A:Can't Delete Record in Access

Does the record look corrupted? Do you see funky values?

If you're running 2000, do tools > db utilities > compact and repair. You will prolly get a table called something like CompactErrors, look for it. Then delete it. Then reopen the table, find the record, and you should be able to kill it.

97 is the same, except you need to Repair first and then Compact, not all in one step yet...

Read other 3 answers

Hi guys.
Just a couple of quick questions (I hope).
I have a user who enters vehicle delivery and handling details into a form in an Access db. She wants to add a new form for additional details about the same vehicles (records).
The two forms would be linked via a button on each in the header area of the form, allowing the user to quickly switch back and forth between the two.

What I need to know is, if I search for a record in form 1, and then click the button to open form 2, can I make the same record appear automatically?
Am I making any sense?
Okay, so I've searched for record number 6 on either form, I've clicked the 'switch forms' button, I wanna see record number 6 smiling back at me.
It sounds like it's something really simple, but then again, this is Access.

Second question, do you think I should add the fields for the new form into the same table that supports the original form, or into a new related table?



A:Access 97 - go to same record in another form

Read other 8 answers

Is there a way that I could export just one of the records from a Access DB.

The Export must be able to be....
Emailed as an attachment.
Be editable (so the recipient can add to it, and email it back)

It would also be a benifit if the export could also be imported back into the original database.

A:MS Access - Export 1 Record

The fact that you want the exported item both editable and importable makes this more difficult and cuts down on te options.
You can easily export the record to an Excel worksheet or a Word document and then import it back in again. It just means that the recipient must have Excel or Word to respond.
The Excel method is easiest using transfer Spreadsheet. You will have to select your record from a form or query first of course, it can be placed in a temporary "transfer" table.
Have a look at the Visual Basic Editors Help, not Access help on how to use Transfer Spreadsheet. If you need more let us know.

Read other 3 answers


My credit union has an online service. I can check my account balance & transaction history.

From the main page I click a link. The next page asks for my acct. number & pin. I put it in, click, & the next page tells me the balance of both savings & checking. To get the transactions for either acct., I have to click the link for the acct. I want to check. So, I click checking and the next page tells me that this page cannot be accessed.

The tech help at the CU told me I needed to have cookies enabled. My cookies were enabled. They had no further idea what the problem might be. Can you help?


A:Why Can't I Access My Bank Record?

Read other 11 answers

hi, i recently started using access 2007. i am not an avid programmer, but managed to create tables / reports / forms for a small database application at our office. an overview of the architecture would be - users enter the data (customers / leads) from their front ends, manager verifies and adds some more data. thats it. i have created a few reports to check the activity.

now i have an issue, of late my manager complained that the number of applications generated by his team was too high (100 a month) and he was scrolling through the form to check each record. if he had to go to the 52 record, he has to scroll through all the 52 records from the begining. can anyone suggest a simple design where in my manager can go to a record of his wish. i am not a s/w programmer,so i would be greatful if you guys can keep it simple.

thanks in advance.

Read other answers

i have a table that has numeric fields (a,b,c). within each record i want to average the data in each of these fields. in other words, i want to average a,b,and c. and then have a report that one of the columns in the report is the average of the 3 fields.

A:averaging a record in access

That should be fairly straight forward. Make a query that adds up colA+colb+colc and then have another column that will take the results of the first and divide them by three....something like [Expr1]/3

Read other 3 answers

I have downloaded invoices from ebay but I can't get them in CSV. They come as in the following sample examples, o f which I have about 400 records to organize:

Aug 2 08:38:39 Spanish English Electronic Dictionary Translator: IPA 180143277420 Final Value Fee $1.42
vixu Final price: $34.00 (Fixed Price)

Aug 3 06:50:08 Spanish English Electronic Dictionary Translator: IPA 180143277420 Final Value Fee $1.42
sergiojlee Final price: $34.00 (Fixed Price)

Aug 4 21:13:08 Lezioni e Saggi su Dante: Francesco de Sanctis; Einaudi 180146139892 Gallery Fee $0.30
Fee of EUR 0.22 converted to $0.30 at a rate of 1.37850 (as of Aug-04-07).

Sep 15 07:10:22 France Marianne 100 Francs used Scott 556 180159894788 Insertion Fee Store Inventory $0.05

Sep 8 18:35:34 Saxofón Saxo Saxophone Alto Púrpura Morado NUEVO 180157735283 Item Subtitle Fee $0.18
Fee of EUR 0.13 converted to $0.18 at a rate of 1.37720 (as of Sep-08-07).

Aug 4 16:58:23 Spanish English Electronic Dictionary Translator: IPA 180143277420 Final Value Fee $1.42
cacophonix1 Final price: $34.00 (Fixed Price)​
I have a bunch for 4 months (about 400-600) so I want to get them delimited so I can get to work with them. I ahve them in MSaccent as individual records with no delimitation.

I forget how to split a record. I would like to put a tab after the date; another tab before the long ID number; another tab after the long ID number; and the easiest I image: a tab in front of all the dollar signs (EXCEPT where it sa... Read more

A:access how to plit record

You will probably find it easier to split the data in Excel using text to columns

Read other 1 answers

In my code below I can't get it to actually go to the first record giving me the Value of App_ID in the 1st record in the database. It keeps on coming up with the same row and the same value for App_ID. I thought rst.MoveFirst would bring it to the 1st record in the database. What am I doing wrong?

What I want is to search the database for 16410020 in the App_ID and diplay a message FOUND if it is found and if it ends up EOF then display a message NOT FOUND.

Private Sub TEST_LOOP()
Dim AppID, App_ID, db, rst

Set db = CurrentDb
Set rst = db.OpenRecordset("tbl_EMAIL_Data", dbOpenTable)

AppID = "16410020"

With rst
If rst.RecordCount > 0 Then
App_ID = rst!App_ID
MsgBox App_ID
Loop Until App_ID = AppID Or rst.EOF
If rst.EOF Then
End If
If App_ID = AppID Then
MsgBox "FOUND!"
End If
End If
End With
End Sub

A:Access 2000, EOF and First Record

bsmith987 said:

With rst
If rst.RecordCount > 0 Then
App_ID = rst!App_ID
MsgBox App_ID
Loop Until App_ID = AppID Or rst.EOF
If rst.EOF Then
End If
If App_ID = AppID Then
MsgBox "FOUND!"
End If
End If
End With
End SubClick to expand...

Looking at your code, you execute a movefirst, and then do a movenext before checking to see if the first record is the one you want. So, this code will always miss the first record. Try using a while instead of a do.
while not rst.eof and rst!AppID <> APPID
if rst.eof then
'msg not found
'msg found
end if
Good luck,
PS. Why use a <i>with rst</i> and then proceed all references with <i>rst.</i>?

Read other 3 answers

I am running Access XP with SP3. After I installed SP 3 I started getting the error message"No current record" when I delete the last record on a form. I cannot find any reference to this error message and I have no idea how to suppress it. The code in the sub that deletes the record is as follows:

DoCmd.SetWarnings False

DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 6, , acMenuVer70

DoCmd.SetWarnings True

Anybody any idea what I can do?

A:Access error msg - delete record

Likely, it's trying to display the next record when it deletes this one. Try adding something like goto record 1 (I don't do code, but I know enough to get into trouble) before turning warnings back on.

Read other 1 answers

I have a form in Access that is based on 2 tables. Table A has business units, Table B has business segments and the corresponding business unit.

For example, Table A will have entries:

And Table B will have entries:
Human Resources | Corporate
Application Development | Engineering
Hardware | Engineering

etc..... The first column in each table is the "ID", and the ID from Table A is linked 1:N to the corresponding field in Table B.

The problem I am having is that on the form, I choose the business unit from the dropdown (table A), and then choose a business segment from another dropdown on the same form. I want the business segments to only show the ones that match the business units from the previous dropdown.

So if I choose Engineering from the first dropdown, I only want to be able to choose from "Application Development" or "Hardware" from the second dropdown. I don't want to see "Human Resources" in the second dropdown, unless I select Corporate from the first dropdown.

Can anyone help me with this?

A:Access 2003 record selection

gurutech, this topic has been covered lots of times in recent past. If you look at some of my posts you will see what I mean.
Open the Form in Design Mode, Click on the second Combo, in it's Properties click on "Row Source" and then the 3 small dots.
Ensure that the first combo's ID field is in the query and enter the following in it's Criteria Row.
Forms![Form name]![ID Field Name]
where Form name is the name of your form.

Read other 1 answers

I have a database table that has approx 425,000 - 1 million records. I have a field that I am using for my primary [Number ID]. Even though there is a number in here the data type is set to text. I cannot change the data type nor can I add another column and put that data type as auto number or number.
What I want to do is this:

I need 30 samples. I have 425,000 records so 425,000/30 = 14166 . (Not rounding up just number before decimal) So I need a query that will pull every 14,166th record from the 425,000 records.

A:Retrive nth record using access query

Read other 12 answers

Hi All,

Still a relative Access 97 VBA newbie here. I've been fiddling with VBA all day today and managed to adapt an Autofill script to my
database that will (when I press my nifty button) automatically copy fields from the LAST record in a table and place it in a new record. This is ALMOST what I need.

Can someone show me how to modify the code so instead of going to the last record before copying the fields, it copies the fields of the record I'm currently on and then places the info in a new record?

FYI, I think this is the basic autofill code from microsoft, edited by me to include automatically adding a new record and generating a PK ID number. . .

Thanks in advance for any help,

Function AutoFillNewRecordOC(F As Form)

Dim RS As Recordset
Dim C As Control
Dim FillFields As String
Dim FillAllFields As Integer
Dim message As String
'-------for PK Generator----------
Dim db As Database
Dim qd As QueryDef
Dim RS1 As Recordset
'-------for PK Generator----------

On Error Resume Next

DoCmd.GoToRecord , , acNewRec
'-----------------------OC PK Generator---------------------

Set db = CurrentDb
Set qd = db.QueryDefs("SEQ_OC_PK")
Set RS1 = qd.OpenRecordset()
message = RS1.Fields("Expr1").Value

F.OC_ID = message
'-----------------------OC PK Generator---------------------
' Exit if not on the new record.
If Not F.NewRecord Then Exit Function

' Goto the last record of the form re... Read more

A:Access 97 VBA: Autofill from Current Record

Maybe this will help?


Read other 3 answers

A record in the table has gotten very corrupted with garbage data. I have tried every trick I can think of to delete the record from the table - and no matter what I do I get the message "Search Key not found in any record" I have gone through and changed the data for all relationship fields, but then I get the message "Invalid Argument". I have tried deleting the relationships and I have also tried deleting all the data on the record and still can not delete the record itself. I even tried writing a delete record query, but that also failed with the same error. Then I tried to copy the table so I could try to get rid of the record by forcing a duplicate, but it won't even let me make a copy of the table - when I try to paste I get the "Invalid Argument" error. Anybody know any tricks as to how to get rid of a corrupt record?

A:Corrupt Record in Access Table

To Punster:
My money says your using referential integrity and i know all the ac export
say thats what it is for, well you got lesson one, never use it. What i'm
speaking about is table analyze. But to solve the sticky wicket your in
try the following steps:
1. create a blank database.
2. close the database for now
3. open your original database
4. look under tools - relationships
5. remove your relationships
ps. if it were me id leave them undone, but thats where me and
ac exports differ in opinion. I've been using ac since 1.0 and
was sucked into to misbelief by book writers with no real world
experience and payed a heavy price for stupidity. I handle all
referential integrity thru query's and programming. But i never
built a database with less than 50 or more tables either, thats
the real world.
6. now close the database
7. open your blank database and recreate the table with fields
manually and do not create any key fields for now. Save table.
8. now open the original database with blank still open and open
the table in datasheet view. highlight and copy say 20 records
at a time and then do a paste append. close the table and then
reopen and to make sure there are no bad issues. If none continue
till all records are transfered.
9. now here is the tricky part, i would close the new database and
then delete the table from my original database, close then reopen
the database and import the table from the blank database. If old
murphy is smiling things shoul... Read more

Read other 1 answers

Hi, I have an access 2007 database where I have a main form and several subforms in tabs.

I would like to have the user be able to "Add a Record" to the subform. The simple "Add record" from the button wizard does not work. What do I need to do to add a record to the subform?


A:Access 2007 - Add record to a subform

Read other 16 answers

Every field is 64 in length yet we cannot export to DB5. We also cannot do a CSV because the file is too large any suggestions

Read other answers

Access 2007 Reports - For a record (I'll call it A) that has multiple records assigned to it, I only want record A to show only once. When I create the report, record A shows as many times as it has a record assigned to it. Example:

Joe (Record A) has two children. Each child is listed as a record, assigned to his home. When I create the report, it lists Joe twice because of his two children. I only want him listed once.

Home A

How do I get Joe to only show once?

A:Access Report - show one record only

Read other 7 answers

This brings me full circle with Access. I am now at the point in this particular database where I began. I now have 99% of it completed.

Here is the remaining 1% and it is the first major problem I ever encountered with Access. The problem itself is simple, I can not get Access to calculate values for individual records in a form. These calculations are done with an Event procedure, ON_Open instead of the controls source. I did it that way because I needed to do very complex lookups and calculations with the bound fields.

When the form is opened Access looks for this:

With CodeContextObject
Forms!WageCalc!Results = Nz(DLookup("[Rate]", "RATES", "[JobNo] &[Time]&[Class]='" & .JobNumber & .RateTime & .Class & "'"), 0)
End With

There are 3 rates for every class, and 13 classes. So there are 39 possibilities, but Access looks at the [Class] value in the first record and uses that Value for every record.

When I originally found this problem I was told that Access 2000 has a work around for this but I do not have the option to upgrade my users so I am faced with a problem.

The only thing I can think of is to create two fields for every record, one bound and one unbound. Do all my lookups and calculations with the unbound fields and then make the bound equal the unbound. It doesn't seem like a very good solution to me though but it would get the job done. Any suggestions?

Having just been introd... Read more

A:Getting Access to treat each record as a individual.

Read other 7 answers

MS Access 2000: Record Locks

I set by Database to "Open database using record-level locking" (by going to Tools >> Advanced) and I selected "Default record locking".

In my Form's properties, I selected "Edited Record" for the "Record Locks" option.

However, when I performed a test, Access STILL allowed two users to Access the same record at the same time (while in edit mode of the form)! Why is that?

I set the form and database to "record locking" to prevent to users from attempting to edit the same record at the same time (to prevent the db from locking and/or crashing). Yet Access still allowed this to happen.

Please explain what I'm doing wrong or is my perception of "Record Locking" not correct?

Note: My db contains "User Level Security"

Read other answers

I realise that the subject seems a bit obvious, but what I am trying to do is -

Scenario first...
I have a main form with a primary key QuoteRef which contains the details of people requesting a quotation. Each enquiry has the potential to have variations of product on the same quote e.g. storage container to buy or storage container to hire. So I have created a second table with a primary key, lets call it ContainerID and this table has QuoteRef as its foreign key linked via a one to many relationship.

The main form has a button that opens a second form based on the second table but the QuoteRef is pulled through so that the details in the second form are related to the person's details in the main form. So far so good...

What I would like is someway to add another record to this second table/form but still have it related to the person's details from the first record. I know it can be done using a sub form on the main form but I'm trying to make the actual data entry more user friendly. I tried creating a button using the wizard but this just creates an embedded macro and I can't find a way to edit it in VB.

I think I need code along the lines of

Forms![frmContainerRequirements]![QuoteRef] = Forms![frmContactDetails]![QuoteRef]

where frmContainerRequirements is the second form and frmContactDetails is the main one.

Sorry for being a bit long winded or confusing but I hope someone here can help me.

A:Access 2010 Adding a new record

Read other 11 answers

I have a main form that I have a combo box on that list all the data for that field. The combo box also is setup to allow you to type in the field. How do I display an error msgbox when the user types in the information and a corresponding record is not in the database. Here is my code.
Private Sub Combo31_AfterUpdate()
Dim rs As Object, SQL As String, fstring As String
SQL = "SELECT [Path id].* " & _
"FROM [Path id] " & _
"WHERE [Service id] = '" & Me.Combo31 & "' "
Set rs = CurrentDb.OpenRecordset(SQL)
fstring = rs.[Site]
Set rs = Nothing
Me.Filter = "[Site] = '" & fstring & "' "
Me.FilterOn = True
'clear out the search field for the next search
Me.Combo31 = Null
Set rs = Nothing
End Sub

A:Access VBA to display msg when record not found

mariaa33, that is quite a complicated way to set a filter.
Unless you have the possibility of more than one record with that Site you might just as well use a "Find Combo".
However if you want to continue using the current method you can add this after Set rs = CurrentDb.OpenRecordset(SQL)

if rs.recordcount =0 then
msgbox "That Site does not exist in the database".
Exit sub
end if

Read other 2 answers

Hey there, if i use the find button from the toolbar it works, but the docmd FinRcord button i created in the main form dont work.

I want to do this:

1). put something in the searchbox the click the search button, if found something go to the record if not do nothing and focus the sarchbox

2) Its there a way to make the navigationbar alittle bigger?

I inclueded the .mb if you wanna checkit. Thanks.

A:Find The Record from a searchTextbox in Access


Read other 2 answers


I have set up a combobox in my Access 2013 database to find a record and display in the rest of the text boxes on the form. I set it up with the wizard and it works when I go into it directly from the navigation pane, but when I go to it from my menu (via a macro), it doesn't display the info in the other text boxes.

This is the linking macro:

Form Name Cheques Presented
View Form
Filter Name
Where Condition =1=0
Data Mode
Window Mode Dialog
Control Name

And this is the macro for the combobox:
Object Type
Object Name
Record First
Where condition =="[ID] = " & Str(Nz([Screen].[ActiveControl],0))
Any ideas?

A:Access find a record not working

bigdawglj,welcome to the Forum.
It sounds like the Open Form Macro is not opening the form with the right info for the Combo to use.
If you manually open the Form from the list of forms does the Combo work?

Read other 4 answers

I am using the Student & classes template to record student grades.
I am trying to figure out how to print a report card per student. As yet all i can do is print a list of all teh students grades & classes all together. Is there a way to print a report that is baseed on a particular record i.e. the student ID.
Thanks in advance

A:(Solved) MS Access Report/per record?

Read other 12 answers


I'm trying to update a recordset using VBA and I get "Run-time Error '3000': Reserved error (-1524); there is no message for this error." when trying to update one of the fields using a variable. All other fields update ok.

Here is (a stripped down version ) the code:

Dim dbsOPRA As DAO.Database
Dim rsHistory As DAO.Recordset
Dim curUser AS String

Set dbsOPRA = CurrentDb
Set rsHistory = dbsOPRA.OpenRecordset("History_SkidLabels")

curUser = fGetFullNameOfLoggedUser

With rsHistory
!Line3 = Me.Line3.OldValue
!Line4 = Me.Line4.OldValue
!Line5 = Me.Line5.OldValue
!UserNameWindows = curUser


End With

Any help would be greatly appreciated!


A:Access: Update record using Variable

Which field gives the error?

Read other 3 answers