Home/ Reference/ View & Performance

doc.Rulers / doc.Grid

Rulers and the grid object. Reading the grid settings in a script prevents "the thing I drew is half a cell off from where I expected".

Signature

doc.Rulers / doc.Grid

Notes

Rulers and the grid object. Reading the grid settings in a script prevents "the thing I drew is half a cell off from where I expected".

Python example (runnable)

Requires pywin32. The example assumes app / doc / page / layer are already connected. See Connection & Init
Python
try:
    grid = doc.Grid
    print("Grid object: ", grid)
    print("Ruler object: ", doc.Rulers)
except Exception as e:
    print("Reading grid or ruler failed: ", e)

About this section: View & Performance

View & Performance — display and performance switches.

Other entries in this section