From Xojo Documentation

You are currently browsing the old Xojo documentation site. It will go offline as of October 2, 2023. Please visit the new Xojo documentation site! - you will be redirected shortly...

Read-Only Property (As Integer )
IntegerValue = aRuntime.ObjectCount

Supported for all project types and targets.

Returns the current number of objects in existence.