Recent content by HarrySpencer

  1. H

    Using a query to count a field multiple times (sub totals and a total)

    @CazB you're idea worked with a little playing around. I now have 8 queries working this all out. The main one collecting the the person info and then 8 total sub-queries, 7 using a variation of the expression you provided and shown below and the last one just doing a simple count on the type...
  2. H

    Using a query to count a field multiple times (sub totals and a total)

    Thanks for the replies. I have a quick update. I've manage to get the counts to work with sub queries but only if there is something to count. So if a person doesn't have a merit type it doesn't return zero and the query doesn't return any record. So I guess a side question, is it possible...
  3. H

    Using a query to count a field multiple times (sub totals and a total)

    Hello Sure this is possible and currently trying different things but haven't been able to find any information on what I'm trying to do but not really sure what to search for. I have 2 tables (person / merit) currently the merti table has 4 fields (MeritID, PersonID, Issuer, Type) I'm...
  4. H

    Error trying to execute SQL statement with VBA

    Yes that was the main problem and everything is now working after a little more editing. Thanks for your help.
  5. H

    Error trying to execute SQL statement with VBA

    That was a typo, thanks for the second set of eyes. Thanks again, Harry
  6. H

    Error trying to execute SQL statement with VBA

    Hello Sorry if this is in the wrong forum. I'm trying to create a function to update and amend records in a table. The update part works and updates existing records with new data but I'm getting an error with the insert part. Might be my SQL, I found it in an example and edited but the...
  7. H

    Need to convert a string to integer but it isn't working

    Great that's work great thanks for your help here is the code if anyone is interested Dim rst As Recordset Set rst = Forms![MainPage_fm].RecordsetClone rst.FindFirst "[PersonalID]=" & Me![PersonalID] If rst.NoMatch = False Then Forms![MainPage_fm].Bookmark =...
  8. H

    Need to convert a string to integer but it isn't working

    Hello, I've been using the following code for ages but wanted to change the fields being search because if the search field(NiNo) is blank it wouldn't return any results or jump to that record. Now trying to use the PersonalID field but having problems matching the data types. The code runs...
  9. H

    limit records in a subform

    EXCELLENT!!! That works perfectly. Cheers Here is the code I've used if anyone is interested. Private Sub Form_BeforeInsert(Cancel As Integer) If Form.RecordsetClone.RecordCount > 6 Then Cancel = True End If End Sub
  10. H

    limit records in a subform

    Hello, I've not been able to locate any information on this and I'm guessing I'll need to do this with some VBA code. I have a table called person with associated fields, name, dob, address, etc and a table called timetable that holds day, start time, end time. I've setup the timetable as a...
  11. H

    Single Record Table

    yes it is bound and that makes perfect sense. Cheers
  12. H

    Single Record Table

    Hello, I've creating a database that will only need to store a single record in one of the tables. This table will be linked to another that can store multiple record, like a workplace and employee. There is only one workplace so I only want there to be one record in this table this record...
  13. H

    DCount is going to make me cry

    thank you that's help me get it working. I only need to calculate certain ages so will just repeat for those. Many thanks again. Harry
  14. H

    DCount is going to make me cry

    Hello Please can someone give mesome advice on my DCount statement. I'm using the statement that will count the number of records (people) with an age of 18 who are connect to a certain establishment. The age only needs to be calculated at certain times of the year so it is stored in the table...
  15. H

    Date format in Access

    solution found Thanks for the help just found the regional settings under windows CP works fine now. Thanks again, Harry
Back
Top Bottom