View Full Version : [Flex Builder 2] Adding Project References doesn't affect classpath?

08-06-2006, 03:44 PM
I am trying to refer to an interface InterfaceA defined in Project A from a ClassB in Project B. I checked off "Project A" in the "Project References" tab of Project B. However, the interface is still not seen by the compiler. When I add Project A's source directory as an extra source dir to Project B, of course everything works. Have I misunderstood the purpose of the "Project References" option in Flex Builder 2? Is it only to set dependencies for project compilation, not to include the source path dir automatically? It definitely used to work that way when I was using Eclipse for Java... :D

08-07-2006, 09:38 AM
i saw you ask this question on flex coders as well :D

an option is to create a swc and copy that into your project, or write your own ant script that you use for compilation (which i would recomend)

08-07-2006, 02:37 PM
I waited till I got no response on flexcoders before posting here :)

Well, it does work if the source directory for Project A is added to Project B. But then it's the dir path is hard coded, I'd much rather refer to another project in the workspace directly. Do you think that I'd be able to do that with an Ant script? It's been a while since I touched Ant...

off: Did you really move from Boston to Cape Town? :D

08-07-2006, 02:43 PM
you can export the swc into the global classpath as well (the whole of the flex shebang will be able to access it then).
but IMO ant is the way to go. look at how the mac people compile, to get that info.
also note that you want to set incrental compilation to true ( yesyes) and that the standard flex eclipse instal has no ant support (or did not before) so you should be installing the plugin version.

yes, i moved from boston to cape town, via a bit of holidaying in london (where i used to stay) and edinburgh :D . going back to boston next month for a bit as i still work there/

08-07-2006, 02:45 PM
Cool, thanx, I should really look at Ant again...

Nice itinerary :) I am in boston at the moment, moving to Tokyo in a couple weeks :D

08-07-2006, 02:47 PM
tokyo is one of my life ambitions as well. i am extremely envious.

08-07-2006, 02:50 PM
Personally, I've always been fascinated with South Africa :) How is it by the way?

08-11-2006, 10:44 AM
being from south africa i must admit i am partial. it is very pretty.

08-11-2006, 10:57 PM
Lol :D I guess it doesn't seem all that mysterious to you then :)