Microsoft Access





Microsoft Access is a rapid application development (RAD) relational database tool. Access can be used for both desktop and web-based applications, and uses VBA (Visual Basic for Applications) as its coding language.

Share tech news, updates, or what's on your mind.

Sign up to Post

I am aware of the "Query is corrupt" issues caused by the MS November update.  I am a developer and sent the notice and link to the fix to all of my clients when the issue occurred.

I hadn't encountered the issue with anything I was running or developing on my office machines so I too no action.

My office machines are 64 bit Win 7 Pro, Office 2013 Pro 32-bit.

Now I'm trying to test something on my office machine and encountered the "query is corrupt" message.

I went back to the MS link with instructions to resolve the issue, downloaded the fix for my environment (ace2013-kb2965317-fullfile-x86-glb.exe).  However, when I run the fix I get a message "There are no products affected by this package installed on this machine".  

I'm obviously missing something but cant' figure pout what it is.

Can anyone suggest what might be happening?

The top of this pic is snapshot from my Office application, the bottom of the pic is the snapshot from the MS 'fix' website.  I clicked on the option to download the fix to the 32-bit version of office which resulted in 'ace2013-kb2965317-fullfile-x86-glb.exe' being downloaded.  

Query Is Corrupt Fix Not Working
Attempt to install the downloaded file led to the message telling me the fix didn't apply to anything on my machine.
I would like to change the Record Source of a sun form in MS access using a query.  This below is not working:

If FrameValues = 1 Then

    Form_navDashboard.frmSubCollectionTemplate_sub.Form.RecordSource = "sqryDashboardInputTable_ALL"
    Form_navDashboard.frmSubCollectionTemplate_sub.Form.RecordSource = "sqryDashboardInputTable_FILTER"
End If
Dear Experts
I still need your expert guidance on the issue below:
(1)      I have form bound to customer table, the type of customers we have range from students, trading customers, hotels or tourist & patients. Since the only difference is in terms of data capturing and the nature of customers in question.

So, we want the same form to be used to across the board BUT with option to select the type of data applicable, for example see below:
•      Company (This may be used for general trading)
•      StudentName (This could be for schools)
•      TouristName (this could be for hotels)
The above three controls must be made optional with a check box so that only customers applicable in that business must be VISIBLE if they are NOT checked.
With the use of VBA how do I use a check box to hide those controls that are not required to be updated depending to the business nature AND unhide after update. The issue here is how to code the checkbox (Option39) vs control name (studentName) etc, for example something in this line.
Afterupdate option39()
Me.StudentName .Visible = False
Exist Sub
End If

Open in new window

The advantage of the suggested system will save us from creating independent tables per each business category. The good news here is that even if I’m sitting at 120 tables, 350 queries, 1 macro & 120 Modules, no single object failed the MS access performance analyser test. If you look at the actual application performance you might think that it has only 4…

I have long ComboBox lists. Is there a way tohave the ComboBox list start at the top of the form or screen
when the control is part way down the form?


This doesn't always work. Is there anything I can add or change?

Private Sub txtSearchActionType_Change()
End Sub
I have attached a Word 2016 document outlining my objective. I am in the process of creating a database on Excel Topics, SubTopics, Issues, and Solutions. There are 4 tables currently set up:
tblTopic; tblSubTopic; tblIssue; tblSolutions.
Where I need help is feedback that I have correctly linked my various tables (Relationship diagram is in the document) and is my structures and relationships correct before I do something stupid like start over again.
It has been 7 years since I last used Access and too many senior moments are  getting in the way.
Thanking you kindly.....
good afternoon!
i  have the following statement:

strBody = strBody & ctl.Name & " : " & ctl.Value & vbCrLf

will produce the following output:

ID : 1 FName : Peter Frampton Email : (all in one line)

is there   a way to break to the following:
ID : 1
FName : Peter Frampton
Femail :

i tried: vbNewLine and chr(13) and & _: nothing is working ... unfortunately
could you help me to finish the task, please
I've attached an Access database with a Form containing a command button that is to be used to select an Access file for import.

The button contains FileDialog code that works and that I take no credit for having written.

I've attached an example of the type of Excel file I need to import.

You will see it contains 3 columns of data that begins on row 18 of columns C, D and E and ends on row 22 of columns C, D, and E.

At a minimum, via use of the command button already on the form where I select a file for import/transfer, I'm trying to bring

those 3 columns and 5 rows of data into an Access table.  I don't care if it goes into a new or existing table.

Ideally though, what I'd like to be able to do is have the first 6 digits of column C (which represents the account number) go into its own column, the remainder of column C go into its own column, the Statistics go into its own column, the Dollar Amount go into its own column, and the date information (in cell D6) go into its own column and appear in every row of data so that the 5-column expected results table will look something like this:

Field1       Field2                                               Field3       Field4           Field5
111111   Description of Account 111111       10           10.00     25-NOV-2019  
222222   Description of Account 222222        5          100.00     25-NOV-2019
333333   Description of Account 333333      100     3000.00     25-NOV-2019  
444444   Description of…

I have been asked to make an Access ComboBox longer so that a user can see more items at once. Is this possible?

Ideally I would like the ComboBox to be close to the height of the screen


I have an Access ComboBox1 with the following RowSource and in the t_Manufacturer Change event
I have the code ComboBox1.Requery but for some reason the ComboBox1 list is not filtering according to what I type in the textbox
SELECT t_Manufacturer.Manufacturer, t_Manufacturer.Country FROM t_Manufacturer WHERE (((t_Manufacturer.Manufacturer) Like "*" & [forms
Hi I posed the following question about filtering an Access ComboBox

I now have a similar scenario where I have three text boxes for Name, Surname and Company Name
I want the user to type anything into one or more of these text boxes and then filter a single ComboBox
called cmbLicensee
How would I do this?
I want to filter a ComboBox by the letters in an adjacent text box as the user types.
What is the best way to do this and what code would I use if my controls are called
ComboBox1 and TextBox1?
Hi Experts,

Getting attached error when trying to perform an update query.
The underlying table is updatable in Access.
Table is SQL based.
I'm trying to use the following code, which is part of some FileDialog code I got on the net to import an Excel file with a .xlsm extension into Access and it's not working.   When I navigate through windows explorer as a result of running the FileDialog code, I'm not seeing the file I want to select. I'm guessing because it has a .xlsm extension.

Also, if I can get the file to import, I'd like to only include columns C, D and E as well as start on row 16 if possible (skip over the first 15 rows).

tblFileName = strFilePath
DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel9, "tblTest", tblFileName, True
hi, i have a simple database
The table tblMain:
ID,Fname, SEmail
SELECT tblMain.ID, tblMain.FName, tblMain.SEmail FROM tblMain;
Form FrmMain
has all three fields and the button

the button should send the content of the particular form to the email ( tblMain.SEmail )
for some reason i am getting the error message :

the command or action "SendObject" is not available now

what should i do?
the database
again, what ever on the form should go to the email on the form
I have an x query that I want to convert to VBA SQL code.  The query is named updqryUpdatePCMDataWarehouseFormToProjectBilledFalse and I'm using it like this:

Private Sub Form_AfterInsert()

    DoCmd.SetWarnings False
        DoCmd.OpenQuery "updqryUpdatePCMDataWarehouseFormToProjectBilledFalse"
    DoCmd.SetWarnings True
    End Sub

Open in new window

The query looks like this:

UPDATE tbl_PCMFinalData SET tbl_PCMFinalData.ProjectBilled = False
WHERE (((tbl_PCMFinalData.[Job Number])=[Forms]![frmTimeSheetHeader].[Form]![frmTimeSheetdetail].[Form].[cboJobNumber]));

But I want to replace the updqryUpdatePCMDataWarehouseFormToProjectBilledFalse with a SQL statement in the VBA window.

How do I do that?
I would like to count today's created record on MS Access
I would like to set a filter button on MS Access form.
Please check sample
I am getting the following error when trying to import Excel data into Access with no explanation of what is causing the error. Is there a way to get more detail than this

I have textBox on a VBA form named txtAnswer

I would like to restrict what can be entered in a VBA TextBox (txtAnswer) to letters only.
If the user presses a number key the number will not be typed into the TextBox but instead a Message Box will pop up showing the number key that has been pressed. Also if the user presses the Enter Key a Message Box should pop up saying “You pressed Enter Key”

So if the user starts typing “ a p p p l e  “ then the word “apple” will get typed into txtAnswer, but if the user presses a number key such 3 then the text in the txtAnswer will remain unchanged but a message box will pop saying “You pressed 3 ‘“
Thank you for your help.
I would like to use following function to locate Blank record
Blank: IIf(InStr([table],"")<>0,"Blank")
However it locates all not null record as "Blank"
Please advise.
Have been using the following code with perfect results:

GCriteria = "OptA" & " LIKE '*" & FindRecText & "*'" & " OR OptB" & " LIKE '*" & FindRecText & "*'"
Form_FEntryQuery.RecordSource = "select * from tObj where " & GCriteria & ""

But now I would like to add "OptC" along with OptA for either to be found.  Ex:

GCriteria = "OptA" & " Or " & "OptAC" & " LIKE '*" & FindRecText & "*'" & " OR
OptAB" & " LIKE '*" & FindRecText & "*'"

My results are not finding the correct records... what am I doing wrong with my syntax?
I am helping a friend with an old access file that is compiled into an .MDE file.    If possible, we need to get the reports and forms out of it.  I know its not easy to convert an .mde to an .mdb, but is it possible?


I have a main form (Main_Menu) and 2 sub forms (Main_DLMP and Main_DeptView). In the main menu I have 2 labels that act as menu.  I have click events on both these labels.  I want to make one visible, and the other not visible.  But I struggling with this.  These are the 2 events I have for each of the labels in my main form.

 This is the event on the first label. As default Main_DLMP visibility is set to True and DLMP_DeptView is set to False.
    Forms![Main_Menu]![Main_DLMP].Form.Visible = True
    Forms![Main_Menu]![Main_DeptView].Form.Visible = False

This is the event on the second lablel
    Forms![Main_Menu]![Main_DeptView].Form.Visible = True
    Forms![Main_Menu]![Main_DLMP].Form.Visible = False
I am getting an error on the second label... Cannot set focus.
Hey Experts,

I have an app that has a function used for relinking on my client's server. All these parameters are stored in variable, and the backend is password protected. This function was originally developed using ADO on a non password protected backend, but now the backend is protected. I'm trying to redo the function so that it works with the password.

Here's the section of code:

Set catDB = New ADOX.Catalog
' Open a catalog on the database in which to refresh links.
catDB.ActiveConnection = CurrentProject.Connection

For Each tblLink In catDB.Tables
    ' Check to make sure table is a linked table.
    If tblLink.Type = "LINK" Then
        If InStr(tblLink.Properties("Jet OLEDB:Link Datasource"), strTransTrack_mdb) > 0 Then
           tblLink.Properties("Jet OLEDB:Link Provider String") = "MS Access;" & strTransTrackPWD & "DATABASE=" & strDBLinkSourceTransTrack & "\" & strTransTrack_mdb
           'tblLink.Properties("Jet OLEDB:Create Link") = True
        ElseIf InStr(tblLink.Properties("Jet OLEDB:Link Datasource"), strStep_mdb) Then
           tblLink.Properties("Jet OLEDB:Link Provider String") = "MS Access;" & strStepPWD & "DATABASE=" & strDBLinksourceStep & "\" & strStep_mdb
           'tblLink.Properties("Jet OLEDB:Create Link") = True
        End If

    End If

Open in new window

On my local machine this works fine. But on the server I'm getting an error message saying the that what I'm trying to link to is NOT  a valid path. Here's the error message.

The problem is... the error message is showing me the path from my LOCAL machine, NOT the path I'm trying to set it to. It's showing me the CURRENT path, which is not what I'm trying to link to. I'm trying to relink to   G:\Step_Tables.mdb, which is a valid path.

What am I missing in the ADO relink?

Any help would be greatly appreciated.

Microsoft Access





Microsoft Access is a rapid application development (RAD) relational database tool. Access can be used for both desktop and web-based applications, and uses VBA (Visual Basic for Applications) as its coding language.