Debug with Visual Studio - Optimized Code issue

Created at 26 Oct 2017, 16:56
How’s your experience with the cTrader Platform?
Your feedback is crucial to cTrader's development. Please take a few seconds to share your opinion and help us improve your trading experience. Thanks!
PR

protradefx

Joined 26.10.2017

Debug with Visual Studio - Optimized Code issue
26 Oct 2017, 16:56


Hi,

I have recently switch to VS2015 for debugging (even still not ufficialy supported) using with the suggested "VSExtension.vsix" for VS2015.

Unfortunally still I receive the following error when I attach VS to CAlgo and try to step over:

"Unable to set the next statement. The next statement cannot be set because the current assembly is optimized".

I have verified the Configuration Manager, the build is set to Debug and the flag Optimize Code is unflagged.

Any suggestion to resolve?

Regards


@protradefx
Replies

ClickAlgo
28 Oct 2017, 18:08

Hi Daniela,

you could try on or more of the following:

  1. Make sure both the project and solution are set as debug
  2. Clean the solution and rebuild all
  3. Tools-Options-Debugging-General, enable "use managed compatibility mode"

If you have already unchecked the optimised code box under project properties then N0. 3 should fix it.

Paul Hayes
Sales & Marketing
Emailcontact@clickalgo.com
Phone: (44) 203 289 6573
Websitehttps://clickalgo.com


@ClickAlgo

protradefx
29 Oct 2017, 22:38

Hi Paul,

thank you vey much! ..the 3rd point really fixed my issue.

Regards


@protradefx