0 votes

We would like to have a report of not-disabled users and with user that have a exchange mailbox inside a business unit but for all business units.

We now generate a report wich is grouped by "MemberOfBusinessUnits" but we are currently unable to count the members of each group.

In the Adaxes Console GUI the User Count is shown, but these number is not included in the export (pdfx, xlsx): image.png

Is there a way to generate a simple report like:

Unit Count Users with Exchange
BU1 100 80
BU2 59 20

Is there a way to generate the diagramm chart automatically to show the user per business unit?

Thanks

by (650 points)
0

Hello,

Is there a way to generate a simple report like:

Yes, it is possible. However, there is no such possibility for Business Units whose membership rules contain value references. If your Business Units do not have value references in the rules, please, specify whether members can have mailboxes in on-premises Exchange, Exchange Online or both. Also, should the report always contain data for all Business Units?

Is there a way to generate the diagramm chart automatically to show the user per business unit?

Sorry for the confusion, but we are not sure what chart you need. Could you, please, provide a live example?

0

Hi

There will be only on-prem Exchange Users. We do not have value refernces. They are selected by the OU in the Active Directory: image.png

Yes, the data should always be generated for all Business Units.

For the chart, we imagine something like this. This could also be split into two charts (Active users/Exchange Users): image.png

The diagramm per Business Unit should be generated automatically so we dont have to define a "chart" manually for each business unit.

0

Hello,

Thank you for the provided details. Unfortunately, there is no possibility to make a chart like in your example. As a solution, the chart can contain two items for each Business Unit: the total number of members and the number of members with Exchange mailboxes. Does this approach meet your needs?

0

Hi

Two items would work too. The chart ist just an extra though.

The most important would be to get the table automised. Can you provide us with an example on how to do it?

Thanks

1 Answer

0 votes
by (174k points)

Hello,

Thank you for the confirmation. Unfortunately, there is no possibility to make a chart with two items per Business Unit, sorry for the confusion. To create the report that will output required information on Business Unit members:

  1. Launch Adaxes Administration Console.
  2. In the Console Tree, right-click your service node.
  3. In the context menu, navigate to New and click Report. image.png
  4. Enter a report name and select Script. image.png
  5. Click Next three times.
  6. In the Report-specific columns section, click Add. image.png
  7. Enter a column name (e.g. Total members count).
  8. Select Number and click Next. image.png
  9. Select Template.
  10. In the field below, enter a default column value (e.g. empty). The value will never be present in the column, but is required as the template cannot be empty. image.png
  11. Click Finish.
  12. Repeat steps 6-11 for the column that will contain the number of users with Exchange mailboxes.
  13. Click Next.
  14. Paste the below script into the corresponding field. In the script:
    • $totalCountColumnID - Specifies the unique identifier of the custom column that will contain the total number of Business Unit members. To get the identifier:
      • On the Columns step, right-click the custom column.
      • In the context menu, navigate to Copy and click Column ID. image.png
      • The identifier will be copied to clipboard.
    • $usersWithExchangeColumnID - Specifies the unique identifier of the custom column that will contain the total number of Business Unit members with exchange mailboxes.
$totalCountColumnID = "{37dc4068-d4c7-4d57-92f1-3234f015aa0f}" # TODO: modify me
$usersWithExchangeColumnID = "{3c273cbf-1d1e-4544-80a3-d7db3626d477}" # TODO: modify me

$businessUnitsContainerPath = $Context.GetWellKnownContainerPath("BusinessUnits")
$searcher = $Context.BindToObject($businessUnitsContainerPath)
$searcher.SearchFilter = "(objectCategory=adm-BusinessUnit)"
$searcher.PageSize = 500
$searcher.SearchScope = "ADS_SCOPE_SUBTREE"

try
{
    $searchResultIterator = $searcher.ExecuteSearch()
    $searchResults = $searchResultIterator.FetchAll()

    foreach ($searchResult in $searchResults)
    {
        # Bind to Business Unit
        $businessUnit = $Context.BindToObjectBySearchResult($searchResult)

        # Get total number of Business Unit members
        $members = $businessUnit.Members()
        $membersCount = $members.Count

        $usersWithExchangeCount = 0

        for ($i = 0; $i -lt $membersCount; $i++)
        {
            $member = $members.GetObject($i)
            if ($member.RecipientType -ne "ADM_EXCHANGERECIPIENTTYPE_MAILBOXENABLED")
            {
                continue
            }

            $usersWithExchangeCount++
        }

        # Specify column values
        $columnValues = @{ $totalCountColumnID = $membersCount; $usersWithExchangeColumnID = $usersWithExchangeCount }

        # Add Business Unit to report
        $Context.Items.Add($businessUnit, $columnValues)
    }
}
finally
{
    # Release resources
    $searchResultIterator.Dispose()
}
  1. Click Next and finish creating the report.
0

Thanks a lot, this worked like a charm and helped understand the script-based reporting.

Send report as email to custom receipient

Related questions

0 votes
1 answer

I think there is a bug in the member selection count in the web UI. When selecting a members in a group to do an export the count is 2x the actual selected users. In my ... select 5 members it would say 10, but I only am showing one user in the example.

asked May 15, 2015 by lasership (1.9k points)
0 votes
1 answer

Dear Support, we try to use a "Custom Business Unit" in a "Property Pattern" for excluding OUs, but it doesn't works. We created a Business Unit called "Service OUs ... Membership Rules is the following filter set: Do you know whats wrong in my Business Unit?

asked Jan 28, 2014 by Napoleon (4.9k points)
0 votes
0 answers

We have a large number of members that we would like to show as part of a Business Unit. I have looked in the config file and found a value that says 500, but wasn't able ... IIS Services to recall the web config and I get the same issue. Version: 3.7.13122.0

asked Jul 1, 2016 by charlesk (250 points)
0 votes
1 answer

Hi, When viewing a business unit in the web interface, in the title bar where the BU name is there is an Other Menu with the Add To Basket option in it. I thought this ... itself which I don't want users to do. Is there a way to remove this function? Thanks

asked Oct 29, 2014 by dazbo (2.6k points)
0 votes
1 answer

Hi, I need to delete a Business Unit. Is it correct that deleting a Business Unit will not delete anything from Active Directory?

asked Sep 6, 2011 by abdutal (880 points)
2,135 questions
1,900 answers
5,319 comments
3,534 users