Value does not fall within the expected range nitrox как исправить

Version

V: 1.5.0.1

Bug

My nitrox won’t boot up. It comes with an error that says:
Value does not fall within the expected range.
System.ArgumentException: Value does not fall within the expected range.
at NitroxServer_Subnautica.Serialization.Resources.ResourceAssets.ValidateMembers(ResourceAssets resourceAssets) in NitroxServer-SubnauticaSerializationResourcesResourceAssets.cs:line 21
at NitroxServer_Subnautica.Serialization.Resources.ResourceAssetsParser.Parse() in NitroxServer-SubnauticaSerializationResourcesResourceAssetsParser.cs:line 52
at NitroxServer_Subnautica.SubnauticaServerAutoFacRegistrar.RegisterDependencies(ContainerBuilder containerBuilder) in NitroxServer-SubnauticaSubnauticaServerAutoFacRegistrar.cs:line 34
at NitroxModel.Core.NitroxServiceLocator.InitializeDependencyContainer(IAutoFacRegistrar[] registrars) in NitroxModelCoreNitroxServiceLocator.cs:line 16
at NitroxServer_Subnautica.Program.

d__3.MoveNext() in NitroxServer-SubnauticaProgram.cs:line 71
— End of stack trace from previous location where exception was thrown —
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at NitroxServer_Subnautica.Program.(String[] args)

Expected

It boots and instead of play it will say multiplayer, and in the cmd window it will not show red text with an error.

Steps to reproduce

Start nitrox, Go to server, Start Server, Goto play game, Press Multiplayer, it fails.

Other details:

Install Folder

C:Program FilesWindowsAppsUnknownWorldsEntertainmen.GAMEPREVIEWSubnautica_1.0.7.0_x64__bh1f6rvenfkm2
yes. I have windows download. not steam.

Получение этой ошибки при запуске всех приложений ClickOnce для определенного пользователя. Это началось после обновления версии (но не с кем-то другим).

Я попытался впоследствии изменить номер версии, добавить/удалить, скомпилировать реестр, очистить папку «Локальные настройки» «Службы» и т.д. Еще не повезло.

Эта статья указывает на повреждение профиля пользователя, но я воссоздаю этого пользователя, это не вариант. Есть ли другие идеи по очистке этого?

 PLATFORM VERSION INFO
    Windows             : 5.1.2600.196608 (Win32NT)
    Common Language Runtime     : 2.0.50727.3082
    System.Deployment.dll       : 2.0.50727.3053 (netfxsp.050727-3000)
    mscorwks.dll            : 2.0.50727.3082 (QFE.050727-3000)
    dfdll.dll           : 2.0.50727.3053 (netfxsp.050727-3000)
    dfshim.dll          : 2.0.50727.3053 (netfxsp.050727-3000)

SOURCES
    Deployment url          : file:///C:/Documents%20and%20Settings/<username>/Start%20Menu/Programs/<programname>/<programname>.appref-ms%7C

ERROR SUMMARY
    Below is a summary of the errors, details of these errors are listed later in the log.
    * Activation of \NDP13CDocuments and Settings<username>Start MenuPrograms<programname><programname>.appref-ms| resulted in exception. Following failure messages were detected:
        + Value does not fall within the expected range.

COMPONENT STORE TRANSACTION FAILURE SUMMARY
    No transaction error was detected.

WARNINGS
    There were no warnings during this operation.

OPERATION PROGRESS STATUS
    * [7/22/2009 10:35:30 AM] : Activation of \NDP13CDocuments and Settings<username>Start MenuPrograms<programname><programname>.appref-ms| has started.

ERROR DETAILS
    Following errors were detected during this operation.
    * [7/22/2009 10:35:30 AM] System.ArgumentException
        - Value does not fall within the expected range.
        - Source: System.Deployment
        - Stack trace:
            at System.Deployment.Internal.Isolation.IsolationInterop.GetUserStore(UInt32 Flags, IntPtr hToken, Guid& riid)
            at System.Deployment.Internal.Isolation.IsolationInterop.GetUserStore()
            at System.Deployment.Application.ComponentStore..ctor(ComponentStoreType storeType, SubscriptionStore subStore)
            at System.Deployment.Application.SubscriptionStore..ctor(String deployPath, String tempPath, ComponentStoreType storeType)
            at System.Deployment.Application.SubscriptionStore.get_CurrentUser()
            at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut, String textualSubId, String deploymentProviderUrlFromExtension, BrowserSettings browserSettings, String& errorPageUrl)
            at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state)

COMPONENT STORE TRANSACTION DETAILS
    No transaction information is available. 

4b9b3361

Ответ 1

Проблема таинственно исчезла после многократного удаления этой папки и попытки переустановки. Возможно, там тоже была перезагрузка.

Ответ 2

Вы можете попробовать следующее:

rundll32 %windir%system32dfshim.dll CleanOnlineAppCache

Ответ 3

Я отключил приложение из панели управления, а затем снова установил, исправил проблему для меня.

Ответ 4

Я также столкнулся с этой ошибкой на компьютере с Windows 7 x64. Наконец, я смог правильно установить приложение ClickOnce, полностью удалив любые ссылки в реестре (но этого было недостаточно), а затем очистил %user%AppDataLocalApps.

Ответ 5

Я понимаю, что это старый вопрос, но я наткнулся на ту же проблему и нашел другое решение: причина была «&». в пути установки сети ClickOnce. Microsoft подтвердила эту проблему и заявила, что не исправит ее: Отчет об ошибке Microsoft

Ответ 6

Простые этапы:

1) удалить с панели управления

2) удалите папку "2.0", расположенную в %user%AppDataLocalApps.
Теперь вы можете переустановить

Ответ 7

После нескольких часов устранения этой ошибки я обнаружил, что в моем случае это было потому, что я пытался запустить установщик с подключенного сетевого диска вместо UNC-пути. При первом запуске установщика он работает нормально. Но если вы запустите его снова, вы получите следующую ошибку:

Не удается запустить приложение

При просмотре сведений об ошибках вы обнаружите очень неоднозначную ошибку:

введите описание изображения здесь

Если я вместо этого запускаю приложение из UNC-пути \MyServerMyShareDeploy... Затем он работает просто отлично, последовательно.

При дальнейших исследованиях, похоже, что здесь происходит то, что установщик проверяет (по соображениям безопасности), что он выполняется с авторизированного URL-адреса развертывания, как указано в манифесте развертывания *.application.

введите описание изображения здесь

Поскольку текущий путь (сопоставленный диск) отличается от пути UNC, установка завершается с ошибкой, и программа удаляется. Обратите внимание на разницу между путями в журнале ошибок:

введите описание изображения здесь

То, что на самом деле означает ошибка, — «Внимание! Приложение невозможно установить, поскольку URL-адрес развертывания не соответствует URL-адресу поставщика, указанному в манифесте развертывания».

Хорошо, это спасло бы меня много часов устранения неполадок!!:-)

Ответ 8

Я решил свое исключение

System.ArgumentException
    - Value does not fall within the expected range.
    - Source: System.Deployment

Проверьте, имеет ли ссылка Copy Local= true. Например, моя проблема заключалась в ссылке Office на true. Когда он попытался скопировать его, возник конфликт, поэтому он не смог открыть программу. Надеюсь, это решает вашу проблему.

Ответ 9

Я некоторое время искал чистое решение этой проблемы. Я мог бы исправить это несколько раз проб и ошибок. Наконец, я смог придумать точный вопрос. Я думал поделиться этим здесь.

Над ошибкой указано, что он не может найти соответствующий файл в папке развертывания.

Если вы столкнулись с этой проблемой для проверки обновлений ниже.

  • Загрузите файл application.exe.manifest из развертывания, которое
    работать.
  • Сравнить текущую версию файла application.exe.manifest   со старым.
  • Посмотрите, какая ссылка добавлена ​​/удалена/изменена. если   вы видите что-нибудь подозрительное, вручную отредактируйте/откат, что часть   манифест и попытка, в большинстве случаев он будет работать.

Если новая загрузка

Убедитесь, что у вас есть все сборки, помеченные как ‘copy local = true’, полученные в папке развертывания, также проверяйте его размер после загрузки.

потому что сборка copy local = false ‘ будет рассматриваться как предварительные условия в движке clickonce. Большая часть проблемы запуска приложения начинается оттуда.

Ответ 10

Удалено все в %user%AppDataLocalApps2.0, и оно сработало.

Ответ 11

Любопытно, что у меня была такая же проблема, и она была решена путем простого входа в систему как другого пользователя и установки/запуска приложения. Когда я вышел из системы, а затем вошел в систему как оригинальный пользователь, все это снова работало.

Ответ 12

Моя проблема вызвана изменением файла csproj.
ссылка на сборку была изменена с:

HintPath > ..Files

к

HintPath > .. .. Files

который добавил элемент XML файла зависимости в файле манифеста.

редактирование файла csproj и публикация, исправлен файл манифеста.

Ответ 13

Мы много раз сталкивались с этой ошибкой, но сегодня она остановила все и вызвала у нас огромные проблемы. Я не мог понять это. Я открыл критический случай поддержки с Microsoft, и во время нашего первого телефонного звонка, прочитав журнал ошибок, я понял это.

Мое решение имеет несколько проектов. Наша основная программа одна, а затем есть общая DLL. Я изменил ссылку в общей dll для Excel (Microsoft.Office.Interop.Excel) с версии 12 и обновил до v15 из-за других проблем с отладкой и совместимостью фреймворка. Затем я вышел после выполнения некоторой работы.

Что я заметил после релиза, так это то, что я не обновил dll Excel и в своем основном проекте, так как в нем также есть несколько ссылок на него. Хорошо, даже после того, как я обновил это до v15, проблема все еще существовала. Это когда я позвонил в Microsoft.

После нашего первого телефонного звонка я заметил пару строк в журнале ошибок при сбое запуска приложения.

* [3/12/2018 2:10:57 PM] : Detecting dependent assembly Microsoft.Vbe.Interop, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71E9BCE111E9429C, processorArchitecture=msil using Microsoft.Vbe.Interop, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c, processorArchitecture=msil.
* [3/12/2018 2:10:57 PM] : Detecting dependent assembly office, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71E9BCE111E9429C using office, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c.
* [3/12/2018 2:10:57 PM] : Detecting dependent assembly office, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71E9BCE111E9429C, processorArchitecture=msil using office, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c, processorArchitecture=msil.

Заметьте, как средняя линия показывает версию 12.0.0.0? Ну, я был смущен. Поэтому я начал искать любые другие офисные ссылки. Я обнаружил, что наша основная программа ссылается только на Office.dll и Interop.Word dll. Я удалил их и прочитал ссылку на Word Interop DLL v15, а затем снова выпустил приложение.

Это все еще не работало, но как только я удалил приложение, затем переустановил, все было хорошо. Люди, которые еще не обновились, не имели проблем с обновлением, как только я исправил проблему. Люди, которые пытались обновить, должны были удалить и переустановить.

К счастью, Microsoft закрыла дело без каких-либо обвинений :)

Надеюсь, это поможет кому-то еще.

Ответ 14

У меня был клиент, устанавливающий наш VSTO addin MSI, и мы видели это.

System.ArgumentException: значение не попадает в ожидаемый диапазон. в System.Deployment.Internal.Isolation.IsolationInterop.GetUserStore (флаги UInt32, IntPtr hToken, Guid & riid)

После проверки их журналов событий мне стало ясно, что у них возникли проблемы с их профилем пользователя. Они восстановили свой профиль пользователя, и это решило проблему.

Ответ 15

Я попробовал простую конфигурацию. Перейдите в проект → свойства → приложение ->

отметьте значок и основной файл, выберите значок рядом с параметром встроить манифест с конфигурацией по умолчанию

удачи


Go to SubnauticaNitrox


«Value does not fall within the expected range» error while trying to run a server

Console error:

Value does not fall within the expected range.

System.ArgumentException: Value does not fall within the expected range.

at NitroxServer_Subnautica.Serialization.Resources.ResourceAssets.ValidateMembers(ResourceAssets resourceAssets) in NitroxServer-SubnauticaSerializationResourcesResourceAssets.cs:line 21

at NitroxServer_Subnautica.Serialization.Resources.ResourceAssetsParser.Parse() in NitroxServer-SubnauticaSerializationResourcesResourceAssetsParser.cs:line 54

at NitroxServer_Subnautica.SubnauticaServerAutoFacRegistrar.RegisterDependencies(ContainerBuilder containerBuilder) in NitroxServer-SubnauticaSubnauticaServerAutoFacRegistrar.cs:line 34

at NitroxModel.Core.NitroxServiceLocator.InitializeDependencyContainer(IAutoFacRegistrar[] registrars) in NitroxModelCoreNitroxServiceLocator.cs:line 21

at NitroxServer_Subnautica.Program.<StartServer>d__4.MoveNext() in NitroxServer-SubnauticaProgram.cs:line 86

— End of stack trace from previous location where exception was thrown —

at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()

at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)

at NitroxServer_Subnautica.Program.<Main>d__3.MoveNext() in NitroxServer-SubnauticaProgram.cs:line 41

— End of stack trace from previous location where exception was thrown —

at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()

at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)

at NitroxServer_Subnautica.Program.<Main>(String[] args)

There were no solutions to it while I tried to search on the internet. Please help.

No I am not in any beta program.

The question is rather unspecific so it’s of course difficult to get on the right track here. All of the given answers focus different issues. I would say that PeterX had the best guess. The reason for the error could be as simple as a modified data source.

I came across with a bug «error output has no corresponding output» quite often when adding a new column to a table that needs to be processed by an existing SSIS package. This bug came along with an error message saying that a «Value does not fall within the expected range».

A newly added column needed to be processed by an existing SSIS Package. The expected behavior is that SSIS will recognize that there is a new column and select this column on the columns page of the OLEDB Source Task SSIS to be processed. However, when opening the OLEDB Source Task for the first time after having modified the table I got twice the following error message: «Value does not fall within the expected range.» The error message showed up when opening the editor and when opening the Columns page of the editor. Within the Advanced Editor of the OLEDB Source Task the new column showed up in the OLEDB Source Output Columns Tree, but not in the OLEDB Source Error Output Columns Tree. This is the actual underlying problem of the error message. Unfortunately, there seems to be no way to add the missing column manually.

To solve the problem, remove and re-add the newly added column on the Columns Page of the normal Editor as mentioned by Jeff.

It is worth to be mentioned that the data source of the OLEDB Source task was a modified MDS View. Microsoft CRM Dynamics – as mentioned in the related thread – is using views, too. That leads me to the conclusion, that using views as a data source may produce either of the above mentioned errors, when modifying datatypes or adding/removing columns.

Related Thread: Error» …The OLE DB Source.Outputs[OLE DB Source Output].Columns[XXXXXXXX] on the non-error output has no corresponding output

The described workaround refers to Visual Studio 2008 Version 9.0.30729.4462 QFE with Mircorsoft.NET Framework 3.5 SP1. The database is SQL Server 2008 R2 (SP2).

Suddenly I am getting this error «Value does not fall within the expected range» whenever I try to add a reference to any project. This also happens with a new blank project. It can list the current references fine.

I rebooted the computer. I am not sure if the recent Update 2 caused this. This is my first add reference since the update. I am using Visual Studio 2013 on Windows 7 64bit.

Any ideas?

enter image description here

Aristos's user avatar

Aristos

65.5k16 gold badges117 silver badges150 bronze badges

asked May 28, 2014 at 1:32

Tony_Henrich's user avatar

Tony_HenrichTony_Henrich

41.4k72 gold badges229 silver badges369 bronze badges

1

I did a ‘devenv /setup’ and that fixed it.

Detail

  • Exit Visual Studio
  • Click Start
  • Type cmd, right click Command Prompt and select Run as administrator
  • Navigate to the appropriate Visual Studio folder
    VS2012: pushd %programfiles(x86)%Microsoft Visual Studio 12.0Common7IDE
    VS2015: pushd %programfiles(x86)%Microsoft Visual Studio 14.0Common7IDE

    VS2017: pushd %programfiles(x86)%Microsoft Visual Studio2017<Edition>Common7IDE

    VS2019: pushd %programfiles(x86)%Microsoft Visual Studio2019<Edition>Common7IDE

  • Type devenv /setup and press enter

  • When the command prompt returns, you’re done. Close the command window, reopen Visual Studio, and test to see if the error’s resolved.

More Information

https://msdn.microsoft.com/en-us/library/ex6a2fad.aspx

answered May 28, 2014 at 1:40

Tony_Henrich's user avatar

Tony_HenrichTony_Henrich

41.4k72 gold badges229 silver badges369 bronze badges

14

In my case deleting .suo file in .vs[solutionName] folder fixed the problem in Visual Studio 2022

answered Aug 9, 2022 at 5:43

Elvin Mammadov's user avatar

Elvin MammadovElvin Mammadov

23.7k10 gold badges39 silver badges81 bronze badges

5

In my case, project was set to use local IIS (when the project set up to use local IIS but the app does not deployed there, it cannot load project but states clearly in the error message. However this time I was keep getting Value does not fall within the expected range with any other info.

Only «solution» worked for me was:

  • Edit csproj file
  • Set <UseIISExpress> to true
  • Set <UseIIS> to false
  • Then reload the project.

(after that you can set your local IIS again)

Synesthetic Symphony's user avatar

answered Feb 21, 2020 at 14:31

curiousBoy's user avatar

0

Some projects (e.g. some web services) require that Visual Studio be run as an administrator. After a Visual Studio upgrade, I hadn’t noticed that it was no longer being started with elevated privileges automatically. When I corrected this, all the projects in the solution loaded.

answered Oct 10, 2019 at 11:21

Graham Laight's user avatar

Graham LaightGraham Laight

4,5803 gold badges29 silver badges28 bronze badges

1

I have tried to delete the .vs hidden folder placed in the same solution directly and it works for me try this it’s straightforward to fix this issue.
thanks.

answered Aug 26, 2022 at 6:46

Masood Subhani's user avatar

3

In my case, this was because I needed a specific version of the .NET Core SDK installed.

Once I got it downloaded and installed, the projects loaded fine. Unfortunately there was no additional information in the Output tab hinting at this.

answered Oct 9, 2019 at 21:39

emragins's user avatar

emraginsemragins

4,3512 gold badges33 silver badges48 bronze badges

1

In my case the file name inside the Solution .sln was wrong (not exist on disk).

I open the solution file MyFullsolution.sln using a text editor and check the Project load files and found that the project ProjectFile.csproj that fails to load was typed wrong.

How that happens ? Because I rename it from the solution some day, but I use the same ProjectFile.csproj again on a different solution! and I rename it in one solution, but the other just didn’t know it… and get the same message (that actual not help at all).

So was my mistake the file rename from the other solution.

answered Sep 20, 2020 at 19:49

Aristos's user avatar

AristosAristos

65.5k16 gold badges117 silver badges150 bronze badges

In my case it was simple, if the file is open and then I run it, it will run. If the file is closed and then I run it by right clicking from the «Solution Explorer», then it throws the error you mentioned.
So, simple steps:
In the Solution Explorer,

  1. Double click on the file and open it
  2. Right click on the file and select «Start with Debugging» or «Start without Debugging»

answered Jul 18, 2019 at 13:59

calvin's user avatar

calvincalvin

1531 silver badge9 bronze badges

I also got the same error with «web» tab missing from project properties, for those having this issue can try changing the target framework of the project.When I changed target framework from 4.6.2 to 4.7.2, the web tab appeared again.

answered Aug 19, 2019 at 5:08

Bhawna Jain's user avatar

I have seen this box in VS-2019 16.5.4 in a Winforms/4.8 app with Std classlibs, on attempting to close one of the Winforms/4.8 source file tabs. The message came up, the tab refused to close.

Solved it by closing an re-opening the Solution.

answered Jun 15, 2020 at 12:03

Goodies's user avatar

GoodiesGoodies

1,87121 silver badges25 bronze badges

I just had the same, it was only one file which casing this issue, When I read the solution above I was worried to fix all visual studio because one .cs file so I tried to right click on the (TAB header) beside the (X) button which closes this and click on (Close All documents)…

it worked : )

answered Jun 25, 2020 at 11:06

Khaleel Hmoz's user avatar

Khaleel HmozKhaleel Hmoz

9592 gold badges13 silver badges24 bronze badges

Kind of a dumb oversight on my part.. but depending on the action that had caused it, you may want to check your console output as well. In my case it was a project that would not load. While there were no explicit errors, the consol window indicated that a file was missing based on a directive from the csproj.

ECommerceProdEcommerceUtilityECommerceCommandsECommerceCommands.csproj
: error : The imported project «C:Program Files
(x86)MSBuildExtensionPack4.0MSBuild.ExtensionPack.tasks» was not
found.

Confirm that the expression in the Import declaration «C:Program
Files (x86)MSBuildExtensionPack4.0MSBuild.ExtensionPack.tasks» is
correct, and that the file exists on disk.

answered Feb 23, 2021 at 17:05

Bonez024's user avatar

Bonez024Bonez024

1,3301 gold badge13 silver badges21 bronze badges

I tried the solution described by Tony_Henrich, as it seemed helpful.
However in my case, I’m building off a USB drive which is encrypted with BitLocker.
I find that the *.c module I want to look at throws this error if I try to force open it with the C++ editor in VS2019 (I’m updating to 16.10.2, so whatever was just before that rev).
Visual Studio was not opening a *.c module in the editor but popping it up in Notepad. If I FORCED it to use Visual Studio C++ editor I got the «Value does not fall» message.

The file is part of a build tree in a repo I’m not responsible for, and it’s not building, so at the moment I suspect Bitlocker/USB disk corruption is somehow giving Visual Studio some fits.

Tortoise-GIT Blame tool shows different/valid source code and Notepad shows a chunk missing.

My fix was to delete the file from the workspace and try seeing if GIT could restore a valid copy from the repository, and this worked. Now clicking on the *.c module in Windows Explorer and requesting to open it, no longer brings up Notepad, the file opens in Visual Studio.

answered Jun 21, 2021 at 15:38

Ross Youngblood's user avatar

Ross YoungbloodRoss Youngblood

4621 gold badge3 silver badges15 bronze badges

Setting up the dev environment for an existing project on a new server: Windows Server 2022, Visual Studio 2022, IPv6 enabled, IIS6 compatibility features installed, public IP address, domain name, web server certificate. The web application does not load. Creating the web application by hand in IIS Manager doesn’t help.

Message box:

Value does not fall within the expected range

Output from: Solution:

error: The Web Application Project webapp is configured to
use IIS. The Web server ‘http://localhost/webapp’ could not be found.

The webapp.csproj file contains:

<IISUrl>http://localhost/webapp</IISUrl>

The project loaded after changing the protocol and the name of the server to match the certificate:

<IISUrl>https://my.domain.com/webapp</IISUrl>

answered Mar 22, 2022 at 2:39

Tom Andraszek's user avatar

Tom AndraszekTom Andraszek

1,6761 gold badge22 silver badges29 bronze badges

  • Remove From My Forums
  • Question

  • i get the error while fetching few fields from list.

    it only occurs with 1 field which is a lookup from another list.

    i have many more fields which are lookups from other tables, but they donot throw error.

    any idea why the error is comming? i have checked the list name, field name and everything is proper.

    is it related with permissions, because for certain group of users it works without throwing this error.

    Description:
    An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.ArgumentException: Value does not fall within the expected range.

Answers

  • You say have other lookupvalues. How many lookupvalues are you having in your operation?

    The List View Lookup Threshold specify the maximum number of Lookup, Person/Group or Workflow status fields that a database query can involve at one time. The list view lookup threshold is default set to 8. Admin users are not restricted by this threshold.
    I think this is your problem.

    You can change this CA -> Web Application Management -> mark your web application -> General Settings -> Resource Throttling.

    Please let me know if this works

    • Marked as answer by

      Saturday, August 6, 2011 6:06 AM

  • You are getting a build error because you do not have a reference to the System.Linq namespace.

    I think the problem is caused by throttling. You are not allowed to invlove more than default 8 lookups in a query. This rule do not apply if you execute the query as an admin (app.pool account). I assmue your employee list contains more than 8 lookup values.
    You could restrict the returned field by setting SPQuery.ViewFields.

    You are welcome. I am glad it now works.

    • Marked as answer by
      Nachiket Kamat
      Friday, June 10, 2011 12:05 PM

IIS applications run on application pools. Application pools receive requests and process them based on the settings defined. One of the settings is application pool identity. This is the account that runs application pool and perform required tasks. You may come across to this error message while trying to set a custom account as application pool identity: “Value does not fall within the expected range.

This error occurs only if you are specifying a custom account and not using any predefined accounts such as ApplicationPoolIdentity or NetworkService.

The exact error message:

There was an error while performing this operation. Details: Value does not fall within the expected range.

"Value does not fall within the expected range" issue

The username and password fields of the custom application pool identity window in IIS Manager has only basic validations such as empty field check, password match check, local user check (no check for domain users). Therefore, “Value does not fall within the expected range” issue is not always a good clue to lead to the solution.

It is likely that there is something simple but easy to miss (a formatting issue in the config files etc.) is causing this issue. I would recommend taking the actions below first:

  1. Check the application pool identities in the applicationHost.config file (C:WindowsSystem32inetsrvConfig) for any syntax issues
  2. Try to obtain a clean copy of applicationHost.config and replace it with the current one
  3. Restart Windows Process Activation Service (Reference)
  4. Close and reopen IIS Manager
net stop was /y
net start w3svc

If this doesn’t work:

  • Create a new application pool and try set its application pool identity
  • Try to open IIS Manager as a local or domain administrator if you are not already
  • Check Event Viewer for more details of the error message

If you see Event ID 5021, 5057 or 5059, check out this post for possible solutions: HTTP 503 Service Unavailable (Application pool has been disabled)

This evening, we kept receiving the Error «Value does not fall within the expected range» when trying to configure a custom identify for an IIS Application Pool. In this case, it was IIS 8 on Server 2012 R2 but we’ve also seen issues posted for Version 7.

For those who don’t want or have time to follow my journey, head on down to the end to «The Answer».

We knew the issue wasn’t something we entered: a bad credential rendered an error, and a bad username did the same. So at runtime, everything was great. It was something to do with trying to save the setting.

Event logs, ho!

To figure out how to resolve this, we went into the event viewer. There was nothing in the Application log, so we headed down to Applications and Services Logs => Microsoft => Windows => IIS-Configuration. The logs in here are disabled by default, so they have
to be enabled. (To do so, right-click the log, and choose Enable Log.) Once enabled, re-run the attempt to set the identity, and refresh the view (Actions pane or F5), and now we have some more information on the error. In the results were two Errors (event
ID 42 and 43). 

ID 42: Failed to initialize the ‘IISWASOnlyAesProvider’ encryption provider in ‘?C:windowssystem32inetsrvconfigapplicationHost.config’. Please check your configuration.

ID 43: Failed to encrypt attribute ‘Microsoft.ApplicationHost.AesProtectedConfigurationProvider’.

Now we know the issue identified with ID 42 was the cause of the issue identified in 43. The IISWASOnlyAesProvider encryption provider’s inability to load was the root cause of the inability to encrypt. Since it mentioned the
applicationHost.config file, let’s take a look at it.

We tried renaming [Note: Rename, not delete] the config file, and restarting IIS, but that didn’t work:

C:>net stop was /y

The following services are dependent on the Windows Process Activation Service s

ervice.

Stopping the Windows Process Activation Service service will also stop these ser

vices.

   World Wide Web Publishing Service

The World Wide Web Publishing Service service is stopping.

The World Wide Web Publishing Service service was stopped successfully.

The Windows Process Activation Service service is stopping.

The Windows Process Activation Service service was stopped successfully.

C:>net start w3svc

System error
1068 has occurred.

The dependency service or group failed to start.


The Answer

Luckily, we were able to obtain a clean configuration file. We replace the applicationHost.config file (C:windowssystem32inetsrvconfigapplicationHost.config), and restarted services again:

net stop was /y

net start w3svc


After that, we were able to successfully make the changes.

We have tried to find the offending setting, but so far have not had any luck. Hopefully knowing that you can swap out the applicationHost.config file will help you out.

Lessons Learned

  • Always keep a clean copy of this file on hand
  • Ensure the file is always backed up

I am getting similar error, maybe this stacktrace is of help.

ArgumentException
   在 Microsoft.Web.WebView2.Core.Raw.ICoreWebView2Controller.MoveFocus(COREWEBVIEW2_MOVE_FOCUS_REASON reason)
   在 Microsoft.Web.WebView2.Core.CoreWebView2Controller.MoveFocus(CoreWebView2MoveFocusReason reason)
   在 System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   在 System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
   在 System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   在 System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
   在 System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
   在 System.Windows.Input.InputManager.ProcessStagingArea()
   在 System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
   在 System.Windows.Input.KeyboardDevice.ChangeFocus(DependencyObject focus, Int32 timestamp)
   在 System.Windows.Input.KeyboardDevice.TryChangeFocus(DependencyObject newFocus, IKeyboardInputProvider keyboardInputProvider, Boolean askOld, Boolean askNew, Boolean forceToNullIfFailed)
   在 System.Windows.Input.KeyboardDevice.Focus(DependencyObject focus, Boolean askOld, Boolean askNew, Boolean forceToNullIfFailed)
   在 System.Windows.Input.KeyboardDevice.Focus(IInputElement element)
   在 System.Windows.UIElement.Focus()
   在 System.Windows.FrameworkElement.OnPreviewGotKeyboardFocus(Object sender, KeyboardFocusChangedEventArgs e)
   在 System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   在 System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
   在 System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   在 System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
   在 System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
   在 System.Windows.Input.InputManager.ProcessStagingArea()
   在 System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
   在 System.Windows.Input.KeyboardDevice.TryChangeFocus(DependencyObject newFocus, IKeyboardInputProvider keyboardInputProvider, Boolean askOld, Boolean askNew, Boolean forceToNullIfFailed)
   在 System.Windows.Input.KeyboardDevice.Focus(DependencyObject focus, Boolean askOld, Boolean askNew, Boolean forceToNullIfFailed)
   在 System.Windows.Input.KeyboardDevice.Focus(IInputElement element)
   在 System.Windows.Interop.HwndKeyboardInputProvider.OnSetFocus(IntPtr hwnd)
   在 System.Windows.Interop.HwndKeyboardInputProvider.FilterMessage(IntPtr hwnd, WindowMessage message, IntPtr wParam, IntPtr lParam, Boolean& handled)
   在 System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   在 MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   在 MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
   在 System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   在 System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

Problem: SharePoint site gave “System.ArgumentException: Value does not fall within the expected range” error!

Here are some possible root causes and solutions:

Case 1: While fetching List item Lookup values programmatically

Root cause: List view threshold value exceeded! This occurs due to the throttling limit on the list view lookup threshold value under web application settings. Try increasing it.

  • Go to Central Administration >> Application Management >> Manage web applications
  • Select your web application, click on General Settings >> Resource Throttling from the ribbon
  • Enter the value for List View Lookup Threshold. E.g. 36 Fix "Value does not fall within the expected range" Error in SharePoint

PowerShell script to increase list view lookup threshold value.

Add-PSSnapin Microsoft.SharePoint.PowerShell -ErrorAction SilentlyContinue

$WebApp = Get-SPWebApplication "https://sharepoint.crescent.com/"

#Set List View Lookup Threshold  
$WebApp.MaxQueryLookupFields = 36
$WebApp.Update()

Case 2: Invalid Field Names

When fetching fields, use internal field names or check whether the particular field exists before getting its value. E.g., use item.Fields.ContainsField(“Title”) before fetching or updating a specific field. So, if you got this error after activating a feature or deploying a solution, the culprit is your recent feature/solution!

Case 3: During Check-In under SharePoint Document Library

Got this error while checking in a document? Well, the solution is simple – Do not set the required field property to true on your content types!

Salaudeen Rajack

Salaudeen Rajack — SharePoint Expert with Two decades of SharePoint Experience. Love to Share my knowledge and experience with the SharePoint community, through real-time articles!

ОБНОВЛЕНИЕ: Оставил анонимный плакат большой комментарий о внутренних имен. Будьте уверены прочитать его.

При работе с приемниками событий и другой код, ссылающийся на элементы списка SharePoint через объектную модель, Я часто делают ошибки, которые создают эту ошибку во время выполнения:

Ошибка при загрузке и запуске приемника событий Conchango.xyzzyEventReceiver в xyzzy, Версия = 1.0.0.0, Культура = нейтральных, PublicKeyToken = 0dc50a750396c3ac. Дополнительная информация приведена ниже. : Значение не попадает в ожидаемый диапазон.

Я думаю, что это довольно общая ошибка, которая потенциально вызывается множество различных способов. Однако, один простое объяснение в том, что я неправильно ссылки поля. Если имя поля «Срок», Я должен ссылаться на него как это в приемник событий:

Свойства.ListItem[«Срок»]

Когда я неправильно или использовать неверный регистр при ссылке на поле, SharePoint генерирует выше упомянутые ошибки во время выполнения. Например, Это неправильно:

Свойства.ListItem[«Срок»]

</конец>

Подписаться на мой блог.

I am getting the error on the following line for a timer job:

if (listItem["Department"] != null)

Normally this error indicates that it cannot find the field, but there are no spaces and the field label name and strong name are the same. Furthermore, if I write it like this:

if (listItem.Fields["Department"] != null)

I no longer get the error.

The problem is I am trying to call TaxonomyFieldValueCollection on the object and cannot call it by Fields. Is there some nuanced difference between the two that I’m missing that’s causing this error?

EDIT: I figured out the problem. I had set
query.ViewFieldsOnly = true;
and «Department» was a new field and was not set in the ViewFields, so as far as the timer job could tell the field didn’t exist. I simply needed to add the field into the list of fields in ViewField.

asked Jan 28, 2013 at 16:43

user11457's user avatar

user11457user11457

5012 gold badges5 silver badges17 bronze badges

2

I figured out the problem. I had set query.ViewFieldsOnly = true; and «Department» was a new field and was not set in the ViewFields, so as far as the timer job could tell the field didn’t exist. I simply needed to add the field into the list of fields in ViewField.

answered Feb 12, 2013 at 18:58

user11457's user avatar

user11457user11457

5012 gold badges5 silver badges17 bronze badges

1

The first line checks if the value of the data in the column «Department» is null for that specific list item.

The second line checks if the SPField object «Department» is null.

If the SPField exists on the list, it should never be null, but the data stored in that field for a specific list item may be.

answered Jan 28, 2013 at 16:50

RJ Cuthbertson's user avatar

RJ CuthbertsonRJ Cuthbertson

8,3326 gold badges36 silver badges76 bronze badges

2

This error System.ArgumentException: Value does not fall within the expected range with exception message Microsoft.SharePoint.SPFieldMap.GetColumnNumber(String strFieldName, Boolean bThrow) is due to throttling limit set at List View Lookup Threshold settings in WebApplication.

To resolve this error, Open the SharePoint Central Administration site and click “Manage Web Application” link located under Application Management Group. Select the web application that has the problem. Select the “Resource Throttling” link under the “General Settings”

Navigate to List View Lookup Threshold section and change the value to a higher value depending on the count of Lookup, Person/Group, or workflow status field available in the list that caused the issue.

answered Dec 9, 2015 at 14:31

EK Ibrahim Akode's user avatar

1

Понравилась статья? Поделить с друзьями:
  • Как найти массовые проценты
  • Как составить иск в суд по лишению родительских прав
  • Как найти дубликатов в экселе
  • Как найти фоновую программу на андроид
  • Как найти админку joomla