Could not find configuration file (pubspec.yaml) on windows - android

I'm using flutter with Dart on AndoidStudio, tried to add image to my app and to do so I need to
find pubspec.yaml file so that I can add image directory but the problem is that there is no pubspec.yaml file in my project files.
enter image description here

the image you uploaded shows your android folder. Open your project folder which will contain pubspec.yaml file along android, ios folder etc.

Related

how to create folder in android/app/src/main with expo eas?

I'm working on to make android application with react-native and expo.
I'm using library to render some 3d object.
.obj format file need to be in android/app/src/main/assets to use that library.
I can load pictures something like .jpg, .png but .obj.
I don't control the android folder with git because it creates too much different files every time. (git ignored)
expo-file-system library doesn't save the file in exact address that I want(android/app/src/main/assets).
If there is a any way to save file with that library, please tell me.
So I created assets folder after expo build android folder.
Then I put .obj file manually(copy and paste) with my self.
Do I have to create folder manually whenever expo builds android folder?
And even I put my file in assets folder, the file is not showing after eas build .....
Please help

Xamarin Android assets folder not updating when building the solution

I have a Xamarin.Forms app that needs to read data from a json file. I placed the file into the Android assets folder and selected the build action AndroidAssets
Then I try to load the file in MainActivity with Assets.Open(filename) and I get a FileNotFoundException. I deleted the Android and PCL bin folders and tried to build the project again but got the same result. Then I opened the .apk file in WinRar and when I go to the assets folder, the files that I added to the project are not there.
Does anyone have any idea what's the problem here?
Did you set the files as embedded resources from the file properties?
If you not, right click on the file -> Properties -> set as Embedded Resources in Build Action
The problem was with using the "-" character in resource file names. Changed it as suggested by York Shen and it started working as it was supposed to.

Cordova Android Build of icon path not found

On typing cordova build android in a DOS box, nothing is built, but instead I see an error message:
Error: Source path does not exist: resources/android/icon/drawable-hdpi-icon.png
I have updated Cordova, android rm & add everything still no luck. I am a native android developer feeling very hard to learn Cordova hybrid app development please guide me to descriptive link too.
If you project is created using Ionic then do the following :-
Create the folder name "resources" in your projects root directory.
Place your icon file name as "icon.png" in the resouces folder.
Icons should be 192x192 px without rounded corners.
Place your splash file name as "splash.png" in the resources folder.
Splashscreens should be 2208x2208 px, with the image centered in the
middle.
After doing the above open you cli , go to the root of your project and enter
ionic cordova resources
your icon and splash will be generated and config file also will be updated.
If you have created this project using cordova/phonegap :-
you can either remove the icon tag you specified in your config.xml completely
or
create the icon and place it in "www/res/icon.png".
Update the path in config.xml
remove all the icon path and just add this line to your config.xml
<icon src="www/res/icon.png"/>

phonegap icon/splash screen path for cli build

While creating my app I issues the command:
phonegap create appdir com.site.myapp myapp
so now the appdir folder has the following.
-.cordova
-hooks
-platforms
-plugins
-www
-config.xml-----(config.xml is generated at top level)
In my www folder i have one index.html and one image that I want to use as my icon
www
-index.html
-icon.png
1)so which do I give the path for the tag in the config.xml file?
2)where do I put the config file do i need to move the config file inside the www folder like in phonegapbuild
I have tried various path combinations but none is working
Using Android, The application icon is located here: res/drawable/
So replace icon.png there.
Same thing for splash screen, replacing res/drawable/screen.png.

Location of default image button in android?

Does anyone know where I can find the default image used for button in android? It will be a nine-patch with the .9.png extensions.
You will find it in the android.jar file in your sdk folder.
For example mine is in
C:\Program Files (x86)\Android\android-sdk\platforms\android-8\android.jar
(for SDK version 8, to get a different version the change the "android-8" part of the path)
You can extract the .jar using winzip/7z etc as it is just a zip file in disguise. You will then find the drawables folder in the folders you unzipped.
Find in the drawable-* folders in the following path
C:\Program Files (x86)\Android\android-sdk\platforms\android-*\data\res

Categories

Resources