Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/powershell/13.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Powershell 从查询访问两个属性_Powershell_Active Directory - Fatal编程技术网

Powershell 从查询访问两个属性

Powershell 从查询访问两个属性,powershell,active-directory,Powershell,Active Directory,我正试图: 查询从当前日期起90天内到期的帐户的AD 写入输出以包括到期日期和用户的电子邮件地址 问题: 我只知道如何提取一处财产。即,用户电子邮件地址的到期日期 这是我的Powershell脚本。先谢谢你 您需要运行get aduser-Properties*以同时拥有所有属性。之后就是脚本逻辑。复制粘贴代码,而不是在这里粘贴它的屏幕截图欢迎使用StackOverflow!请不要发布代码截图-而是将代码作为原始文本发布!如果您无法正确设置格式,只需将其粘贴在底部,我们将帮助您修复:-)

我正试图:

  • 查询从当前日期起90天内到期的帐户的AD
  • 写入输出以包括到期日期和用户的电子邮件地址
  • 问题: 我只知道如何提取一处财产。即,用户电子邮件地址的到期日期

    这是我的Powershell脚本。先谢谢你


    您需要运行
    get aduser-Properties*
    以同时拥有所有属性。之后就是脚本逻辑。

    复制粘贴代码,而不是在这里粘贴它的屏幕截图欢迎使用StackOverflow!请不要发布代码截图-而是将代码作为原始文本发布!如果您无法正确设置格式,只需将其粘贴在底部,我们将帮助您修复:-)