- Upvotes Received
- 2
- Posts with Upvotes
- 2
- Upvoting Members
- 1
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
Here I have a program and I'm getting the following error ControlPanel is not abstract and does not override abstract method actionPerformed(java.awt.event.ActionEvent) in java.awt.event.ActionListener public class ControlPanel extends JPanel implements ActionListener ^ I don't fully seem to understand how the best way is to overcome this? [CODE]import java.awt.*; import javax.swing.*; … |
|
Hi I was wondering if anyone knows why I'm getting the reached end of file while parsing error. It mentions the bracket at the end of the file however when I remove it I get loads of errors. I know that I need to remove it however i dont understand … |
|
Im trying to call the reset method within this Connect4Model class is that possible. As you can see I have made and attempt and I'm getting 33 errors. I can't exactly see where I'm going wrong. If someone can guide me and let me know where I've gone wrong that … |
|
Hi, I have some code for a program that I'm doing. Basically I'm trying to write method whereby the reset() method takes two parameters which are number of columns and number of rows. I'm doing this method whereby I have to to move all the contents of the Connect4Model constructor … |
|
I'm new to doing Java and i was wondering if anyone would happen to know why this return type error is occurring. this is the following error C:\Users\..\Desktop\Connect4Model.invalid method declaration; return type required public reset(int numCols, int numRows) [CODE]public class Connect4Model { Connect4Column [] columns; // an array of columns … |
|
Im currently working on a Connect4 progrqam and I'm trying to convert a string into an integer. You will see that it is under the Connect4View. Its really frustrating as I'm struggling to find a way round this. Is there a possible solution to this and can someone please tell … |
|
I have this program where I need to get the suggested next move (a column index) and also call the 'go' method using this column as the parameter. This is what I have come up with so far. [B]Connect4Model[/B] [CODE]public class Connect4Model { Connect4Column [] columns; // an array of … |
|
Hi I'm currently doing a connect 4 program and I need to write an apporpiate get and set methods so that the other classes can access this information. ('State of the autoplay' is simply whether red or yellow (or no-one) is set to have the computer make their move). I've … |
|
[B]Connect4View[/B] [CODE]import java.awt.*; import java.awt.geom.*; import javax.swing.*; import java.awt.event.MouseListener; import java.awt.event.MouseEvent; import java.awt.event.ActionListener; import java.awt.event.ActionEvent; import javax.swing.JButton; public class Connect4View extends JFrame { DrawPanel canvas; Connect4Model model; ControlPanel myControlPanel, JRadioButton; public static void main(String[] args) { Connect4View w = new Connect4View(); w.setVisible(true); } public Connect4View() { setTitle("Connect4 solution"); setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); setSize(500,220); … |
|
[CODE]import java.awt.*; import java.awt.geom.*; import javax.swing.*; import java.awt.event.MouseListener; import java.awt.event.MouseEvent; import java.awt.event.ActionListener; import java.awt.event.ActionEvent; import javax.swing.JButton; public class Connect4View extends JFrame { DrawPanel canvas; Connect4Model model; ControlPanel myControlPanel, JRadioButton; public static void main(String[] args) { Connect4View w = new Connect4View(); w.setVisible(true); } public Connect4View() { setTitle("Connect4 solution"); setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); setSize(500,220); setLocation(300,300); … |
|
I'm currently doing a model, however its occurred that I'm getting 1 error that which is saying that the && operator. I don't fully understand why that is. If there is a solution to this that would be great, also with a good explanation why I have made this mistake … |
|
currently writing a program, and for some reason I'm getting these two errors which are really bugging me. I've tried adding the brackets and changing the statement and still no luck. If there is a possible solution that would be grateful. [B]Please note that I have solved the bracket error, … |
|
Hi basically I'm current doing a connect 4 program that consist of 3 separate programs Connect4Model, Connect 4 Column and Connect4View... I'm trying to compile and run my connect4View program but for some what reason I'm unable to do so. Below I have supplied the code for the 3 programs. … |