Solved

How to find users already enabled in Lync 2013 Server using CSV or Text file?

Posted on 2014-11-18
6
1,224 Views
Last Modified: 2014-11-22
I have a CSV or Text file containing usernames. I need to use it in a PS script to see if they are already enabled in Lync Server.

Thank you,
0
Comment
Question by:kt KTAdmin
  • 3
  • 2
6 Comments
 
LVL 5

Expert Comment

by:Mai Ali (MVP)
Comment Utility
using the Lync management shell type this command:
get-csuser | Select-Object DisplayName, SAMAccountname, SIPAddress >e:\user.csv
user file will be filled with the lync enabled user.
Also you can check below command
http://www.techysnippets.com/export-lync-user-info-to-csv/
0
 

Author Comment

by:kt KTAdmin
Comment Utility
Actually, what I'm looking for is to take a list of users from a text or CSV and use it as a filter to see if they are enabled in Lync.  Your script simply shows how to export a list of users into a CSV file.
0
 

Author Comment

by:kt KTAdmin
Comment Utility
How can I use filter below to find users in a text file to see if they are enabled on Lync or not?

Get-CsAdUser –Filter {CsEnabled –eq $False}
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 5

Expert Comment

by:Mai Ali (MVP)
Comment Utility
The above command will list to you all enable users if you want to run command from Lync Server.
To filter which is enable or not. That based on AD by checking sip address who have sip address is enable.
Also you can run below script
http://blogs.technet.com/b/meacoex/archive/2011/04/24/powershell-script-get-group-members-and-check-for-users-that-are-not-enabled-for-lync-and-enable-these-users-using-e-mail-address.aspx
0
 
LVL 40

Accepted Solution

by:
Subsun earned 500 total points
Comment Utility
So if you are trying to verify the user accounts from a list then the following code will help you..
Import-Module lync
GC C:\user.txt | %{
Try{Get-CsUser $_ -ea stop | Out-Null;$Status = "Enabled"}Catch{$Status = "Disabled"}
$_ | Select @{N="User";E={$_}},@{N="Lync";E={$Status}}
} 

Open in new window

C:\user.txt Input file should be like.
UserA
UserB
UserC

Open in new window

You can also use Export-csv to export the result to a csv file..
0
 

Author Closing Comment

by:kt KTAdmin
Comment Utility
This script was very helpful.

Thank you!
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

Suggested Solutions

Are you one of those front-line IT Service Desk staff fielding calls, replying to emails, all-the-while working to resolve end-user technological nightmares? I am! That's why I have put together this brief overview of tools and techniques I use in o…
Microsoft Windows Server Update Service (WSUS) is free for everyone, but it lacks of some desirable features like send an e-mail to the administrator with the status of all computers on the WSUS server. This article is based on my PowerShell script …
The goal of the tutorial is to teach the user how to instant message and make a video call in Skype.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now