{"id":5016,"date":"2017-11-30T15:00:05","date_gmt":"2017-11-30T14:00:05","guid":{"rendered":"http:\/\/www.samlogic.net\/blog\/?p=5016"},"modified":"2019-07-07T17:18:37","modified_gmt":"2019-07-07T17:18:37","slug":"using-the-add-tree-function-in-visual-installer","status":"publish","type":"post","link":"https:\/\/www.samlogic.net\/blog\/2017\/11\/using-the-add-tree-function-in-visual-installer\/","title":{"rendered":"Using the &#8216;Add tree&#8217; function in Visual Installer"},"content":{"rendered":"<p>If you already have created a folder structure on your hard drive, with the files that you want to install, and want to create a similar folder structure on the destination drive, there is a very useful function in <a href=\"https:\/\/www.samlogic.net\/visual-installer\/visual-installer.htm\" target=\"_blank\" rel=\"noopener noreferrer\">Visual Installer<\/a> that you can use. The name of the function is <strong>Add tree<\/strong> and you can access it via the <strong>List<\/strong> menu in Visual Installer, by choosing the <strong>List &#8211; Add &#8211; Add tree<\/strong> menu item (see the picture below):<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.samlogic.net\/blog\/images\/product-visual-installer\/vi-menu-list-add-tree.png\" alt=\"The 'Add tree' menu option\" border=\"0\"><\/p>\n<p>After you have chosen this menu item, the following dialog box is shown:<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.samlogic.net\/blog\/images\/product-visual-installer\/vi-dialogbox--add-tree--select-folder-1.png\" alt=\"The 'Select folder' dialog box (1)\" border=\"0\"><\/p>\n<p>Via this dialog box you can browse to the folder, with sub folders and files, that you want to add to Visual Installer&#8217;s file list. For example like:<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.samlogic.net\/blog\/images\/product-visual-installer\/vi-dialogbox--add-tree--select-folder-2.png\" alt=\"The 'Select folder' dialog box (2)\" border=\"0\"><\/p>\n<p>You can see the current folder path to the right of the <strong>Folder<\/strong> field name in the dialog box.<\/p>\n<p>After you have selected your folder, you can click on the <strong>OK<\/strong> button to continue. The following dialog box will now be shown:<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.samlogic.net\/blog\/images\/product-visual-installer\/vi-dialogbox--add-tree--collect-files.png\" alt=\"Collect files from folders and sub folders\" border=\"0\"><\/p>\n<p>In the option frame (above the three buttons) you can choose how the folder structure will be built in Visual Installer&#8217;s file list. You can choose between replacing the root level of the folder tree with the <strong>%DESTDIR<\/strong> variable, or add the folder tree to the <strong>%DESTDIR<\/strong> variable.<\/p>\n<p>When you have decided how you want to build the folder tree, you can press the <strong>Add files<\/strong> button. Now Visual Installer&#8217;s file list will be filled with the files and folders. And you can see how many files that were collected in the <strong>No. files<\/strong> field name in the dialog box:<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.samlogic.net\/blog\/images\/product-visual-installer\/vi-dialogbox--add-tree--collect-files--ready.png\" alt=\"Ready!\" border=\"0\"><\/p>\n<p>To return to the file list, just press <strong>Close<\/strong> in the dialog box.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.samlogic.net\/blog\/images\/product-visual-installer\/vi-editor-tab-filelist--add-tree-example--cropped.png\" alt=\"The collected files\" border=\"0\"><\/p>\n<p><strong>How to obtain only folders of a folder tree<\/strong><br \/>\nInstead of collecting the files in a folder tree you can also extract only the folders (directories) of the tree and skip all files. In <a href=\"https:\/\/www.samlogic.net\/blog\/2017\/11\/how-to-add-a-folder-tree-to-visual-installers-file-list\/\">this blog post<\/a> we explain how to do this.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you already have created a folder structure on your hard drive, with the files that you want to install, and want to create a similar folder structure on the destination drive, there is a very useful function in Visual Installer that you can use. The name of the function is Add tree and you &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.samlogic.net\/blog\/2017\/11\/using-the-add-tree-function-in-visual-installer\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Using the &#8216;Add tree&#8217; function in Visual Installer&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[10,15],"tags":[],"_links":{"self":[{"href":"https:\/\/www.samlogic.net\/blog\/wp-json\/wp\/v2\/posts\/5016"}],"collection":[{"href":"https:\/\/www.samlogic.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.samlogic.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.samlogic.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.samlogic.net\/blog\/wp-json\/wp\/v2\/comments?post=5016"}],"version-history":[{"count":1,"href":"https:\/\/www.samlogic.net\/blog\/wp-json\/wp\/v2\/posts\/5016\/revisions"}],"predecessor-version":[{"id":6009,"href":"https:\/\/www.samlogic.net\/blog\/wp-json\/wp\/v2\/posts\/5016\/revisions\/6009"}],"wp:attachment":[{"href":"https:\/\/www.samlogic.net\/blog\/wp-json\/wp\/v2\/media?parent=5016"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.samlogic.net\/blog\/wp-json\/wp\/v2\/categories?post=5016"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.samlogic.net\/blog\/wp-json\/wp\/v2\/tags?post=5016"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}