• 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
  • Liutauras Vilda
  • Tim Cooke
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Knute Snortum
  • paul wheaton
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Ron McLeod
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Tim Holloway
  • Carey Brown
  • salvin francis

Error: The active editor does not contain a main type

 
Ranch Hand
Posts: 76
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am using eclipse 1.3.2. When i tried to run a program having a main class as java application, it gives an dialog popup 'The active editor does not contain a main type'. Donno why eclipse is not recognizes the main method.

Even when i tried to use run and create a new launch configuration, there is a box to give the main class trying to run. On clicking browse button to get the main class, my main class is not returned in the search result.

This was working before. I moved the physical location of the project from one place to another place (in C Drive) and configured as new java project. After this change, this gave the error. Please give me pointers on solving this issue.
 
Ranch Hand
Posts: 234
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I am using eclipse 1.3.2


I guess this is a typo (and should be something like 3.2.1)?

Are you sure you don't have some typo in the declaration of your main method?
(is it public and static?)
 
Don't listen to Steve. Just read this tiny ad:
create, convert, edit or print DOC and DOCX in Java
https://products.aspose.com/words/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!