MSOnline不能在PowerShell的进口(连接-MsolService错误) [英] MSOnline can't be imported on PowerShell (Connect-MsolService error)

查看:547
本文介绍了MSOnline不能在PowerShell的进口(连接-MsolService错误)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有这个问题,couldn't找到任何答案。问题是,我试图用天青cdmlets通过C#code连接到O365,但我couldn't获得连接 - msolservice

  

当您尝试在Office 365运行管理的Windows PowerShell cmdlet这个词是不承认错误

解决方案

在搜索和尝试的小时里,我发现了一个X64服务器的MSOnline模块必须安装x64和一些程序需要运行它们使用在x86 PS版,所以他们永远也找不到它。

[解决] 我所做的,解决这个问题是:

复制名为文件夹 MSOnline MSOnline扩展从源头

  

C:\ WINDOWS \ SYSTEM32 \ WindowsPowerShell \ V1.0 \模块\   到文件夹

     

C:\ WINDOWS \ Syswow64资料\ WindowsPowerShell \ V1.0 \模块\

然后在PS运行导入模块MSOnline ,它会自动进入模块:D

I had this issue and couldn´t find any answer. The issue was that I was trying to use Azure cdmlets to connect to O365 via c# code, but I couldn´t get the connect-msolservice.

""The term is not recognized" error when you try to run administrative Windows PowerShell cmdlets in Office 365"

解决方案

After hours of searching and trying I found out that on a x64 server the MSOnline modules must be installed for x64, and some programs that need to run them are using the x86 PS version, so they will never find it.

[SOLUTION] What I did to solve the issue was:

Copy the folders called MSOnline and MSOnline Extended from the source

C:\Windows\System32\WindowsPowerShell\v1.0\Modules\ to the folder

C:\Windows\SysWOW64\WindowsPowerShell\v1.0\Modules\

And then in PS run the Import-Module MSOnline, and it will automatically get the module :D

这篇关于MSOnline不能在PowerShell的进口(连接-MsolService错误)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆