4 Replies Latest reply on Sep 11, 2013 5:41 PM by JulieAnderson

    Layout Object as variable



      Layout Object as variable


           Don't you hate when you haven't done something in a while, know you have done it but can't remember how to do it today?  Especially when you know it has to be simple?  Anyway, that is where I am at this point.

           I have a layout with a list of companies.  I want to let the user select from the list and then generate a report for just the chosen company.  Unfortunately, I can't seem to get the layout object to set as a variable for a script.  I tried setting it in a table and that isn't working.  Is there a simple step here that I am missing?




        • 1. Re: Layout Object as variable

               Is your List of companies a value list such as that found in a drop down or pop up? Or is it some other kind of list like a list view or portal where you click a button?

               You may not need to use a variable at all for this, BTW.

          • 2. Re: Layout Object as variable

                 I tried it as a drop down and then as a drop down in its own window.



            • 3. Re: Layout Object as variable

                   In which case, you don't need a variable though you could indeed make that work.

                   If you define your field with the value list as a global field, you could set up the onObjectSave (drop down) or OnObjectModify ( Pop up) script trigger to perform a find script such as the examples in this thread: Scripted Find Examples

                   If your value list formatted field is setup as match field to a related table, you may be able to use Go To Related Records or even list the matching records in a portal beneath the field.

                   Or you can use the script step

                   Set Variable [$YourVarirable ; Value: YourTable::YourValueLIstFIeld ]

                   and put it in a variable. wink

              • 4. Re: Layout Object as variable

                     Sounds like I am going at this all wrong and that I have a lot to learn.  I think I will hit some of the training manuals and then come back if I still need help.  Thanks so much for getting me going in the right direction.