|
Just to note:
The code of the instantiation above will work but has one small lack. When "core" is declared as an "Object" and then created via CreateObject("...") - the compiler-time type checking and intellisense technology in which could prevent a lot of programming problems will not work in Microsoft Visual Studio IDE.
For example, if you write
"core.MakeTradeDesk" instead of "core.CreateTradeDesk" - the code above will fail at the execution time, but when you will use project references and declaration in the form: "Dim core as FXCore.CoreAut", the error will be found during the compilation time. This can save your time during the application writing and debugging.
...OLE Automation API in the Windows provides too much variants to do the same things but sometimes helps developers to have "...two ways to tie shoes. One way is only good for lying down. The other way is good for walking." ((c) R.A. Heinlein, Stranger in a Strange Land).
Last edited by Nikolay.Gekht; 06-09-2009 at 05:35 PM..
|