Results 1 to 8 of 8
  1. #1
    rshaw63 is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Mar 2020
    Posts
    32

    Need some help

    Hello Everyone

    I had been trying to get this to work but really dont understand VBA .

    What i am trying to do is take the dates for renewing permits in Access table and create Outlook calanadar events to remind me to renew on that day. Is there a way to do this?

    Click image for larger version. 

Name:	Capture.PNG 
Views:	18 
Size:	25.8 KB 
ID:	44278 this is the Form i want to use in this case.

    Click image for larger version. 

Name:	Capture2.PNG 
Views:	17 
Size:	27.5 KB 
ID:	44279 this date needs to be added to an outlook calendar as a reminder when this date is due

    Click image for larger version. 

Name:	Capture3.PNG 
Views:	17 
Size:	29.4 KB 
ID:	44280 i wanted to add as an option to send email reminder on this date to whoever submitted the request.


    thanks everyone in advance let me know if you need additional info to help out.


    Click image for larger version. 

Name:	capture5.PNG 
Views:	17 
Size:	175.1 KB 
ID:	44281
    Last edited by rshaw63; 02-17-2021 at 03:41 PM. Reason: Additional information

  2. #2
    Join Date
    Jan 2017
    Location
    Swansea,South Wales,UK
    Posts
    4,914
    Even the first link from the link below should get you started?

    https://www.google.com/search?q=crea...hrome&ie=UTF-8
    Please use # icon on toolbar when posting code snippets.
    Cross Posting: https://www.excelguru.ca/content.php?184
    Debugging Access: https://www.youtube.com/results?sear...bug+access+vba

  3. #3
    rshaw63 is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Mar 2020
    Posts
    32
    I forgot to mention i would like this all to happen Once that new record is entered into the database seamlessly so when record is saved it updates calendar and sends email.

    Again thanks so much for all of your help.

  4. #4
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,791
    Why bother with an Outlook calendar appointment reminder when the db could simply issue a reminder, or even a report showing whatever you want - missed, current, future? Sure, you need to have the db open to get that reminder, but you can't get a reminder from Outlook if it isn't open either.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  5. #5
    rshaw63 is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Mar 2020
    Posts
    32
    I like that idea as well as i use the database daily can you share how to do that? i imagine its a messagebox however like i said earlier i dont have much luck with VBA yet lol

  6. #6
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,791
    If you want this upon opening, either use an AutoExec macro that calls a function to look for whatever it is you're looking for and then notify, or use a form that is set to open (under db options) and have code behind that. You can do pretty much whatever you can think of. I'd consider a message box to be of very limited use for this. A form or report will likely prove more useful, or you can send an email with body text details or perhaps a pdf view of a report. On the other hand, that would only be a one time check at the beginning. If you want updates throughout the day, you might want to open a form hidden instead of the AutoExec and have a timer event on it that checks periodically as long as that form is open (realize that 1000 is 1 second in a timer event). Your table(s) need the data that will drive the process. Perhaps a lead time value (e.g. 5 days) that gets added to the due date for advanced warnings. Or maybe you just want reminders for past due? In the case of time based checks, your "due date" data needs to have valid times, not just the date. If you're only going to check once every time db opens, date values without specific times will do.

    Your code could run a query looking for (due tomorrow? past due?) and if the resulting recordset isn't empty, then do your notice thing, whatever that is.

    Be that as it may, you said you wanted this reminder for yourself so that's why I made the suggestion. If you send email reminders to other users and they don't open the message, that may not help. Getting access to other user's calendar can be problematic in a corporate suggestion, so if this really isn't for just you then reconsider.

    We're here to help with the vba and all that but you need some idea of how you see this playing out first.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  7. #7
    rshaw63 is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Mar 2020
    Posts
    32
    Quote Originally Posted by Micron View Post
    If you want this upon opening, either use an AutoExec macro that calls a function to look for whatever it is you're looking for and then notify, or use a form that is set to open (under db options) and have code behind that. You can do pretty much whatever you can think of. I'd consider a message box to be of very limited use for this. A form or report will likely prove more useful, or you can send an email with body text details or perhaps a pdf view of a report. On the other hand, that would only be a one time check at the beginning. If you want updates throughout the day, you might want to open a form hidden instead of the AutoExec and have a timer event on it that checks periodically as long as that form is open (realize that 1000 is 1 second in a timer event). Your table(s) need the data that will drive the process. Perhaps a lead time value (e.g. 5 days) that gets added to the due date for advanced warnings. Or maybe you just want reminders for past due? In the case of time based checks, your "due date" data needs to have valid times, not just the date. If you're only going to check once every time db opens, date values without specific times will do.

    Your code could run a query looking for (due tomorrow? past due?) and if the resulting recordset isn't empty, then do your notice thing, whatever that is.

    Be that as it may, you said you wanted this reminder for yourself so that's why I made the suggestion. If you send email reminders to other users and they don't open the message, that may not help. Getting access to other user's calendar can be problematic in a corporate suggestion, so if this really isn't for just you then reconsider.

    We're here to help with the vba and all that but you need some idea of how you see this playing out first.

    Again thank you for your help i have figured out how to do the query based on due date can that be displayed in message box? right now i have to click on the link to bring that up. I usually run Multiple projects at the same time and was hoping i could get a reminder to pop up

  8. #8
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,791
    can that be displayed in message box? right now i have to click on the link to bring that up
    No idea what "that" is or what "link" you're talking about. Yes you can raise a message box, but with a message, not a query.
    was hoping i could get a reminder to pop up
    I gave you a few methods/ideas. Pick one or come up with your own if they aren't suitable and then you have a path to follow. Right now, you have a desire for an end result and not much else.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

Please reply to this thread with any new information or opinions.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums