I have a code which generated dll, but at the time of loading that project I am getting IDE exception as mentioned below :
Error loading type library/dll.
Its type is EInternalTypeLibraryException.
and exact message is:
An error occurred while referencing a user defined type. This may be caused by a missing or unregistered type library.
Related
When building a Xamarin.Android project it is written in the output window that aapt2 has removed resources due to a missing default value.
Xamarin.Android.Aapt2.targets(160,3): warning APT2000: warn: removing resource com.companyname.demo_app:drawable/parking_slot without required default value.
The removed resource is part of a Xamarin.Android binding project and is also included in the aar-file under drawables and in the R.txt.
Because it is only a log-statement in the build output, the project builds and the app can be started. But when using one part of the binding-project the following error will be thrown:
Java.Lang.NoSuchFieldError: 'No static field parking_slot of type l in class Lcom/company/sample/R$drawable; or its superclasses (declaration of 'com.company.sample.R$drawable' appears in /data/app/com.companyname.demo_app-Ab0cDefG==/base.apk)'
What does cause the removal of the resource and how can it be prevented?
Edit 1:
The missing resource parking_slot is not in the drawable folder but in drawable-xhdpi-v4 for example. To check this I renamed the aar to zip and extracted it.
I then copied parking_slot it to the drawable folder, zipped and renamed it to aar again. Building is now without the aapt2 warning. Yet the app crashes again with:
Java.Lang.NoClassDefFoundError: 'Failed resolution of: Lcom/company/sample/R$drawable;'
I tested the aar-file with a native non-Xamarin app and no issue came to my attention which brings me to the conclusion that something might be broken with the way the Xamarin app is build.
Nevertheless the fix (or the workaround if you want) looks like this:
Rename aar to zip and unzip.
Search for the missing resource. In my case parking_slot
Copy the missing resource into your app-project
I think this works because of the way Androids fallback-system works.
I'm currently involved in a Delphi XE5 project and I'm facing a problem that I could not solve. I have a Delphi project group that conists of one EXE; this EXE loads multiple runtime BPL's dynamically. These BPL's are also part of the project group. However, when I run the application, I got the error 'Project {MyProject.exe} raised exception class EPackageError with message 'Cannot load package 'PumpMethod'. It contains unit 'FlEdit', which is also contained in package 'eXtractionUnitMethod'.
I already searched on SO, and I've found the cause. Especially Is "implicitly imported" always a bad thing in Delphi packages? was of big help. During compilation, both BPL's of my project, emit the following message:
[dcc32 Warning] PumpMethod.dpk(46): W1033 Unit 'FlEdit' implicitly imported into package 'PumpMethod'
Other one as well:
[dcc32 Warning] eXtractionUnitMethod.dpk(46): W1033 Unit 'FlEdit' implicitly imported into package 'eXtractionUnitMethod'
But the point is that FlEdit, a textbox control that allows only the input of floats, is already part of an installed package. This package, 'Spark190.bpl', contains the control, and thus also the FlEdit unit. I've registered it and the control appears on the Tool palette. This is the project with the control:
There is also a project DclSpark190.bpl, but that is a design time package (contains the registering of the controls). When I close this project group and create a new one, I can drag/drop 'My float edit' on a form, and this runs all fine.
When I now open the project group with the EXE, and build the BPL's I got this message:
This again seems okay for me. The Spark package (with the FlEdit) is now included in the 'requires' list:
But when I compile again, the 'the following changes...' is shown again. That looks abnormal to me; the Spark BPL is already included in the requires list? So:
Q1: Why is that happening? Is it a bug in Delphi XE5? Do I something wrong here?
Also, the 'FlEdit' implicitly imported into package 'PumpMethod' is still not away:
So:
Q2: I think I've put FlEdit in a separate package 'Spark'. Both BPL's contain 'Spark' in the required package list, but still the warning (W1033) is shown. What else can I do?
My project complied fine. But when I am running application in debug mode, I'm getting many runtime errors each time regarding resources. How can I resolve this?
EDIT
the Actual error is "project raised exception class EResNotFound with message 'Resource WW_DBN_PRIOR_ENABLED not found'
I have downloaded one DirectX Animation Project from a forum.
When I am trying to load the project in Delphi XE2 I am getting one error message:
“Class TDXDraw” and ” Class TDXDDIB” not found.
Then I load the project ignoring the error message. Again I am getting error message for the following component like “DXDraw1: TDXDraw”, “DXDIB1: TDXDIB” and “Background: TDXDIB”. Hence I have downloaded “DXSDK_Jun10.exe” and installed. But the error is the same.
I think, the error occurs due the DirectX components are not imported in DelphiXE2.
Which components are to be imported and how?
Those look like (un)DelphiX component names. Take a look at http://www.micrel.cz/Dx/index.html for DelphiXE2 support.
I am trying to preverify "signpost-commonshttp4-1.2.1.1.jar" file to use it in BlackBerry project
Here is the command im trying. Since it also needs "signpost-core-1.2.1.1.jar" to classpath which is already preverified.
C:\Eclipse_bb\plugins\net.rim.ejde.componentpack5.0.0_5.0.0.25\components\bin>
preverify.exe -classpath
"C:\Eclipse_bb\plugins\net.rim.ejde.componentpack5.0.0_5.
0.0.25\components\lib\net_rim_api.jar;C:\Program Files\Java\jdk1.6.0_25\jre\lib\
rt.jar;C:\Eclipse_bb\plugins\net.rim.ejde.componentpack5.0.0_5.0.0.25\components
\bin\output\signpost-core-1.2.1.1.jar"
signpost-commonshttp4-1.2.1.1.jar
Here i have added classpath of net_rim_api.jar, rt.jar & signpost-core-1.2.1.1.jar
It throws below Error
Error preverifying class
oauth.signpost.commonshttp.CommonsHttpOAuthConsumer
VERIFIER ERROR oauth/signpost/commonshttp/CommonsHttpOAuthConsumer.wrap(Ljava/lang/Object;)Loauth/signpost/http/HttpRequest;:
Illegal type in constant pool
If you mean signpost, with source code hosted on github by kaeppler, then it appears to be a Java-SE library. BlackBerry is a Java-ME device, so you will need to find a Java-ME compliant library. The preverifier errors you are seeing are the first indication that the Java-SE code won't work on BlackBerry.