Unhandle exception occured when running the .Net Application

Ask general questions here.
Linna
Posts: 6
Joined: Tue Jun 18, 2013 9:52 am

Unhandle exception occured when running the .Net Application

Post by Linna » Wed Jun 19, 2013 9:02 am

Hi,
It will pop up "Microsoft .Net Framework" which is presentation of "Unhandle exception has occured in your application……Value cannot be null,parameter name:value" occured When i record the .Net Application.After i select run a application and click Start button on the Record Settings ,the preceding error dialog pop up immediately. I don't know how to solve. the ranorex version is 4.0.3
Attachments
ERPAutoTest.zip
(3.79 MiB) Downloaded 220 times

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Unhandle exception occured when running the .Net Application

Post by Support Team » Thu Jun 20, 2013 4:10 pm

Hello,

Thank you for the project and the snapshot files.
Unfortunately I am not able to reproduce the issue because I do not have your Application under test.
It seems to be an unhandled exception, which is thrown in your application.
Which version of the .NET Framework are you using?
Could you please check which message is shown if you open the details in the exception dialog.
Additionally could you please ask the responsible developer in your company if this is an exception in your application.
Thank you!

Regards,
Bernhard
.
Image

Linna
Posts: 6
Joined: Tue Jun 18, 2013 9:52 am

Re: Unhandle exception occured when running the .Net Application

Post by Linna » Sat Jun 22, 2013 2:57 pm

Hi Bernhard,

Thanks for your reply.The version of .Net Framework is 4.0.This issue isn't related to my Application under test because i directly open my Application under test that will not produce the issue.But I try it by two methods that will produce the issue in Ranorex Studio. One method is setting the work directory of my AUT in Recoder Settings.Another method is writing code in UserCode eg.Host.Local.RunApplication(@"D://ERP//ERP-1.10test//HKMain.exe");





Regards
Linna

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Unhandle exception occured when running the .Net Application

Post by Support Team » Tue Jun 25, 2013 1:07 pm

Hi Linna,

Could you check if it would work if you set the working directory and the arguments (if needed) to the application specific values?
Host.Local.RunApplication("D:\\ERP\\ERP-1.10test\\HKMain.exe", "arguments", "workingDirectory", false);
Please use the following methode: RunApplication Method (fileName, arguments, workingDirectory, maximized).

Regards,
Markus
.
Image

Linna
Posts: 6
Joined: Tue Jun 18, 2013 9:52 am

Re: Unhandle exception occured when running the .Net Application

Post by Linna » Wed Jun 26, 2013 1:46 pm

Hi Markus,

Thank you, I use the code as you recommended but there is still this issue.Due to my file is too big,I will send E-mail to [email protected] .




Regards
Linna