This is a migrated thread and some comments may be shown as answers.

Reverse Engineering wizard can't find it's own files.

10 Answers 162 Views
Getting Started
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Bill
Top achievements
Rank 2
Bill asked on 23 Sep 2009, 05:57 PM
I'm running the reverse engineering wizard to go from an Oracle 10g db to classes.
Everything is going fine now up until I try to generate the sources - then I get :


Could not find file 'C:\Users\wblevins\AppData\Local\Temp\RefEmailtype.Telerik.OpenAccess.cs'

Please try again after fixing the problem.

In the "Generate Sources" window.

It is saving everything in the reversemapping.config file

RefEmailtype is one of the oracle tables I'm trying to map...

10 Answers, 1 is accepted

Sort by
0
Alexander
Telerik team
answered on 25 Sep 2009, 07:09 AM
Hi Bill,

Unfortunately, we were not able to reproduce this behavior. The problem seems to be that the code generator cannot create the source files in the temporary directory. You can try restarting Visual Studio. If this does not help, please create another test project and see if the same thing happens or the problem is only in the current project.

Regards,
Alexander
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Bill
Top achievements
Rank 2
answered on 25 Sep 2009, 07:36 PM
It's happening on any project I create.  I've even tried running Studio 2008 under the Administrator account/credentials/

Does OA need the temp directory to be in a specific place?

The temp dir on this (vista ultimate os) machine is C:\temp

Bill

0
Bill
Top achievements
Rank 2
answered on 28 Sep 2009, 11:48 PM
I decided to back up and take a look at your example - but I can't seem to get it running either...


Unable to cast object of type 'Factory' to type 'OpenAccessRuntime.Relational.RelationalKeyGeneratorFactory'.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.InvalidCastException: Unable to cast object of type 'Factory' to type 'OpenAccessRuntime.Relational.RelationalKeyGeneratorFactory'.

Source Error:

Line 116:			Database db = Database();
Line 117:
Line 118: IObjectScope newScope = db.GetObjectScope();Line 119:			return newScope;
Line 120:		}

Source File: C:\OA_Telerik_Ajax\OpenAccessSimpleApplication\OpenAccessSimpleApplication.WebSite\ObjectScopeProvider1.cs    Line: 118

Stack Trace:

[InvalidCastException: Unable to cast object of type 'Factory' to type 'OpenAccessRuntime.Relational.RelationalKeyGeneratorFactory'.]
   OpenAccessRuntime.Relational.RelationalKeyGeneratorFactoryRegistry.getFactory(String name) +265

[OpenAccessException: Unable to create RelationalKeyGeneratorFactory instance OpenAccessRuntime.Relational.sql.HighLowRelationalKeyGenerator+Factory]
   Telerik.OpenAccess.SPI.Backends.ThrowException(Exception e) +28
   Telerik.OpenAccess.RT.ExceptionWrapper.Throw() +34
   OpenAccessRuntime.storagemanager.StorageManagerFactoryBuilder.createSmfForURL() +408
   OpenAccessRuntime.storagemanager.StorageManagerFactoryBuilder.createStorageManagerFactory() +474
   OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp.createStorageManagerFactory() +446
   OpenAccessRuntime.DataObjects.PersistenceManagerFactoryBase.init() +562
   OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp.init() +101
   OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp..ctor(IDictionary properties, Object classloader) +542
   OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp.getPersistenceManagerFactory(IDictionary props) +49
   OpenAccessRuntime.DataObjects.BootstrapPMF.getPersistenceManagerFactory(IDictionary props) +242
   Telerik.OpenAccess.RT.Helper.getPersistenceManagerFactory(IDictionary props) +883
   Telerik.OpenAccess.RT.DatabaseAdapter.AssertPersistenceManagerFactory(String usr, String password, Boolean open) +1772
   Telerik.OpenAccess.RT.DatabaseAdapter.GetObjectScope(TransactionProvider provider) +70
   Telerik.OpenAccess.RT.DatabaseAdapter.GetObjectScope() +37
   Telerik.OpenAccess.Database.GetObjectScope() +34
   OpenAccessSimpleApplication.WebSite.ObjectScopeProvider1.GetNewObjectScope() in C:\OA_Telerik_Ajax\OpenAccessSimpleApplication\OpenAccessSimpleApplication.WebSite\ObjectScopeProvider1.cs:118

[TargetInvocationException: Exception has been thrown by the target of an invocation.]
   System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner) +0
   System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner) +71
   System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks) +350
   System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) +29
   System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters) +19
   Telerik.OpenAccess.RT.DataSource.OpenAccessDataSourceView.ConstructContext() +892

[InvalidOperationException: No constructor for the strongly-typed IObjectScope takes 0 parameters.]
   Telerik.OpenAccess.RT.DataSource.OpenAccessDataSourceView.ConstructContext() +1014
   Telerik.OpenAccess.RT.DataSource.OpenAccessDataSourceView.ExecuteSelect(DataSourceSelectArguments arguments) +126
   System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) +19
   System.Web.UI.WebControls.DataBoundControl.PerformSelect() +142
   Telerik.Web.UI.GridTableView.PerformSelect() +28
   System.Web.UI.WebControls.BaseDataBoundControl.DataBind() +73
   Telerik.Web.UI.GridTableView.DataBind() +365
   Telerik.Web.UI.RadGrid.DataBind() +165
   System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound() +82
   System.Web.UI.WebControls.CompositeDataBoundControl.CreateChildControls() +72
   System.Web.UI.Control.EnsureChildControls() +87
   Telerik.Web.UI.GridBaseDataList.get_Controls() +33
   Telerik.Web.UI.RadAjaxControl.PopulatePlainPanels(Control parent, List`1 list, Control root) +114
   Telerik.Web.UI.RadAjaxControl.OnPagePreRender(Object sender, EventArgs e) +1777
   System.EventHandler.Invoke(Object sender, EventArgs e) +0
   System.Web.UI.Control.OnPreRender(EventArgs e) +8682870
   System.Web.UI.Control.PreRenderRecursiveInternal() +80
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +842
0
Brendan Enrick
Top achievements
Rank 1
answered on 29 Sep 2009, 12:35 PM
Hey Bill,

Have you checked to see if you have any OpenAccess files in the "C:\Users\wblevins\AppData\Local\Temp\" folder?

Brendan
0
Bill
Top achievements
Rank 2
answered on 29 Sep 2009, 09:13 PM
There are other  'Telerik.OpenAccess.cs' files for the project I was trying to do there, but not 'RefEmailType'... 

The only 'RefEmailType' file on the machine is at:

c:\Users\wblevins\Documents\Visual Studio 2008\Projects\WebSiteTest\OAlib\Refemailtype.Telerik.OpenAccess.cs

When I tried moving it - the file was deleted from the temp directory and I got the error message again.


I'm going to delete everything and start over again one more time.

0
Ady
Telerik team
answered on 30 Sep 2009, 03:12 PM
Hi Bill,

 Can you send us some more information about your setup - the kind of project on which you are running the Reverse mapping wizard, have you been able to successfully generate the sources for any other class before this?

Can you try switching off partial classes generation via the Options dialog? This could help us in narrowing down the problem.

All the best,
Ady
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Chris Jansen
Top achievements
Rank 1
answered on 08 Oct 2009, 06:29 PM

For what it's worth, I was having the same issue. However, I deleted all of the entity classes that were created, deleted reversemapping.config and app.config, and re-enabled the project to use ORM. I then generated classes without generating partial classes, and it worked.

0
Ady
Telerik team
answered on 13 Oct 2009, 01:45 PM
Hi,

 @Chris - Thank you for the input Chris. There seems to be an intermittent problem while generating the designer class file (<classname>.Telerik.OpenAccess.cs/vb).

We would like to try and determine the reason behind this.

@Bill -
Hi Bill..were you able to progress after removing all files and starting again? If you are still experiencing the error can you send us the information requested in my earlier reply and also your system information (OS,Visual Studio version etc) ? Thanks.

Regards,
Ady
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Bill
Top achievements
Rank 2
answered on 17 Nov 2009, 06:30 PM
I've been off of this project for a while - just installed 2009 Q3 - I'll let you know if I have the same trouble.
0
Ady
Telerik team
answered on 23 Nov 2009, 10:50 AM
Hi Bill,

 Any news on this problem after installing the Q3 version? Feel free to share your experience with us which will help us continuously improve the product.

Best wishes,
Ady
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
Getting Started
Asked by
Bill
Top achievements
Rank 2
Answers by
Alexander
Telerik team
Bill
Top achievements
Rank 2
Brendan Enrick
Top achievements
Rank 1
Ady
Telerik team
Chris Jansen
Top achievements
Rank 1
Share this question
or