Skip to main content



      Home
Home » Newcomers » Newcomers » Opening Files(I'm having a tough time understanding Eclipse...)
Opening Files [message #910595] Mon, 10 September 2012 00:03 Go to next message
Eclipse UserFriend
Is it possible to simply open a file, save/compile it, and run it? I've been at it for a few hours and I'm only able to run a new class file created under a project. I can not open simply open and run a file, and even with a project up I am unable to bring an existing file into the project; it just opens and I have the same problem.

Is this intentional? Am I missing something? I suppose I could just open the existing files and copy/paste their contents into a New class under a Project, but that seems awfully tedious and far too time-consuming to be reasonable.
Re: Opening Files [message #910654 is a reply to message #910595] Mon, 10 September 2012 02:53 Go to previous messageGo to next message
Eclipse UserFriend
Yes, the project is usually what tells Eclipse what you're building against, and allows it to incrementally build your sources as you change them. Past the simple 'Hello, World' case, you won't be dealing with a singular class file.
Re: Opening Files [message #910656 is a reply to message #910595] Mon, 10 September 2012 02:52 Go to previous messageGo to next message
Eclipse UserFriend
Yes, you need to have the files in your workspace projects. You can use
File->Import...->General->* to import things into your workspace.
You'll want to import them into a Java Project's source folder.


On 10/09/2012 6:03 AM, D F wrote:
> Is it possible to simply open a file, save/compile it, and run it?
> I've been at it for a few hours and I'm only able to run a new class
> file created under a project. I can not open simply open and run a
> file, and even with a project up I am unable to bring an existing file
> into the project; it just opens and I have the same problem.
>
> Is this intentional? Am I missing something? I suppose I could just
> open the existing files and copy/paste their contents into a New class
> under a Project, but that seems awfully tedious and far too
> time-consuming to be reasonable.
>
Re: Opening Files [message #910855 is a reply to message #910595] Mon, 10 September 2012 09:59 Go to previous message
Eclipse UserFriend
On 9/9/2012 10:03 PM, D F wrote:
> Is it possible to simply open a file, save/compile it, and run it? I've
> been at it for a few hours and I'm only able to run a new class file
> created under a project. I can not open simply open and run a file, and
> even with a project up I am unable to bring an existing file into the
> project; it just opens and I have the same problem.
>
> Is this intentional? Am I missing something? I suppose I could just open
> the existing files and copy/paste their contents into a New class under
> a Project, but that seems awfully tedious and far too time-consuming to
> be reasonable.

Eclipse is really for building applications.

In my most active work spaces, I keep a scratch project around in which
I can just throw something quick to try out
Previous Topic:Arithmetics Example
Next Topic:exit code=13
Goto Forum:
  


Current Time: Tue Jul 15 10:50:19 EDT 2025

Powered by FUDForum. Page generated in 0.11434 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top