0
votes
0answers
41 views

Filter Document Libraries based on a column name

Get-SPWeb http://sharepoint/sites/training | Select -ExpandProperty Lists | Where { $_.GetType().Name -eq "SPDocumentLibrary" } | Select Title I have this code which outputs all of the document ...
0
votes
0answers
41 views

Url column fill with powershell how to disable link on a item

I have a list with custom columns. One column type is URL. I create an item like that : $new = $list.Items.Add() $new["Client"] = "http://google.fr/, $($i.client)" Is that possible to disable the ...
0
votes
1answer
190 views

SharePoint Powershell Number and User columns

I need to create two list fields by powershell. One that accept only Integer (type Number with no decimal) and the other User (multiple selection). I can create Number field and Single User field ...
0
votes
2answers
387 views

Create Lookup Field Powershell

I am using SharePoint 2013, I need to create a lookup field throw PowerShell. I tried this code but is not working: $SiteUrl = "http://mySite" $WebObj = Get-SPWeb -identity $SiteUrl $myCustomList = ...
2
votes
3answers
4k views

Retrieve All Lists With Specific Name Using Powershell

I have a powershell script that I am trying to use to add a column (Created) to a specific view in a specific list in multiple webs. The list exists in every sub web. The view exists in every list. ...
0
votes
0answers
63 views

2013 - Powershell Enable columns

I'm creating sites, subsites and lists via PS. And I need to "enable" the version/size columns, in lists I created. I don't want to create them because they already exist. In graphical mode, I just ...
0
votes
0answers
511 views

C#: cannot get listitem field value but works fine in powershell?

back again with a strange issue. Using powershell I can get a handle on a SPListItem and do Item["My Field"] which prints its value. However, in a C# custm workflow activity, when I attempt to do ...
3
votes
1answer
4k views

Uploading a file using powershell and updating column values

I am trying to upload a file from a local drive to a sharepoint doc lib, this much I have been able to find, however, I also want to update a column relative to the file, foe example, I have a company ...
0
votes
2answers
2k views

Sharepoint 2007 Powershell: $item.update() gives error that file has been modified

I am trying to programmatically update some metadata for a sharepoint item using powershell. Here is my code: $web = getWebByURL("http://test-site/spadmin/") $itm = $web.lists["Documents"].items[0] ...
2
votes
4answers
3k views

How to set columns visible only in Display Form on a Column used by a Content Type

I have a column that we will call C. This Column is associated to a Content Type (CT). If I go to the properties of the CT -> Column C I can set the column to be Facoltative or Hidden: If I put it ...
1
vote
1answer
362 views

Adding a content type to a list gives me a duplicate field error

I have the following code: list.ContentTypes.Add(contentType); It works on my dev environment, but on test fails with the following error: A duplicate field name "[GUID]" was found. I've had ...
1
vote
1answer
227 views

Adding a field of type metadata with powershell

I'm trying to add a column of type Metadata. I've first exported the SchemaXml of an existing column on which i'm working. After that I added the column with method AddAsSchemaXml. The field is ...