make an existing script read from a csv file

Posted on 2011-10-24
Last Modified: 2012-05-12
Hi I have a snippet of power shell code to change the max send email size
SET-Mailbox –Identity Janas –MaxSendSize 1038400
i need the users to be read from a csv file instead any help much appreciated
Question by:davidm27
    LVL 14

    Accepted Solution

    Try this.. Create a CSV file named users.csv

    $list = Import-Csv "users.csv"

    foreach($samaccountname in $list)
    SET-Mailbox –Identity $samaccountname –MaxSendSize 1038400


    Author Closing Comment


    Featured Post

    Looking for New Ways to Advertise?

    Engage with tech pros in our community with native advertising, as a Vendor Expert, and more.

    Join & Write a Comment

    Use email signature images to promote corporate certifications and industry awards.
    Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
    In this video we show how to create a Shared Mailbox in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Recipients >> Sha…
    In this Micro Video tutorial you will learn the basics about Database Availability Groups and How to configure one using a live Exchange Server Environment. The video tutorial explains the basics of the Exchange server Database Availability grou…

    746 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

    18 Experts available now in Live!

    Get 1:1 Help Now