RSS Feed Is this your first time here? Get regular updates

Google Chrome v37+ causes problem changing user in TeamTime on SharePoint 2010

Date:November 24th, 2014 Author: Tags: ,
Category: SharePoint TeamTime Comments:1 ;

Google have controversially removed a feature (showModalDialog) from Chrome v37+ that has been included in most browsers since 1994 and is still part of the HTML5 specification.

This has caused problems with lots of web applications including companies internally developed apps, ’3rd party apps’ and Microsoft products like Outlook Web Access, Dynamics and of course SharePoint.

TeamTime (our timesheet app for SharePoint) has been effected by this too as we use SharePoints built in People Picker control in the Timesheet to allow you to view other users timesheets (if you’ve got the right permissions).


teamtime-people-picker

With Google Chrome v37 and above it will open up the people picker and let you select an individual, but when you click OK it won’t update the main page.

This is actually due to a bug in SharePoint 2010 and you can see the same problem if you edit a normal “Person or Group” field like the Assigned To field in any task list.

Interestingly (to us nerds anyway!) it works fine if the Edit Form opens as a dialog, but won’t work if it opens up full screen (which will happen if you right click Open In New Window, click on an edit link in an email or turn of Launch forms in a dialog in List Settings > Advanced Settings).

edit-form-in-popupEdit Form opens in dialog – people picker will work OK. edit-form-no-dialogEdit Form opened full screen, SharePoint 2010 people picker will not work in Google Chrome v37 or above

This isn’t something we can fix – the problem is a bug in Microsoft’s SharePoint 2010 javascript code which has been triggered by Google’s change to Chrome.

Nerd Alert – The bug is in init.js, function commonShowModalDialog. At the end of the function (in the branch that runs if showModalDialog is not available) you have the line

               if (window.frameElement != null)
                              window.fndlgClose = d

Where d is the ‘callback’ function to run when the user selects a person. The test if (window.frameElement != null) means this is only ran if its running in an iFrame – hence it working if the edit form opens up in a ‘popup’ itself.

What are my options?

  • Stop using Chrome in favour of another browser.
  • Temporarily use a registry hack to turn showModalDialog back on (but this will only work until the end of April 2015)
  • Upgrade to SharePoint 2013 (this only happens on SharePoint 2010, not 2007 or 2013)
  • Wait until either Microsoft fix this or Google come to their senses.

Tags: ,

Did you enjoy this post? Get the next one by RSS or by email

One Response to “Google Chrome v37+ causes problem changing user in TeamTime on SharePoint 2010”

  1. Alex says:

    OR you can override init.js commonShowModalDialog function. Just copy it and change the lines

    if (window.frameElement !=null)
    {
    window.fndlgClose=callback;
    }

    to
    window.fndlgClose=callback;

    Since its a window-scoped function you will override it without any pain in the ass.

Leave a Reply

Anti-Spam Quiz: