Solved

VBA adding appointment to Outlook calendar subtracting 1 day from end date

Posted on 2011-03-11
4
512 Views
Last Modified: 2013-11-27
I'm not sure if I can still ask a question here of if I'm supposed to start a new thread...sorry I'm a newbie.  

The problem I'm having is when the vacation request is for multiple days...say 3/2/2011 to 3/7/2011.  It goes into the calendar but subtracts a day from the end date.  So in the calendar it shows the vaca as 3/2/2011 to 3/6/2011.  Is there a correct way to fix this?  
0
Comment
Question by:AronMcD
  • 2
4 Comments
 
LVL 14

Accepted Solution

by:
pteranodon72 earned 500 total points
ID: 35109814
You don't show any code, so we are in the dark. My shot in the dark is:

If you specify only a date value, the time is assumed to be midnight. So, a vacation from midnight 3/2/2011 to midnight 3/7/2011 would mean that 3/7/2011 8:00 AM should be post-vacation. Add one day to the end date to move the end to midnight of the day of return.

Hope this helps,
pT72
0
 

Author Comment

by:AronMcD
ID: 35109855
Thanks pteranodon72.  I kind of figured that may be whats happening.  I can't just add a day to the end date as there are sometimes vacation requests for just one day ie: Start Date - 3/2/2011 to End Date - 3/2/2011.  Will have to do a check before adding the day?  If so, how would be the best way to do so?  Or is there another way?

Thanks again.
0
 
LVL 59

Expert Comment

by:Chris Bottomley
ID: 35110099
Can you give some examples as to what you have in your Db for me.startdate and me.enddate,  i.e for 1 and multiple day entries?

Chris
0
 

Author Comment

by:AronMcD
ID: 35110614
I ended up doing a check on the start date and end date.  If the end date was different than the start date I added a day.  Seems to work fine.

Thanks guys for the help.  
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Check out this infographic on what you need to make a good email signature that will work perfectly for your organization.
This process describes the steps required to Import and Export data from and to .pst files using Exchange 2010. We can use these steps to export data from a user to a .pst file, import data back to the same or a different user, or even import data t…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This Experts Exchange video Micro Tutorial shows how to tell Microsoft Office that a word is NOT spelled correctly. Microsoft Office has a built-in, main dictionary that is shared by Office apps, including Excel, Outlook, PowerPoint, and Word. When …

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now