$var = get-spfarm
$var | get-member -membertype property
Saturday, May 31, 2014
Thursday, May 29, 2014
PowerShell - Custom List - Delete All Versions
$web = Get-SPWeb "http://localhost"
$list = $web.Lists["MyList"]
foreach ($item in $list.Items)
{
$item.Versions.DeleteAll()
}
$list.EnableVersioning=$False
$list.update()
$web.Dispose();
Update: This seems to have issues, so need to follow up with better solution.
$list = $web.Lists["MyList"]
foreach ($item in $list.Items)
{
$item.Versions.DeleteAll()
}
$list.EnableVersioning=$False
$list.update()
$web.Dispose();
Update: This seems to have issues, so need to follow up with better solution.
Labels:
PowerShell
Friday, May 23, 2014
Get Content Database Name with PowerShell
Get-SPDatabase | Where-Object { $_.TypeName -eq "Configuration Database" } | Select Name
Sunday, May 18, 2014
Windows Explorer - Favorites
Windows Explorer > Right-Click 'Favorites' > Add current location to Favorites.
C:\Windows\System32\drivers\etc
C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14
C:\inetpub\wwwroot\wss\VirtualDirectories
C:\ProgramData\Microsoft\SharePoint\Config
C:\Windows\System32\drivers\etc
C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14
C:\inetpub\wwwroot\wss\VirtualDirectories
C:\ProgramData\Microsoft\SharePoint\Config
Wednesday, May 14, 2014
Filter on Workflow Status
NotStarted = 0
FailedOnStart = 1
InProgress = 2
ErrorOccurred = 3
StoppedByUser = 4
Completed = 5
FailedOnStartRetrying = 6
ErrorOccurredRetrying = 7
ViewQueryOverflow = 8
Max = 15
OOTB Approval WF:
Canceled = 15
Approved = 0×10 (16)
Rejected = 0×11 (17)
References:
http://chanakyajayabalan.wordpress.com/2010/03/08/sharepoint-workflow-status-codes/
FailedOnStart = 1
InProgress = 2
ErrorOccurred = 3
StoppedByUser = 4
Completed = 5
FailedOnStartRetrying = 6
ErrorOccurredRetrying = 7
ViewQueryOverflow = 8
Max = 15
OOTB Approval WF:
Canceled = 15
Approved = 0×10 (16)
Rejected = 0×11 (17)
References:
http://chanakyajayabalan.wordpress.com/2010/03/08/sharepoint-workflow-status-codes/
Friday, May 9, 2014
Word 2010 - Show Document Panel
Word 2010 > 'File' tab > 'Info' > 'Properties' dropdown > 'Show Document Panel'
Subscribe to:
Posts (Atom)