I got this in my folders :
But on my android device, i have a file not found error because it looks for andoid_assets instead...
Where can i set my folder path ?
fixed,
do not put underscores as prefix for folder name..
Need to access the asset files from your main root(projectname->www) only on android device need to set the path like file:///android_asset/www/yourfilepath
E.g., file:///android_asset/www/images/xyz.png
Related
I am making an app which use the following java line:
Net dnnNet = Dnn.readNetFromONNX("path\to\file");
As you can see, readNetFromONNX requires path to onnx file.
So I put my onnx file under assest folder, so I can use it at run time.
The problem is I you can only read assets foler with AssestManager and inputstream... the readNetFromONNX needs path...
How do I overcome this probelm? Is there a way to get the path of the file at run time? Maybe other folder?
Thanks from advance
I need to extract the application icon in a APK file.
I'm using aapt to know the icon location inside the APK file.
I'm running aapt dump badging com.example.app.apk:
this command returns me:
(...)
application-icon-120:'res/drawable-anydpi-v26/ic_launcher.xml'
application-icon-160:'res/drawable-anydpi-v26/ic_launcher.xml'
application-icon-240:'res/drawable-anydpi-v26/ic_launcher.xml'
application-icon-320:'res/drawable-anydpi-v26/ic_launcher.xml'
application-icon-480:'res/drawable-anydpi-v26/ic_launcher.xml'
application-icon-640:'res/drawable-anydpi-v26/ic_launcher.xml'
application-icon-65534:'res/drawable-anydpi-v26/ic_launcher.xml'
(...)
but as you can see it returns me the location of an XML file which in some way is encrypted. I know this XML file has the real path for the PNG file icon, but I don't know how can I get that real path (or how can I decrypt the XML and then parse it).
Is there any way to get the real path for an application icon inside a APK file with a XML pointing to other location?
Thanks!
Check out this project,
https://github.com/iBotPeaches/Apktool
It can be used to unarchive an APK, including the assets.
apktool d <your>.apk
try extract your apk file with 7-zip and you will get res foulder
I am trying to copy image file to backup it on my desktop which is linux mint (17.3 or Rosa) installed. I am using Infinix X510 phone with the newest version of android 6. At the beginning it was OK. But, at the end i get the message
“libmtp error: Could not get file from device”
I tried the solution as found by Googling here https://askubuntu.com/questions/879029/libmtp-error-could-not-get-file-from-device-on-attempting-to-transfer-files
But, it wasn't working for me. Is there a way to solve this matter? I need file to support my company job which supplying cosmetics.
Try compressing the file to a compressed format(tar,zip).Copy the file and then decompress it.
Changing the filename was the solution for me e.g: file.mkv to file.zip
Try to rename file, make sure file name not contain (-) (:) etc. Just rename it to alphabet
I want to add some resources to android 5.0 framework,and I added some drawable/anim/layout files to /framework/base/core/res/res,and add "" in the public.xml in values directory,then I use "mm" at "/frameworks/base/core/res" to make a framework-res.apk ,and "adb put framework-res.apk /system/framework" ,but it does not work ,system crashes!
How can I add some resources to framework and it work?
You just add your resources under /framework/base/core/res/res/Resource_Type_Folder/.
Make an entry of your resource in public.xml under /framework/base/core/res/res/values/public.xml
That's it.
Build your image and you can access it from any app using following syntax:
#android:resoure_type/resource_name
BR,
Rahul
I need to have some files in android assets folder, how can I add them using QtCreator/QMake?
Assuming you have the following structure in your source directory:
foo.pro
extra_data/file1
extra_data/file2
…
Adding the following to foo.pro should deploy the extra_data folder to assets://extra_data (exact path might differ, cannot verify right now) in the APK:
folder_01.source = extra_data
folder_01.target = extra_data
DEPLOYMENTFOLDERS += folder_01
If you are developing the application, then simply copy/paste the files in assets folder.
But if your application is already built and available as .apk file then you cannot modify any of its content.
Copying files to /5.2.0/android_armv7/src/android/java/assets did the trick