Entrypoint is not a Dart file in flutter - flutter

i have been reading more than 10 similiar question for this error and still cant solve my problem
im trying delete .idea and still cant solve it,trying add content root in my project too, but the problem isn`t solved, can you help me?, thanks

Apart from the warning 'Entrypoint is not a dart file' my main.dart was also showing the code in just one plain color (white) with no intellisense whatsoever.
After deleting .ideal/ folder and dart_tools, uninstalling/re-instaling android studio, and other attempts, there was no luck and no solution on google addressing this very error message so i decided to try this:
After saving my work
Go To File in Android Studio Menu at the top
Manage IDE Settings
Restore Default Settings
It will redownload android sdk and setup everything as new.
Paste your codes from previous projects and ride on!

Related

How do I access the "New Module" option in Android Studio?

I'm attempting to follow these instructions to integrate the Bolt Mobile SDK into my Flutter project, where step 5a is, after opening my project in Android Studio:
Click File, select New, then select New Module.
However, I do not appear to have any such option:
Is there something I need to do to enable it? Was it moved somewhere else, or merged into another option (Import Module doesn't seem to cover it)? The Android web site confirms that it should be there, and that page was last updated 8 days ago as of this writing.
If you are trying to access the module into the main project than follow the instructions:
Move the module in your project directory.
Suppose if your module name is - library
In setting.gradle file add this lines
include ':library'
In build.gradle file, inside the dependencies block add this lines
implementation project (':library')
.........................................
Happy coding :)
Follow the instructions on image
After that you will find multiple options, go to new and then at the top you will find New Module option. From there you can create new module or you can import, do as per your requirement.
Happy coding :)
I give a solution for this issue,
Just follow my steps :
Step 1
Step 2
Step 3
Feel free to ask if any problem comes.
Happy coding :)
I think you have to check your flutter sdk set up because when you set up your flutter sdk it will be added automatically.
And If you done this.
Then check that did you add flutter plugin into android studio ? If not then follow this step.
Go to setings
Then search plugin
then search flutter into plugin
section.
Then click on install on install button into flutter plugin
Then restart your android studio
I hope this problem will be solved because this is probable solution for this problem .
Thank you .

I Have to add JAVA_HOME to gradle.properties every time I start a new flutter project in vs code! how to solve it once & for all?

I am starting to learn flutter & by extension, dart.
However! every time I follow a tutorial & start a new project in vs code I have to go to the file called gradle.properties and add org.gradle.java.home=C:/Program Files/Java/jdk-11.0.9 or else I won't be able to run/debug!
Because I get an error saying I need java 11 while I'm using 1.8 which is TOTALLY not true because my java_home (& path) variable is set to java 11, which is the directory i add through the previously mentioned line of code.
Please, I do not know what to do, and googling is no longer helping as no result I'm finding is working. I need someone to tell me what to do to solve this... issue because I am sure something can be done once instead of repeating this process every time.
Note: I found on google people saying stuff like:
Set Gradle jdk path to java 11 in android studio
but I do not have that option.
Also, please note that I am still a beginner-level developer with little practical experience - Sorry if my question is, well, stupid.
attached images:
Gradle Error if gradle.properties not modified
gradle.properties file
my Android Studio settings
Android Studio settings found on the internet
~Have a nice day.
I had same problem after updating Flutter. Try to check your JAVA version java -version (update it, if it less than 8).
Then update Android SDK: https://stackoverflow.com/a/61434900/13506243
This helped me.

Project Template Not Updating on Build

I've been working on a project template today, first time doing so but it has been going alright. I'm almost finished but have now run into some weird issue I can't figure out.
For some reason which I don't know, whenever I try and debug my project template it is now stuck to using some old version of it. No matter what or how much I change then rebuild and try to debug - it still uses some weird old version stuck in some sort of limbo.
I can't seem to figure out where it's finding this file, I've cleared my temp folder. It doesn't show up as installed when I go to Manage Extensions in Visual Studio.
Any ideas what might have happened? There are no errors or warnings.
I was able to solve this by deleting all files inside %LOCALAPPDATA%\Microsoft\VisualStudio\16.0_cfa111feExp\Extensions. After doing so, I restarted VS and loaded up my project and rebuild (not build) the solution.
After that, it now shows the up-to-date version of the project template. What caused this and how to potentially prevent it in the future - I still have absolutely no idea.
I use Visual Studio 2019 Version 16.4.2

Rendering Problems: class could not be instantiated: - android.support.design.widget.FloatingActionButton

I recently changed over to Android Studio from Eclipse and when starting new projects with a blank activity template have come across the following message in my main layout xml file
I looked up SO and tried the following solutions:
*Raising the minSDK in the build.gradle file - it raised additional problems of missing styles
*Trying to update Android Studio - I was up-to-date even in the "Canary" setting
*Reducing the API level of the layout - when I went down to API 22, the image disappeared altogether.
In Eclipse, I would go to Properties/Android and see if anything needed to be updated, or go to Build Path to see if it looked OK.
What can I do here? Thanks:)
I have just found an answer on SO that worked for me. (I am sorry but I haven't figured out how to quote the question no.)
I also got this problem today,
Check your build.gradle file, do you use support design lib version
23.2, like
compile 'com.android.support:design:23.2.0' if so, change it to
version 23.1.0
compile 'com.android.support:design:23.1.0' then rebuild your
project... seems version 23.2 is still buggy

Metro App cannot open package.appxmanifest

I have this Metro App project that I just tried building for the Windows Store.
After completing the buildprocess (with no errors) I can't open the appxmanifest xml file in visual studio anymore. If I select "STORE" > "Edit App Manifest" I get the following error message: "Value does not fall within the expected range."
I can't open any manifest file in any project now.
Does anybody know whats happening, do I need to reinstall Visual Studio or whats going on?
I'm pretty desperate, so any suggestions are welcome.
Found the answer here http://forums.asp.net/t/1836720.aspx/ - so i tried deleting the .suo files from the project, and now it seems to work. I have no clue why that would affect newly created/other/checked out projects, weird behavior indeed?
(Since I am both new to SO and to Visual Studio, I don't know if answering my own question is considered bad practice, if it is, please let me know what I should do instead)
It's an XML file, so you could try to open it with a text editor to figure out if there's an invalid value set somewhere. You could always compare to a default Package.appxmanifest from a new project.
Can your fellow coworker open the manifesting file you're having trouble with?
The first thing to check is to make sure you are running Visual Studio as an admin. (Right click, run as administrator)
Try creating a completely new project. Save it without modifications. Build it. See if you can open the manifesting file in that project. If you can't, try a XAML/C# project instead of JS just to see if something is wrong with the specific project type.
And before you try completely reinstalling, you might try resetting your Visual Studio settings. Make sure to take a backup just in case you need to get your environment back to where it was once you find the issue.
http://msdn.microsoft.com/en-us/library/ms247075.aspx