• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Liutauras Vilda
  • Bear Bibeault
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Piet Souris
  • salvin francis
  • Stephan van Hulst
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Jj Roberts

Why did I get this error: LocalVariableDeclarationStatement?

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I got an error that I've never seen before and don't understand what it's telling me

LocalVariableDeclarationStatement
Multiple markers at this line
- void is an invalid type for the variable myMethod ( Why is this?)
- Syntax error, insert ";" to complete (I don't see where I missed a ;)


 
Charles Earley
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Duh! Found my mistake! Smh....
 
Ranch Hand
Posts: 570
3
Android Eclipse IDE Java
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Consider post your answer here.You never know, somebody else might have the same problem and come here searching for solutions.
 
Charles Earley
Greenhorn
Posts: 7
  • Likes 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I put myMethod in the main method. Should be outside.
 
Charles Earley
Greenhorn
Posts: 7
  • Likes 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Complete code here

 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic