4 Replies Latest reply on Sep 24, 2014 10:31 AM by ultranix

    Getting object name when you click on it

    ultranix

      Title

      Getting object name when you click on it

      Post

      I have 20 container fields (sort of image thumbnails), that serve as buttons and when I click one of them, I want the script to get that field name and depending on that to go to appropriate layout and display full size picture.

      In order not to create 20 scripts for all 20 fields, I am trying to set up 1 conditional script.

      First of all, i gave all those 20 fields and object name - p01. p02, p03, etc.

      Then i set up a script, but it's not working properly.

      Set Variable [$Field; "OBJECTS_Base::p" & Middle (Get(ActiveFieldName); 2; 2))]
      Set Field [BASE::xpicture; $Field]
      Go to Layout [BASE_Picture]

      But both Get(ActiveFieldName) and Get(ActiveLayoutObjectName) doesn't work - it doesn't set field name variable. How do I get them to work?

      To make sure, I want to get the object name (which corresponds to field name) or field name of the field I click on to perform such script.