Find out from the machine name, what user is logged in

thank you. Is there a way to find out from the machine name, what user is logged in or who the machine belongs to?
I can actually find out from the username what machine they have because there is a field called the wWWHomePage that gets populated with the computer name
how do I do that? 
Also I have a list of email addresses. How do I find the username from the list of email addresses ?
thanks

I have no good way to test this, so you'll probably have to adjust this on your end:
Get-Content .\users.txt | ForEach {
$emailAddr = $_
$props = @{
EmailAddress = $emailAddr
Username = ''
ComputerName = ''
ComputerPath = ''
try {
$userDetails = Get-ADUser -Filter "EmailAddress -eq '$emailAddr'" -Properties wWWHomePage -ErrorAction Stop
$pcDetails = Get-ADComputer -Identity $userDetails.wWWHomePage -Properties CanonicalName -ErrorAction Stop
$props.Username = $userDetails.SamAccountName
$props.ComputerName = $userDetails.wWWHomePage
$props.ComputerPath = $pcDetails.CanonicalName
} catch {
$props.Username = 'ERROR'
$props.ComputerName = 'ERROR'
$props.ComputerPath = 'ERROR'
New-Object PsObject -Property $props
} | Select EmailAddress,Username,ComputerName,ComputerPath
Don't retire TechNet! -
(Don't give up yet - 12,950+ strong and growing)

Similar Messages

  • How can i find out all the different meanings of  User ID Paramtrs (USR05)?

    Dear Gurus
    How can i find out all the different meanings of  User ID Parameters (table USR05)?
    Thanks
    Nuno Natividade

    hi,
       the values are stored in the table tpara and they are used to put the landscape of the system,and to know the log of the system.
      FORM DETERMINE_LANDSCAPE .
        SELECT SINGLE * FROM USR05
                        WHERE BNAME = SY-UNAME
                            AND PARID = 'ZLANDSCAPE'.
        IF SY-SUBRC = 0.
          IF NOT USR05-PARVA IS INITIAL.
       REPLACE
          ELSE.
            PERFORM DETERMINE_FROM_CENTRAL_SYSTEM.
          ENDIF.
        ELSE.
          PERFORM DETERMINE_FROM_CENTRAL_SYSTEM.
        ENDIF.
      ENDFORM.                    " determine_landscape
      FORM DETERMINE_LOG_PARAMETER.
        SELECT SINGLE * FROM USR05 WHERE BNAME = SY-UNAME
                            AND PARID = 'ZLOG_USER'
                            AND PARVA = 'X'.
        IF SY-SUBRC = 0.
          WITH_LOG = 'X'.
        ENDIF.
    <REMOVED BY MODERATOR>
    venkat.
    Edited by: Alvaro Tejada Galindo on Mar 4, 2008 12:47 PM

  • How I can find out all menu item name at runtime from forms 9i ?

    Hellow all
    we can find out all the block name and item name in forms at runtime.
    but
    can I find out all the menu item at runtime without knowing the name of menu item.
    I want disable some menu item at runtime.
    From
    Chirag Patel

    Hi Frank
    I hope the solution from u
    please.......
    are u got my problem ?
    from
    Chirag Patel

  • Can I enable the root user account from the log in screen when I am locked out of the machine?

    Hello everyone,
    I am working on my friends mac to get it ready to sell. I went into the advanced options of the user and changed the name of the account. That's all I changed. I did read the warning that said if anything was changed it could cause damage, that's why I only changed the name of the user account. I didn't want to mess with anything else. Well, needless to say, I am locked out of the machine. Apparently the root user, system administrator, account was not enabled and I am stuck at the screen that I can get to with my installation disc. So how can I enable the root user account and get back onto the machine from the screen I am at? Can I enable the root user from terminal? I spent a good 8 hours yesterday researching this topic and have come up empty. Changing passwords from commands in terminal is not the problem. I am given just one account to choose from to log on and it's not accepting the password because of the changes I made in the advanced options menu.
    Is there any hope of getting this thing going again? Or have I just screwed myself over?
    Thanks for your help!
    Leah

    You can reset the password.
    http://pondini.org/OSX/Password.html
    Do you need to recover data from it before you sell it?  If not you can just wipe the disk and prepare it for sale.
    See  > Apple What to do before selling or giving away your Mac
    http://support.apple.com/kb/HT5189?viewlocale=en_US&locale=en_US
    Also See Thomas Reed's How to Prepare your Mac for sale
    http://www.thesafemac.com/how-to-prepare-your-mac-for-sale/
    and this thread
    https://discussions.apple.com/thread/5474062?tstart=0

  • How to find the machine name

    How to find the machine name from which the table is created ?
    Yogesh

    Turn on DDL auditing.
    http://www.oracle-base.com/articles/10g/Auditing_10gR2.php outlines some uses ... i'm sure you can find more with a google search.

  • Is there a way to find out if the projector is used from cd or dvd?

    I have a projector which includes options for user to permanently edit some texts. These functions will not work if the projector is used from cd or dvd, because texts can't be saved. Is there a way I could find out if the presentation is used from cd or dvd, so I could hide the editing features and show them only when the projector is used from a hard drive or usb memory stick.

    code would like something like this*:
    driveLetter = the first char of the moviePath
    driveType = baDiskInfo(driveLetter, "type")
    if  driveType = "CD-ROM" or driveType = "DVD-ROM" then
    -- do your stuff here
    end if
    *modify to fit your project
    You could also use FileXtra's fxObj.fx_VolumeIsCDROM() too:
    driveLetter = the first char of the moviePath
    fxObj = xtra("FileXtra4").new()
    isCDDrive = fxObj.fx_VolumeIsCDROM(driveLetter)
    fxObj = 0
    if  isCDDrive then
    -- do your stuff here
    end if

  • Where can i find out all the standared table name

    Dear Friend,
    could you please tell me where can i find out all the standard table names,
    ( for example: tstc for find all the T-codes) .

    HI Srinivas,
      DD02L has the name of all the TABLES in the SYSTEM. It has both SAP and Customer's TABLES.
      First of all exclude all Z* and Y* tables from dd02L. Still there are many tables in CUSTOMER NAMSPACE.
      So make a program, LOOP at all entries of DD02L and then check the name space of each entry using the function module:-
    <b>TRINT_OBJECT_NAMESPACE_INFO</b>.
    If the namspace is not EQUAL to 'S', then dont count that entry else add one to the counter.
      This would tell you all SAP Standard Tables in the system.
    Thanks and regards,
    RAVI :).
    NOTE: Points keep me alive on SDN .

  • What is ilife ?? is it comes with macbook pro 13in ?? how to find out in the system

    what is ilife ?? is it comes with macbook pro 13in ?? how to find out in the system?? I am using OSX 10.8.5

    These are the iLife applications:
    http://www.apple.com/ilife/
    They come with every new Mac.  If they are not in your applications folder, download them from the App store.
    Ciao.

  • I activated an iTunes gift card, my iPod showed the amount available ($15) and after downloading 2 songs all I had left was $.04.  Any ideas on what happened to my funds or how I can find out where the rest of the money went?

    I activated an iTunes gift card, my iPod showed the amount available ($15) then after downloading 2 songs my balance was $.04.  Any ideas on what happened to the rest of my funds or how I can find out where the rest of my money went?

    - Have youwent to yur iTunes account looked at your puchase history for purchases thant y might have forgotton?
    - Maybe you had an unpaid balance before redeeming the card.
    - Contact iTunes
    Apple - Support - iTunes - Contact Us

  • How to find out whether the system user is a vendor or a purchaser

    Hi,
    I am working in SRM 5.0. I have a requirement that some fields of Bid invitation can be visible by purchaser but not to bidder.
    How to find out whether the system user (user id though which system logged in) is a vendor or a purchaser. Kindly help me to resolve this issue.
    Sushmita Singh

    check his role.
    is surrogate bidding available for that bidder.
    via surrogate bid , purchaser can submit bid on behalf of the bidder.
    masa is correct
    pposa_bbp - search via user . so he might be  a purchaser.
    maintain business partner -supply your bidder bp number -edit
    go to bidder data .Under bidder data you must flag "PERMIT PROXY BIDDING"
    regards
    Muthu
    br
    muthu

  • I have iTunes installed on a laptop that I use for work, but it's owned by my employer.  A new policy my have them deleting iTunes from the machine.  If that happens, will I lose all my music?  I am an iCloud user and pay for iTunes match.

    I have iTunes installed on a laptop that I use for work, but it's owned by my employer.  A new policy my have them deleting iTunes from the machine. If that happens, will I lose all my music?  I am an iCloud user and pay for iTunes match.

    If they just delete iTunes, the music files should still be there. I suggest making a backup of them though. Locate your iTunes folder (The one that contains your library file) and just copy the whole thing to your Documents folder or wherever you like (Just not in the same directory of the original folder otherwise the computer will get confused and could confuse your iTunes library). Then you will have a backup of all your music, plus if you purchased it from iTunes, you will still have it linked to your Apple ID so you can re-download them to any computer with iTunes on it when you feel like it.

  • Table Name or Function Module to find out all the Screens & Subscreens for

    Hello Experts,
          Table Name or Function Module to find out all the Screens & Subscreens for all T-Codes
    Helpful Answer will b rewarded
    Arif Shaik

    Hi Balaji,
       But TSTC only Gives the Program Name , T-Code and Screen but not all the Subscreen details
    Any other which U know

  • I deleted photos cause the capacity is so big but i backup first on itunes then when i was to restore some of those i cannot find photos from the last backup that i 've done. What to do?

    I deleted photos cause the capacity is so big but i backup first on itunes then when i was to restore some of those i cannot find photos from the last backup that i 've done. What to do?

    As far as i know, you can use a third party iPad photos recovery software to have a try. If i remember correctly, this software has two methods to restore your photos. One is recovering from your iTunes backup, another is recovering from your iPad directly.
    http://easy-iphone-recovery.blogspot.com/iphone-recovery-resource.html
    It is worth to try if your photos are important.

  • HT4623 I appear to have lost the £15 redeemed voucher credit from my iphone.How do i find out where the money has gone to,Thanks

    I was bought a voucher for Xmas.I redeemed it and the balance showed as £15.A few weeks later the balance is at 0.03p and i have not bought anything.How do i find out where the money has gone to.
    Thanks

    Login to iTunes on your computer: Store>View My Apple ID>Purchase History.

  • How do I find out if the pressed key is printable?

    I have made a game and now I'm working on a hiscore table for it. But with my function the program doesn't know if the pressed key is printable or if it's shift, ctrl or something like that. And I made it possible to enter maximum 40 letters as name, so if the user holds the shift key for a while then the whole String is filled with shift characters and nothing shows on the screen and he/she isn't able to type in any more letters... So is there any way to find out if the pressed key contains a printable char?
    This is what my function looks like now. My program is quite big so I just post the function and try to explain what is happening
    /* high is an array of
    int score;
    String name;
    boolean WritingName;
    boolean GAMEOVER;
    boolean newgame;
    public void keyPressed(KeyEvent e) {
         if (GAMEOVER){  // checks if the game has ended
             char button = e.getKeyChar();
             int keyCode = e.getKeyCode();
             if (newgame){  // this is false if the hi-score list is showing otherwise its true. i.e. its true when typing name for hiscore list
                   if (keyCode == 10) {       // check if the pressed key is enter
                        WritingName = false;  // Tells an other function that the user has finished typing his/her name so it can save it and start showing the hiscore-list on the screen
                   } else {
                        if (keyCode == 8){    // check if the pressed key is backspace and if so removes the last char from the string
                             if (high[99].name.length() > 0){
                                  high[99].name=high[99].name.substring(0,high[99].name.length()-1); 
                        } else {  // if any other key is pressed then add it to the end of the string
                             if (high[99].name.length() <= 40 ) high[99].name += button;
                   paint(getGraphics());
              } else {  // checks if space is pressed to stop showing the hiscore-list and start a new game
                   if (keyCode == 32) newgame = true;
    }

    But with my function the program doesn't know if the pressed key is printable or if it's shift, ctrl
    or something like thatProbably the easiest way is to check and see if e.getKeyChar() < a space character or if e.getKeyCode() >= 127. You can use e.getModifiers() to get the modifier, etc... -- take a look at the documentation for java.awt.event.KeyEvent class.
    V.V.

Maybe you are looking for

  • Hyperion Shared Services Question

    Hi, I need to see the filters that have been assigned to a particular group in HSS. We have a folder called projects in the tree where the analytic server is added, but when I go to the corresponding application under that analytic server to check, t

  • CD Expiry Software for Mac

    We are developing a training application which runs off a CD-Rom. The application is being developed using Flash to be compatible with both Windows and OSX. The clients would like expiry software added to the CD so that it does not allow the user to

  • After Effects download error

    I am trying to download the after effects trial and I keep getting an error code 107. I have tried all of the toubleshooting solutions but I still get the error. I am able to download all of the other trial except after effects. I am using a window c

  • Photoshop Elements 3.0: Vorgabeotionen ändern

    Hallo! Ich bin begeisterter Photoshopbenutzer doch würde mich interessieren ob es denn möglich ist die Vorgabeoptionen beim Freistellen zu ändern. Freistellungsoptionen mit 5 x 3 Zoll oder so sind nämlich nicht sehr hilfreich. Grüße aus Wien Christia

  • I am unable to connect my iPhone5 to macbook Pro running on Version 10.6.8. Help please?

    I am unable to connect my iPhone5 to macbook Pro running on Version 10.6.8. Help please?