Error on startup

Bug reports.
leo
Posts: 4
Joined: Thu Aug 28, 2008 10:09 pm

Error on startup

Post by leo » Thu Aug 28, 2008 10:14 pm

i just installed the 1.5 trial
when i start, i get the following error (in the first line of the code, when i try to open a webdocument)



bei mshtml.IHTMLDocument2.get_parentWindow()
bei Ranorex.Web.WebDocument.UpdateWindowFromHandle()
bei Ranorex.Web.WebDocument..ctor(Control ieServerControl, Int32 subFrameIndex)
bei Ranorex.Web.WebDocument..ctor(Control ieServerControl)
bei Ranorex.Web.WebDocument.GetDocument(Control control, Int32 timeout)
bei Ranorex.Web.WebDocument.GetDocument(Control control)
bei Ranorex.Web.WebDocument.OpenDocument(String url, Boolean waitForLoaded, Int32 timeout)
bei Ranorex.Web.WebDocument.OpenDocument(String url, Boolean waitForLoaded)
bei CW_RouteImporter.Program.Main(String[] args) in C:\Dokumente und Einstellungen\interAD\Eigene Dateien\Visual Studio 2008\Projects\CW_RouteImporter\CW_RouteImporter\Program.cs:Zeile 16.
bei System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args)
bei System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
bei Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
bei System.Threading.ThreadHelper.ThreadStart_Context(Object state)
bei System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
bei System.Threading.ThreadHelper.ThreadStart()

regards!

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Post by Support Team » Fri Aug 29, 2008 8:38 am

Could you please tell us the type of exception being thrown? You only posted the stacktrace.

I can only assume that you forgot to set the STAThreadAttribute to your Main method or to set the apartment state of the thread executing the Ranorex.Web code to ApartmentState.STA.

Regards,
Alex
Ranorex Support Team

leo
Posts: 4
Joined: Thu Aug 28, 2008 10:09 pm

Post by leo » Fri Aug 29, 2008 9:01 am

[STAThread] is set to the Main Method of the console application.

the Exception is "COMException" "Klasse nicht registriert"
HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG)

thanks!
regards!

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Post by Support Team » Fri Aug 29, 2008 9:22 am

Sounds like a strange problem. What's your operating system and Internet Explorer version?

It may be that either the Ranorex or the Internet Explorer installations are broken. You could try to reinstall/repair the Ranorex installation. And if then the exception is still there, reinstalling/repairing your Internet Explorer installation might help.

Regards,
Alex
Ranorex Support Team

leo
Posts: 4
Joined: Thu Aug 28, 2008 10:09 pm

Post by leo » Fri Aug 29, 2008 9:31 am

yes ;)

IE6: 6.0.2300.2180
Windows XP SP 2

--> virtual PC 2007

i already re-installed ranorex. i also installed the older version 1.4
both with the same error.

is it maybe the virtual PC??

regards!!

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Post by Support Team » Fri Aug 29, 2008 9:36 am

leo wrote:is it maybe the virtual PC??
I don't think so.

Have you tried reinstalling IE 6?

Regards,
Alex
Ranorex Support Team

leo
Posts: 4
Joined: Thu Aug 28, 2008 10:09 pm

Post by leo » Fri Aug 29, 2008 9:39 am

no, i have not. how does this work!?

regards!

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Post by Support Team » Mon Sep 01, 2008 2:31 pm

I could (finally) reproduce this error. Reinstalling the Internet Explorer won't help, sorry!

I posted a workaround for this bug in the following forum thread:
http://www.ranorex.com/forum/ranorex-st ... .html#1441

Regards,
Alex
Ranorex Support Team