"Value cannot be null. Parameter name: name" error is shown when editing a file field in the Experience Editor


Description

Editing a file field might fail with an error when you click Open file in the Experience Editor.

The following error can be found in the logs:

Exception: System.ArgumentNullException
Message: Value cannot be null.
Parameter name: name
Source: Sitecore.Kernel
at Sitecore.Diagnostics.Assert.ArgumentNotNull(Object argument, String argumentName)
at Sitecore.Globalization.Language.Parse(String name)
at Sitecore.Shell.Applications.ContentEditor.File.OpenFile(ClientPipelineArgs args)

Solution

To resolve the issue, consider one of the following options: