Issues with inline const System::String

31 Views Asked by At
namespace Globals
{
    using namespace System;
    public ref class GlobalClass
    {
    public: 
        inline static const String^ File_Path = "Database.xml";
    };
}

I am using Visual Studio 2022. After creating this in a header file, I get this error for inline:

a nonstatic data member cannot be declared as inline

I googled but couldn't find anything specific.

0

There are 0 best solutions below