OLE Documentation generally

ON the OLE Documentation page, as an example, the GetTickerList() method has documentation;

GetTickerList**(ByVal nType As Long) As String

with properties;


  • Item(ByVal Item As Variant) As Object [r/o] [default]
  • Count As Long

In this example, I understand that;

The nType parameter can take the following values:

  • 0: All tickers
  • 1: Stocks
  • 2: Commodities
  • 3: Forex
  • 4: Indices
  • 5: Sectors
  • 6: Watchlist
  • 7: All symbols (including indices, sectors, etc.)

but in order to get that information I had to go on to chatGPT.

Searching the OLE documentation online and in the local help file does not reveal this information. Where would I find this information generally for all of the methods?

@SpandexMan, i think this is a case of Chat-GPT hallucination...

The function is not properly documented, but in an old document I found this note:

  • GetTickerList( Type: number ) : string (new in 4.00) (Type is reserved for the future, set it to zero)

In my short test with a js script, invoking it with any number returns all the tickers in the DB.

1 Like

To be more precise, the function returns all the "Stocks" in the Amibroker DB.

For historical reasons the name of the object is Stock, but it can hold any kind of instrument (including futures, forex, etc).

For each of the returned objects you can retrive the properties listed in the " Stock" object (Ticker, Quotations, Fullname, etc.).


Haha, I thought it might be the case re chat ChatGPT hallucination. Thanks very much for that.

I’ve experimented a bit with the OLE model and managed to get a few bits, but it starts to get messy when having to parse the results into various formats etc for external processing. It does work well for importing.

I clean forgot about simply using runbatch/ explorations, and exporting the results to csv and parsing them that way. I’ve become somewhat obsessed by doing things programmatically.

Thanks once again.

The problem with ChatGPT is hallucination. You can't trust it.
What you can trust if AmiBroker documentation. Documentation is NOT only the Users' Guide but also Release Notes.
ReleaseNotes.html is included in every AmiBroker. Simple text search for GetTickerList gives you this:

CHANGES FOR VERSION 3.95.0 (as compared to 3.93.1)
OLE automation: new method added to Stocks collection:
string GetTickerList( long type ) (type = -1 - all tickers)
- returns comma separated ticker list 

Value of -1 returns comma separated ticker list together with last update date. Value of 0 - as @beppe wrote gives you comma separated list of tickers alone.

Some functions in OLE are really for our internal use. For example GetTickerList was developed solely for ONE REASON: to allow AmiQuote to get ticker list from AmiBroker. For this reason it has built-in features like skipping group 253 (composites) because you don't want to download data for composites. Vague / or lack of description typically means that function wasn't meant for public consumption.