Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Newcomers » Newcomers » How to influence current directory when starting Eclipse 3.0.1 (Windows)
How to influence current directory when starting Eclipse 3.0.1 (Windows) [message #49273] Fri, 08 April 2005 14:56 Go to next message
Eclipse UserFriend
Originally posted by: Martin.Purkert.bawag.com

Hi there!
We have the following constellation.

Unfortunately, we have two projects in Eclipse. One containing Java-Code
and one containing lots of resources as xml-files etc.

Due to bad design (not from me ;-) ) the java-code reads the resource
files with relative paths from the current dir. Under Eclipse 2.1 we met
this requirement by starting Eclipse from a Link setting the current dir
to the resource project directory.

This has no effect with Eclipse 3.0.1 the current dir is changed to the
actual project dir. So in our case when executing, the java code does not
find it's resource files.

I want to ask if there is some possibility to override that behaviour and
to set the current dir in Eclipse 3.0.1.

thx in advance
regards
Martin Purkert
Re: How to influence current directory when starting Eclipse 3.0.1 (Windows) [message #49419 is a reply to message #49273] Fri, 08 April 2005 16:53 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: wegener.cboenospam.com

Martin Purkert wrote:

> Hi there!
> We have the following constellation.

> Unfortunately, we have two projects in Eclipse. One containing Java-Code
> and one containing lots of resources as xml-files etc.

> Due to bad design (not from me ;-) ) the java-code reads the resource
> files with relative paths from the current dir. Under Eclipse 2.1 we met
> this requirement by starting Eclipse from a Link setting the current dir
> to the resource project directory.

> This has no effect with Eclipse 3.0.1 the current dir is changed to the
> actual project dir. So in our case when executing, the java code does not
> find it's resource files.

> I want to ask if there is some possibility to override that behaviour and
> to set the current dir in Eclipse 3.0.1.

> thx in advance
> regards
> Martin Purkert

It sounds like you are developing java applications and not plugins for
eclipse. In this case, you can set the working directory in the launch
configuration. It is at the bottom of the Arguments tab.
Re: How to influence current directory when starting Eclipse 3.0.1 (Windows) [message #50409 is a reply to message #49419] Mon, 11 April 2005 06:58 Go to previous message
Eclipse UserFriend
Originally posted by: Martin.Purkert.bawag.com

Thank you for the tip!

My situation is a little more tricky. I should explain it more detailed.

All in all we have 3 Eclipse projects involved.

The first one (lets call it the "GUI-Project") contains mainly Swing
Dialogs using the Visual Editor (VEP).

On that dialogs are lots of custom controls which sources are located in
the second project (the "Architecture" project).

And the architecture needs files from the third ("Resource") project.

So architecture code is not launched explicitly as Java Application (where
I could set the working dir as you mentioned) but implicitly when I open a
screen of the "GUI"-Project in the Visual Editor.

In production scenario all three projects are deployed in one dir so it
works there. It's only in development where I have to find a solution.

If nothing in that direction is possible, I think about adapting the
architecture code, so that it checks if running in development environment
and looks for a path in a System property or something set by Eclipse
start.

regards
Martin Purkert
Previous Topic:after download,i can't decompress correctly
Next Topic:How to disable the on-the-fly-syntax-checker?
Goto Forum:
  


Current Time: Thu Dec 26 12:15:28 GMT 2024

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

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

Back to the top