Jump to content
Sign in to follow this  

Problem with objevent

Recommended Posts



I'm new with autoit but I made some scripts and I have not problems until now. I want to use a com object, declared correctly, and I want to handle some of events from that object. The object have six events and I can catch three of them but the others not. So my question is: it is possible for autoit to handle only a part of events fired up from an object?

Share this post

Link to post
Share on other sites

Can't say. There is no systemic issue I am aware of. You'll need to post reproducer code.


Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl

MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model

Automate input type=file (Related)

Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded  Better Better?

IE.au3 issues with Vista - Workarounds

SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead?

Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble

Share this post

Link to post
Share on other sites

The object that I use is s COM installed by a software for building ebook files for a dedicated ebook reader called Ebookwise1150. So it is not a common object and because of this I can not supply a reproducer code.

A quote from the documentation of this COM

As an ActiveX control, AutoPublisher is fully OLE Automation compliant and will be able to work with any environment that supports OLE Automation. This includes, but is not limited to ActiveState Perl for Windows, Microsoft Windows Scripting, Microsoft Visual Basic and Visual Basic for Applications, and, to a limited extent, Microsofts Java implementation.

The event I want to use is called OnBuildStart:


Parameters: [in] IProject* project


This event is fired immediately before beginning the build process. The project interface being used to control the build is supplied to the event handling routine. This allows a client to perform last minute changes to the project before the build. Especially important when invoking a build method that uses a default project (e.g. BuildFromTextFile).

Other events are called: onerror, OnLayoutFeedback, OnParserFeedback, OnSourceDone, OnSourceStart.

I have defined the object as normal(in my case)


and the function that I use are

Func Builder_Event_OnLayoutFeedback($msg)
Func Builder_Event_OnParserFeedback($bytes,$totalbytes)
Func Builder_Event_onerror($file,$msg,$line,$col,$severity)

this functions are working well but

Func Builder_Event_OnBuildStart($Proj)

is note fired up, and I don't know why...

For me it is a mystery why the first three functions are working

and the last is not.

O, and for the others I don't even know if they are working, I don't want to use them

so I not even try them.

I have a filling about not using correctly the OnBuildStart event but I not have a clue what is wrong.

Maybe the onerror event is 'dispatch' type and OnBuildStart is not...(In the same com interface?)

Give me a hint please...

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this