Referencing STATIC class outside of project

Posted by Roger Blanchard on 12-Sep-2009 10:14

I have a workspace and within the workspace I have three OE projects lets say Project1, Project2 and Project3. In my project2 properties I reference Project1 since that project has some STATIC classes that I want to reference. Now while working in Project2 I type StaticClass: and all my STATIC METHODS popup. I then choose "Method1" but then I get a compile error stating "Could not locate element 'Method1' in class 'StaticClass' (12927). Should I not be able to do this or am I missing something? OE Architect can see the STATIC methods just fine so I am not sure why I would get a compile error.

All Replies

Posted by Admin on 12-Sep-2009 12:19

rblanchard schrieb:

I have a workspace and within the workspace I have three OE projects lets say Project1, Project2 and Project3. In my project2 properties I reference Project1 since that project has some STATIC classes that I want to reference.

AFAIK setting up project references does not affect the propath. The propath is required for the compiler (AVM session).

Have you tried adding project2 to the propath of projetc1?

A good question to some of the folks from Progress would be if the referenced projects do have any meaning at all for the OpenEdge Architect - I suspect it's just inherited functionality from Eclipse.

Posted by Roger Blanchard on 12-Sep-2009 12:37

Actually, if I add an external directory to the propath it works without the project reference. Not sure what the reference really does.

Thanks mike.

Posted by Admin on 12-Sep-2009 13:16

Actually it would be nice if the "Add Directory" button would list directories from the referenced projects as well (or something similar to the "Add project" button in the run configurations dialog). It's a bit disturbing that something from within the same workspace needs to be added as an external directory; searching the file system all over is against the idea of an workspace.

In Visual Studio adding a project reference is close to adding that project to the propath. Additionally it controls the order in which projects are compiled.

Posted by Roger Blanchard on 12-Sep-2009 15:52

I agree. I would expect all I need to do is reference the project.

Posted by Matt Baker on 13-Sep-2009 16:31

This was changed in 10.2B so you can add other projects directory entries to the PROPATH.   OEA doesn't use the Eclipse project references for anything.

Posted by Roger Blanchard on 14-Sep-2009 06:52

Mathew,

Could you elaborate?

Roger Blanchard

Osprey Retail Systems, Inc.

404 County St.

New Bedford, MA 02740

Phone: (508) 992-1097

Fax: (508) 992-2716

This thread is closed