<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Using a project within another project in LabVIEW</title>
    <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192761#M924924</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://ni.lithium.com/t5/user/viewprofilepage/user-id/326738"&gt;@David-Baratheon&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So I might use the initial project as a Sub-VI in my new project, so that is how it could conceivably be useful in the "real world"&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;A project is just a collection of files, it contains no source, and is useless on it's own. &amp;nbsp;Think of it as Windows explorer. &amp;nbsp;It is just a way of viewing your files you have on your disk. &amp;nbsp;You can't use Windows explorer as a file, you use it to view other files. &amp;nbsp;Make one project that contains all the source you want for a given build and deployment. &amp;nbsp;Files can be in more than one project at a time.&lt;/P&gt;</description>
    <pubDate>Thu, 17 Sep 2015 12:18:41 GMT</pubDate>
    <dc:creator>Hooovahh</dc:creator>
    <dc:date>2015-09-17T12:18:41Z</dc:date>
    <item>
      <title>Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192693#M924893</link>
      <description>&lt;P&gt;If I completed a project, and then wanted to use that project as a sub element within a new project, what is the best practise for doing this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also, what happens if I have 5 projects, and I called the main VI in each project "main"? If I then wanted to bring all of those projects together into one project with a menu function that calls up the project you wish to use, won't you effectively have multiple VIs all called main?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am working trhough the exercise sheet that I was given after core 1 and 2, and one of the challenges is to create a VI that calls up each of the previous VIs based on a menu.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am concerned that working across projects might mean files get missed etc, so wanted to know the best practise for this.&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 09:27:58 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192693#M924893</guid>
      <dc:creator>David-Baratheon</dc:creator>
      <dc:date>2015-09-17T09:27:58Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192751#M924918</link>
      <description>&lt;P&gt;Well I've never had a time where I wanted to put a project in a project. &amp;nbsp;A project usually contains all files and builds that I want for a given...well project. &amp;nbsp;You can have multiple builds in a project so I don't really see a need to have multiple projects.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As for name space. &amp;nbsp;Having "Main.vi" in two different projects is fine. &amp;nbsp;They are opened in their own instance (context) and so there won't be a name collision, assuming you open them from the project. &amp;nbsp;As soon as you try to make one project with two Main.vi files you will have problems. &amp;nbsp;This is a reason to try to give a more descriptive name. &amp;nbsp;Another thing people do is put files in libraries to organize them. &amp;nbsp;This causes the name space to be appended with the library name. &amp;nbsp;So you actually have "My Library name::Main.vi".&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I guess I'd like more information on what you are trying to do, and why you need multiple projects.&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 12:09:11 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192751#M924918</guid>
      <dc:creator>Hooovahh</dc:creator>
      <dc:date>2015-09-17T12:09:11Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192758#M924922</link>
      <description>&lt;P&gt;Its a set of 6 exercises from NI.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The first exercise is to create a series of dice rolls and perform some statistical calculations on your dice rolls.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Second is to have a state changing boolean system, so each time a button is toggled, the system detects the change in state (as opposed to detecting the current state).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Third is to create a multuplication table.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Fourth is to create a system that can read from the file you have outputted in stage 3.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Fifth is to create a menu button that lets you choose which of the previous 4 exercises you would like to run.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As I have created a different project for each of the first 4 questions, the fifth one will involve me suing projects within a project or referencing one project in another project.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The reason I use "main" is because I think of it like a C program, with a main function that calls my sub routines (Sub-VIs)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In future I may develop a VI for something, for example monitoring power. At a later date, someone might want a system that detects power and other things also. So I might use the initial project as a Sub-VI in my new project, so that is how it could conceivably be useful in the "real world"&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Problems I could forsee, are if I copy a VI into another VI in a different project, that new VI may still be calling on sub-VIs stored in the previous labview folder. If in future that labview folder was deleted, my new project could no longer find the sub-VIs it was calling upon. Same issue could apply for other types of files my code might be using to run such as .dll files etc.&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 12:18:44 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192758#M924922</guid>
      <dc:creator>David-Baratheon</dc:creator>
      <dc:date>2015-09-17T12:18:44Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192761#M924924</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://ni.lithium.com/t5/user/viewprofilepage/user-id/326738"&gt;@David-Baratheon&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So I might use the initial project as a Sub-VI in my new project, so that is how it could conceivably be useful in the "real world"&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;A project is just a collection of files, it contains no source, and is useless on it's own. &amp;nbsp;Think of it as Windows explorer. &amp;nbsp;It is just a way of viewing your files you have on your disk. &amp;nbsp;You can't use Windows explorer as a file, you use it to view other files. &amp;nbsp;Make one project that contains all the source you want for a given build and deployment. &amp;nbsp;Files can be in more than one project at a time.&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 12:18:41 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192761#M924924</guid>
      <dc:creator>Hooovahh</dc:creator>
      <dc:date>2015-09-17T12:18:41Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192763#M924925</link>
      <description>&lt;P&gt;But doesn't that get messy? What if I create a new folder for my new project, and upon importing a sub-VI into my code, my VI now relies on files external to the initial folder I made for my VI. What if I can no longer access that extern location where the sub-VI is found? I just thought it seemed like good practise to keep all files for a project in on folder and sub folders&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 12:21:37 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192763#M924925</guid>
      <dc:creator>David-Baratheon</dc:creator>
      <dc:date>2015-09-17T12:21:37Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192776#M924931</link>
      <description>&lt;P&gt;I clearly don't know enough about what you are trying to do, but there are a couple options to keep it from getting messy. &amp;nbsp;The goal is really to have the project and the source have a mostly common path. while also not duplicating&amp;nbsp;code. &amp;nbsp;You may have a folder structure like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My Project.lvproj&lt;/P&gt;
&lt;P&gt;Main.vi&lt;/P&gt;
&lt;P&gt;--Utilities&lt;/P&gt;
&lt;P&gt;--Controls&lt;/P&gt;
&lt;P&gt;--UI&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But one alternative (that I admittedly&amp;nbsp;haven't tired) is you can have multiple projects together.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My Project.lvproj&lt;/P&gt;
&lt;P&gt;My other Project.lvproj&lt;/P&gt;
&lt;P&gt;--Utilities&lt;/P&gt;
&lt;P&gt;--Controls&lt;/P&gt;
&lt;P&gt;--UI&lt;/P&gt;
&lt;P&gt;--Top Level VIs&lt;/P&gt;
&lt;P&gt;----Project 1 Main.vi&lt;/P&gt;
&lt;P&gt;----Project 2 Main.vi&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But honestly now that I'm talking about this, the reason that this type of layout is uncommon, is because sharing code between projects in the real world shouldn't be something that happens often, at least without a formalized reuse process.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If I have common code between two project, I personally will split the projects and have two copies of some code. &amp;nbsp;This seems unnecessary&amp;nbsp;but I don't want to update code for one project, and have it also make changes for another project. &amp;nbsp;For me most the time a project is for a particular customer, for a particular job. &amp;nbsp;So a new project is made for each new program for each new customer. &amp;nbsp;The majority of the common code they share is stored in the &amp;lt;user.lib&amp;gt; and is available on the palette. &amp;nbsp;This code has a formal release process and is versioned and tracked. &amp;nbsp;If code has some incompatibilty then we need to roll back or forward the reuse for a particular project, but efforts are made to avoid this. &amp;nbsp;The code that might be common between two programs that isn't formally tracked, is copied in an ad-hoc reuse type of situation.&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 12:36:01 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192776#M924931</guid>
      <dc:creator>Hooovahh</dc:creator>
      <dc:date>2015-09-17T12:36:01Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192813#M924938</link>
      <description>&lt;P&gt;Deciding on how&amp;nbsp;&lt;U&gt;you&lt;/U&gt; want to handle Projects is something of Trial and Error. &amp;nbsp;I've adopted the idea of a nested set of folders on disk that correspond to a single Project, with the Project File appearing in the top level, and sub-folders being things like Documentation, Sub-VIs, Types, RT Target (with its own set of sub-folders), etc. &amp;nbsp;I make the folders in the Project (which are "virtual folders", and do not necessarily correspond to physical folders on disk) correspond exactly to the physical folders that constitute the Project. &amp;nbsp;This allows me to easily manage the Project as a single entity in SVN, for example.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I've wrestled with the question of how to handle "common utilities" that I want to use in multiple Projects -- should I have a single copy somewhere (where?), should I have multiple copies in each Project that needs them, or what? &amp;nbsp;For now, I'm using multiple copies, but I'm not that happy with this method. &amp;nbsp;One Virtue is if I migrate a Project from, say, LabVIEW 2012 to LabVIEW 2014, all of the sub-VIs migrate together, but a version in another (un-migrated) Project isn't affected, unlike the case with a single source.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;A better idea, it seems to me, that I've not&amp;nbsp;&lt;U&gt;yet&lt;/U&gt; implemented, is to make a Package of my utilities and use VIPM to install them as User Libraries in LabVIEW itself. &amp;nbsp;Sort of Having Your Cake and Eating It, Too.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Bob Schor&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 13:38:43 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192813#M924938</guid>
      <dc:creator>Bob_Schor</dc:creator>
      <dc:date>2015-09-17T13:38:43Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192820#M924940</link>
      <description>&lt;P&gt;Bob, I am glad I am not the only one struggling with this question &lt;span class="lia-unicode-emoji" title=":grinning_face_with_smiling_eyes:"&gt;😄&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So when you start a new project that utilises some old code, do you have to drag each individual VI into the new project folder? It sounds like that requires a bit of "messing around" each time. A VI can have sub-VIs which can have sub VIs as you know so do you have to copy each individual sub-VI across to the new project folder and then incorporate them one by one into the new project?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I was hoping their was a way so simply drag and drop the highest level VI across and it would copy all of the sub-VIs across with it.&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 13:45:09 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192820#M924940</guid>
      <dc:creator>David-Baratheon</dc:creator>
      <dc:date>2015-09-17T13:45:09Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192823#M924941</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://ni.lithium.com/t5/user/viewprofilepage/user-id/326738"&gt;@David-Baratheon&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I was hoping their was a way so simply drag and drop the highest level VI across and it would copy all of the sub-VIs across with it.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;It does do this. &amp;nbsp;Well first there are auto populate folders which can be useful but has it's draw backs. &amp;nbsp;There are snapshot folders too which might be more appropriate. &amp;nbsp;But if you just drag the top level VI over, all of it's dependencies will be loaded and put under dependencies.&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 13:47:46 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192823#M924941</guid>
      <dc:creator>Hooovahh</dc:creator>
      <dc:date>2015-09-17T13:47:46Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192830#M924944</link>
      <description>&lt;P&gt;Ah ok so if I copy a VI from one project into another whilst both projects are open (from the icon next to the connector pane) it will automatically copy the VI and sub-VI into dependcies and make a local copy within that project folder?&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 13:54:32 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192830#M924944</guid>
      <dc:creator>David-Baratheon</dc:creator>
      <dc:date>2015-09-17T13:54:32Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192832#M924945</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://ni.lithium.com/t5/user/viewprofilepage/user-id/326738"&gt;@David-Baratheon&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;and make a local copy within that project folder?&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Nope, project explorer does no file operations, it is just a way of organizing files. &amp;nbsp;My point was that if you had a top level, and a bunch of sub VIs, you don't have to drag them over one at a time, if you just drag over the main, all of the dependencies are loaded and put under the dependencies section. &amp;nbsp;But I also was suggesting other ways of adding multiple files to the project explorer quickly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;EDIT: &amp;nbsp;Oh but one other option, within a project you can do a Save As which can duplicate the whole file structure and dependencies, making a new copy of the project too.&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 13:58:41 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192832#M924945</guid>
      <dc:creator>Hooovahh</dc:creator>
      <dc:date>2015-09-17T13:58:41Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192837#M924946</link>
      <description>&lt;P&gt;So I would do it outside of labview. Just drag and drop the VI and sub VIs from folder of old project to folder of new project?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I just thought that might cause some problems on bigger programs doing it that way. Thought it might have been better to do it within LabVIEW if there was a "proper method" of doing it&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Save as is ok if you want to use an old project as a basis for a new one, but I want to copy 6 VIs from 6 different projects into one project&lt;/P&gt;</description>
      <pubDate>Thu, 17 Sep 2015 14:00:40 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3192837#M924946</guid>
      <dc:creator>David-Baratheon</dc:creator>
      <dc:date>2015-09-17T14:00:40Z</dc:date>
    </item>
    <item>
      <title>Re: Using a project within another project</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3193406#M925151</link>
      <description>&lt;P&gt;Just a bit of feedback.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I created 6 projects (five different functions plus a main project with a menu for calling the other five).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I created five autopopulating folders and directed each one to a project folder.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Because I used "main" as the main VI for each project, when I imported them all with an autopopulating folder, it raised it as a conflict.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I was only required to browse and find the specific main I was looking for, so it wasn't really very difficult to resolve, but could be difficult if you weren't the person who initially worked on the project or if you had a large complex project.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The error came up when I came to import each individual VI into the program selection menu VI.&lt;/P&gt;</description>
      <pubDate>Fri, 18 Sep 2015 12:03:03 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Using-a-project-within-another-project/m-p/3193406#M925151</guid>
      <dc:creator>David-Baratheon</dc:creator>
      <dc:date>2015-09-18T12:03:03Z</dc:date>
    </item>
  </channel>
</rss>

