1

I have an application that will use oleacc.dll to grab the other running windows application text. In my client I have found the case, the access to oleacc.dll is denied or failed and my application could not grab the running application text. I do not know exactly why the access to oleacc.dll at my client end is denied.

After researching on the OLEACC.DLL, it is found that the oleacc.dll error can be cause by:

  1. Windows update might delete this dll Could not find exactly what particular updates cause this issue.
  2. Anti-Virus software, Registry cleaner or booster might corrupt or delete this dll Eg; AVG, Zone Alarm Internet Security Suite Installation
  3. Virus, Trojan and Malware infection which has corrupted or delete it Eg; Trojan: Win 32/Agent E Malware: Win32/Cnzz
  4. Invalid or corrupt oleacc.dll registry entry
  5. Microsoft hardware failure, such as a bad hard drive, which has corrupted the oleacc.dll file
  6. Another program overwrote the required version of oleacc.dll
  7. Another program maliciously or mistakenly deleted the oleacc.dll file
  8. Another program uninstalled the oleacc.dll file.

Major drawback of my application is, it could not know if the access to oleacc.dll is okay or not - hence my application runs but will not grab and users could not know if it is grabbing the text or not.

So, I wanted to know is there any way to check if the access to oleacc.dll is failed. Once detected, my application could able to raise an alert to user and register the oleacc.dll (using regsvr32 command) from my application automatically.

Code:

IAccessible acc = null;

int retval = AccessibleObjectFromWindow( hWnd, 0, IID_IAccessible.ToByteArray(), ref acc );

Thanks Prakash

Prakash
  • 422
  • 1
  • 12
  • 31
  • What happens when you can't access the file? Is there really no exception? – SimpleVar Aug 26 '14 at 05:26
  • Yes. There is no exception but the while enumerating the children of main window it returns different sequences of child object(different role). I think, Tracking this sequence of child object role will not be good solution and I am not sure why the API return different sequence. – Prakash Aug 26 '14 at 06:47
  • In normal working case, the sequence of objects is pane list ListItem In not working case, the sequence of object is window grip scrollbar pushbutton – Prakash Aug 26 '14 at 06:51
  • Sounds like your assumptions about how an API should work are off. Your conclusion, that the error is outside your application is likely wrong as well. Fix your assumptions, and your code will follow. – IInspectable Aug 26 '14 at 09:51
  • To replicate the step, I have to delete the registry key SOFTWARE\Classes\Wow6432Node\Interface\{618736E0-3C3D-11CF-810C-00AA00389B71}. From my test, it is observed that the point at which the application starts to deviate is at line int retval = AccessibleObjectFromWindow( hWnd, 0, IID_IAccessible.ToByteArray(), ref acc ); In normal case, enumerating child of acc object is as expected. In non-working case (at least I did replicate by corrupting the registry), enumerating child of acc object is different. – Prakash Aug 26 '14 at 10:20

0 Answers0