Auto Capture Image... some help required

mastermind007

Well-Known Member
#31
Basically your jscript doing the same thing but embedded into amibroker. Thank you for your help and Hope this method work well.
Yes. Both approach use embedding Amibroker thru COM.

Why don't you try it out and see for yourself.

There is one small error that I discovered. Year(), Month() etc do not return latest year month but return year and month of whichever candle you've clicked. (Vertical blue line)

Remedy is to replace Year() month() and Day() with appropriate Now() functions.

Of course, if you could figure out how to pass full date format string, it
would be slightly simpler.
 
#32
wow, I saw here very good technical issues and technical people.
from many days I would want to have a code such that it shows
all the free charts like jackpot,marketcalls, etc in one free site
to view it daily live stream at a glance and at one place.
that chart should be like four square, four charts in four boxes.
technical people should have a kind eye upon this small project for a trader.
 

mastermind007

Well-Known Member
#33
wow, I saw here very good technical issues and technical people.
from many days I would want to have a code such that it shows
all the free charts like jackpot,marketcalls, etc in one free site
to view it daily live stream at a glance and at one place.
that chart should be like four square, four charts in four boxes.
technical people should have a kind eye upon this small project for a trader.
Problem is that most small traders cheat technical people. They do not
pay what they've promised.
 
#34
Does the website automatically run while pc off also.
means does it capture images of ami afl chart and show in website chart as auto streaming chart live without any interruption.

or shall we always run the ami chart in our pc.
shall we have to have any arrangements from ami side.
 

mastermind007

Well-Known Member
#35
Does the website automatically run while pc off also. means does it capture images of ami afl chart and show in website chart as auto streaming chart live without any interruption.

or shall we always run the ami chart in our pc.
shall we have to have any arrangements from ami side.
preethnfo,

PC that hosts website is usually called WebServer and is designed to stay on 24x7x366. In 99% of the cases, machine is physically owned and maintained by the hosting company. PC that created web apps can be turned on and off.

The solution that I gave for capturing images frequently has to have Amibroker running and the script has to be included in the first chart tab. Also, the amibroker has to have some live data feed otherwise the image will not change and capturing image is meaningless. Once the image file is created, it will have to be uploaded (FTP'd) to the web server.
 

KelvinHand

Well-Known Member
#36
Hi
I'm trying to live stream my ami chart online so that I can use it else...

so when I capture the image with the below code- MANUALLY it works!
Code:
Capture = ParamTrigger("Capture", "Click");
if ( Capture )
ShellExecute("E:\\AutoExportChart\\AutoExportChart.js","","");
but when I try to capture images automatically then I get a windows host error... some one please help me auto capture the images....

this is what I tried....
Code:
_SECTION_BEGIN("Time Left");
function GetSecondNum()
{
    Time 		= Now( 4 );
    Seconds 	= int( Time % 100 );
    Minutes 	= int( Time / 100 % 100 );
    Hours 	= int( Time / 10000 % 100 );
    SecondNum = int( Hours * 60 * 60 + Minutes * 60 + Seconds );
    return SecondNum;
}
 
RequestTimedRefresh( 1 );
TimeFrame=15;
SecNumber = GetSecondNum();
Newperiod = SecNumber % TimeFrame == 0;
SecsLeft	 = SecNumber - int( SecNumber / TimeFrame ) * TimeFrame;
SecsToGo	 = TimeFrame - SecsLeft;
 
if ( NewPeriod )
{
ShellExecute("E:\\AutoExportChart\\AutoExportChart.js","","");
}
or is there any other means thru which I can live stream my chart online?

I was not able to ShellExecute() the above code in Version 5.6x
I finally figure out the solution to this problem. This should be the correct way.



PHP:
_SECTION_BEGIN("Time Left");
function GetSecondNum()
{
    Time 		= Now( 4 );
    Seconds 	= int( Time % 100 );
    Minutes 	= int( Time / 100 % 100 );
    Hours 	= int( Time / 10000 % 100 );
    SecondNum = int( Hours * 60 * 60 + Minutes * 60 + Seconds );
    return SecondNum;
}
 
RequestTimedRefresh( 1 );
TimeFrame=15;
SecNumber = GetSecondNum();
Newperiod = SecNumber % TimeFrame == 0;
SecsLeft	 = SecNumber - int( SecNumber / TimeFrame ) * TimeFrame;
SecsToGo	 = TimeFrame - SecsLeft;
 
if ( NewPeriod )
{
 ShellExecute("wscript.exe", "AutoExportChart.js", "E:\\AutoExportChart\\"); 
}

To call the jscript inside the Amibroker Scripts folder (so far work on V5.6x):
PHP:
ShellExecute("wscript.exe", "ExportImage.js", ".\\Scripts");
Hope this work on all version and become an universal standard.
 
Last edited:

Similar threads