hi ECEK
you would use the LIKE operator and use the * before and after any text/variable. Something like the below (untested);
Me.Filter = "firstname LIKE '*' &" & Me.textBox2 & "& '*' AND surname LIKE '*'&" & textBox1 & "&'*'"
As far as i know, even in MS Access 2016, there are no commands to lock/unlock the VBA project. You may be able to fudge something with sendkeys, but that is fraught with so many problems/liabilities.
Do you really need the project locked?
He all
My company has just switched to a new server. I have gone through a DB re linking the tables to the new location of the back end. However 1 table (HICC_List) would NOT link. It kept hitting me with "cannot open or write" error. So i thought create a new link, rename and delete origal:
I...
Hi
You just need to make number property of the DateAdd() function negative, so
DateAdd("d", -1, tmpDate)
So if you called the function as this - addWorkDays(5, 15/06/2016) it will return 09/06/2016 unless there were bank holidays
Hi jdraw
Many thanks for the links.
It is in the plans to put copies of the front end on each users PC - or at least each users My Docs folder on the server. Will that still work as 'seperate' instances of the FE?
Hi
I would probably try using "≤5" as the default colour.
So if you want the textbox?cell?Field? to go red with "≤5" in, set its background or foreground to red, then create conditional formats for 6, 7, 8, 9 and N/A and NULL
Hi Minty
Deliberately avoided multiple front ends initially to make updates easier, but that may be the solution now.
Do you think storing the user ID would work and which is the better approach?
So a query would be look like;
SELECT A,B,C FROM TABLE WHERE recSlct = TRUE AND recSlctID =...
Hi all
I have a table that includes a boolean field called recSlct. The purpose of this field is to allow a user to select multiple records on a continuous form to then carry out a range of tasks (view detailed data, print reports, update statuses etc). This works all well and good in single...
You can get a full explanation of this at https://msdn.microsoft.com/en-us/library/office/ff844793.aspx
In short, TransferSpreadsheet has 4 parameters for exporting
TransferType - acExport
SpreadsheetType - variable to identify the version of Excel
TableName - the table or query to export...
Have a look at the DoCmd.TransferSpreadsheet method.
Just create a sub routine to be called before closing the database (on prompt from a command button OR On_Close event of a form OR On_Timer interval event etc). Loop through each table in your DB (excluding the SYS_xxxx tables), create a...
Hi
It would not work error handling specifically, it would not know which field has not been missed.
The simple answer is data checking. So in the On_Click event of the Enter button, check each of the required fields for null values, and use message boxes to inform the user of the missing...
Hi,
If you just want to open it, then use FollowHyperlink method, so
Application.FollowHyperlink("\\MyNetworkFile\name.accdb")
If this does not work due to the file path, try the drive letter EG C:\MyNetworkFile\name.accdb
hi
OK my bad i'm doing this on the fly. Connections I think should be applied to the application object, so just
.Connections("NPCP_DATA")
The second error would be no reference set to the relevant Excel library.
I am sure it should just refresh. A couple of thoughts on why not but i do not think it should affect it.
Is the spreadsheet already open by another user?
Is there already an instance of Excel running on your PC (your method will open a new instance of excel and open the spredsheet in it.)
I...
The piece of code you just posted has 17 field names but 18 values so Access does not know where the extra piece of data should go.
When there is no date (rst![RPIDate] is null) you do not want to include the field name [RPIDate] in list of fields to assign values to AND you do not want to...
hi Frank
Assuming they are bound, you would need an update query, either an existing query or run SQL on the fly. Your query would need to say update fieldX to value of fieldY on FormZ where join field = FormZ.join field.
Are the check boxes on the subform bound to a field in a table?
What are...
Hi Nyanko,
Firstly thank you for such a concise explanation of the issue.
My approach here would be to check the value of rst![RPIDate] before building strSQL. You will need to build strSQL including RPIDate if RPIDate is a date and build strSQL excluding RPIDate if RPIDate is null.
If...
That was good advice. Just amend the query slightly and voila, SQL of a query that will achieve your aim of identifying the differences.
SELECT Query1.Key
FROM Query1 LEFT JOIN Query2 ON Query1.[Key] = Query2.[Key]
WHERE (((Query2.F1)<>[Query1].[F1])) OR (((Query2.F2)<>[Query1].[F2])) OR...