Connect-MicrosoftTeams not working

Anonymous
2019-09-21T21:59:22+00:00

Hi Team, Please advice am i doing something wrong

PS C:\WINDOWS\system32> find-Module -Name MicrosoftTeams

Version    Name                                Repository           Description

-------    ----                                ----------           -----------

1.0.2      MicrosoftTeams                      PSGallery            Teams Cmdlets module

Installed module using - install-Module -Name MicrosoftTeams.

Getting error when run     Connect-MicrosoftTeams

PS C:\WINDOWS\system32> Connect-MicrosoftTeams

Connect-MicrosoftTeams : The term 'Connect-MicrosoftTeams' is not recognized as the name of a cmdlet, function, script

file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct

and try again.

At line:1 char:1

  • Connect-MicrosoftTeams
  • 
    

    + CategoryInfo          : ObjectNotFound: (Connect-MicrosoftTeams:String) [], CommandNotFoundException

    + FullyQualifiedErrorId : CommandNotFoundException

Microsoft Teams | Microsoft Teams for business | Other

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

54 answers

Sort by: Most helpful
  1. Anonymous
    2019-09-29T21:14:27+00:00

    Dear Rick, dear Ashka123,

    I had the same issue. Relaxing the execution policy fixed the problem for me:

    Set-ExecutionPolicy -ExecutionPolicy RemoteSigned

    Maybe that also helps in your case.

    Best regards,

    Christian

    Was this answer helpful?

    40+ people found this answer helpful.
    0 comments No comments
  2. Anonymous
    2021-03-30T20:27:39+00:00

    It worked for me like this:

    1. Install module in Administrator's powershell

    2. Then run powershell as user

    PS C:\Users\t> Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope Process

    Execution Policy Change

    The execution policy helps protect you from scripts that you do not trust. Changing the execution policy might expose

    you to the security risks described in the about_Execution_Policies help topic at

    https:/go.microsoft.com/fwlink/?LinkID=135170. Do you want to change the execution policy?

    [Y] Yes  [A] Yes to All  [N] No  [L] No to All  [S] Suspend  [?] Help (default is "N"): y

    PS C:\Users\t> Import-Module MicrosoftTeams

    PS C:\Users\t> Connect-MicrosoftTeams

    (asks for credentials)

    Account                       Environment Tenant                               TenantId

    -------                       ----------- ------                               --------

    Was this answer helpful?

    10+ people found this answer helpful.
    0 comments No comments
  3. Anonymous
    2019-12-24T17:49:26+00:00

    Ashka123,

    Same problem, I had to install an earlier version and my problem was resolved. Hope it works for you.

    ( Install-Module -Name MicrosoftTeams -RequiredVersion 1.0.0 )

    Was this answer helpful?

    10+ people found this answer helpful.
    0 comments No comments
  4. Anonymous
    2019-09-22T00:40:52+00:00

    Hello Ashka123,

    Thanks for your post in the forum. According to the error message, it seems that MicrosoftTeams PowerShell module wasn’t installed.

    First, please run the following command to confirm whether you have installed Teams PowerShell module successfully: Get-Module -ListAvailable -Name MicrosoftTeams. If it is installed successfully, you will see the results like below:

     

    If you cannot see the result, it means that the PowerShell module wasn’t installed correctly. Go to this link to download and install the module manually: https://www.powershellgallery.com/packages/MicrosoftTeams/1.0.2

    Please feel free to post back if you have any update on it.

    Regards,

    Rick

    Was this answer helpful?

    10 people found this answer helpful.
    0 comments No comments
  5. Anonymous
    2020-03-15T09:56:41+00:00

    Thanks for sharing.

    How do i install an earlier version? do i have to uninstall my current version?

    Yes, you first uninstall the newer or current  version with :

    Uninstall-Module MicrosoftTeams

    then you install the version you want / need :

    Install-Module -Name MicrosoftTeams -RequiredVersion 1.0.0

    Was this answer helpful?

    8 people found this answer helpful.
    0 comments No comments