2024-01-22
05:10 PM
- last edited on
2024-09-26
01:25 PM
by
Doreena Deng
I have a fully automated office stamp object that is placed on the Master Layouts. I am now being asked to also include the layout number within a subset. This is possible using autotexts in regular text boxes. However, I want to incorporate this into my object. Is it possible to obtain the 'autotext list' in a user interface of a GDL object?
Solved! Go to Solution.
2024-01-22 06:22 PM - edited 2024-01-22 06:23 PM
Hi,
Here is a small example
2024-01-22 06:22 PM - edited 2024-01-22 06:23 PM
2024-01-23 11:47 AM
Thank you Yves!
I was clearly overthinking it. This was simpler than I thought.
2025-06-03 07:29 PM
Dear Yves,
Can you please, do an altered code, which is for getting a property of the parent object?
p.s.: it would be long to explain the purpose, but I'm sure I need a gdl object like this
unfortunately, the REQUEST("PROPERTIES_OF_PARENT" and the details of the UI scripts are not 100% clear for me
2025-06-04 08:47 AM
Hi talmacsi_petrolterv
I think this is wat you need...
Parameter: "PropertyValue" > Text type
Master script:
myProperty = PropertyValue
Interface script:
! Define array to hold parent properties
dim _parentProperties[]
n = REQUEST("Properties_Of_Parent", "", _parentProperties) ! Get all properties available from the parent object
! Initialize display name for the selected property
_displayName = ""
! Retrieve readable name parts for the currently selected property (type, group, and property name)
n = REQUEST("Property_Name", myProperty, _typeName, _groupName, _propertyName)
! Build display name by combining available parts
if _typeName # "" then _displayName = _typeName + " : "
if _groupName # "" then _displayName = _displayName + _groupName + " : "
_displayName = _displayName + _propertyName ! Always add property name (it's never empty)
! Create dropdown menu to list all properties
ui_custom_popup_infield "PropertyValue",
5, 5, 100, 20, ! Position and size: x, y, width, height
1, ! Store hidden ID (internal reference)
3, ! Tree depth for grouping (use 3 for full hierarchy: type > group > name)
1, ! Grouping method (1 = group by type and group)
_displayName, ! Description of selected item
_parentProperties ! The list of available properties