From: Charles Lowe Date: 2008-04-24T18:25:43+09:00 Subject: Re: WIN32OLE disable busy dialog etc Masaki Suketa wrote: > Hello, > > Charles Lowe wrote: > > > Well, it doesn't look like much, it involves a proprietary com object > > (factset api). > > > > Code goes something like this: > > > > comobj = WIN32OLE.new 'FactSet.FactSet_API' > > comobj.runapplication 'Downloading', 'File=' + file, 'Batch=True' > > How can I get the factset api? > > > If you look at what was added to the python equivalent (win32uiole), > > they used the "AfxOleGetMessageFilter" function, and exposed some > > methods on top of that, you can just do: > > > > win32uiole.AfxOleInit() > > win32uiole.SetMessagePendingDelay(aBigDelay); > > win32uiole.EnableNotRespondingDialog(False); > > win32uiole.EnableBusyDialog(False); > > I had seen the python win32uiole, but the "AfxOleGetMessageFilter" > function is in MFC library. > And I won't use MFC library because I don't have MFC library > and Ruby source does not depend on MFC. > So I'd like to implement the python equivalent function > without MFC(AfxOleGetMessageFilter). > But I don't know how to implement it now. > I need the sample script which occurs the problem in order > to investigate how to implement it without MFC. > And If I could implement it, I would need the sample script to check > my implementation is correct or not. > > Regards, > Masaki Suketa Unfortunately you wouldn't be able to get access to the factset api. Its a proprietary, licensed data access api. Hmmm, I didn't realize that the ruby source doesn't use MFC. Is it possible, do you think, to solve this problem by loading the appropriate dll and making the call using WIN32::Api? I tried to figure out an approach this way with no success so far. One possibility may be to write a simple, unfriendly test com object, that is single threaded, and blocks for a long time when calling some method. I think that should be sufficient to be able to reproduce the problem locally? -- Posted via http://www.ruby-forum.com/.