I've changed our existing .NET Framework (4.6.2) projects to target .NET 5. We have a number of c# libraries that are referenced by a C++/CLI library. When I attempt to compile the C++/CLI library I get the following error
1> XComFileSystem.cpp(77,68): error C2668: 'System::IO::StreamReader::StreamReader': ambiguous call to overloaded function
1> XComFileSystem.cpp(77): message : could be 'System::IO::StreamReader::StreamReader(System::IO::Stream ^,System::Text::Encoding ^,bool,int,bool)'
1> XComFileSystem.cpp(77): message : or 'System::IO::StreamReader::StreamReader(System::IO::Stream ^)'
1> XComFileSystem.cpp(77,68): message : while trying to match the argument list '(System::IO::Stream ^)'
Here's my code...
System::IO::Stream^ sss;
StreamReader^ lobFileReader = gcnew StreamReader( sss );
Can anyone suggest how I can get passed this error ?
Thanks