This discussion has been locked.
You can no longer post new replies to this discussion. Posts are automatically locked, when no new replies have been made for a long time. If you have a question you can start a new discussion.

Could not get the Exception::Error Message to maintain log

Dear All,

I need to get the error message with below code.Please help me in this regard.

try

    {

        startLengthyOperation();

        this.CashInPatientNew();

        endLengthyOperation();

    }

    catch(Exception::Error)

    {

        How to get error message here.

    }

    catch(Exception::CLRError)

    {

        ex = ClrInterop::getLastException();

        if (ex != null)

        {

            ex = ex.get_InnerException();

            if (ex != null)

            {

                errorTxt = ex.get_Message();

                errorStr = strFmt("%1 ",  errorTxt);

            }

        }        

    }

 

Thanks & Regards,

Britto John Baskar.A

Related
Recommended