Relative "using" Path

I've developed some sets of functions that I use across a variety of custom CIQ apps. I put them in modules and include them with "using".

I'd like to place these in a shared module folder. But I can't figure out the syntax to refer to this folder. The first example works of course, with the module in the same folder as my code. But then I need to duplicate the module for the other projects (apps). Any idea how to refer to a module in a different folder? Standard absolute and relative pathing does not work. Thanks!!

// my personal modules - shared functions
using systemValues as mySys; // WORKS
using ..\SharedModules\systemValues as mySys; // Relative Path does not work
using C:\SHARED_VMWARE\ConnectIQ\MyProjects\SharedModules\systemValues as mySys; // Absolute PAth does not work


  • Former Member
    Former Member
    This pathing has to be handled at the point where files are passed to the compiler, not on the using line. The using line should always match the first one you have listed.

    If you were passing files to the compiler manually on the command line the paths you have listed above could be passed there.

    Using eclipse, you can right click on the source folder for your project and select New->Folder. Then under "Advanced", select "Link to alternate location (Linked Folder)" Select your folder with your shared source there.

    Note that if you have several utilities in one shared folder, but only need some of them for your application, the compiler will still include all the referenced code in your build unless you use build exclusions to restrict what is built.

    You can also link to individual files in a similar manner within eclipse.
  • this pathing has to be handled at the point where files are passed to the compiler, not on the using line. The using line should always match the first one you have listed.

    If you were passing files to the compiler manually on the command line the paths you have listed above could be passed there.

    Using eclipse, you can right click on the source folder for your project and select new->folder. Then under "advanced", select "link to alternate location (linked folder)" select your folder with your shared source there.

    Note that if you have several utilities in one shared folder, but only need some of them for your application, the compiler will still include all the referenced code in your build unless you use build exclusions to restrict what is built.

    You can also link to individual files in a similar manner within eclipse.


    thank you!!
  • I've been using the eclipse links that Brian mentioned for a long time and they work well. I usually link to specific files, but will also link to a directory for things the the icon font I use in watch faces.
  • to do the linking you can also hold shift and ctrl while doing drag and drop.

    I too have been using this extensively, mostly for my unit test projects - check my website for a tutorial on that :)

    (when the linking doesn't work make sure that your perspective is set to the connect iq perspective)