you dont need java to run jscript. all u need is windows scripting
installed from microsoft.
--- In [email protected], moha...@... wrote:
>
>
>
>
> The autorun jscript is not running . I installed java on this
computer
> and it on windows xp and AB 5.2.
>
> ANy help is appreciated.
>
> Thanks
>
> Mohan
>
> /*
> Below is sample JScript (to be saved in a separate file with .JS
> extension).
> Usage:
> 1. Open AmiBroker. Setup the watch list 1.
> 2. Double click the .JS file
> 3. Enjoy slideshow.
> */
>
> //////////////////////////////
> // Sample Slideshow script
>
> /// USER DEFINABLE VARIABLES
> ///
> WatchListNo = 1; // <---- THE WATCH LIST TO USE
> ChangeEverySec = 2; // <--- TIME BETWEEN SLIDE CHANGES (in
seconds)
> ///
> ////////////////
>
> // Don't touch code below
> AB = WScript.CreateObject("Broker.Application");
>
> Stocks = AB.Stocks;
>
> iQty = Stocks.Count
> for( i = 0; i < iQty; i++ )
> {
> s = Stocks( i );
>
> if( ( WatchListNo < 32 && s.WatchListBits & ( 1 <<
WatchListNo ) )
> ||
> ( WatchListNo >= 32 && s.WatchListBits2 & ( 1 <<
> (WatchListNo-32) ) ) )
> {
> prevdoc = AB.ActiveDocument;
> AB.Documents.Open( s.Ticker );
> if( prevdoc != null ) prevdoc.Close();
> WScript.Sleep( 1000 * ChangeEverySec );
> }
>
> }
>
> // END....
>