View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Jim Thomlinson Jim Thomlinson is offline
external usenet poster
 
Posts: 5,939
Default Excel text box VBA

You probably want the lost focus event instead fo the change event...

Private Sub TextBox1_LostFocus()
Range("A1").Select
End Sub
--
HTH...

Jim Thomlinson


"R Ormerod" wrote:

I've entered a text box into my worksheet from the Control Toolbox toolbar.

When entering text into the box, how can I get the cursor to return to a
cell in the worksheet after entry has been completed?

I tried the following:

Private Sub TextBox1_Change()

Range("A1").Select

End Sub

But the cursor moved to cell A1 as soon as I started typing text in the box.

Regards

--
R Ormerod