.NET MAUI: The type or namespace name ‚Resources‘ does not exist …

This error causes me problems regularly. Example:

I use the LocalizationResourceManager.Maui NuGet package to make my app multilingual. I therefore add a folder „Translations“ and in this some resx resource files. When I want to set up the LocalizationResourceManager in the MauiProgram.cs file, it tells me, that it can not find the Translations folder, if I start to type

using Name_of_my_Project.Resources...

it wont even recognize the Resources folder.

Look into your csproj file: VS may have created such lines:

<ItemGroup>
<Compile Remove="Resources\Translations\AppTranslations.Designer.cs" />
<Compile Remove="Resources\Translations\AppTranslations.de.Designer.cs" />
</ItemGroup>

Delete the complete ItemGroup, this will solve the problem.