1
votes

I see this warning in the DevOps build log file.

I don't get a warning when I build on my own computer.

C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Roslyn\csc.exe /noconfig /nowarn:1701,1702 /nostdlib+ /errorreport:prompt /warn:4 /define:TRACE /highentropyva+ /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.6.1\mscorlib.dll" /reference:d:\a\1\s\Common\bin\Release\SBD.Common.dll /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.6.1\System.Core.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.6.1\System.Data.DataSetExtensions.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.6.1\System.Data.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.6.1\System.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.6.1\System.Drawing.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.6.1\System.ServiceModel.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.6.1\System.Windows.Forms.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.6.1\System.Xml.dll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.6.1\System.Xml.Linq.dll" /debug:pdbonly /filealign:512 /optimize+ /out:obj\Release\SBD.Common.WinForms.dll /ruleset:"C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Team Tools\Static Analysis Tools\Rule Sets\MinimumRecommendedRules.ruleset" /subsystemversion:6.00 /resource:obj\Release\SBD.Common.WinForms.AboutDialogBase.resources /resource:obj\Release\SBD.Common.WinForms.DatabaseConnectDialog.resources /resource:AboutIcon.ico,SBD.Common.WinForms.AboutIcon.ico /resource:AboutTemplate.rtf,SBD.Common.WinForms.AboutTemplate.rtf /target:library /utf8output AboutDialogBase.cs AboutDialogBase.Designer.cs AuthenticateResult.cs CredentialsDialog.cs CREDUI.cs DatabaseConnectDialog.cs DatabaseConnectDialog.Designer.cs FileBasedResourceManager.cs FileBasedResourceSet.cs FormUtils.cs MessagePop.cs Properties\AssemblyInfo.cs "C:\Users\VssAdministrator\AppData\Local\Temp.NETFramework,Version=v4.6.1.AssemblyAttributes.cs" Using shared compilation with compiler from directory: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Roslyn ##[warning]Common.WinForms\FileBasedResourceManager.cs(72,62): Warning CS0618: 'ResourceManager.ResourceSets' is obsolete: 'call InternalGetResourceSet instead'

The project has the following files

1
Do you use Hosted agent ot Private agent?Shayki Abramczyk
I am using the VS2017 hosted agentKirsten Greed
What is your target framework of your project?Joy
I experienced the problem using 4.6.1 and then switched to 4.5.2 but that did not help.Kirsten Greed
@KirstenGreed, AFAIK, ResourceSets is obsolete in .net 4.0, so switch to 4.5.2 will not resolve this warning. Clear this warning, you may need to switch 3.5 and below. Why not try to the suggestion using call InternalGetResourceSet? social.msdn.microsoft.com/Forums/vstudio/en-US/…Leo Liu-MSFT

1 Answers

2
votes

warning CS0618: 'ResourceManager.ResourceSets' is obsolete: 'call InternalGetResourceSet instead'

AFAIK, ResourceSets was obsoleted in .net 4.0, so switch to 4.5.2 will not resolve this warning. Clear this warning, you may need to switch .net 3.5 and below.

Besides, you can try the suggestion in the log, using call InternalGetResourceSet instead. Check the thread for some more details.

Hope this helps.