Unhandled Exception When Stepping into code

Bug reports.
Steve
Posts: 4
Joined: Fri Jul 17, 2009 1:41 pm

Unhandled Exception When Stepping into code

Post by Steve » Fri Jul 17, 2009 2:03 pm

If i add a break point in the code, then try to step into the try/catch statements, as soon as the step into button is clicked, ranorex freezes and eventually returns with the unhandled exception message i've added below.
If i set a break point on the method, it steps through with no problem, but freezes as soon as i reach the next try/catch.

I've added the try/catch statement and below it, is the method it's calling.
I'm still fairly new to coding, so it's not the most complicated script.

Any help appreciated


//
              try {
				Recording1.Current_Selection_Classification_WeddingArrangements();
				Report.Success("Test Case 1H - Current Selection Classification is Wedding Arrangements");
			} catch (Exception) {
				Report.Failure("Test Case 1H - Current Selection Classification is Not Wedding Arrangements");
				Report.Screenshot();
				goto Exit1;
			}   

public static void Current_Selection_Classification_WeddingArrangements()
		{
			//Your code here. Code inside this method will not be changed by the code generator.
			//Runs a comare test of the current selection, Classification option and the
			//text hard coded in the second line below.
			String Category_text = repo.WebDocument.Current_Ad_Selection_Classification.InnerText.ToString();
			String.Compare(Category_text, "Wedding Arrangements");
		}

Ranorex Studio Version : 2.1.2.6480
.NET Version : 2.0.50727.3053
OS Version : Microsoft Windows NT 5.1.2600 Service Pack 3
Current culture : English (United Kingdom) (en-GB)
Current UI language : en-US
Working Set Memory : 91856kb
GC Heap Memory : 24253kb

Exception thrown:
System.Runtime.InteropServices.COMException (0x80131C08): A wait timed out, likely an indication of deadlock. (Exception from HRESULT: 0x80131C08)
at Debugger.Interop.CorDebug.ICorDebugStepper.StepRange(Int32 bStepIn, IntPtr ranges, UInt32 cRangeCount)
at Debugger.Wrappers.CorDebug.ICorDebugStepper.StepRange(Boolean bStepIn, Int32[] ranges)
at Debugger.Stepper.StepIn(StackFrame stackFrame, Int32[] stepRanges, String name)
at Debugger.StackFrame.AsyncStep(Boolean stepIn)
at Debugger.StackFrame.AsyncStepInto()
at ICSharpCode.SharpDevelop.Services.WindowsDebugger.StepInto()
at ICSharpCode.SharpDevelop.Project.Commands.StepIntoDebuggingCommand.Run()
at ICSharpCode.Core.WinForms.ToolBarCommand.OnClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
at System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
at System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

---- Recent log messages:
Failed to append recent log messages.
System.InvalidOperationException: Sequence contains no elements
at System.Linq.Enumerable.Single[TSource](IEnumerable`1 source)
at ICSharpCode.SharpDevelop.Sda.LogMessageRecorder.AppendRecentLogMessages(StringBuilder sb, ILog log)
at ICSharpCode.SharpDevelop.Sda.ExceptionBox.getClipboardString()

---- Post-error application state information:
Installed 3rd party AddIns: [RanorexLogViewer, Enabled=True, Action=Enable], [RxObjectRepository, Enabled=True, Action=Enable], [RxRecorder, Enabled=True, Action=Enable], [Workflow Foundation Designer, Enabled=True, Action=Enable], [ElementTree, Enabled=True, Action=Enable]
Workbench.ActiveContent: [TextEditorDisplayBindingWrapper E:\Ranorex Studio Projects\SamUI\Use progress bar\Use progress bar\Recording1.cs]
ProjectService.OpenSolution: [Solution: FileName=E:\Ranorex Studio Projects\SamUI\Use progress bar\Use progress bar.rxsln, HasProjects=True, ReadOnly=False]
ProjectService.CurrentProject: [CSharpProject: Use_progress_bar]

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

Re: Unhandled Exception When Stepping into code

Post by Support Team » Thu Jul 23, 2009 1:47 pm

Hi steve,
we aren`t able to reproduce this issue.
Does it happen every time you want to debug and step over try/catch blocks?

Regards,
Christian
Support Team
.
Image

Steve
Posts: 4
Joined: Fri Jul 17, 2009 1:41 pm

Re: Unhandled Exception When Stepping into code

Post by Steve » Thu Jul 23, 2009 5:06 pm

Hi !

Yes the error occurs evey time i try to use the step into code option on the try/catch.

I asked a colleague who has ranorex version 2.0 to try the same thing today, he had the same error with his version.

Regards

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

Re: Unhandled Exception When Stepping into code

Post by Support Team » Mon Jul 27, 2009 9:47 am

Hi steve,
I still cant`t reproduce your issue. Could you please give me an exact description(step-by-step) how I can get the 'ComException' based on a new project.

Regards,
Christian
Support Team
.
Image

Steve
Posts: 4
Joined: Fri Jul 17, 2009 1:41 pm

Re: Unhandled Exception When Stepping into code

Post by Steve » Tue Aug 04, 2009 9:52 am

Hi Christian

Sorry i haven't replied yet, but we have a release date coming up, i will hopefully have time to add the details you require next week.

Regards

Steve

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

Re: Unhandled Exception When Stepping into code

Post by Support Team » Tue Aug 04, 2009 12:59 pm

Thanks for your reply and supporting us to improve our product. I hope we can fix your issue asap.

Regards,
Christian
Support Team
.
Image

Steve
Posts: 4
Joined: Fri Jul 17, 2009 1:41 pm

Re: Unhandled Exception When Stepping into code

Post by Steve » Mon Nov 02, 2009 5:57 pm

Good afternoon!

I have not been able to return to this issue for some time due to work constraints, since returning to it with an updated ranorex build, i am no longer able to reproduce the issue.
So i believe from my point of view that the issue as it stands no longer exists and is therefore fixed an a later release.
If you could close this as an issue would be much appreciated.

Regards

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

Re: Unhandled Exception When Stepping into code

Post by Support Team » Tue Nov 03, 2009 7:29 pm

Thanks for the update on that issue!

Regards,
Alex
Ranorex Support Team
.
Image