Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » path problem in workspace project!!!!!
path problem in workspace project!!!!! [message #457947] Fri, 08 July 2005 03:53 Go to next message
Eclipse UserFriend
Originally posted by: gautamn.iitk.ac.in

Hi,
suppose my source files of project are in folder ":/Documents and
Settings/nitin/Desktop/myproject". I have done Import>Existing Project in
Workspace.....My problem how can I get above path.The reason is that I
have some XML files in the source folder and I want to access it using
File class.
Presently just giving the name of XML file is showing errors.
Regards,
Nitin Gautam.

Note: I am running my project as an External Workbence.
Re: path problem in workspace project!!!!! [message #457957 is a reply to message #457947] Fri, 08 July 2005 07:32 Go to previous message
Eclipse UserFriend
Originally posted by: nightblue99.yahoo.com

Hi;

When you import an existing project into workspace, tihs project folder go
into the workspace that you define. Then you can read your files relative
to the root of the project. Lets say your project name in the workspace is
FileOperations and your source folder name is src; and you have file that
name is Readme.txt in the src folder then

File file = new File("src\\Readme.txt");
FileInputStream stream = new FileInputStream(file);
stream.read();..
bla bla bla....

PS: This like questions may be post to the Eclipse newsgroup.

Night BLue
Previous Topic:Change table row selection color
Next Topic:ScrolledComposite bug
Goto Forum:
  


Current Time: Thu Apr 25 13:12:28 GMT 2024

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

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

Back to the top