ailts
asked on
Using a Visual Basic ActiveX dll in Delphi
I have read how to use a Visual Basic Active X dll in Delphi on Borland;s delphi WEB pages. I followed there instructions, but recieve this error.
"Project TestConfig.exe raised exception class EOleSysError with message 'Colnitialize has not been called'. Process Stopped. Use Step or Run to Continue."
Here is my code:
var
testconfig: Variant;
testconfig := CreateOleObject('Configura tor.Infere nceEngine' );
I have search delphi help and the WEB for this error message with no luck. Any ideas?
"Project TestConfig.exe raised exception class EOleSysError with message 'Colnitialize has not been called'. Process Stopped. Use Step or Run to Continue."
Here is my code:
var
testconfig: Variant;
testconfig := CreateOleObject('Configura
I have search delphi help and the WEB for this error message with no luck. Any ideas?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Why was that line not generated automatically like it was supposed to be?
ASKER
To clarify my previous comment. Why was the line "Application.Initialize;" not generated automatically? I was under the impression that you did not need to edit the project file at all. this line was all I needed to add to my code to get it to run.
usually you would use the second method but first also works sometimes.
it is not needed for many apps to have this,for d5 anyway half the apps that need this use comobj which does this inside itself.
it is not needed for many apps to have this,for d5 anyway half the apps that need this use comobj which does this inside itself.
for second method you may need add "activex" to the uses section.