#include "pch.h" #include "ClassLibrary1.h" using namespace ClassLibrary1; void Class1::ThrowMessage() { try { throw std::exception("Throw message"); //SEHException message occurred! } catch (const std::exception& exc) { throw gcnew System::Exception(msclr::interop::marshal_as<System::String^>(exc.what())); } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)