Download MetaTrader 5

if encountered a "stack damaged" exception,try to use "cdecl" instead of "stdcall" in your DLL code

To add comments, please log in or register
coastarica
13
coastarica  

When I try to migrate my C# code to Delphi, I found that when using the array as a parameter, it will always raise a "stack damaged" failure. Even use the example code  shown here. After many times trying, I finally realized that it's caused by the  calling conversion. Now I fixed this problem by using "cdecl" other than "stdcall" like almost others said.

So ,is anybody aware of this thing?  May my approaching  be a help hand for you .

To add comments, please log in or register