2,300 questions with PowerShell-related tags

Sort by: Updated
2 answers

How can I send a message to microsoft teams channel with powershell, without using a webook?

Webhooks do not seem to work with our teams instance no matter what permissions we try: Therefore, I am wanting to do this via powershell. I have created an app registration in the azure tenant, and given it the following permissions: This is my current…

Microsoft Teams
Microsoft Teams
A Microsoft customizable chat-based workspace.
9,567 questions
Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
11,348 questions
Microsoft Teams Development
Microsoft Teams Development
Microsoft Teams: A Microsoft customizable chat-based workspace.Development: The process of researching, productizing, and refining new or existing technologies.
3,043 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2023-07-03T23:00:20.8733333+00:00
Aaron Dalla-Longa 0 Reputation points
commented 2024-07-17T21:34:10.45+00:00
Yousef Imran 0 Reputation points
0 answers

Invoke-PnPTenantTemplate is not performing any action.. "Access token acquired"

I have 2 SharePoint Online tenants which both have a modern communication sites. now i used this command to get the source site template:- PS C:\Users\mohan> Connect-PnPOnline -Url "https://ssms.sharepoint.com/sites/PPM-test/"…

SharePoint
SharePoint
A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.
10,242 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,451 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-17T18:01:50.68+00:00
john john Pter 115 Reputation points
commented 2024-07-17T18:37:45.8366667+00:00
Rich Matheisen 45,671 Reputation points
1 answer

Set -RemotePowerShellEnabled on Multiple Accounts with Duplicate Display Names

Hey team, I've been racking my brain for the last hour and I think I just need a fresh perspective. In short - The following command would disable remote PowerShell for all users within the tenant: Get-User | Set-User -RemotePowerShellEnabled…

Microsoft 365
Microsoft 365
Formerly Office 365, is a line of subscription services offered by Microsoft which adds to and includes the Microsoft Office product line.
4,305 questions
Microsoft Exchange Online
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-17T17:14:40.9666667+00:00
Championface 0 Reputation points
answered 2024-07-17T18:27:04.4266667+00:00
Vasil Michev 99,941 Reputation points MVP
0 answers

Invoke-PnPTenantTemplate is not performing any action, and ends after 2 seconds.. Access token acquired

I have 2 SharePoint Online tenants which both have a modern communication sites. now i used this command to get the source site template:- PS C:\Users\mohan> Connect-PnPOnline -Url "https://ssms.sharepoint.com/sites/PPM-test/"…

SharePoint
SharePoint
A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.
10,242 questions
SharePoint Development
SharePoint Development
SharePoint: A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.Development: The process of researching, productizing, and refining new or existing technologies.
2,796 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-17T17:58:40.58+00:00
john john Pter 115 Reputation points
2 answers One of the answers was accepted by the question author.

Runtime Exception When Using Set-OrganizationConfig

Trying to run Set-OrganizationConfig cmdlet in powershell EXO V3 module returns runtime exception: "unable to find type [uint]". Has anyone had this error before and know of a potential solution? I cannot find anything online to reference…

Microsoft Exchange Online Management
Microsoft Exchange Online Management
Microsoft Exchange Online: A Microsoft email and calendaring hosted service.Management: The act or process of organizing, handling, directing or controlling something.
4,368 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-17T11:36:20.5+00:00
Rhys Pickett 0 Reputation points
answered 2024-07-17T15:35:03.1433333+00:00
Rich Matheisen 45,671 Reputation points
1 answer One of the answers was accepted by the question author.

How to Get-ItemProperty for registry items on remote servers

I am attempting to pull SQL server instance details for a multitude of SQL servers, but am not able to get it working. Seems to come down to how parameter 'Path' gets it's value from my $path variable.: #Set server list manually with array $serverList =…

PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-16T15:29:27.31+00:00
Lindberg, Andrew 20 Reputation points
commented 2024-07-17T15:08:40.7233333+00:00
Rich Matheisen 45,671 Reputation points
0 answers

Invalid input error when configuring exclusions for MARS agent backup schedules via PowerShell

MARS agent version: 2.0.9266.0 Operating Systems: Server 2022, 2019, Windows 11 Azure Powershell versions 10.4.1.37722 x64 as well as 12.1.0.38758 x64 We need to deploy the MARS agent and configure backup schedules via powershell to many devices. The…

Azure Backup
Azure Backup
An Azure backup service that provides built-in management at scale.
1,186 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-17T03:32:28.3+00:00
Joel Stockley 5 Reputation points
commented 2024-07-17T14:57:55.55+00:00
SadiqhAhmed-MSFT 41,066 Reputation points Microsoft Employee
1 answer One of the answers was accepted by the question author.

Get-Service blocked by firewall

Hi, I have 2 virtual machines named AAA and BBB. I tried running the following command from the BBB machine and it didn't work: Get-Service -ComputerName AAA | Where-Object {($_.starttype -like "*auto*") -and ($_.Status -eq…

Windows Server 2019
Windows Server 2019
A Microsoft server operating system that supports enterprise-level management updated to data storage.
3,595 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-16T09:35:04.2+00:00
SC 166 Reputation points
accepted 2024-07-17T14:38:59.8366667+00:00
SC 166 Reputation points
3 answers

Wie behebe ich Code 0x8031005a?

Ich habe die Win 11 23H2-Version . Ein Geräteschlüssel ist nicht hinterlegt. Beim Versuch einen solchen selbst zu generieren, wird mir die Meldung angezeigt, daß die PowerShell -Version nicht aktuell ist. Ein Versuch mit folgender Eingabe schlägt…

Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
8,904 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-14T14:44:58.38+00:00
Dr. Detlef Briese 0 Reputation points
answered 2024-07-17T07:11:44.53+00:00
Dr. Detlef Briese 0 Reputation points
0 answers

Automation runbook for start/stop VM using Storage account blob

Hi, I am trying to deploy a powershell runbook in automation account which should read contents of CSV stored in storage account blob using system assigned managed identity of automation account. Looking for a piece of code as I don't want to use sas…

Azure Storage Accounts
Azure Storage Accounts
Globally unique resources that provide access to data management services and serve as the parent namespace for the services.
2,906 questions
Azure Automation
Azure Automation
An Azure service that is used to automate, configure, and install updates across hybrid environments.
1,187 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-17T06:57:19.4766667+00:00
WinTechie 286 Reputation points
1 answer One of the answers was accepted by the question author.

Find all expired sharing links in SharePoint using PowerShell

How can I use PowerShell to find all expired anonymously shared links in SharePoint? I found this script (shared (1).txt) in this thread and modified it to (File.txt). However, it only fetches links with the access type of "can view and can…

SharePoint
SharePoint
A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.
10,242 questions
SharePoint Development
SharePoint Development
SharePoint: A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.Development: The process of researching, productizing, and refining new or existing technologies.
2,796 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-16T12:31:42.8066667+00:00
Roy_Jaze 20 Reputation points
accepted 2024-07-17T02:46:39.78+00:00
Roy_Jaze 20 Reputation points
2 answers One of the answers was accepted by the question author.

I want to send en email and have that converted into news post in Sharepoint

Please help with this relatively simple ask (I think) which there are few recent answers on the MS community. I would like to Send an email from outlook to a certain email address with a subject and body I want that email to go to Sharepoint and be…

Outlook
Outlook
A family of Microsoft email and calendar products.
3,396 questions
SharePoint
SharePoint
A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.
10,242 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-11T00:29:59.7166667+00:00
kman202020 20 Reputation points
answered 2024-07-16T17:42:07.0033333+00:00
kman202020 20 Reputation points
1 answer

How to deploy KIR through script

Team, We have over 1000 assets managed by a third party RMM tool. The document here describes how to configure local groups manually through the GUI. Since we don't have GPO or Intune, we need a way to do this through CLI or a script. Please help us…

Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
8,904 questions
Microsoft Intune Grouping
Microsoft Intune Grouping
Microsoft Intune: A Microsoft cloud-based management solution that offers mobile device management, mobile application management, and PC management capabilities.Grouping: The arrangement or formation of people or things in a group or groups.
48 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-15T14:11:14.04+00:00
Kishor Kumar 10 Reputation points
edited a comment 2024-07-16T15:22:29.8233333+00:00
MotoX80 32,726 Reputation points
1 answer

How to expand PowerShell MS Graph Microsoft.Graph.PowerShell.Models.MicrosoftGraphDirectoryObject Microsoft.Graph.PowerShell.Models.MicrosoftGraphVerifiedPublisher?

Using PowerShell for Microsoft Graphs, how can I expand or convert the below attributes or columns? CreatedOnBehalfOf : Microsoft.Graph.PowerShell.Models.MicrosoftGraphDirectoryObject VerifiedPublisher :…

Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
11,348 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
Microsoft Entra
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
20,493 questions
asked 2024-06-19T11:15:12.33+00:00
EnterpriseArchitect 5,116 Reputation points
answered 2024-07-16T15:17:37.7833333+00:00
Carolyne-3676 201 Reputation points
0 answers

Real "files on demand". Automatically uploading cached OneDrive user files?

Hello, I recently came across a seemingly simple task, but in fact I have been unable to get OneDrive to do what I want it to do for two weeks now. I'll try to describe it briefly. The problem is that when a Windows user restarts or logs off their…

OneDrive
OneDrive
A Microsoft file hosting and synchronization service.
957 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
8,904 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-16T15:13:32.9266667+00:00
Станістав Ільїн 0 Reputation points
5 answers

PowerShell command outputting 'System.__ComObject' on Windows 11 23H2

I am working on a Windows 11 23H2 system and attempting to retrieve installed update details using the PowerShell command below, but it's giving me an output of System.__ComObject: $UpdateSession = New-Object -ComObject…

PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-02T12:00:45.7933333+00:00
VM 61 Reputation points
commented 2024-07-16T14:48:09.4766667+00:00
Kishor Kumar 10 Reputation points
3 answers

Windows update agent api - Access denied on AddScanPackageService

Hi Together Could someone help me in this matter... I am trying to run following script block on remote system to get updates needed and getting access denied on following line: " $UpdateServiceManager.AddScanPackageService("Offline Sync…

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,451 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2023-03-14T12:14:37.4066667+00:00
Zeljko Zaric 1 Reputation point
answered 2024-07-16T13:44:16.7066667+00:00
Jesper Arnecke 0 Reputation points
2 answers

Getting error in azure devops release

Below is the error: Error: The term 'Update-AzVmssInstances' is not recognized as a name of a cmdlet, function, script file, or executable program throws in Azure powershell of Azure devops pipeline. How can I solve this issue

PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-12T17:18:41.65+00:00
Anonymous
answered 2024-07-16T06:35:20.2866667+00:00
Yanhong Liu 4,815 Reputation points Microsoft Vendor
1 answer

Azue runbook - Exchange PowerShell

We are trying to automate mail flow reporting via Azure runbooks using an app registration (service principal) to authenticate. The runbook will query Exhchange Online powershell modules for mailflow data. The only Entra permissions that seem to allow…

Microsoft Exchange Online
Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
11,348 questions
Azure Automation
Azure Automation
An Azure service that is used to automate, configure, and install updates across hybrid environments.
1,187 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-12T14:18:19.4366667+00:00
Daniel Birrell 41 Reputation points
commented 2024-07-16T05:30:50.15+00:00
Noah Ma-MSFT 2,340 Reputation points Microsoft Vendor
0 answers

How can I use Microsoft Graph (+PowerShell) to copy one user's calendar to a 365 Group calendar?

Hello, I am trying to copy events from one former employee's shared calendar to a 365 Group. I posted in the community earlier today and was directed here for further assistance. The situation: Employee 1 was part of Department A and had a created a…

Microsoft 365
Microsoft 365
Formerly Office 365, is a line of subscription services offered by Microsoft which adds to and includes the Microsoft Office product line.
4,305 questions
Outlook
Outlook
A family of Microsoft email and calendar products.
3,396 questions
Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
11,348 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,300 questions
asked 2024-07-15T21:32:49.4366667+00:00
Darron 0 Reputation points