Thread View: borland.public.jbuilder.java.swing
9 messages
9 total messages
Started by Houman Khorasani
Sun, 30 May 2004 03:49
How to determine the project path?
Author: Houman Khorasani
Date: Sun, 30 May 2004 03:49
Date: Sun, 30 May 2004 03:49
11 lines
1046 bytes
1046 bytes
Hi There, How can I ask Jbuilder where the actual project is stored? Usually it's stored in c:\Documents and Settings\[username]\jbproject\[projectname] But can I ask for the whole as a string? Thanks Houman
Re: How to determine the project path?
Author: Lori M Olson (TeamB)
Date: Mon, 31 May 2004 14:42
Date: Mon, 31 May 2004 14:42
44 lines
2021 bytes
2021 bytes
Houman Khorasani wrote:
> Hi There,
>
> How can I ask Jbuilder where the actual project is stored?
>
> Usually it's stored in c:\Documents and
> Settings\[username]\jbproject\[projectname]
>
> But can I ask for the whole as a string?
>
> Thanks
> Houman
>
>
>
Well, I'm not sure of the context here, but there are macros available
when you configure command-line tools.
Tools | Configure Tools
Select "Add" or "Edit"
Select "Insert Macro"
That will show you the list of available macros. $ProjectPath gives the
value you want.
--
Regards,
Lori Olson (TeamB)
------------
Save yourself, and everyone else, some time and search the
newsgroups and the FAQ-O-Matic before posting your next
question.
Google Advanced Newsgroup Search
http://www.google.ca/advanced_group_search
Other Newsgroup Searches:
http://www.borland.com/newsgroups/ngsearch.html
Joi Ellis's FAQ-O-Matic:
http://www.visi.com/~gyles19/fom-serve/cache/1.html
Re: How to determine the project path?
Author: Houman Khorasani
Date: Mon, 31 May 2004 22:57
Date: Mon, 31 May 2004 22:57
63 lines
2200 bytes
2200 bytes
Actually I am looking for ($ProjectDir). Something what tells me the directory of the project. How can I store this value into a String and use it in my java class? Thank you Houman > Well, I'm not sure of the context here, but there are macros available > when you configure command-line tools. > > Tools | Configure Tools > Select "Add" or "Edit" > Select "Insert Macro" > > That will show you the list of available macros. $ProjectPath gives the > value you want. > > > > > > > Well, I'm not sure of the context here, but there are macros available > when you configure command-line tools. > > Tools | Configure Tools > Select "Add" or "Edit" > Select "Insert Macro" > > That will show you the list of available macros. $ProjectPath gives the > value you want. > > -- > > Regards, > > Lori Olson (TeamB) > > ------------ > > Save yourself, and everyone else, some time and search the > newsgroups and the FAQ-O-Matic before posting your next > question. > > Google Advanced Newsgroup Search > http://www.google.ca/advanced_group_search > Other Newsgroup Searches: > http://www.borland.com/newsgroups/ngsearch.html > Joi Ellis's FAQ-O-Matic: > http://www.visi.com/~gyles19/fom-serve/cache/1.html >
Re: How to determine the project path?
Author: Kevin Dean
Date: Tue, 01 Jun 2004 00:30
Date: Tue, 01 Jun 2004 00:30
81 lines
2953 bytes
2953 bytes
Perhaps it would be better if you told us why you want to do that in the first place. The moment you package your application and distribute it, the project path likely will no longer exist. -- Check out our latest white papers at http://www.datadevelopment.com/papers/index.html BladeNET Scores With Borland Enterprise Tools Team Development with JBuilder and Borland Enterprise Server Dolphin Data Development Ltd. http://www.datadevelopment.com/ "Houman Khorasani" <khorasaniNOSPAM@web.de> wrote in message news:40bbb844$1@newsgroups.borland.com... > Actually I am looking for ($ProjectDir). Something what tells me the > directory of the project. How can I store this value into a String and use > it in my java class? > > Thank you > > Houman > > > > > Well, I'm not sure of the context here, but there are macros available > > > when you configure command-line tools. > > > > > > Tools | Configure Tools > > > Select "Add" or "Edit" > > > Select "Insert Macro" > > > > > > That will show you the list of available macros. $ProjectPath gives the > > > value you want. > > > > > > > > > > > > > > > Well, I'm not sure of the context here, but there are macros available > > when you configure command-line tools. > > > > Tools | Configure Tools > > Select "Add" or "Edit" > > Select "Insert Macro" > > > > That will show you the list of available macros. $ProjectPath gives the > > value you want. > > > > -- > > > > Regards, > > > > Lori Olson (TeamB) > > > > ------------ > > > > Save yourself, and everyone else, some time and search the > > newsgroups and the FAQ-O-Matic before posting your next > > question. > > > > Google Advanced Newsgroup Search > > http://www.google.ca/advanced_group_search > > Other Newsgroup Searches: > > http://www.borland.com/newsgroups/ngsearch.html > > Joi Ellis's FAQ-O-Matic: > > http://www.visi.com/~gyles19/fom-serve/cache/1.html > > > >
Re: How to determine the project path?
Author: David C. Browne
Date: Tue, 01 Jun 2004 02:33
Date: Tue, 01 Jun 2004 02:33
20 lines
1484 bytes
1484 bytes
Maybe this is what you are looking for?
import java.util.Properties;
Properties props = System.getProperties();
String userDir = (String)props.getProperty("user.dir");
David
Houman Khorasani wrote:
> Actually I am looking for ($ProjectDir). Something what tells me the
> directory of the project. How can I store this value into a String and use
> it in my java class?
>
> Thank you
>
> Houman
>
Re: How to determine the project path?
Author: Tor Iver Wilhelmsen (TeamB)
Date: Tue, 01 Jun 2004 07:10
Date: Tue, 01 Jun 2004 07:10
8 lines
1210 bytes
1210 bytes
"Houman Khorasani" <khorasaniNOSPAM@web.de> writes: > Actually I am looking for ($ProjectDir). Something what tells me the > directory of the project. How can I store this value into a String and use > it in my java class? Are you writing an OpenTool for JBuilder? Then you can get that value via an API call. Check the OpenTool examples.
Re: How to determine the project path?
Author: Houman Khorasani
Date: Tue, 01 Jun 2004 20:16
Date: Tue, 01 Jun 2004 20:16
18 lines
1510 bytes
1510 bytes
WOw thats exactly what I was looking for. ANd it works fine.
Thanks a lot David.
Houman
"David C. Browne" <cognoscenti-removethispart@comcast.net> wrote in message
news:40bbeaee$1@newsgroups.borland.com...
> Maybe this is what you are looking for?
>
> import java.util.Properties;
>
> Properties props = System.getProperties();
> String userDir = (String)props.getProperty("user.dir");
>
>
> David
Re: How to determine the project path?
Author: Houman Khorasani
Date: Tue, 01 Jun 2004 20:23
Date: Tue, 01 Jun 2004 20:23
17 lines
1534 bytes
1534 bytes
I am still in developing phase. It's an application for my Thesis. I don't know yet if I am going to package it. Besides I have no exprience with making a jar file. I have JBuilder Foundation X and this version doesn't include the jar distribution functionality. Let see... So far the userDir from David helped me out. Thanks for response Houman > Perhaps it would be better if you told us why you want to do that in the > first place. The moment you package your application and distribute it, the > project path likely will no longer exist.
Re: How to determine the project path?
Author: Houman Khorasani
Date: Tue, 01 Jun 2004 20:24
Date: Tue, 01 Jun 2004 20:24
7 lines
1152 bytes
1152 bytes
> Are you writing an OpenTool for JBuilder? Then you can get that value > via an API call. Check the OpenTool examples. No just working within the normal java code. Thanks Houman
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads