Search results

  1. G

    Calculating the information for a text field on a form from a query

    Hi vbaInet The idea was to identify the date of the last holiday taken using the start date and the date of the next holiday booked using the end date.
  2. G

    Calculating the information for a text field on a form from a query

    Can I safely remove the db now?
  3. G

    Calculating the information for a text field on a form from a query

    I'm assuming that you mean make sure it's set to general date which both are. I'm going to post a copy of the db. Can you let me know when you get a copy as it contains information that I don't want to leave on the site but it would take forever to rebuild the db if I removed it
  4. G

    Calculating the information for a text field on a form from a query

    Hello again vbaInet I'll upload a sample dbase this morning. What formatting were you wanting for the text boxes?
  5. G

    Calculating the information for a text field on a form from a query

    I'm back. vbaInet I hope you had a peacefull time without me nagging away with my questions:D Rain, I know far better than to ignore vbaInets advice. Anyway I've created the second message box as requested and it accurately reflects the trainer name and start date that I enter. The Holiday...
  6. G

    Calculating the information for a text field on a form from a query

    Thanks vbaInet I stop today for a week and wont have access to the database till next Saturday. You can be sure you'll know when I get back. Cheers Guinness
  7. G

    Calculating the information for a text field on a form from a query

    Ok that's the function in the form and the Payroll_Number field in the query. The query is sorted by Start_Date ascending. The function is presently called by cicking a button called Test_Button
  8. G

    Calculating the information for a text field on a form from a query

    Thanks vbaInet I've taken the employye ID which is the primary key from the employees table and put it in to the Hours Holiday_P1 query. Do you need me to take the module and place it on the form as well?
  9. G

    Calculating the information for a text field on a form from a query

    The second of the two message boxes didn't work. It kept comming up invalid use of Me. I thought it was just an alternative to the first so wasn't worried. I haven't used ID in either my form or my query so would then have to either add it to both or reference the employees table as well as...
  10. G

    Calculating the information for a text field on a form from a query

    Hi vbaInet Sorry for the time in replying. I was away from my desk I used a button as suggested but am now getting 02/01/2014 as the most recent date. I appreciate that it would be possible to have two trainers with the same name however the database is restricted to using the names from...
  11. G

    Calculating the information for a text field on a form from a query

    Hi vbaInet It runs automatically when you tab out of the field Private Sub Start_Date_AfterUpdate() LastHol End Sub
  12. G

    Calculating the information for a text field on a form from a query

    Come in Houston we appear to have a problem Hi vbaInet. I'm testing that date function at the moment before I attempt datediff and I'm afraid it has issues. I've attached a screenshot to give an example. I'm trying to book a trainer for 18/08/2014. His most recent holiday based on that date...
  13. G

    Calculating the information for a text field on a form from a query

    Will do (possibly on both counts but I'd have to be better at access first) but she's about due home now so I might have to get to this either after 11pm or in the morning:D
  14. G

    Calculating the information for a text field on a form from a query

    Ok I know better than to doubt you. So what do you want me to do next?
  15. G

    Calculating the information for a text field on a form from a query

    So in sequence: Enter Start_Date produces Last_Hol date Difference between the two creates number of days since Holiday which can have it's very own text box. Then enter end date (Provided it's not a holiday) Look at next holiday booked date (If there is one) Work out the days...
  16. G

    Calculating the information for a text field on a form from a query

    You're getting ahead of me again It isn't hard to do. My thinking was if I went back to plan A where instead of a message box that date was populated in the Last Hol text box then I could reference that text box and the Start_Date above when attempting to define the DateDiff. Am I off...
  17. G

    Calculating the information for a text field on a form from a query

    Should I pour a large drink first or is this something I might actually cope with? Also I thought I needed to create variables and reference them hence the dims I wrote but your code doesn't seem to really need them. I kind of got that bit from a book but maybe I've missed the point...
Back
Top Bottom