[Q] Help me please !!! - Android Q&A, Help & Troubleshooting

hello everyone ,
I'm a new in developing application .
OK , I followed guides how to install the SDK and eclipse now when I'm trying to write application i get theses error(s)
Multiple annotations found at this line:
- The markup in the document following the root element must be well-
formed.
- error: Error parsing XML: junk after document element
"R cannot be resolved to a variable"
please help me to find out a solution !

Related

[Q] [Noob] Having troubles importing a project

So I found this project online that lets me use the gyroscope of a phone. It has all the required files but when I import it into my workspace I get these three errors....
1) The project was not built since its build path is incomplete. Cannot find the class file for java.lang.Object. Fix the build path then try building this project
(java problem)
2) The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class file
(java problem)
3) Unable to resolve target 'android-5' AccessGyroscope Unknown Android (Target Problem)
Thanks in advanced
EDIT: Actually I think i just fix the problem

[Q] Android Proguard ERROR: Unknown verificatification type[10]

I am trying to build an apk file for release. My application lib contains a jar (probably obfuscated) from a third party vendor of one of my company's hard-wares. When I build the apk in debug mode it is successful, but when I try to do it in release mode using "ant release" it throws the following error.
Code:
BUILD FAILED
C:\adt-bundle-windows-x86_64\sdk\tools\ant\build.xml:868: Can't read [D:\Workspace\MyProject\libs\ThirdPartyJarV3.1.jar] (Can't process class [g.class] (Unknown verification type [10] in stack map frame))
I have successfully built apks in release mode for other projects (which doesn't have this jar file.)
It seems to be an issue around proguard not being able to read this class in the jar. I have looked through ProGuard's trouble shooting manual and also on google and found no help with this particular error:
Code:
(Unknown verification type [10] in stack map frame)
I also updated proguard from V4.7 to 4.10, but it still encounters the same error.
To my little mind it seems to be a problem with the jar itself and if so how do I fix it? Any help would be appreciated. TIA!
[P.S: I'm new to android]

Need help with porting a TW package

Hi guys!
I'm trying to port some package from Samsung ROM to CM following this guide and I'm stuck.
I decompiled the package, removed TW dependency from the manifest and now I'm adding additional classes from TW framework into this package. Everything was smooth so far as I was getting rid of "class not found" and similar messages in logcat by adding the missing class and recompiling the package.
But now I'm facing an issue, which I don't know how to fix:
When I try to run the app, I get the following message in logcat:
Code:
I/dalvikvm(30301): Could not find method com.sec.android.touchwiz.widget.TwAbsListView.isInDialog, referenced from method com.sec.android.touchwiz.widget.TwAbsListView.onHoverDrawableState
W/dalvikvm(30301): VFY: unable to resolve virtual method 9561: Lcom/sec/android/touchwiz/widget/TwAbsListView;.isInDialog ()Z
D/dalvikvm(30301): VFY: replacing opcode 0x74 at 0x006c
TwAbsListView class derives from TwAdapterView (from TwAbsListView.smali):
Code:
.super Lcom/sec/android/touchwiz/widget/TwAdapterView;
TwAdapterView derives from android.view.ViewGroup, which derives from android.view.View, which has a definition for "isInDialog". This what I found when decompiled framework.jar from the stock ROM:
smali\android\view\View.smali
Code:
.method public isInDialog()Z
However, based on official documentation this method does not exist in this class.
If I try to add android.view.ViewGroup and android.view.View from stock framework.jar into the package explicitly, I start getting "multiple definition" messages in logcat, and isInDialog still can't be resolved.
So, I'm currently stuck. Please advise. Is there something I'm doing wrong or not doing?
I guess with my last edit, I answered my own question.
It looks like Samsung decided to change implementation of android.view.View class to include isInDialog() method.
I just tried moving the definition of this method into com.sec.android.touchwiz.widget.TwAdapterView class, which derives from android.view.ViewGroup, and it looks like I no longer getting the message about missing isInDialog method.
There are still a gazillion other methods like this, but at least it's clear now what needs to be done.

[Q] Make a private Caldav server work

Hi, I recently purchased the ZTE Open C and want to synchronize its calendar with my own Caldav server.
Firefox rejects the connection tough, because the server has an invalid (self signed) certificate.
So i tried adding my certificate to firefox.
I found this guide:
http : // wiki . mozfr . org / Adding_CA_to_FirefoxOS
(Sorry for inserted spaces, won't let me post a link in first post.)
However I fail in the very first steps.
Code:
adb shell ls /data/b2g/mozilla/
Returns: /data/b2g/mozilla/: Permission denied
This means I dont have reading rights in this directory.
How do I get those rights, or alternativeley is there a better way to achieve my Caldav-Server goal?
Mathews123 said:
Hi, I recently purchased the ZTE Open C and want to synchronize its calendar with my own Caldav server.
Firefox rejects the connection tough, because the server has an invalid (self signed) certificate.
So i tried adding my certificate to firefox.
I found this guide:
http : // wiki . mozfr . org / Adding_CA_to_FirefoxOS
(Sorry for inserted spaces, won't let me post a link in first post.)
However I fail in the very first steps.
Code:
adb shell ls /data/b2g/mozilla/
Returns: /data/b2g/mozilla/: Permission denied
This means I dont have reading rights in this directory.
How do I get those rights, or alternativeley is there a better way to achieve my Caldav-Server goal?
Click to expand...
Click to collapse
You cannot use that method unless your phone is rooted, BUT...
I had the same problem and solved it a lot easier. Just launch the browser and input your server's URL. Then you will be warned about the not valid cert, add a permanent exception and that's all, now calendars should sync over HTTPS.
BTW this worked for me until FFOS v1.4. Today I updated to FFOS 2.1 and this trick stopped working, so you have been warned.
Thank you for the suggestion.
I am not running v2.0, so I tried it.
I could add the certificate.
However, when trying to connect, I get:
"Unknown Error. Please try again later."
Any way to figure out what's wrong now?
Seems to be a problem with the server I used. (Baikal)
Using a different one (Owncloud - sadly quite a lot bigger), it works with your tip.
So thanks for the help.
to ged rid of the "unknown error" in Caldav (etc.?)
doragasu said:
I had the same problem and solved it a lot easier. Just launch the browser and input your server's URL. Then you will be warned about the not valid cert, add a permanent exception and that's all, now calendars should sync over HTTPS.
Click to expand...
Click to collapse
thank you so much :victory:

My Android SDK AVD Create Error

AVD create error
plz help me, how can create offline ( some time i have no internet)

Categories

Resources