Lync Tip: List Lync users with LineURI’s to CSV

Using the Get-CsUser cmdlet you can get information about Lync users in your organization.

The below powershell command exports Lync users, sip address, Enterprise Voice Enabled and Line URI to a CSV file.

 

Author: Chris Hayward

Share This Post On

3 Comments

  1. Tnx a lot!
    Just thinking about that and see your post.

    Post a Reply
  2. Hi! This will populate the CSV with LineURI value in tel:+11234567890;ext=7890 format. What if I wanted to format the value for LineURI in (123) 456-7890 format?

    Post a Reply
    • Hi Shah,

      You could probably do this in PowerShell, but the easiest way is probably just to add another column in the Excel sheet with the following formula (assuming all of your LineURI’s are in this format):

      =CONCATENATE(“(“,MID(D1,7,3),”)”,” “,MID(D1,10,3),”-“,MID(D1,13,4))

      This formula basically:

      Starts with a “(”
      Adds characters 7,8 and 9 (from the LineURI column, D)
      Adds a “)”
      Adds a space ” ”
      Adds characters 10,11,12
      Adds a “-”
      Adds characters 13,14,15 and 16

      Just tested and this formats “tel:+11234567890;ext=7890” in to “(123) 456-7890”

      Regards

      Post a Reply

Submit a Comment

Your email address will not be published. Required fields are marked *