Hello,

At 09/04/2009 11:29 PM, Chuck Remes wrote:
>> How about commenting the 3 lines from line 4480 to line 4482?
>> Does it work?
>>
>>         ary2ptr_dispparams(outargv, pdispparams)
>>      end
>>
>>      # if pvarResult
>>      #    WIN32OLE.ole_val2variant(result,pvarResult)
>>      # end
>>      S_OK
>>   })
> 
> Commenting out those lines fixes (hides?) the problem described above. 
> It now runs the program successfully.
> 
> However, this pure ruby version of the library still crashes when I run 
> the code described in my original post. It crashes without writing any 
> error message to the Output window in NetBeans. I *assume* it is 
> crashing somewhere in #message_loop but I don't know that for sure.
> 
> Is there any easy way to instrument the win32ole code so I can pinpoint 
> the crash location?

I would like to know more detail about the event when the code
crashes.

At 09/03/2009 02:48 AM, Chuck Remes wrote:
> Anyway, I am doing some application automation on Windows using the
> WIN32OLE classes. In this particular case, I have registered event
> handlers for a bunch of possible events that may be generated by another
> Windows application. I have tested about a dozen of these handlers and
> all is well. However, I added one more and now when I trigger the event
> that calls it, ruby crashes. 

Does the event expect the return value from event handler?
If so, what kind of the return value the event expect?
For example, the NavigateComplete2 of InternetExplorer is as following,
and does not expect the return value(VOID).

   VOID NavigateComplete2(pDisp[in], URL[in])

Or could you show me the IDL of the event?

   Regards,
   Masaki Suketa