Amazon Ad

Friday, 29 August 2014

System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.BadImageFormatException: Invalid access to memory location. (Exception from HRESULT: 0x800703E6)

Dear all,

I was struggling with an error in ASP.NET. The error was coming when i implemented Ad (Active Directory) password change code in one of my forms. It some times worked but sometimes it gave the following error

 System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.BadImageFormatException: Invalid access to memory location. (Exception from HRESULT: 0x800703E6) --- End of inner exception stack trace --- at System.DirectoryServices.DirectoryEntry.Invoke(String methodName, Object[] args) at _adPassword.ChangeUserADPassword(String Username, String Password, String newPwd)

I searched a lot and then found a solution for this problem. The problem was the CPU overload on the server. The server CPU usage when moved above 75-90% this form resulted this error. I recycled the Application pool and also made some changes on the server to maintain the CPU usage below 75%. This solved the problem and now i don't face any sort of problem with this form.

Thanks
Ritesh Tandon

How to implement Captcha v3 in ASP.NET

 I was facing an issue of dom parsing in my website. I finally resolved it by using Google Captcha V3. Step 1: Get your keys from https:...