When I import androidx.activity.result.ActivityResult; my IDE says: can not resolve symbol 'result' as bellow:
.
In different similar situations, e.g., cannot access androidx activity result activityresultcaller and package androidx activity result does not exist, I see that the problem is solved by upgrading androidx.activity, androidx.appcompat, and androidx.fragment in the dependency part of the build.gradle.
I tried to upgrade different combination of the above packages in the module build.gradle, but non of them solved the problem.
Does anyone know how I can solve it? Thanks.
Related
I am supporting a Java 1.8 project (I know, I can see the eyes rolling)
The code base compiles using Maven with no error. Using VS Code there is an error. In order to resolved the error an import is required to access an inner class of a parent class in the current type hierarchy.
The version of Java is enforced by using the Maven Enforcer plugin. And VS Code is correctly configured also.
I think this has started to happened in the last 2 weeks, so I suspect an update to VS Code or an extension is likely to be the cause of the problem.
It was a bug in a VS Extension. (Which extension or the exact nature of the bug I am unsure. A colleague directed me to this fix.)
To get around this I added the following to the settings.json:
"java.compile.nullAnalysis.nonnull": [],
"java.compile.nullAnalysis.nullable": [],
Recently, I have been getting this error a lot and from some research, I got to know that the cause for it is the Xamarin.Build package.
The error text is as follows:
The "User7ZipPath" parameter is not supported by the "XamarinDownloadArchives" task. Verify the parameter exists on the task, and it is a settable public instance property.
I have tried the solution here and here but nothing helped.
My configuration is as follows:
Xamarin version: 4.7.10.38
Visual Studio 2015
The Error occurs when I update the xamarin build NuGet package, If anyone has a solution to this problem please help me.
Thanks.
At last after all this time I was able to solve this problem.
The problem was with Xamarin.Build.Download package.
Now this package had a problem in version 4.7 where it is unable to find the XamarinDownloadArchives task.
I checked a lot of places and for the answer but nothing seemed to help with this issue after that I removed the bin, obj folders for all my projects.
And Updated my Xamarin.Build.Download package to version 0.4.11 and everything started working.
I hope this helps someone else, In case of any queries related to this issue feel free to comment.
Finally! I've come with a solution. The problem was in the Xamarin.Build.Download package, v0.4.0. It was a annidated dependency (in iOS) of Xamarin.Forms.GoogleMaps v2.2.1.
Updating Xamarin.Forms.GoogleMaps to v2.3.0 (the most recent version as of today) solves the issue. Make sure to clean the solution after update NuGet dependencies, though.
So I enabled proguard on one of my application. I had some problems with it but I solved them all ( had to update proguard, make a symlink of android sdk without spaces )
Now I enabled pro guard on another application and i'm constantly getting this error:
The "Xamarin.Build.Download.XamarinBuildAndroidAarProguardConfigs" task could not be loaded from the assembly C:\Users\xxx\Desktop\xxx oud\packages\Xamarin.Build.Download.0.4.6\build\Xamarin.Build.Download.dll. Confirm that the <UsingTask> declaration is correct, that the assembly and all its dependencies are available, and that the task contains a public class that implements Microsoft.Build.Framework.ITask.
Anybody knows a way to solve this? Not sure what more I could add
I resolved my issue by restarting my computer
Edit: It seems restarting visual studio might be enough to resolve the problem
Restarting Visual Studio or my computer didn't work for me. The correct fix is to modify the package version of Xamarin.Build.Download to something that works.
For me, it meant changing the packages that referred to version 0.4.7 to 0.4.3.
It seems that a lot of people have had trouble with 0.4.7.
I want to use the example code from http://nlp.stanford.edu/software/openie.html but the line
System.out.println(sentence.get(SemanticGraphCoreAnnotations.EnhancedDependenciesAnnotation.class).toString(SemanticGraph.OutputFormat.LIST));
gives the error
SemanticGraphCoreAnnotations.EnhancedDependenciesAnnotation cannot be
resolved to a type
even though I imported edu.stanford.nlp.semgraph.SemanticGraphCoreAnnotations.
Eclipse suggests following quick fixes:
Change to "AlternativeDependenciesAnnotation"
(edu.stanford.nlp.semgraph.SemanticGraphCoreAnnotations;)
Change to "BasicDependenciesAnnotation"
(edu.stanford.nlp.semgraph.SemanticGraphCoreAnnotations;)
Applying the first fix leads to an java.lang.NullPointerException while the second fix gives following, rather unsatisfying results for the first sentence:
Loading clause searcher from
edu/stanford/nlp/models/naturalli/clauseSearcherModel.ser.gz...1.0 Obama be
bear in Hawaii
The import edu.stanford.nlp.semgraph.SemanticGraphCoreAnnotations.EnhancedDependenciesAnnotation; cannot be resolved and the import import edu.stanford.nlp.semgraph.SemanticGraphCoreAnnotations; does not help either.
I imported the JARs
joda-time
stanford-corenlp-3.6.0
stanford-corenlp-3.6.0-models
ejml-0.23
jollyday
xom
slf4j
slf4j-simple
I use CoreNLP 3.6.0. . I checked the SemanticGraphCoreAnnotations.java in edu.stanford.nlp.semgraph and it contains the EnhancedDependenciesAnnotation.class . How can I fix this issue?
It seems like the example code was written for the latest version of OpenIE, which is so far only on GitHub. The easiest way of getting this to run would probably be to clone the repository and compile CoreNLP yourself.
Use the stanford-corenlp-3.9.2 jar. This worked for me.
I am very new to Flex/Adobe FlashBuilder and I am running into an "import not found" error. Coming from a Java background, I understand this is more of a question of importing the equivalent of *.jar files in Flex/Flash. But how exactly I should go about resolving this, I am unaware.
Anybody want to help and get some points :) ?
If you're a beginner probably everything you import is included is Flex framework or is made by you. If you import your own classes remember to preserve package in their names (if the come from different package). Check classes names for spelling errors.
When using class in code you can use content assist (Ctrl+Space), then imports will be added automatically.
You can also check what quickfix lightbulb says (it's the same as in Eclipse as FBuilder is based on it).
You can make your question much better by including the code that causes the error.