I think they are different. This statement from post#15:
if(x <= 20){
is NOT in post#9.
You said that the code in post#9 worked
The code in post #15 does not work. Add some printlns to...
Type: Posts; User: Norm
I think they are different. This statement from post#15:
if(x <= 20){
is NOT in post#9.
You said that the code in post#9 worked
The code in post #15 does not work. Add some printlns to...
You'll have to post the code if you want any help with it.
Did you see this in my last post?
If the code in post#9 printed out correct X&Y values for the corners,
why didn't you use the logic...
Is it being assigned a null value?
Object obj1 = null;
Object obj2 = obj1; // obj2 will be null here because obj1 is null
Did you see this in my last post?
If the code in post#9 printed out...
What variable on line 46 has a null value? Add a println to print out the values of all the variables on line 46 if you can't tell which variable could be null.
If the code in post#9 printed...
Not much without the code.
What variable is null and why is it null?
I'm done for tonight. Back tomorrow.
If it has any value, it won't be null and cause a NullPointerException.
If you don't post the full text of the error message and the code, there is very little anyone can do to help you.
The default value for object variables is null. If they are not assigned a non-null value, their value will still be null.
Check the logic and add printlns to show where dbImage is given a value.
What printed out in the testing program? Can you post the testing program and its output?
Also post the current version of your code
and the full text of the error messages.
To work out the logic you first need to make a drawing and label the upper left corner of each square.
The look at the relationship of the x an y values for all the squares in the columns on each...
Look at line 43 and find the variable with the null value. Then backtrack in the code to find out why that variable does not have a valid non-null value.