Results 1 to 6 of 6
Thread: Method Not Working
- 06-09-2011, 11:21 PM #1
Member
- Join Date
- Jun 2011
- Posts
- 20
- Rep Power
- 0
- 06-09-2011, 11:24 PM #2
Member
- Join Date
- Jun 2011
- Posts
- 20
- Rep Power
- 0
Here Is the method:
Java Code:public MidiEvent makeEvent(int comd, int chan, int one, int two, int tick) { try { ShortMessage a = new ShortMessage(); a.setMessage(comd, chan, one, two); MidiEvent event = new MidiEvent(a, tick); } catch(Exception ex) { ex.printStackTrace(); } return event; }
- 06-09-2011, 11:25 PM #3
Member
- Join Date
- Jun 2011
- Posts
- 20
- Rep Power
- 0
HERE IS THE ERROR:
Java Code:Updating property file: /home/jacob/NetBeansProjects/ScienceFairRMI/build/built-jar.properties Compiling 6 source files to /home/jacob/NetBeansProjects/ScienceFairRMI/build/classes /Jacob/Source/VisualMusicService.java:37: class, interface, or enum expected public MidiEvent makeEvent(int comd, int chan, int one, int two, int tick) { ^ /Jacob/Source/VisualMusicService.java:40: class, interface, or enum expected a.setMessage(comd, chan, one, two); ^ /Jacob/Source/VisualMusicService.java:41: class, interface, or enum expected MidiEvent event = new MidiEvent(a, tick); ^ /Jacob/Source/VisualMusicService.java:42: class, interface, or enum expected } catch(Exception ex) { ^ /Jacob/Source/VisualMusicService.java:44: class, interface, or enum expected } ^ /Jacob/Source/VisualMusicService.java:47: class, interface, or enum expected } ^ 6 errors /home/jacob/NetBeansProjects/ScienceFairRMI/nbproject/build-impl.xml:413: The following error occurred while executing this line: /home/jacob/NetBeansProjects/ScienceFairRMI/nbproject/build-impl.xml:199: Compile failed; see the compiler error output for details. BUILD FAILED (total time: 2 seconds)
-
Can we see some more code, especially the code around this method. Are you declaring a method inside of another method for instance?
- 06-10-2011, 01:06 AM #5
Member
- Join Date
- Jun 2011
- Posts
- 20
- Rep Power
- 0
*CLOSED*
I found out the problem
-
Similar Threads
-
ugh another method that isn't working
By jjth39347 in forum New To JavaReplies: 14Last Post: 04-17-2011, 09:57 PM -
Why isn't my toString method working
By arri3oi in forum New To JavaReplies: 7Last Post: 12-13-2010, 05:34 AM -
dispose() method not working
By R&R in forum New To JavaReplies: 19Last Post: 11-15-2010, 01:46 AM -
Can't find out how to get this method working :)
By Shadaw in forum Java AppletsReplies: 2Last Post: 12-29-2008, 05:35 PM -
makeButton method not working
By ljk8950 in forum AWT / SwingReplies: 8Last Post: 08-10-2008, 10:20 PM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks