First find where the source for the method is. Without the source you will not be able to change it.
If it is in a class with generic definitions, you might be able to define the class with a...
Type: Posts; User: Norm
First find where the source for the method is. Without the source you will not be able to change it.
If it is in a class with generic definitions, you might be able to define the class with a...
The error posted in post #1 is a compiler error. The compiler says this line is not correctly coded:
List<Donors> resultList = query.getResultList();
The getResultList() is not defined to...
If that we true you would code:
String aString = query.getResultList();
Can you ask some help from the person that wrote the code you are working with?
Look at the definition for the getResultList() method. What is it defined to return?
For example this method is defined to return a String:
public String getActionCommand() {
What data type is the object returned by the getResultList() method?
The variable to the left of the = should be the same data type.
What does the getResultList() method return?
Is it a List<Donors> object?
Or just a List?
The compiler wants a List<Donors> object (the required: item).
Please post the source code for the lines where the compiler is saying there is an error.