This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$jsLink = Add-PnPJavaScriptLink -Name "jQuery" -Url "https://code.jquery.com/jquery.min.js" -Sequence 10 -Scope Site |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
param ( | |
[Parameter(Mandatory=$true)] | |
[string]$ContentType, | |
[Parameter(Mandatory=$true)] | |
[string]$FieldName, | |
[ValidateSet("First", "Last", "Position")] | |
[string]$Mode, | |
[string]$NewPosition | |
) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
param ( | |
[string]$ContentTypeName, | |
[string]$FieldName | |
) | |
$result = -1 | |
$currentPosition = -1 | |
$ct = Get-PnPContentType -Identity $ContentTypeName |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
param ( | |
[string]$Listname, | |
[string]$Viewname, | |
[string]$Fieldname | |
) | |
$result = -1 | |
$currentPosition = -1 | |
$view = Get-PnPView -List $Listname -Identity $Viewname -Includes ViewFields |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using System.Security; | |
using Microsoft.SharePoint.Client; | |
namespace VersioningTester | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using System.IO; | |
using Aspose.Words; | |
using Aspose.Pdf; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static MemoryStream MergePdfDocuments(Stream pdf1, Stream pdf2) | |
{ | |
MemoryStream result = null; | |
Aspose.Pdf.Document pdf1Document = new Aspose.Pdf.Document(pdf1); | |
Aspose.Pdf.Document pdf2Document = new Aspose.Pdf.Document(pdf2); | |
Aspose.Pdf.Document pdfResult = new Aspose.Pdf.Document(); | |
pdfResult.Pages.Add(pdf1Document.Pages); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function MoveFieldBehind | |
{ | |
param ( | |
[string]$ContentTypeName, | |
[string]$FieldToMove, | |
[string]$AnchorField | |
) | |
Write-Host "Put field $FieldToMove behind $AnchorField in Content Type $ContentTypeName" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
param ( | |
$Path, | |
$DestinationPath, | |
$ZipFile | |
) | |
Write-Host "Path: $Path" | |
Write-Host "DestinationPath: $DestinationPath" | |
Write-Host "ZipFile: $ZipFile" | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
param ( | |
[Parameter(Mandatory=$true)] | |
$Url, | |
$Cred, | |
[switch]$UseWebLogin | |
) | |
if ($UseWebLogin.ToBool() -eq $false) | |
{ | |
if ($Cred -eq $null) |