Is script running in Raw Profit Mode or Portfolio Simulation Mode?
Author: kazuna
Creation Date: 8/16/2009 4:11 AM
profile picture

kazuna

#1
Is there a way for the script to know whether it is running in Raw Profit Mode or Portfolio Simulation Mode?
profile picture

Eugene

#2
Yes, using a little hack.

Frankly, such capability already exists in Community.Components - just the method is used internally and therefore was marked "private". I'll make the necessary change in the upcoming build so it will be taking only 2 lines of code to use in your Strategies.

For now, please use this workaround:
CODE:
Please log in to see this code.
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).