View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Johan2000 Johan2000 is offline
external usenet poster
 
Posts: 16
Default How to get the correct active Cell position in Worksheet_Change

In a Excel Cell (A1), if we type 123 [ENTER]

then the code bellow will
Private Sub Worksheet_Change(ByVal Target As Range)
MsgBox ActiveCell.Address
End Sub

output A2 or B1 (depent on the direction of the cursor we set in
Tools/Option/Edit/Direction after selection (down, right,....)
Which is not what I wanted! (I wanted A1......)

question : How to get (to modify) the content of A1 (like a VALID clause in
VB)...
which we will doing a validation before leaving the cell..........

thanks so much!