* Get the height of the border (frame) DO CASE CASE oForm.BorderStyle = 0 * No Border lnresult = 0 CASE oForm.BorderStyle = 1 * Fixed Single lnresult = SYSMETRIC(11) CASE oForm.BorderStyle = 2 * Fixed Double lnresult = SYSMETRIC(13) CASE oForm.BorderStyle = 3 * Sizeable lnresult = SYSMETRIC(4) ENDCASE RETURN lnresult * Get the width of the border DO CASE CASE oForm.BorderStyle = 0 * No Border lnresult = 0 CASE oForm.BorderStyle = 1 * Fixed Single lnresult = SYSMETRIC(10) CASE oForm.BorderStyle = 2 * Fixed Double lnresult = SYSMETRIC(12) CASE oForm.BorderStyle = 3 * Sizeable lnresult = SYSMETRIC(3) ENDCASE RETURN lnresult * The title bar height lnresult = 0 IF loObject.TitleBar = 1 * It has a title bar IF NOT oForm.HalfHeightCaption * Normal Title Bar lnresult = SYSMETRIC(9) ELSE * Half height title bar * I've noted that half height's are 5 more pixels * than exactly half lnresult = ROUND((SYSMETRIC(9) / 2), 0) + 5 ENDIF ENDIF RETURN lnresult