sometimes it's useful to specify the column size of your JTextFields. For instance,
JTextField helperDate = new JTextField(7);
Type: Posts; User: curmudgeon
sometimes it's useful to specify the column size of your JTextFields. For instance,
JTextField helperDate = new JTextField(7);
If you have a question, ask for help here by posting what you've done and what confuses you. Do not ask for "tutoring assistance" since that's not what this forum is for. If that is what you need,...
Spam posts removed. Thread locked.
words30 is a non-generic ArrayList, and as such, it only knows that it holds Objects. Your options include:
Make words30 a generic ArrayList<String>. This is likely the most elegant and practical...
You'll want to ask this in a Javascript forum not a Java forum. The languages are pretty far apart you know. Google can help you find the correct spot to post this.
You will want to post the actual line of code that is throwing the NPE.
So yeah, you're still not telling us which variable is null.
The lines may be created by borders, but it's hard to tell as your images are so small.
Have you considered using GridBagLayout, not GridLayout for the middle JPanel?
Where is the code that prints each cell's value? I don't see it posted anywhere.
Why did you abandon this thread?
The reason I ask is because your output looks completely correct and expected to me. I wonder if you are confused as to the concept of static fields, but I have to await your answer to know with...
What part of your output is "wrong or unexpected"?
--- Update ---
The reason I ask is because your output looks completely correct and expected to me. I wonder if you are confused as to the...
You give us things we don't need: a due date, you give us some requirements and some code (unformatted), but you don't ask a specific answerable question, one that tells us where you're stuck...
Closed question as it is little more than a homework dump. Original poster, next time please show your efforts and ask a specific question. No one wants to do your assignments for you.
--- Update...
Your best bit is to:
First and foremost, always use the formatting tools of whatever forum you're posting your code on so that the code retains its formatting. Different forums use different...
Again, a variable cannot be synchronized. What probably must be synchronized is the method that sets this variable. Make this variable volatile, and then you will need to use a shared Object that it...
What you've done is to post your entire assignment without showing what work you've done, without asking a specific question, and that is not how to get help here (or at any forum). For one, we have...
Whoa -- that's a lot of unformatted code up there! Please edit your original post (press the Edit Post button at the bottom of your question) and surround your pasted code with code tags:
...
The firstMiddleLast() method is a method of the Name class, and to call it, you must call it on a Name object. You're calling it as if it were a static method of the NameTest class, and it's not. So...
This looks like a homework assignment. Please post the actual assignment text. Let's see exactly what your requirements are.
If it's to be a constant, then make it a final variable. Or if I'm misunderstanding you, please clarify your problem some more.
This doesn't make sense. What do you mean by "synchronize" a variable. This cannot be done in Java, period. You can synchronize on an *object* not a variable, and it's often an object that is not...
That's a heck of a lot of code to ask us to go through. I suggest:
1) please surround your posted code with code tags:
// ... your code goes here
This way your code will retain its...
Please explain why you would expect that. Understand that you're calling the calculateRent() method on the flats variable. Please show where you make settings to the object that this variable...