Skip to content
Advertisement

Tag: static-methods

Cannot make a static reference to the non-static method

Building a multi-language application in Java. Getting an error when inserting String value from R.string resource XML file: This is the error message: Error: Cannot make a static reference to the non-static method getText(int) from the type Context How is this caused and how can I solve it? Answer Since getText() is non-static you cannot call it from a static

Advertisement