Code to de-select a shape

M

Mark Tangard

Is there code that will de-select a shape (a text box) but *not* finish with the
cursor inside the shape's text frame?

I'm looking for the same effect as pressing ESC when the text box is selected
(i.e., fuzzy border). Recording the action gives Selection.Collapse, but running
that code places the cursor inside the box (which doesn't happen when ESC is
pressed).

I want to have the user's view and zoom to be unchanged (same result as pressing
ESC), so choosing another spot for the selection doesn't work. It doesn't matter
where the cursor ends up, as long as it doesn't move the screen or land inside
the box.

All shapes on each page are anchored to the same paragraph (at its top), and
they're small (1/4" x 1/2"), but their vertical positions vary. Users are
normally viewing these pages zoomed at over 150%.

SendKeys "{ESC}" doesn't do it. (No surprise.)

Anyone?

MT
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top