Exchange Meeting Room Statistics

This script uses Exchange Web Services to connect to one or more meeting rooms and gather statistics regarding their usage between to specific dates.

 
 
 
 
 
4.4 Star
(5)
5,523 times
Add to favorites
Exchange
12/15/2017
E-mail Twitter del.icio.us Digg Facebook
Sign in to ask a question


  • Binding Error
    6 Posts | Last post August 19, 2019
    • Hi Nuno,
      
      Thank you for this script!
      
      I tried running this but i have been getting an error "Unable to connect to xyz@domain.com. Please check permissions: Exception calling "Bind" with "2"
      argument(s): "The request failed. The remote server returned an error: (401) Unauthorized.". Skipping xyz@domain.com"
      
      I have Hybrid environment and have full access on mailbox and Reviewer access on Calendar.Also i am a Global Admin on this tenant, but unable to resolve this issue of permission.
    • Hi MeaSri,
      
      Where is that particular meeting room located (on-prem or Exchange Online)? Where is the script connecting to (AutoDiscover)?
      
      Regards,
      Nuno
    • Hi Nuno,
      
      The meeting room is located on Exchange Online and script is "https://outlook.office365.com/EWS/Exchange.asmx"
      
      Do i need to make any changes in the script?
      
      Thank you,
      Mea
    • Hi Nuno,
      
      Can you check this as it is urgent and we don't have any other way to do this :)
      
      Thank you,
      Mea
    • Hi, I had the same error. The cause was MFA. Since you are Global Admin for tenant then MFA most likely is enabled by default. 
    • I have the same error. Hybrid Ex2016 on prem. Also a global admin in EXO.
      
      VERBOSE: Binding to the <mailbox> Calendar folder.
      VERBOSE: Unable to connect to <mailbox>. Please check permissions: Cannot find an overload for "Bind" and the argument count: "2".. Skipping <mailbox>.
      
      I granted FullAccess to my Global Admin account to the room mailbox.
  • not getting any output
    2 Posts | Last post August 18, 2019
    • Hi I am not getting any output when i run the ps1
    • Yes, it will also work for Exchange 2016. Try updating the following line:
      $service = New-Object Microsoft.Exchange.WebServices.Data.ExchangeService([Microsoft.Exchange.WebServices.Data.ExchangeVersion]::Exchange2013_SP1)
      
      What level of permissions do you have to the room or room calendars? Does the account you are using have a mailbox?
  • No Averages per room
    6 Posts | Last post August 18, 2019
    • Hi Nuno,
      
      Great script works like a charm. You answered a question from a user a year ago who wanted to do away with the averages and get stats per room. I am struggling with the answer you gave. 
      
      Here is the question and your response could you elaborate, if possible.
      "Is there a chance to have script that does not make a Average of meeting? I need to know how many meeting were booked the last three months. I need to see how many people attended the specific meeting, in which meetingroom. Can that be done?
      We need to figure out how the meetingrooms are being booked, do we have enough, do we have too many big meetingrooms and so on. Therefore we cannot use average numbers..."
      
      Your response was:
      "Sure, it doesn't take much work to update the script for what you want. Using my latest script on TechNet (https://gallery.technet.microsoft.com/Exchange-Meeting-Room-2aab769a) which uses EWS instead, all you have to do is put the:
      $romObj = New-Object PSObject -Property @{
      
      inside the:
      ForEach ($meeting in $fiItems.Items) {
      
      and update the room object so that instead of saving averages, it saves the data for every single meeting."
    • Hi Bryan,
      
      Thank you for the feedback!
      The script goes through every meeting for a particular meeting room, and gathers stats for each of those meetings. Then, after all meetings have been processed, it created a PowerShell object for that meeting room, calculates some averages, and saves the object.
      So, if you create an object within each meeting instead of within each meeting room (with some unique identifier), than you can have stats for all meetings, instead of averages. You’ll just need to update the object with the information you want, and remove the averages.
      Hope that makes sense.
      
      Regards,
      Nuno
    • Hi Bryan,
      
      Thank you for the feedback!
      The script goes through every meeting for a particular meeting room, and gathers stats for each of those meetings. Then, after all meetings have been processed, it created a PowerShell object for that meeting room, calculates some averages, and saves the object.
      So, if you create an object within each meeting instead of within each meeting room (with some unique identifier), than you can have stats for all meetings, instead of averages. You’ll just need to update the object with the information you want, and remove the averages.
      Hope that makes sense.
      
      Regards,
      Nuno
    • Hi Nuno,
      I tried doing what you said to list out all of the meetings for a room but it blanks on output. Basically:
      
      ...
      [Array] $mtgsCol = @()
      ...
      ForEach ($meeting in $fiItems.Items) {
      blah blah unchanged
      
      # Save the information gathered into an object and add it to our object collection
      	$mtgObj = New-Object PSObject -Property @{
      	blah blah unchanged	
      	}
      $mtgsCol += $mtgObj
      }
      $mtgsCol | Select ID, From, To, RoomEmail, RoomName, Meetings, Duration, AvgDuration, TotAttendees, AvgAttendees, RecAttendees, OptAttendees, AMtotal, AMperc, PMtotal, PMperc, RecTotal, RecPerc, TopOrg, TopAtt | Sort From, RoomName, RoomEmail
      
      
      I tried printing results inside each meeting, inside each room, and outside everything and still doesn't work. What am I doing wrong? Any advice would be helpful. Thanks. 
    • Also, it works fine if I don't modify the code at all. All permissions and everything work just fine. Thanks.
    • Hi WingDingRule,
      
      Sorry, but is it working or not after all?
      If you want to print every single meeting, the $meeting is what you want (inside the "ForEach ($meeting in $fiItems.Items)" statement. That variable will include every meeting for that particular room.
      
      Regards,
      Nuno
  • No results
    3 Posts | Last post August 18, 2019
    • I tried running as you suggested for our Office 365 mailboxes, but the output is always blank.
    • I did not realize you had to install the EWS Managed API MSI package first.  The script is running but now my global admin doesn't have rights to the resource (unable to connect).
    • Hi Cathi,
      
      If you do not have the EWS API installed, the script should throw a warning and exit.
      What level of permissions do you have to the room or room calendars? Does the account you are using have a mailbox?
      
      Regards,
      Nuno
  • Will this work for Exchange 2016 CU12
    1 Posts | Last post July 30, 2019
    • Will this work for Exchange 2016 CU12
  • Suggestion on Parameters
    1 Posts | Last post July 19, 2019
    • Not a question, more a suggestion, if you replace the parameters to be:
      	[Parameter(Position = 1, Mandatory = $False)]
      	[DateTime] $From = (Get-Date -Day 1 -Hour 0 -Minute -0 -Second 0).AddMonths(-1),
      	
      	[Parameter(Position = 2, Mandatory = $False)]
      	[DateTime] $To = (Get-Date -Day 1 -Hour 0 -Minute -0 -Second 0),
      
      It will default to giving you the last months reports for the rooms selected. Handy if you are automating reports for the business.
      
      Awesome script all in all, thank you for taking the time to write it, this has opened up alot of reporting opportunities. 
      
      
  • AutoDiscover Blocked...
    2 Posts | Last post July 02, 2019
    • I to am getting the auto discover issue. I have verified auto discover is working.
      
      xception calling "AutodiscoverUrl" with "1" argument(s): "Autodiscover blocked a potentially insecure redirection to https://autodiscover.xx.xxx.com/autodiscover/autodiscover.xml. To allow Autodiscover to follow the redirection, use the AutodiscoverUrl(string, 
      AutodiscoverRedirectionUrlValidationCallback) overload."
      At C:\Users\u93552.UNCH\Desktop\Scripts\Get-MeetingRoomStats.ps1:105 char:3
      +         $service.AutodiscoverUrl($Mailbox)
      
      Any help appreciated...
    • Add switch -ExchangeOnline
  • How to get the details of all the Meeting Rooms...
    1 Posts | Last post June 27, 2019
    • Hi , Thanks for your script , is there a way to get date of all the meeting rooms ? Without mentioning one at a time  or to call txt /csv file with room smtp address or details. 
      
      Thanks
      
  • 1000 Result size limit
    1 Posts | Last post May 15, 2019
    • I seemed to have hit the result size limit of 1000 defined in the "$CalendarView" object. And it would not allow me to increase that number any higher, instead the error suggest me use "paging". Any suggestion on how to get pass this? Thanks!
      
      Following is the error message:
      
      VERBOSE: Unable to retrieve data from user@domain.com calendar. Please check permissions: Exception calling "FindAppointments" with "2" argument(s): "You have exceeded the maximum number of objects that can be
      returned for the find operation. Use paging to reduce the result size and try your request again.". Skipping user@domain.com.
  • Exporting to ics?
    1 Posts | Last post May 14, 2019
    • Do you think this script could be modified to export O365 calendars to ICS files?  
      
      I think there's a way of granting access to the anonymous user and then getting a link out of OWA's Calendar (Options > Shared Calendars > Calendar Publishing) and downloading the file from there; but it doesn't seem very straight-forward.
1 - 10 of 36 Items