Tag: page

Podemos obtener las propiedades por medio de un control llamado ProfileProperty. 1 Registrar el namespace <!--SPM:<%@ Register Tagprefix="PortalWebControls" Namespace="Microsoft.SharePoint.Portal.WebControls" Assembly="Microsoft.SharePoint.Portal, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>--> 2 Cargar el control <!--SPM:<PortalWebControls:ProfilePropertyLoader runat="server" […]
A través de esta función podemos obtener la URL para ver las propiedades de un item de una lista de SharePoint: public static string GetItemPropertiesURL(SPListItem item) { string web = […]
Normalmente suele producirse cuando desplegamos una columna de sitio errónea y la modificamos. Para resolverlo debemos buscar ese campo en la base de datos de contenido y borrarlo. Lo encontramos […]
Para cambiar la MasterPage de SharePoint por PowerShell tan solo debemos abrir la consola de SharePoint (SharePoint Management Shell) como administradores y ejecutar: $web = Get-SPWeb http://MY_SITE.com $web.CustomMasterUrl = "/_catalogs/masterpage/MY_MASTER.master" […]
Podemos ejecutar funciones JS al final de la carga de la página por medio de JQuery. No obstante, en SharePoint esto no siempre funciona: $(document).ready(function(){ //My code }); Esto ocurre […]
When a page is loaded in a Modal Dialog, its URL ends with “IsDlg=1”, that means that it’s being opened in a SharePoint PopUp. If you need to hide some […]
SPSecurity.RunWithElevatedPrivileges(delegate() { using (SPSite site = new SPSite("YOURSITE")) { using (SPWeb web = site.OpenWeb()) { //Obtain the page PublishingPageCollection publishingPages = PublishingWeb.GetPublishingWeb(web).GetPublishingPages(); PublishingPage page = publishingPages.FirstOrDefault(f => f.Uri.AbsoluteUri == "YOURPAGE"); […]
Unpublish and Checkout SharePoint Page: SPSecurity.RunWithElevatedPrivileges(delegate() { using (SPSite site = new SPSite("YOURSITE")) { using (SPWeb web = site.OpenWeb()) { //Obtain the Page PublishingPageCollection publishingPages = PublishingWeb.GetPublishingWeb(web).GetPublishingPages(); PublishingPage page = […]
My case: It’s a standard register form created in a SharePoint WebPart (but this error could happen even if you’re not using SharePoint). When I submit the form, sometimes I […]
If we couldn’t acces to the menu item “Edit Page” for any reason and we want to edit that page (e.g. to remove some webpart that blocks our page) we’ve […]