Jeroen Derde's Blog

My Software Engineering Universe

SharePoint TaxonomyField and “The object has been updated by another user since it was last fetched”

clock April 11, 2012 23:22 by author Jeroen Derde

Got this error after creating some taxonomy fields and then importing them into Visual Studio using CKSDev. If I then tried to connect a term to the taxonomy field the error occured.

 (“The object has been updated by another user since it was last fetched”)

This did not happen at first, but only after removing my Development Site Collection, and then deploying again from Visual Studio to a new clean sitecollection.

The error was thrown because there was a version number specified in the field xml of the taxonomy field. More detailed information can be found at: http://www.mpspartners.com/2012/02/SharePointTaxonomyFieldandTheobjecthasbeenupdatedbyanotherusersinceitwaslastfetched/



Add the source parameter to SharePoint links

clock October 5, 2011 20:46 by author Jeroen Derde

Let say we have a publishing page, and we create a link on that publishing page to the NewForm of a List.
Aftre the user created the listitem we would like to go back to the page the user clicked the link, in stead of the list overview page.
When you want to return to the page you came from, sharepoint uses a QueryString Parameter called "source".
Microsoft was even kind enough to provide us with al small javascript function to automatically add this parameter to a Link.
In a content editor webpart u can use
<A onclick="GoToLink(this);return false;" href="/feedback/_layouts/listform.aspx?PageType=8&ListId={B0EF9608-FC48-401E-9343-4EDDF4585131}&RootFolder=">new feedback</A>
--update--
If however you are in a Publishing page Content Field, SharePoint is kind enough to strip all javascript from the contents.
So you will have to manually add the source parameter for that link.
GoToLink is located in the core.js
 
 


PublishingWebControls:EditModePanel

clock October 1, 2011 02:56 by author Jeroen Derde

Found out today that the behaviour of the PublishingWebControls:EditModePanel changed between MOSS2007 and SP2010.

Apparently,now in SP2010, you need the EditItem Permission to be able to see what is in an EditModePanel even if the PageDisplayMode attribute is set to "Display".

So basically it works like a SPSecurityTrimmedControl

Example:

<SharePoint:SPSecurityTrimmedControl PermissionsString="EditListItems" runat="server"> 
</SharePoint:SPSecurityTrimmedControl>

Update
This behaviour has been changed back to 2007 behaviour as of SP1 for Sharepoint 2010



XSL for Raw Search XML of SharePoint search results

clock September 27, 2011 20:36 by author Jeroen Derde

I keep losing this really handy xsl for displaying the raw search result XML in SharePoint. Blogging it for future reference :).

<xsl:stylesheet version="1.0"
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
 <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes"/>
 <xsl:template match="/">
  <xmp><xsl:copy-of select="*"/></xmp>
 </xsl:template>
</xsl:stylesheet>

 

 



Missing Search Refinement Webpart in SP2010 Site Collection

clock September 14, 2011 00:32 by author Jeroen Derde
When you upgrade to Microsoft SharePoint Server 2010, some of the new SharePoint Enterprise Search Web Parts are missing from the Web Part gallery for upgraded site collections.
The following are the missing Web Parts:
  • Refinement Panel
  • Related Queries
  • People Refinement Panel
  • Dual Chinese Search
This topic describes how you can add these Web Parts to the Web Part galleries of the upgraded site collections.
Another post about this with more detailed problem information


Powershell RunWithElevatedPrivileges

clock September 13, 2011 20:46 by author Jeroen Derde
[Microsoft.SharePoint.SPSecurity]::RunWithElevatedPrivileges( 
{
     $site = get-spsite "http://localhost/nonfarmadminsitecollection" 
}
) 

$elevatedSite = new-object Microsoft.SharePoint.SPSite([Guid]$site.ID,$site.SystemAccount.UserToken)


Link Tools (Ribbon) Remove Link does not delete link

clock July 18, 2011 20:38 by author Jeroen Derde

The issue occurs on a publishing site that has a contenttype containing a Publishing Hyperlink (SPFieldLink).
Inserting a link with the Link Tools Tab of the ribbon works fine, but removing the link after it has been set does not.
Found a post on Stackoverflow that describes the issue in detail:

For quick reproduction: (steps and testing by M. Siepel)

  • Create a Publishing Portal site
  • Create a column of type Publishing Hyperlink 
  • Add the column to de Welcome Page contenttype
  • Navigate to the Press Releases page 
  • View information -> Edit
  • Add a link to the newly created column and save the page
  • Open it again, remove the link (the link is visually removed, it even says: Click here to add a new Hyperlink)
  • Save the page again
  • Now open the page again. 
  • In our situation, the message 'Click here...' is gone, and if you view the source our original link is still there, but there is no text inside it.

I did some testing on it and these are the results:

  • It occurs on dev and prod server with a custom solution installed
  • It occurs on a server with no custom solution installed (clean install)
  • It also occurs on the 'Adventure Works' site (both on a clean install and on a server with custom solution) 
  • It occurs both when creating a sitecolumn of type Publishing Hyperlink through API and UI
  • When viewed with firebug the 'deleted' link is still in the href property, but the text property is empty
  • Tested on IE/FF
  • When viewing with Sharepoint Manager 2010, the link is still in de DB (with no text property as stated above)
  • It happens on Dutch and English sites.

A little more time on the Bing machine resulted in finding a post from M Siepel on the Microsoft forums:
http://social.msdn.microsoft.com/Forums/en-AU/sharepoint2010general/thread/8ce468ec-096b-4ad2-a1e9-0bfb93cecf95

Basicly it states that the bug can be reproduced consistently and it has been reported to the product team. Lets hope this will be fixed in the next CU.

Someone already created a powershell fix, but that is not really end-user friendly. I will update this post

Param([string]$site0=http://mysharepoint, 
[string]$list0="My List",
[string]$itemKey0="Item Key",
[string]$linkUrl0=http://newlink,
[string]$desc0="New description",
[string]$toolTip0="New Tooltip") $site = Get-SPSite($site0) $rootWeb = $site.rootWeb $lists = $rootWeb.Lists $list = $lists[$list0] $items = $list.Items $listItem = $items | Where-Object {$_.Name -eq $itemKey0} $linkUrl = $listItem["Link Url"] $linkUrl.NavigateUrl = $linkUrl0 $linkUrl.Description = $desc0 $linkUrl.ToolTip = $toolTip0 # this is the trick - set the object back to listItem $listItem["Link Url"] = $linkUrl $listItem.Update()

 



Visio 2010 XSD

clock June 6, 2011 23:28 by author Jeroen Derde

About a week ago Microsoft published the XML Schema Definition (XSD) files for the Microsoft Visio 2010 XML Drawing (.vdx) format. This schema is also known as DatadiagramML.
This should make it alot easier to use the visio file to generate code based in the visio file.

The DatadiagramML Schema for Visio 2010 consists of three .XSD files:

  • visio.xsd is the core schema used by Visio 2003 and later
  • visio12.xsd is the set of extensions used by Visio 2007 and later
  • visio14.xsd is the set of extensions used by Visio 2010

More information about the schema is available in the Visio 2010 XML Schema Reference on MSDN.



Cumulative Update SharePoint 2010 April

clock May 12, 2011 22:59 by author Jeroen Derde

I missed these when they where released

28 April Sharepoint  Foundation CU

http://support.microsoft.com/kb/2512804/en-us

11 March Sharepoint  Foundation CU Hotfixes

http://support.microsoft.com/kb/2475880/en-us

28 April Sharepoint Server CU

http://support.microsoft.com/kb/2512800/en-us



Microsoft Country Partner of the Year

clock April 21, 2011 19:58 by author Jeroen Derde

 At e-office we have been working hard at baking our Microsoft cake this year

Lets just say we are pretty serious about our baking skills.
To put the cherry on top we are submitting a great case to the anual Microsoft World Partner Conference in LA.



Check-LookupColumn PowerShell

clock April 14, 2011 01:08 by author Jeroen Derde

Today I had some issues with a Lookup Column in SP2010.

When using my Admin account I was able to edit an Item and select a value. When using my normal useraccount (with contribute rights on bot lookuplist an list) I wasn't able to select anything, and SP2010 showed an empty dropdown.
Looking at the column properties in SharePoint everything looked OK, but using SP Designer the properties where empty.
Figuring this just might be something other then a rights issue, I wrote a little PowerShell function to check the settings of my Column.

 

Function Check-LookupColumn($webURL, $listName, $columnName, $lookupListName)
{
 $web = Get-SPWeb $webURL
 $list = $web.Lists[$listName]
 $column = $list.Fields[$columnName]
 $lookupList = $web.Lists[$lookupListName]
 
 
 write-host "lookupweb              : " $column.LookupWebId.ToString() 
 write-host "should be equal to web : " $web.ID.ToString() 
 write-host "lookuplist             : " $column.LookupList.ToString() 
 write-host "should be equal to list: " $lookupList.ID.ToString()
}

Turned out that during the migration from one environment to the other, the references of the lookup column had not been updated.
The Admin account had sufficient rights on both environments, so it worked for that account. my user account on the other hand was not available in the source environment, so no sigar.
After updating the column with the right GUID's everything works again.

Wish I had seen this before writing my onw script Laughing, but the script to fix the lookup column can be found at: http://get-spscripts.com/2011/01/fixing-blank-lookup-columns-in.html



New job at e-office

clock April 9, 2011 00:23 by author Jeroen Derde

April 1st I started my new job at e-office.  e-office focusses on Human software, and does this using Microsoft, IBM and Google technology.
Human sofware can be seen as 'messaging', 'collaboration', 'enterprise 2.0', 'unified communications', 'user experience' and 'mobile'.
It does however not stop at the technology, because at e-office we believe that people and organisations are an equal part of the equation.

I've joined the SharePoint team at e-office, and I'm already very excited about the upcoming projects that I have seen.

You can follow e-office on:

twitter: http://twitter.com/#!/e_office_com

facebook http://www.facebook.com/group.php?gid=109382118015

linked-in: http://www.linkedin.com/groups?mostPopular=&gid=145232

 



Sharepoint and the iPad

clock February 9, 2011 21:29 by author Jeroen Derde

 

I've been using the iPad for a while now, and regulary find myself accessing my companies SharePoint intranet.
First I just used the iPad's browser, but found that touch input is a bit cumbersome at times and the screen realestate is a bit small on the iPad.
The screen realestate issue could be fixed with some nice orientation enhancements for SP2010 (http://www.youtube.com/watch?v=K8NrTPEu_pY), but that would still leave me with my navigational issues.

To make my life a bit easier I did some research into the available iPad apps that make navigating and using SharePoint easier.

I currently use SharePlus lite. This is the free version of SharePlus.
The Pro version will currently set you back:
 - USD 14,99 or
 - EUR 11,99
http://www.southlabs.com/detail.aspx?id=SharePlus

SharePlus features I really like are:

  • Big buttons that make for easy navigation
  • Pro version is a 1 time buy for all your iOS devices
  • ISA and ForeFront authentication support
  • Add, edit & delete list items, such as: tasks, pictures, contacts, custom lists, discussion boards and documents while connected. Edit includes Check In, Check Out & Discard CheckIn support (pro only).
  • Send documents by email.
  • Browse data by view in online mode, respecting server defined list views, with ordering and filtering settings.
  • SSL Support
  • Connects to WSS 3.0, MOSS 2007, SP2010, and all editions of SharePoint Online (BPOS included), as long as they use windows based authentication and not forms based. Form based is now supported

Other iPad applications for SharePoint I found are:

Fillament (this is the next one I will be trying)

Haven't tried this yet, so no actual experience

  1. Also has a lite and a pro version
  2. Pro version is USD 12,99 or EUR 10,49
  3. Pro: bit cheaper, supports form based authentication, SSL self signed certificate support
  4. Con: irritating music in demo video :), data editting only in pro version
  5. Site: http://www.aircreek.com/home/Products/FilamenteforiPad.aspx
  6. Video:http://www.youtube.com/watch?v=LHOg2-pT_I8

 

SPDashboard 

  1. Free
  2. Pro: Free, Dashboard function
  3. Con: version 1.0, not as advanced as the other two
  4. Site: http://www.unique-conceptions.de/spdashboard.php
  5. Video: http://www.youtube.com/watch?v=kt6o5V5up7g

 



VS2010 released

clock April 13, 2010 19:44 by author Jeroen Derde

I've been using the beta an RC version of Visual Studio 2010 for a while.
Yesterday VS2010 was offically released.

Take a look if there is a launchparty near your location.

http://www.microsoft.com/visualstudio/en-us/visual-studio-events

Enjoy.



First Sharepoint 2010 NEN 2082 certified project

clock March 5, 2010 00:50 by author Jeroen Derde

 

Together with 3 colleagues from QNH Business Integration I am currently finishing implementing a already NEN 2082 certified project based on SharePoint 2010.
When SharePoint 2010 hits RTM there will be another audit for this version of SharePoint, because currently the pre release version has been certified.

NEN 2082 is a Dutch standard which is similar the DoD5015 and MoReq standards.

This project was done for the Gemeente Nieuwegein, which is a Dutch local Government.

For this project we have also been nominated for the “Innovation of the year” award:

More information (Dutch)

My colleagues at QNH:




Month List

Calendar

<<  September 2014  >>
MoTuWeThFrSaSu
25262728293031
1234567
891011121314
15161718192021
22232425262728
293012345

View posts in large calendar

Sign in