Sharepoint Blog Template – No content types
By peter.stilgoe
I was hoping to use a Sharepoint blog with custom templates for showcasing products but it appears you cant’
“The Post Content Type used in Blogs (0×0110) can be changed, but the changes are not propagated to the list (as its AllowContentTypes is false).”
More From pstilgoe
Content Type Toolbar Web Part
By peter.stilgoe
The Content Type Toolbar is a simple add-on that will enhance the use of SharePoint Content Types in large deployments.
The use of content types in SharePoint 2007 has a number of benefits and businesses may spend a considerable amount of time planning and deploying content type to help support their business processes. Unfortunately, the default methods of using content types may not be intuitive for most users who do not have experience with SharePoint. This problem will lead to content types not being used or being neglected by the end users. This can be avoided by training your end users, but it may be sometime before all your users receive the appropriate level of training, so in the meantime the content types are still neglected.
More From pstilgoe
How to group by more than 2 columns in a Sharepoint view
By peter.stilgoe
Excellent step by step instructions here:
http://techtrainingnotes.blogspot.com/2008/11/sharepoint-group-by-on-more-than-2.html
More From pstilgoe
Displaying the week number using a Sharepoint calculated column
By peter.stilgoe
Create & calculated column and add the following formula:
=INT(([Start Date]-DATE(YEAR([Start Date]),1,1)+(TEXT(WEEKDAY(DATE(YEAR([Start Date]),1,1)),”d”)))/7)+1
More From pstilgoe
Creating filtered views in Sharepoint
By peter.stilgoe
For lists and libraries with large numbers of items, users can access the items with a mix of views and search. The following are some suggestions for views that work well with an indexed column:
Recently changed: To create a view of only the items that have changed in the past week, you can index the Modified column and then apply the filter Modified (Indexed) is greater than [Today]-7.
New items: To create a view of only those items that were added in the past week, you can index the Created column and then apply the filter Created is greater than [Today]-7.
My items: To create a view of only those items that you added, you can index the Created By column and then apply the filter Created By is equal to [Me].
Due today: For lists or libraries with a Due Date column, you can index that column and then apply the filter Due Date is equal to [Today].
Discussion board updates: To create a view of only the discussions that were updated in the past month, you can index the Last Updated column on a discussion board, create a new Subject view, and then apply the filter Last Updated is greater than [Today]-30.
People and Groups: If you have a lot of people visiting your site, you can improve the performance of the All Groups and All People pages by indexing the Content Type column for the User Information List.
Even if only a few people appear on the All People page, many people visiting the site will result in inactive users being written to the User Information List, which can still affect the performance of this list.
Find links to more information about creating or changing views and about formulas and functions that you can use to filter views in the
Note: Because creating views that use a column index correctly is more complicated for large lists and libraries, you might want to remove the Manage Personal Views permission from contributors for a large list or library. By removing this permission, you can prevent users from creating a view that spans all of the items and that might adversely affect the performance of the rest of the site.
More From pstilgoe
Sharepoint 2010 – Sneak Preview
By peter.stilgoe
Sharepoint 2010 – Sneak Preview
http://sharepoint.microsoft.com/2010/Sneak_Peek/Pages/Overview-Video.aspx
More From pstilgoe
K2 – General rules for configuring kerberos delegation
By peter.stilgoe
A good set of rules from K2underground:
1. Kerberos delegation should be configured for each of the following services:
a. K2 server
b. K2 workspace
c. SharePoint – Sites that will interact with K2 and also your Central admin site
d. SQL reporting services
e. SQL server
2. SPNs needed (you should always create SPNs for both the Fully Qualified Domain name (FQDN) and the NetBIOS name of each service:
a. K2 server – When you run a K2 farm please remember that you will need to set the below settings for each server in the farm as well as the farm name itself (Therefore [MachineNameForServer1] can be = to [MachineNameForServer2] etc. or [FarmName]
i. setspn -A K2Server/[MachineNameForServer1]:5252 domain\K2 Service Account domain\K2 Service Account
ii. setspn -A K2Server/[MachineNameForServer1]:5252 domain\K2 Service Account
iii. setspn -A K2HostServer/[MachineNameForServer1]:5555 domain\K2 Service Account domain\K2 Service Account
iv. setspn -A K2HostServer/[MachineNameForServer1]:5555 domain\K2 Service Account domain\K2 Service Account
b. K2 workspace: The best implementation is to use host headers for site names. If you do want to use http://machinename:port, make sure that you don’t have multiple Application pool identities for different sites on the same IIS server and don’t include the port number in the SPN. Best way to avoid that is to use Host headers (A type or Host type DNS record and not CNAME)
i. setspn -A HTTP/K2WSSiteName domain\K2 Workspace Site Application pool identity
ii. setspn -A HTTP/K2WSSiteName.FQDN domain\K2 Workspace Site Application pool identity
c. SharePoint – Sites that will interact with K2 and also your Central admin site. The best implementation is to use hostheaders for site names. If you do want to use http://machinename:port, make sure that you don’t have multiple Application pool identities for different sites on the same IIS server. Best way to avoid that is to use Hostheaders (A type or Host type DNS record and not CNAME)
i. setspn -A HTTP/SharePointSiteName domain\SharePointSite Application pool identity
ii. setspn -A HTTP/SharePointSiteName.FQDN domain\SharePoint Site Application pool identity
iii. setspn -A HTTP/SharePointCentralAdminSiteName domain\SharePointCentralAdmin Application pool identity
iv. setspn -A HTTP/SharePointCentralAdminSiteName.FQDN domain\SharePointCentralAdmin Site Application pool identity
d. SQL reporting services:
i. setspn -A HTTP/SSRSSiteName domain\SSRS Application pool identity
ii. setspn -A HTTP/SSRSSiteName.FQDN domain\SSRS Site Application pool identity
e. SQL Server – please see SQL server documentation for the correct SPN value
3. Check your system for duplicate SPNs. This is a very important step to take. With Windows 2003 there is not any clean or easy way to check this, accept to make a dump of the SPNs in your AD structure and manually checking for duplicate values. With Windows 2008 you can run the following command to check for duplicate values: setspn –x
4. Make sure that each the mentioned accounts above has permissions to delegate to any service (less secure, but most simple way of configuring)
5. Set the NTAuthenticationProviders node to Negotiate,NTLM for each IIS site as noted above on each IIS server (If farming K2 workspace, SharePoint or SSRS make sure to set this on each machine where the site exists) PS. These steps only apply to IIS 6.0
6. Change Authentication per SharePoint site in SharePoint Central Admin to allow for Negotiate
7. Remember to always perform an IIS reset if you make any such changes to any of your sites and restart your services.
More From pstilgoe
Calculated column – some restrictions
By peter.stilgoe
- You cannot reference a value in a row other than the current row (as opposed to Excel).
- You cannot reference a value in another list or library.
- You cannot reference lookup fields in a formula.
- You cannot reference the ID of a row for a newly inserted row. The ID does not yet exist when the calculation is performed.
More From pstilgoe
Using a calculated column to display month name
By peter.stilgoe
You probably think this is going to be quite long winded & involve many IF statements, its actually pretty simple as I just found out.
Create a ‘Calculated Column’ & for your formula add:
=TEXT([YourDateField],”mmmm”)
More From pstilgoe
Sharepoint Common Date Formulas For Calculated Columns
By peter.stilgoe
Get Week of the year:
=DATE(YEAR([Start Time]),MONTH([Start Time]),DAY([Start Time]))+0.5-WEEKDAY(DATE(YEAR([Start Time]),MONTH([Start Time]),DAY([Start Time])),2)+1
First day of the week for a given date:=[Start Date]-WEEKDAY([Start Date])+1
Last day of the week for a given date:
=[End Date]+7-WEEKDAY([End Date])
First day of the month for a given date:
=DATEVALUE(”1/”&MONTH([Start Date])&”/”&YEAR([Start Date]))
Last day of the month for a given year (does not handle Feb 29). Result is in date format:
=DATEVALUE (CHOOSE(MONTH([End Date]),31,28,31,30,31,30,31,31,30,31,30,31) &”/” & MONTH([End Date])&”/”&YEAR([End Date]))
Day Name of the week : e.g Monday, Mon
=TEXT(WEEKDAY([Start Date]), “dddd”)
=TEXT(WEEKDAY([Start Date]), “ddd”)
The name of the month for a given date – numbered for sorting – e.g. 01. January:
=CHOOSE(MONTH([Date Created]),”01. January”, “02. February”, “03. March”, “04. April”, “05. May” , “06. June” , “07. July” , “08. August” , “09. September” , “10. October” , “11. November” , “12. December”)
Get Hours difference between two Date-Time :
=IF(NOT(ISBLANK([End Time])),([End Time]-[Start Time])*24,0)
Date Difference in days – Hours – Min format : e.g 4days 5hours 10min :
=YEAR(Today)-YEAR(Created)-IF(OR(MONTH(Today) More From pstilgoe
Creating an Org Chart using Visio 2007 and a SharePoint List
By peter.stilgoe
Many times during a project, you hit a requirement to have the ability to display an org chart on your SharePoint portal, and because there are many options to do this, it is difficult to know what approach is best for your particular scenario.
Here is a quick way of developing an org chart that the business users can update themselves! There are many options in terms of what data source you can use, such as Excel, MS Access, SQL Server or any OLEDB or ODBC data source.
For this scenario, we simply configure the Visio 2007 Org Chart to retrieve its data from a SharePoint List. The possibilities are endless in terms of how that data gets populated into the SharePoint List as well. For instance, you can write some code to retrieve and cleanup some data before programmatically importing it into the List.
More From pstilgoe
View PDF documents in a webpart
By peter.stilgoe
You can view PDF’s on your Sharepoint pages suprisingly easily using the CEWP.
Add a CEWP & add the following code:
The only dependency is that your clients will need Adobe Reader installed locally on their PC.
More From pstilgoe
Change default.aspx to a different page with different name
By peter.stilgoe
For publishing portals, you can’t just replace default.aspx with your custom code, but you can change the URL to your default page:
From the Top Level Site > Site Actions > Site Settings > Look and Feel > Welcome Page > Change the path to your custom page.
More From pstilgoe
Error: Cannot retrieve the information for application credential key
By peter.stilgoe
If you are receiving the error Cannot retrieve the information for application credential key. the problem is that the credentials could not be encrypted because no credential key has been established; to establish a credential key you must run STSADM -o setappassword -password
After you have established a credential key to encrypt the logon identity password you will be able to run STSADM -o setproperty -url http://server:port -pn “peoplepicker-searchadforests” -pv “domain:bar.foo.corp.com”, LoginName, P@ssword.
For detailed information on support for cross-forest deployments visit http://blogs.msdn.com/sharepoint/archive/2006/03/15/552331.aspx



August 28th, 2009
