Tag Info

Hot answers tagged

3

When working with parent/child content types, I do this: The parent has only the fields that will exist in all child content types. Then each child content type only has the fields in it that are needed and are not inherited from the parent. So if your children each have different priority values, then each one would have their own priority field that is ...


2

If you do a .remove() instead of a .hide() the fields could (although I haven't seen it to be the case) get blanked out. You would likely see some sort of post back error in that the HTML delivered is different than what was sent, I saw this a lot when trying to modify dropdown lists. If you hide the rows with a .hide(), the fields are still present in the ...


2

If your list/library has multiple content types associated with it, the drop down will appear. If there are other content types that are not being used, remove them from the list and they'll go away. Otherwise, you'll need some script or css to remove/hide it.


2

In this case, the list that you would want to show the related information, you would create a lookup column to your list that has the prospect content type associated to it. In the configuration of the lookup column, you can select additional columns from the list item to bring over into the list.


2

attempting to answer your questions specifically when adding a new column, you'll want to add it to the parent if you want the parent and subsequent children to have the same column. If your parent is an OOTB SharePoint CT, then only add it to your child. I don't recommend modifying SharePoint content types, you never know what Microsoft might do, plus ...


1

The hierarchical relationship allows you to reuse the settings (fields) defined in one content type (parent) in other (child) content types. The hierarchy of content types can be extended to an infinite width and depth, but the best practice is to use 3-level parent-child hierarchy. You could read more best practices on how to manage content types and ...


1

Based on previous answers the approach I can think of is to add an event receiver which checks who the user is as denies the change if they are not allowed. You could use the SPListEventReceiver FieldUpdating event. https://msdn.microsoft.com/en-us/library/office/microsoft.sharepoint.splisteventreceiver.fieldupdating(v=office.14).aspx You would need to ...


1

Couple of things to check: Make sure that MMS proxy associated with the web app.( Central admin > Application management > web app and from ribbon select service connection) Also check if MMS services is running on at least one server in the farm.( Central admin > Managed Services on server.) Also browse the MMS from central admin and see if it working ...


1

You can use PowerShell as below $site = get-spsite http://sitecollectionurl foreach($web in $site.AllWebs) { $libraryName = "DocumentLibrary" $list = $web.Lists[$libraryName] if($list) { #logic to update the library; like modifying field information etc. } }


1

If the Issue Status field does not meet your requirement you should not use it and use a custom column instead. If you envision this list being used in multiple places and across site collections I'd suggest using a Managed Metadata field, because once your users start using it they will find they need additional choices.


1

Two things to make sure: Make sure you have published the content types in the hub (as described here) Run the timer job called "Content Type Hub Subscriber" for the web application that the site you want the content type on belongs to from Central Adminstration. Note: This is not possible in Office 365 (SharePoint Online), since you can not manually run ...


1

You can get the list of content types associated with a List. And the first one is the default one. $webs = Get-SPSite http://siteurl | Get-SPWeb foreach ($web in $webs) { foreach ($list in $web.lists) { if($list.ContentTypes.Count > 0) { Write-Host "Default Content Type = " + $list.ContentTypes[0].Name } ...


1

Indexes are associated with List. So you need to modify the list and add index. You can automate this using PowerShell. $site = Get-SPsite http://siteurl foreach ($web in $site.AllWebs) { #foreach ($list in $web.Lists) for ($i = 0; $i -lt $web.Lists.Count; $i++) { $list = $web.Lists[$i] foreach ($ct in $list.ContentTypes) ...


1

You can do it using below code SPList list = currentWeb.Lists.TryGetList("ListName"); if (list != null) { SPContentType itemCT = list.ContentTypes["CTName"]; if (itemCT != null) { list.ContentTypes.Delete(itemCT.Id); list.Update(); } }


1

I'm going to bump this - agreed with the original poster... in as much as I need to have a way for the newform.aspx to tell the user WHICH content type they are inputting. In my case, I have a big announcements list with events, announcements, marketplace, departmental, and organization-wide announcements. They all have different fields. But perhaps they ...


1

You can update the associated content type by this indirect route. Suppose you have a content type name $contentTypeName, a web $web, and the list item of your page layout, $item. $item.Properties["PublishingAssociatedContentType"] = ";#" + $contentTypeName + ";#" + $web.AvailableContentTypes[$contentTypeName].Id.ToString() + ";#" $item.Update() ...


1

Old question but I thought I'd post a possible solution here for anyone looking. There is no such flag and using SPBuiltInContentTypeId is not sufficient because it doesn't include all built in content types. Based on the SharePoint 2013 content types here I've cobbled this together. I've run this on my own farm and the only content types I got back that ...



Only top voted, non community-wiki answers of a minimum length are eligible