wilson83:
There is a potential work around, if the object is Drawing Title type, one of its parameters is
AC_LayoutRect, which is an array that gives the extents of the layout the Drawing Title is on. So you might be able to use this information to determine the size of the layout. Juha's solution is much simpler.
You should add a Signature to your Profile (click the Profile button near the top of this page) with your ArchiCAD version and operating system (see mine for an example) for more accurate help in this forum.
David