Author: jbmurphy
-
PowerShell: foreach with a first and last item number
I wanted to work through 1000+ items in a PowerShell foreach loop, but I wanted to do it X at a time. I figured out the following foreach syntax to loop through all items after first and before last:
-
Knockout alternate formattting
I was using KnockoutJS to loop through and display some data. I wanted to apply some alternate formatting on every other row. I used this syntax containing the MOD operation to achieve the formatting I wanted. The other thing I learned was that $index() is observable, so I can +1 it? I believe that is…
-
Using PowerShell to add a Contact to a CRM 2011 MarketingList (SOAP)
We had a user delete a Marketing List. I needed to recreate it. I went to a database backup and found the GUID of the deleted list. Then I used the following SQL query to find the GUIDs of all the members of that list: I saved the EntityId column to a text file, and…
-
I am at SharePoint Conference 2012 !!! #SPC12
I can’t wait for the sessions to start. Although seeing all these smart people is a little intimidating.
-
PowerShell script to backup all SharePoint 2010 lists in all webs in all sites
More backups the better. I wanted a file level backup of every list. Below I used PowerShell to iterate through all the lists on the server and dump them into a folder
-
Install-SPSolution, Add-SPSolution and Update-SPSolution return error: not supported with version 4.0.30319.269 of the Microsoft .Net Runtime.
Just tried to install a soliution, and I received the error: Install-SPSolution : Microsoft SharePoint is not supported with version 4.0.30319.269 of the Microsoft .Net Runtime. I just installed the new PowerShell 3.0. To fix, launch a new powershell with -Version 2, and then run your command again: powershell -version 2 That is what I…
-
How to find the pid of your SharePoint site in Windows server 2008 (for Visual Studio attaching to w3wp.exe)
C:\Windows\system32\inetsrv\appcmd.exe list wp
-
My git notes
Been playing around with git to manage my “Environment”. This is a note to self. May add more at some point List files that have been “staged” git diff –name-only –cached To create a “Centro repo” To setup an empty central repo: mkdir /your/path/folder/project.git cd /your/path/folder/project.git git init –bare –shared To add files to the…
-
Coolest thing I have found in server 2012 – Management OData IIS Extensions
Am I interpreting Management OData IIS Extensions correctly? This means I can write an iOS app to run my custom enterprise PowerShell scripts? Now I can justify iOS dev training! Cool.
-
Run PowerShell as system
.\psexec -i -s Powershell.exe Found this from here:
