中文提示 : 连接数据库过程中发生错误,检查服务器是否正常连接字符串是否正确,错误信息:Only the invariant culture is supported in globalization-invariant mode. See https://aka.ms/GlobalizationInvariantMode for more information. (Parameter 'name') en-us is an invalid culture identifier.DbType="SqlServer";ConfigId="". English Message : Connection open error . Only the invariant culture is supported in globalization-invariant mode. See https://aka.ms/GlobalizationInvariantMode for more information. (Parameter 'name') en-us is an invalid culture identifier.DbType="SqlServer";ConfigId=""
此异常可这样处理: 参考:https://blog.csdn.net/lihuxie/article/details/134795017
<PropertyGroup> <TargetFramework>net8.0</TargetFramework> <Nullable>enable</Nullable> <ImplicitUsings>enable</ImplicitUsings> <InvariantGlobalization>false</InvariantGlobalization> </PropertyGroup>
将项目文件中,如上面的红字部分从 true 改成 false 即可解决。
标签:Core,en,false,C#,culture,https,invariant,net From: https://www.cnblogs.com/z5337/p/17962319