Hil

Forum Replies Created

Viewing 15 posts - 16 through 30 (of 46 total)
  • Author
    Posts
  • Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    Thanks Olaf.

    Your suggestion works great.

    Although I was hoping to get the “-Filter” to work as that would be a lot faster than doing it the other way around, especially since we have 50,000 users and they are in the Cloud. If you have any other ideas, please let me know

    Thanks

    Hil

     

    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    No worries. I figured it out.

    Get-Mailbox -ResultSize Unlimited | Get-MailboxStatistics | Where {(($_.TotalDeletedItemSize -split ” “)[0]) -gt 10}

     

    in reply to: Get mobile devices for cloud users #146814
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    No. When I have the command as “Select-Object -First 10” and the scripts returns 10 items it means the script is complete and should return to the prompt but it just sits there.

    Its just a single line of powershell code, so there should be no error in the line itself. Try it out. you will see what I mean.

    in reply to: Get OU of AD user #133736
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    Actually there is a comma in most names. I mentioned it in my earlier message too “Although I need to be able to keep that as a variable as some names contain comma and some do not”. Why would I want to reinvent the wheel if there was no comma?

    Anyway its all cool as I have it just the way I need it.

     

    in reply to: Get OU of AD user #133503
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    Thanks Luc, this one works great too !!!

    in reply to: Get OU of AD user #133497
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    Hi Logan, Thanks for your reply and the tip on calculated properties!!!!

    I see that the number of comas have been hardcoded to 1. Although I need to be able to keep that as a variable as some names contain comma and some do not.

    Hence I had  ($user.Name -split ‘,’).count instead of 1.

    This works great:

    in reply to: Start a process as a different user in a script #133484
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    You can try to call another powershell script from within your current script and wait for it to complete ( probably with a flag file)

    Here is a similar part of the script I wrote sometime back. The important ones are the Invoke command and the script block.

    in reply to: List emails in an Office 365 mailbox #104855
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    I was able to get autodiscover to work, but $inbox returns the Inbox of the admin account.
    How can i get it to return the Inbox of the mobileprint shared mailbox.
    Any ideas?

    in reply to: List emails in an Office 365 mailbox #104678
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    I am already an admin and have full rights to all user mailboxes.

    Any ideas on the correct syntax?

    in reply to: Speeding up a powershell script #103643
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    Hi Iain, I just tried the workflow script and it gives me the following error:
    Missing opening ‘(‘ after keyword ‘foreach’.
    Tried couple variations.. same thing

    in reply to: Speeding up a powershell script #103618
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    Thank you. That works Great !!!
    The For loop is down to 5 minutes.

    in reply to: Have $Alias in the display #103565
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    That works great. Thank you

    in reply to: Have $Alias in the display #103457
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    Joel, Thanks for the input.
    I was hoping for something along those lines, but just putting in the ALIAS at the end does not work.
    Its not part of the fields that can be selected.
    Try it in exchange and you will see what I mean.

    in reply to: Office 365 mail queue #101176
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor

    Fpoli, yes that is true.
    Although I was thinking along the lines like an HTTP request.
    Currently to see the pending queues it would be Security & Compliance — Mail flow — Message trace — Start a trace — Delivery status = pending.
    Can some type of call be based on this?
    Thanks

    in reply to: Powershell script for o365 Usuage report #100429
    Hil
    Participant
    Topics: 34
    Replies: 46
    Points: 265
    Rank: Contributor
Viewing 15 posts - 16 through 30 (of 46 total)