PureBytes Links
Trading Reference Links
|
Hello,
I want to save an image to file after the Buy or Short for each
trade. The export image method to do this is in Jscript, and must
be called from outside of AB. But I have a problem since I need to
use the BUY(or Short) from AB to trigger the image export. So what
I have come up with is to use the Alertif function inside AB to
trigger the external action, e.g.,
AlertIf( Buy, "EXEC C:\\ExportImage.js" , "At "+Now() , 1 );
Then on the root directory of the C: drive, a I have a Jscript file,
ExportImage.js which is:
AB = new ActiveXObject("Broker.Application");
Win = AB.ActiveWindow;
Win.ExportImage( "test3.png", 1280, 960 );
So far so good. Works like a champ EXCEPT that it keeps writing
each new image to the same file name, test3.png.
So here is the question: How do I increment the number after test
or attach a time stamp to it sso that I get individual files for
each image? I have tried several approaches but nothing works so
far. Also can see from the Jscript documentation in the User's
Guide and on the web, that it will be a chore to learn Jscript
basics. I want to do that over time , but not right now.
Can anyone help?
Thanks in advance,
Grover
------------------------------------
Please note that this group is for discussion between users only.
To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com
For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/
For other support material please check also:
http://www.amibroker.com/support.html
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/amibroker/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:amibroker-digest@xxxxxxxxxxxxxxx
mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx
<*> To unsubscribe from this group, send an email to:
amibroker-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|