not applicable for the ' main.dart ' configuration - java

i couldn't run my flutter application on a real device neither on the emulator even thought the flutter sdk is installed and it's path is set does anybody knows what can be the cause of it ?
here's how it is shown in android studio
when checked the project structure it says how can i also fix this ?
here's the command that i made because they said that i should verifiy that my phone can be seen by the flutter sdk and that i should make sure that there is no error left by the 'flutter doctor' command
but nothing did actually help

I would make sure to get rid of that Android licenses and VS Code error.
Then on android studio, from the menu bar: "Tools > Device Manager > Create new device". Create a new virtual emulator from there and delete any old ones.
Also, I would recommend to ask for help after your "flutter doctor -v" comes out clean with "No issues found!".

Related

Flutter can't accept android licenses

I have set up Flutter in my Ubuntu Machine, but cannot accept the Android Licenses, thus am not able to use the tool.
Flutter appears to be working fine in root, but when I try to run flutter doctor it tells me that Android Licenses have not been accepted, even though I did accept them. If I try to type again flutter doctor --android-licenses it works as though I never accepted the licenses. If I accept all of them once more, it just gets back to as though I never accepted them.
I could use flutter in root, but that's not really secure and I would rather have it usable as a normal user.
EDIT:
The solution appears to lie in the repositories.cfg file. It appeared to be missing and adding a blank file with that name solved the issue.
Go to your $ANDROID_HOME/tools/bin and open the command line
Run the following command ./sdkmanager --licenses
Accept All licenses listed there.

android studio wont install app with code android.os.Binder.execTransact(Binder.java:697

After a little of playing with java codes in android studio, suddenly it stopped installing apps on avd. I can have the apk output and install it on my phone(there I get the play protect error of unconfirmed developer ) as I disabled play protect on my avd. I have no idea what the problem is.
every time I try to do that android studio retries to uninstall the app from avd and the app is not on the apps list of avd device the error code is this:
Unknown failure (at android.os.Binder.execTransact(Binder.java:697))
I have done the solution on this post but it didn't help.
this post:https://stackoverflow.com/questions/44202530/error-unknown-failure-at-android-os-binder-exectransactbinder-java565-error
Edit
another error raised:
error pic
the problem was that with the ioutils that i was adding on dependencies some how made compatibility problem with the system cpu (the problem that i didn't have on my android phone)so next time it happens to any one first check your dependencies by going to:
File -> project structure -> dependencies tab
delete any unusually item there that did the trick for me
Note That it may make your app to act abnormally

Cannot launch AVD in emulator. ?android studio

my emulator is not runnnig and gives the error in image below
error image
and test at run window
C:\Users\Wahlah\AppData\Local\Android\sdk\tools\emulator.exe
-netdelay gprs -netspeed full -avd Nexus_4_API_21
This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.
terminate called after throwing an instance of 'std::logic_error'
what(): basic_string::_S_construct null not valid
and second error exist is this image
ERROR 2
I got the same problem with the same logged warnings and errors (and the alert as well).
Although from the first logged line (C:\...emulator.exe) it looked like the tools did find the emulator - my problem was resolved only after I followed this answer, and changed the ANDROID_SDK_ROOT environment variable (which pointed to a folder above the sdk instead to the sdk's folder itself).
So I changed it from
C:\Users\<username>\AppData\Local\Android
to
C:\Users\<username>\AppData\Local\Android\sdk
and... voila! The emulator is running properly.
I should note that I'm working on Windows and from the question it looks like AIR TRAVELS was as well.
I had the same problem and fixed it by selecting Cold Boot from the Tools > Android > AVD Manager > Edit > Show Advanced > Boot option from Quick Boot to Cold Boot.
Hope this helps.
You can fix this error, need configure the device again. Download all the necessary libraries through the SDK manager.

my eclipse install another app instead of mine in emulator

I'm having a problem with my eclipse i have edited my app and it's ready with no error shows but now when i run it into my emulator it runs another app i have in my eclipse so i deleted the app and still i run the application i want in the eclipse and still it shows the old app that i didn't even ask to install it in my emulator so it's installing an app that i don't have at first place in my eclipse i don't know how it is possible i cleaned my project and still the problem is there and changed my emulator still its install the old app for me
uninstall the app from the emulator and check in your run configuration about the running app and try with new emulator
Be sure you have selected in package explorer the app you want to run. Try to unistall the app from the emulator or create a new device on emulator. Hope this help.
Check the Run configuration: Run->Run configuration. Under the Android tab, choose your project. If you run in Debug, you have similar option too.
Another similar case I saw, is that some application was installed, but the name was not updated. Verify the names of your application in both the strings.xml and the Manifest. (If you create a project by duplicating another one, it might be the problem).

Android Emulator not loading on netbeans

I just downloaded the android sdk from the adnroid site and followed this tutorial to set it up on netbeans. Everything to seem to have installed fine but whenever i try to run the application this window pops up:
alt text http://img80.imageshack.us/img80/4327/androidemulator.png
What I am assuming it asking me to choose the emulator, but it is not showing up on the list. Is there a reason why?
I don't use netbeans, but it looks like you don't have any AVD's created, and if you do, then there is probably a way to associate them that you are missing in netbeans. You can check here to create an AVD http://developer.android.com/guide/developing/tools/avd.html
But I would just use eclipse if possible, the integration works really well, and it was written to run in eclipse, so there are less issues and hurdles.
Also see Running Your Application section of http://developer.android.com/guide/developing/other-ide.html that will describe how to launch the app from the tools outside of the IDE.
I have the same problem with you. But i have my emulator works now.
Are you have to do is running your Android SDK Manager, then click Virtual devices, and Make new AVD device.
Click New. Then fill name, and select Target (Platform of your Android), Skin, and hardware.
Then click Create AVD to finish.
Now you have device to choose. :)
go in C:\Program Files\Android\android-sdk\SDK Manager.exe and create the virtual device. After it appear in device list.
Thats it.
Open Sdk manager
Tool Manage AVD
Select and start AVD. wait open.
Goto netbean Run project.
U must see project run in AVD.
Success..
The article at the link #broschb had posted is explaining how to create an AVD using command line. Do exactly what is says there (it's very easy). Once you have created the AVD it will appear in the AVD list in Netbeans. Actually, if you have only one AVD it will start by default when you run your app.
run the avd manager which is location in the android-sdk folder and then create a new avd,but be sure you have already downloaded ARM EABI system image tool set.
Just create avd (android virtual device) and run it..
like android -avd "name of your avd"
Then try to run your application.
It will ask you to select the virtual device that you have started above.
Thats it.

Categories

Resources