Login  Register

Re: .NET Framework 4.0 Application Runtime Exceptions Problem

Posted by Luigi Ballabio on Apr 03, 2012; 10:14am
URL: http://quantlib.414.s1.nabble.com/NET-Framework-4-0-Application-Runtime-Exceptions-Problem-tp8685p8695.html

May you check the wrapper code in quantlib_wrap.cpp?  There should be
a try/catch block around each call into QuantLib code that should trap
the exception and convert it into a C# one.  Maybe you can try
debugging that somehow?

Luigi


On Thu, Mar 29, 2012 at 2:52 AM, Mark Gillis <[hidden email]> wrote:

> It doesn't seem to want to for some reason.... Any time the c++ dll throws an exception, all the c# side seems to do is throw an AccessViolationException... Even when I throw the code into a try catch block.
>
> Kcross
>
>
>
> On Mar 22, 2012, at 4:28 AM, Luigi Ballabio <[hidden email]> wrote:
>
>> On Mon, Mar 12, 2012 at 2:32 AM, kcross <[hidden email]> wrote:
>>> Do you know if there is a way to have the C# side catch the QuantLib
>>> exceptions?  Even if I wrapped it in a try-catch block it wouldn't work..
>>
>> The SWIG machinery should catch the C++ exception and convert it into a C# one.
>> Doesn't this work? What happens instead?
>>
>> Luigi

------------------------------------------------------------------------------
Better than sec? Nothing is better than sec when it comes to
monitoring Big Data applications. Try Boundary one-second
resolution app monitoring today. Free.
http://p.sf.net/sfu/Boundary-dev2dev
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users