[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [amibroker] Amiquote and Amibroker



PureBytes Links

Trading Reference Links




Arthur,
 
Here are 2 simple JScript files that will do 
what you want..
 
The first one, is the one that I use to add the 
required .AX to my codes.
You only have to modify the alias field, instead of 
the TICKER itself.
 
try this script
 
<---- Cut here for SetUpAlias.js 
---
var oAB = new 
ActiveXObject("Broker.Application");
 
var oStocks = oAB.Stocks;var StockQty = 
oStocks.Count;
 
WScript.Echo("Script ready to start" 
);
 
for( i = 0; i < StockQty; i++ 
){        oStock = oStocks( i 
);
 
        if 
(oStock == null) continue;        
oStock.Alias = oStock.Ticker + ".AX"; 
        oStock.IsDirty=1; 
}WScript.Echo("Script finished" );
 
<-- Cut here
 
Then to create the .TLS file for AmiQuote to use, 
just use the following JScript file
 
 
<-- Cut here for Make_TLS_File.js 
-------------
var oAB = new 
ActiveXObject("Broker.Application");var fso = new 
ActiveXObject("Scripting.FileSystemObject");
 
var oStocks = oAB.Stocks;
 
var StockQty = 
oStocks.Count;WScript.Echo("Started script" );f = 
fso.OpenTextFile("c:\\Amibroker\\Amiquote\\ASX.TLS", 2, true );for( i = 0; i 
< StockQty; i++ ){ oStock = oStocks( i );<FONT 
face=Arial size=2> f.WriteLine (oStock.Ticker);}<FONT 
face=Arial size=2>f.Close();
WScript.Echo("ASX.TLS file created" );
 
 
Bruce
Perth, Australia
 
 
 
<BLOCKQUOTE 
>
  ----- Original Message ----- 
  <DIV 
  >From: 
  Arthur 
  Sawilejskij 
  To: <A title=amibroker@xxxxxxxxxxxxxxx 
  href="">amibroker@xxxxxxxxxxxxxxx 
  Sent: Saturday, July 19, 2003 8:15 
  PM
  Subject: [amibroker] Amiquote and 
  Amibroker
  <FONT face=Arial 
  size=2>I have a database of Australian stock that I want 
  to update with Amiquote.At the moment the stock have a 3 letter format 
  - like AGL - but I need to change the database to AGL.AX to accommodate 
  getting the Yahoo data via Amiquote and appending the latest data to my 
  database.Is there an easy way to do this - or do I have to manually 
  append .AX to all the 3 letter stock codes in my AB 
  database.Arthur






Yahoo! Groups Sponsor


  ADVERTISEMENT 









Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html



Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.