none
No of Days per Month in the definition of FreeBusy method? RRS feed

  • Question

  • As per the definition, FreeBusy method returns the string representing one month of free/busy information for recipent.

    Executing the below code is giving me 28 whereas it should give me 30 or 31 depending on the start date month

    len(myRecipient.freebusy(objappt.start,24*60))

    Can someone please let me know, how many no of days are there in one month in the definition of this function?


    http://learn2automate.wordpress.com Vijay Gupta

    Thursday, September 12, 2013 1:49 PM

Answers

  • What does this have to do with a month? What is *your* definition of a month? Where does it even come from? If you want f/b data for, say, 61 days, it is your responsibility to split that interval into multiple slices each no longer than 28 days (4 weeks) long.

    Dmitry Streblechenko (MVP)
    http://www.dimastr.com/redemption
    Redemption - what the Outlook
    Object Model should have been
    Version 5.5 is now available!

    • Marked as answer by gupta vijay Saturday, September 14, 2013 6:42 AM
    Friday, September 13, 2013 1:43 PM

All replies

  • What difference does it make how long a month is? If you ask Outlook to give you 10 days worth of f/b data starting with August 25, the result will cover both August and September. Outlook does not return data starting with the first day of a month, you provide the start date.

    Dmitry Streblechenko (MVP)
    http://www.dimastr.com/redemption
    Redemption - what the Outlook
    Object Model should have been
    Version 5.5 is now available!

    Thursday, September 12, 2013 4:43 PM
  • Dimitri,

    The issue is: If I need free/busy information for 2 months, then I need to call free/busy method with different start dates and I need no of days in a month information to calculate 2nd start date.


    http://learn2automate.wordpress.com Vijay Gupta

    Thursday, September 12, 2013 5:12 PM
  • No, why? If you get back 28 days, call the method once, add 28 to the start date (whatever it is), call GetFreeBusy again, etc.

    Dmitry Streblechenko (MVP)
    http://www.dimastr.com/redemption
    Redemption - what the Outlook
    Object Model should have been
    Version 5.5 is now available!

    Thursday, September 12, 2013 5:25 PM
  • So, month has 28 days as per the function...correct?

    Can you try running the above statement at your end and check what are you getting?


    http://learn2automate.wordpress.com Vijay Gupta

    Friday, September 13, 2013 9:18 AM
  • What does this have to do with a month? What is *your* definition of a month? Where does it even come from? If you want f/b data for, say, 61 days, it is your responsibility to split that interval into multiple slices each no longer than 28 days (4 weeks) long.

    Dmitry Streblechenko (MVP)
    http://www.dimastr.com/redemption
    Redemption - what the Outlook
    Object Model should have been
    Version 5.5 is now available!

    • Marked as answer by gupta vijay Saturday, September 14, 2013 6:42 AM
    Friday, September 13, 2013 1:43 PM
  • Sure Dmitri. I will do that. However, to answer your query that from where the month issue came from: It came from the MSDN's description of the function. 28 days should be mentioned there instead of a month.

    http://learn2automate.wordpress.com Vijay Gupta

    Saturday, September 14, 2013 6:41 AM