Unable to run automation on 32bit application

I am trying to automate some activities on a GUI application which is a 32bit application. The machine on which I’m working in 64bit and both Studio and my application are running there.
Whenever I click anything on the screen or try to do any activity from UiPath Studio my application is closing with unhandled exception. This is not happening if I do the same activity directly on my application, not from UiPath.
Anybody has any idea what could be the problem?

Thank you,