Windows PowerShell is Microsoft's task automation framework, consisting of a command-line shell and associated scripting language built on top of, and integrated with the .NET Framework. PowerShell provides full access to COM and WMI, enabling administrators to perform administrative tasks on both ...

learn more… | top users | synonyms

1
vote
2answers
30 views

PowerShell script to create hundreds of sub sites

What's the best way to create hundreds of sub sites in a site collection for testing purposes? It doesn't matter what their names are. Doing some research, I found a few scripts that either require ...
0
votes
1answer
12 views

Uploading Files to Sharepoint Document Library and Updateing Column Fields Using Powershell

I'm a new learner to Powershell and a bit new to SharePoint as well. I'm learning powershell to create a script that uploads files to a sub-site library inside SharePoint. I managed to get it working ...
1
vote
0answers
13 views

Get master page object in Powershell / Update master page containts using Powershell

I have to create one Powershell script. This will iterate though all the sites/subsites in one site collection and access master page used by the site. Once i get it, i have to update that master page ...
0
votes
0answers
15 views

Creating SPNavigationNodes via PowerShell

Unfortunately I don't have my screenshots since they are at work so I'll try to explain this as best as possible. On a site collection's top level site at work, I would like to have the top navigation ...
0
votes
2answers
26 views

Programatically sort choices in a list field

I'm updating choices in a list field and want them to be stored alphabetically, however when I try to sort the choices I get the following error: $web = Get-SPWeb "mysite" $list = ...
0
votes
1answer
20 views

Powershell to delete all items from a list based on created date

I have this powershell script to delete all items from a list: $siteURL = "URL" $site = new-object Microsoft.SharePoint.SPSite ( $siteURL ) $web = $site.OpenWeb() $oList = $web.Lists["ListName"]; ...
0
votes
2answers
16 views

After deleting all nodes, QuickLaunch throws “You cannot call a method on a null-valued expression”

If QuickLaunch has nodes, the following causes the error "You cannot call a method on a null valued expression". If not, it carries on as normal. $nodes = $subWeb.Navigation.QuickLaunch write-host ...
0
votes
1answer
16 views

Using PowerShell variables in CAML Queries?

I'm trying to reconfigure scripts I made to move list items from one list to another. At the time the list were not going to change so all the variables were hard coded. Is it possible to use a ...
1
vote
0answers
19 views

Create Result Source Using Powershell

I want to set Type="People Search Results" and in Credential Information want to set default authentication using power shell. I have used below code to create result source but I am not able to set ...
0
votes
1answer
16 views

Clone site collection vs web templates provisioning (team site)

What's the drawback of cloning existing team sites? Fist I created team sites based on web templates, but after a while with tons of changes from the client I'm thinking of just cloning a "team ...
0
votes
0answers
15 views

Powershell Automation of Workflow Visio Exports

In Sharepoint 2013 I'm working on a solution for automated backups at the list level (as opposed to full site backups). Thus far it's a two part solution involving powershell commands that would run ...
0
votes
2answers
15 views

Powershell - creating document libraries and wish to add an existing group

I have a powershell script I developed in order to create document libraries across multiple sites under a single site collection. I wish to now add the appropriate Site Administrators with ...
0
votes
1answer
23 views

powershell - get permissions for users

I have a csv file with users (domain\user) that I need to find their access. I found a good link here (Powershell script to find permissions for a specific user) on SP Forum. I am calling the function ...
0
votes
0answers
6 views

Powershell how to set a List field by Display User, or set by

I don't have a User Login Name. I have got a Display User Name. With this form - "User Surname User Name", If i have do it by workflow its works, but after 180 elements workflow crashed me. How could ...
0
votes
0answers
8 views

Powershell User set in Sharepoint

When I migrate to a list I must update the sharepoint User Group Field. How Could I update it ? Can I set by "Surname Name" User ?
0
votes
2answers
23 views

Copy-SPSite not recognised?

I am trying to copy a site with power shell using SP2010 Enterprise and the SharePoint management shell but the cmdlet does not recognize the Copy-SPSite term!? It is not permissions as I am admin ...
0
votes
1answer
20 views

Reactivating feature with powershell - disable enable feature if it's active

$snapin = Get-PSSnapin | Where-Object { $_.Name -eq "Microsoft.SharePoint.Powershell" } #This script enables a feature on every site collection on a given web app if ($snapin -eq $null) { ...
0
votes
1answer
16 views

Import list from powershell to money field

If I tried to import from powershell to sharepoint field it adds me two 00 to the values. How to import a fields in this sequention 000,00 I have got a MS SQL view with this form 000,00 but when I ...
0
votes
0answers
14 views

The job 'GUID' is already running and cannot be canceled- PowerShell

A deployment or retraction is already under way for the solution "xxx.wsp", and only one deployment or retraction at a time is supported it occurs if anomalies deployment is running for the same ...
2
votes
0answers
24 views

Can I use Set-SPOUser to set an O365 security group as a secondary site collection administrator?

Is there a way to use Set-SPOUser to add a security group I created in Office 365 as a secondary site collection administrator? I have the security group's Login Name which begins with "s-1-5-21-..." ...
0
votes
1answer
33 views

How to get C# to recognize argument passed through PowerShell

I'm using PowerShell to call C# code to turn list alerts on or off on a specific list. When I try to use [AlertsOnOff1.onOff]::Main("off") to call the Main method and pass the arugment of "off"the ...
0
votes
0answers
22 views

Test-Connection and Access denied using Powershell

I have Windows Server 2012 and Sharepoint 2013. I have this issue deploy Sharepoint using Powershell: I execute powershell.exe with credentials UserInstallerMoss. UserinstallerMoss is Farm ...
0
votes
1answer
49 views

I need help getting powershell to run c# code

I found a technet blog saying you could run c# code in powershell, so I ended up giving it a try. When I try to run the following powershell script I get 2 errors and I'm not sure how to resolve them. ...
0
votes
1answer
36 views

Remove all list item permissions with PowerShell

I'm trying to remove all permissions from a list item (SharePoint 2013). I worked out the following script that should do that: $url = "https://Site" $listName = "Tasks"; $SPWeb = Get-SPWeb $url; ...
0
votes
0answers
30 views

Using SPQuery returns today's recurring calendar item and tomorrows. Why?

We have an on call calendar in SharePoint. I'm trying to send an automated, weekly email of the calendar. The calendar has a mix of weekly recurring entries and non recurring entries. I'm trying to ...
0
votes
2answers
41 views

how to copy a sitecollection with powershell

Does any one know how to copy a site collection using PowerShell. I used this : Copy-SPSite http://contoso/sites/OldTeam -DestinationDatabase WSS_Content -TargetUrl http://contoso/sites/NewTeam but ...
1
vote
1answer
30 views

Is there a way to temporarily disable existing alert emails from executing?

I have a powershell script the runs automatically once a week to move old list items to an archive list. On the current list my end users are receiving alerts when the item is moved (create/deleted) ...
0
votes
0answers
17 views

Access denied for Users after database migration from SP2010 to SP2013

After content DB migration from SP2010 to SP2013, a number of users who has permission to access cannot access to the SharePoint 2013 site. The error message given is "Access Denied". I have confirmed ...
0
votes
2answers
37 views

Access denied: 0x80070005 OWSSVR.DLL using Powershell

I have this issue deploy Sharepoint using Powershell: I have Windows Service C# with credentials for user UserInstallerMoss. Windows Service execute an EXE Console Aplicaction C# with credentials ...
0
votes
2answers
149 views

How to get running workflow instances on listitems in powershell?

I have craeted a powershell script to terminate all the corrupted workflows which are older than 4 hours. But I think it is not looking only for the running workflows. It is looking for all the ...
0
votes
2answers
31 views

Deployiment Issues - multiple webparts

If my SharePoint Project has multiple web parts, then I should see multiple .webpart files when I deploy the solution and check the webpart gallery, right? If not then what do I do/why is it ...
0
votes
1answer
37 views

Managing synchronization options in User Profile Service Application using Powershell

I am trying to manage the synchronization options in SharePoint Farm using Powershell. I would like to change the "Use SharePoint Profile Synchronization" to "Enable External Identity Manager" by ...
0
votes
0answers
17 views

Terminate corrupted workflows in powershell

What is wrong with this powershell script to terminate corrupted workflows? I've got this error: An error occurred while enumerating through a collection: Collection was modified; enumeration ...
0
votes
3answers
25 views

SharePoint warmup script implementation

I've implemented the SPWarmup script from Codeplex on development and production environment. This script (that can be found here https://spbestwarmup.codeplex.com/) is working well, when I run it ...
0
votes
0answers
33 views

Powershell where-object doesn't work

I have this Powershell code that works in 2013, but it doesn't work in 2010, although am using a functionality that supposed to work in 2010, my problem is with the where-object, it's not really ...
0
votes
2answers
34 views

Deployment Problems

I am trying to deploy SharePoint web parts that are based on a SharePoint project developed beforehand. I deployed them using a .bat and .ps1 files, running the former from command prompt. I've been ...
1
vote
0answers
15 views

How to compare field changes using powershell to iterate thru the version history

I need to be able to to notify users daily whenever an update to a list item has changed, and give them a list of fields that have been changed. I am using powershell to do this, and send out an ...
-1
votes
0answers
20 views

Creating wiki pages using PowerShell

How to create a wiki page using PowerShell in Sharepoint? I have tried every example online without luck. Do we need to use XML code for it to work?
0
votes
1answer
29 views

Show or hide individual subsites using powershell

I want to show or hide subsite link from Parent site top navigation. e.g. from UI i can do it by Show or hide individual subsites and pages On the Site Actions menu, click Site Settings. On the ...
0
votes
1answer
9 views

Copy-SPSite is not recognized

I'm completely new to Sharepoint and was tasked with copying some new sites. However when I opened Sharepoint Management Shell and typed "Copy-SPSite", it displayed the following message Also, the ...
0
votes
0answers
36 views

Restore backup to new SharePoint 2010 server

this issue is piggybacking on a previous Issue I had. I just set up a new SharePoint server for testing purposes, and I want to import the back ups of our production server for obvious reasons. ...
0
votes
0answers
23 views

What's up with the three bytes at the beginning of these SharePoint files?

I've been playing with SharePoint files in PowerShell, and I've notice three bytes at the beginning of most files (forms and master pages): $web = Get-SPWeb ... $masterFolder = ...
0
votes
1answer
31 views

Missing operation name or the operation name is invalid

I run the following power shell command inside SharePoint 2013 power shell window:- PS C:\Windows\system32> stsadm -o gl-fixpublishingpagespagelayouturl -url "http://gvstg01/wikilibrary/52" -scope ...
0
votes
1answer
31 views

Updating a SharePoint list using export-spweb powershell

I have a list in two different sites. Those lists data has to be in sync. But somehow my content guys forgot to do that. What happens when i import the list from one site to another site which ...
0
votes
1answer
30 views

Replicate site collection with a different URL and retain its content

I have a site collection that is published externally and is constantly getting updated with newer versions of files. The business has a requirement where we need some external users to only see ...
1
vote
2answers
27 views

Delete the defualt folder in sharepoint 2013

i have used the below scripts to delete the folder in sharepoint 2013 This folder is generated by while creating my site which always creates the same folder name in the "Documents" Document ...
0
votes
0answers
9 views

Delete the default folder in sharepoint 2013 using powercell [duplicate]

whenver im creating mysite each user aving default folder in document lib. Shared with every one. so my requirement is to delete the "shared with every one" folder in all my site. is there any ...
0
votes
1answer
31 views

Powershell send email from email field in csv

I have construct powershell to get sitecollection information. What i am trying to achieve is to get all email address of site owner email address and secondary owner email address and put in the CC ...
2
votes
2answers
114 views

Powershell return properly the selected value from multi-choice field

In my powershell script I want to fetch the value of a mulit-choice-field in a sharepoint list. The problem is that although the value is returned, it is encased in ;# - for example, I would receive ...
0
votes
1answer
37 views

check if list has already been created

I've written a bit of powershell for creating a list just wondering how add say an if statement to check if its already been created. In Client side not server side here is my code : param( ...