Friday, September 24, 2010

As soon as setting up the User Profile Synchronization Application service, when clicking on User Profile Service Application in SharePoint 2010 - UserProfileServiceUserStatisticsWebPart:LoadControl failed

As soon as setting up the User Profile Synchronization Application service, when clicking on User Profile Service Application in SharePoint 2010 - UserProfileServiceUserStatisticsWebPart:LoadControl failed

[UserProfileServiceUserStatisticsWebPart:LoadControl failed, Exception: System.IO.FileLoadException: The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) at Microsoft.Office.Server.UserProfiles.UserProfileConfigManager.InitializeIlmClient(String ILMMachineName, Int32 FIMWebClientTimeOut) at Microsoft.Office.Server.UserProfiles.UserProfileConfigManager..ctor(UserProfileApplicationProxy userProfileApplicationProxy, Guid partitionID)]
Check-1: You may have forgotten to issue iisreset /noforce
Check-2: Verify that “Forefront Identity Manager Synchronization Service” and the “Forefront Identity Manager Service” are running

Thursday, September 23, 2010

SPSite Constructor throws FileNotFoundException

Most of the time we try out a Console application to test a specific piece of code, but when you do this on a x64 bit platform there is a chance that you might come across an exception as “FileNotFoundException” – complaining that the site not found.
The most basic reason for this issue could be that your output assembly is not compatible with the SharePoint assembly which is running out.
Ensure that your target platform is set to “AnyCPU”, before you further investigate on any other reasons.

Tuesday, September 21, 2010

Issues when running SharePoint 2010 Products Configuration Wizard - System.Security.Cryptography.CryptographicException: Keyset does not exist

Here the encryption key was created on a specific thread which was impersonated under a specific users account. When the .NET Finalizer processes the encryption key while the timer service shuts down it executed on a different thread which is not impersonated - so the key does not exist and you get an exception like "keyset does not exist".
To configure the server to no longer show a dialog when an unhandled exception occurs, use the registry editor to delete the following registry keys:

- HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AeDebug\Debugger
- HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\.NETFramework\DbgManagedDebugger
On a 64-bit operating system also delete the following registry keys:

- HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows NT\CurrentVersion\AeDebug\Debugger
- HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\.NETFramework\DbgManagedDebugger

Monday, September 20, 2010

iisapp equivalent in IIS7 (Related to Windows 2008 or above)

When working with IIS 6.0 it was pretty handy to use the iisapp VbScript to find out which w3wp worker process relates to which Application Pool. In IIS7, this script doesn’t work anymore. There is a replacement though. You can add the command below to a batch file and just call it:



%windir%\system32\inetsrv\appcmd.exe list wp