Method GetObjectAbsoluteLayout
GetObjectAbsoluteLayout(object?)
Retrieves the AbsoluteLayout associated with the specified object instance.
public static AbsoluteLayout? GetObjectAbsoluteLayout(object? instance)
Parameters
instanceobjectThe object instance for which to retrieve the AbsoluteLayout. This can be a Page, View, or Control.
Returns
- AbsoluteLayout
The AbsoluteLayout associated with the specified object instance, or null if no AbsoluteLayout is found.
Remarks
This method determines the AbsoluteLayout based on the type of the provided instance:
- If the instance is a Page, the method attempts to retrieve the root child as an AbsoluteLayout.
- If the instance is a View, the method attempts to retrieve the top-level AbsoluteLayout.
- If the instance is a Control, the method retrieves the container associated with the control and attempts to retrieve the top-level AbsoluteLayout from the container.