1

Could someone be so kind as to check the following in their 2010 environments.

  1. Create a doc library
  2. Turn on force check-out
  3. Turn on versioning.
  4. Add the "Edit (link to edit item)" column to the default view.
  5. Now upload a document and check it in.
  6. Use the Edit column to edit the properties.

You should see:

You must check out this item before making changes. Do you want to check out this item now?

Clicking OK, would normally check the document out and take you to the edit form (in a dialog in sp2010 if dialogs set to yes for library).

However in two environments of mine, nothing happens anymore!!!!

On live I tested tested a new library in an existing site, a new library in a new site, and an existing library in a migrated site (from 2007).

Strangely I found one document library in a migrated site which DOES STILL WORK but why this one library works is puzzling me!! The issue is new libraries don't work and that seems to confuse me more!

Again, I tried new libraries in two SharePoint environments and same behaviour.

Anyone?

10
  • Is there anything in the ULS or Event Logs?
    – Dave Wise
    Commented Oct 24, 2012 at 17:41
  • Nothing in ULS and assume this is because nothing is happening following clicking OK! Are you saying you don't have this behaviour? Once again I've tried in production and in development. Totally separate environments on new site collections and both don't work!
    – Tezza
    Commented Oct 25, 2012 at 12:38
  • I'm quite surprised no one has confirmed whether they also get this issue? It may be a bug but could someone please try this for my sanity!? :) Now three environments later and same behaviour in them all for me.
    – Tezza
    Commented Nov 13, 2012 at 17:36
  • I've discovered that in almost all cases where I am seeing a problem but there is nothing on it on the net that it means that it is an issue unique to my local environment. Either it is in the way that SharePoint is configured, custom features that are enabled or in the way that Office is configured.
    – Dave Wise
    Commented Nov 13, 2012 at 18:04
  • Thanks but once again, three environments tried!! Not remotely close to being the same config either! Are you saying you don't get the behaviour described?
    – Tezza
    Commented Nov 13, 2012 at 22:20

1 Answer 1

0

I had the same problem on my environment. I found a solution for it - you need to edit the xsl template for the 'Edit' column.

Here is part of the original code:

<xsl:when test="$hasRight = '1'">
    <a href="{$FORM_EDIT}&amp;ID={$ID}" onclick="EditItemWithCheckoutAlert(event, '{$FORM_EDIT}&amp;ID={$ID}', '{$requiresCheckout}', '{$thisNode/@IsCheckedoutToLocal}', '{$thisNode/@FileRef.urlencode}', '{$HttpVDir}', '{$thisNode/@CheckedOutUserId}', '{$Userid}');return false;" target="_self">
      <img border="0" alt="{$thisNode/../@Edit}" src="/_layouts/images/edititem.gif"/>
    </a>
</xsl:when>

And here is the one I am using:

<xsl:when test="$hasRight = '1'">
    <a href="{$FORM_EDIT}&amp;ID={$ID}" onclick="EditItemWithCheckoutAlert(event, '{$FORM_EDIT}&amp;ID={$ID}', '{$requiresCheckout}', '{$thisNode/@IsCheckedoutToLocal}', '{$thisNode/@FileRef.urlencodeasurl}', '{$HttpVDir}', '{$thisNode/@CheckedOutUserId}', '{$Userid}');return false;" target="_self">
      <img border="0" alt="{$thisNode/../@Edit}" src="/_layouts/images/edititem.gif"/>
    </a>
</xsl:when>

Notice how the 5th parameter in the javascript function EditItemWithCheckoutAlert in my version is $thisNode/@FileRef.urlencodeasurl while the orginal is just $thisNode/@FileRef.urlencode

Here is the difference in rendering (example):

original: %2FLibrary%2FBSORU%2FMDM%2Fsb%20avatar%2Epng

my version: /Library/BSORU/MDM/sb%20avatar.png

I did not test this very thoroughly, but it worked for a few check-ins/outs. Hopefully this will work on your environment too.

EDIT: I saw this solution had some problems with non-latin characters and changed the parameter to just $thisNode/@FileRef - this doesn't encode the location or filename.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.