2 Replies Latest reply on Aug 28, 2013 1:00 PM by danshockley

    Creating a Value List from Layout Names

    NickFrese

      Title

      Creating a Value List from Layout Names

      Post

           I'd like to be able to create a value list based upon SOME of the layout names in my database. I have the layout names I wish to included inside a folder called "Approved Layouts". I have managed to get ALL the layouts into a Global Calculated Field via:

      LayoutNames (Get(FileName))

           But I can't figure out how to show JUST the layouts in the Approved Layouts folder. How would you go about restricting it to only the layouts in that folder? And even if I am able to do that, how do I then get those layouts correctly into a Value List?

           Thanks in advance for the help!

        • 1. Re: Creating a Value List from Layout Names
          philmodjunk

               You may already be aware of this, but there's a check box in Layout Setup.. and Manage Layouts where you can select which layouts appear in the layout drop down in the status tool bar.

               If you want your own drop down list with just these layouts, you'd need to use either a script or manual edits to put the names of the layouts that you want either in a single text field or in the text field of a set of records in a table.

          • 2. Re: Creating a Value List from Layout Names
            danshockley

                  

                 Phil, it sounds like Nick wanted a specific group of layout names to use somewhere other than in the standard layout popup menu. 

                 Two things, though: 

                 1) I don't know of any way to get a list of names of layouts that happen to be within a specific layout folder.

                 2) You can get a value list to build by putting a return-delimited list in a single non-global field in a utility table built for this purpose, or by putting each in its own record in such a utility table. 

                 As far as #1 goes, you'd have to distinguish them in some way that design functions can see. That means either including something in the name of the layouts whose names you want or those you don't, or somehow collecting those layouts' IDs and then loop over those IDs using Fabrice Nordmann's FM_Name_ID function to get their current name(s) if they have changed.