See this http://support.microsoft.com/kb/947284
If you create a workflow to start automatically on creation of a new item or a change in the item – it may not start if the following conditions are true:
- The Windows SharePoint Services Web application runs under a user’s domain account.
- The user logs in by using this domain account.
- The site displays the user name as System Account.
A change to the service accounts is required – or you need to login as another user.
Typically you will face this in your individual development environment as you are most likely using one account for everything.
Had to create custom list using powershell + add columns + create a new view + set that as a default view. For the longest time, the default view just would not be set – no errors, till it dawned that I need to update the view once it is set to default (and not just update the list).
I could also not find a relevant example to add declared columns to a new view (within msdn or google), so including that as well. Check the two lines in bold below.
Here is an example:
$webURL = “http://spurl/site/”
$spSite = [Microsoft.SharePoint.SPSite]($webURL)
$spWeb = $spSite.OpenWeb()
# Create a custom list (ID is 100)
$myListGuid = $spWeb.Lists.Add(“CustInfo”, “Customer Information for Northern Projects”, 100)
$myList = $spweb.Lists[$myListGuid]
# Update the List Title
$myListObj = $spWeb.Lists[“CustInfo”]
$myListObj.Title = “Customer Information”
# Adding fields
$myFieldCustomerName = $myList.Fields.Add(“CustomerName”, “Text”, 0)
$myList.Fields[$myFieldCustomerName].Title = “Customer Name”
# Adding fields
$myFieldCustomerAvailable = $myList.Fields.Add(“CustomerAvailable”, “Boolean”, 0)
$myList.Fields[$myFieldCustomerAvailable].Title = “Customer Available”
# Adding fields
$myFieldCustomerDate = $myList.Fields.Add(“CustomerDate”, “DateTime”, 0)
$myList.Fields[$myFieldCustomerDate].Title = “Customer Date”
$myList.Fields[$myFieldCustomerDate].DisplayFormat = “DateOnly”
# Setting the Query for the View
$viewQuery = “<OrderBy><FieldRef Name=””Modified”” Ascending=””False”” /></OrderBy>”
# Adding fields to the view
$viewFields = New-Object System.Collections.Specialized.StringCollection
# View Name
$viewName = “view_name_here”
# Finally – Provisioning the View
$myListView = $myList.Views.Add($viewName, $viewFields, $viewQuery, 100, $True, $False, “HTML”, $False)
# You need to Update the View for changes made to the view
# Updating the List is not enough
$myListView.DefaultView = $True
$myList.OnQuickLaunch = $True
If you are using your laptop / desktop as a SharePoint Development Environment, and then ocassionally “dont” want to work with SharePoint, here is an easy way to free up local resources (CPU/memory/etc).
The following “windows services” are associated with my SharePoint instance (note the default status as Automatic/Manual/Disabled).
I updated the Automatic to Manual.
Once they are all setup as Manual, use the following to fire up or shut down any of these (in the order) from an elevated command prompt.
net start SQLWriter
net start SQLBrowser
net start MSSQL$SHAREPOINT
net start SQLAgent$SHAREPOINT
net start W3SVC
net start SPAdminV4
net start SPTimerV4
net start SPTraceV4
net start OSearch14
net start WebAnalyticsService
net stop W3SVC
net stop SPAdminV4
net stop SPTimerV4
net stop SPTraceV4
net stop OSearch14
net stop WebAnalyticsService
net stop SQLAgent$SHAREPOINT
net stop MSSQL$SHAREPOINT
net stop SQLBrowser
net stop SQLWriter
A newly created BCS error shows “There are no addresses available for this application”
- You have started the “Business Data Connectivity Service” from Application Management > Manage Services on Server
- Perform an iisreset
If you find the following in the ULS error:
Load control template file /_controltemplates/TaxonomyPicker.ascx failed: Could not load type ‘Microsoft.SharePoint.Portal.WebControls.TaxonomyPicker’ from assembly ‘Microsoft.SharePoint.Portal, Version=188.8.131.52, Culture=neutral, PublicKeyToken=71e9bce111e9429c’.
<pre>Edit C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\CONTROLTEMPLATES\TaxonomyPicker.ascx
Find the character string , and replace with a comma “,” (without quotes). Change “Microsoft.SharePoint.Portal.WebControls.TaxonomyPicker,” to “Microsoft.SharePoint.Portal.WebControls.TaxonomyPicker,”
This has been documented at http://support.microsoft.com/kb/2481844