View Single Post
  #7   Report Post  
Posted to microsoft.public.excel.programming
Alan Alan is offline
external usenet poster
 
Posts: 138
Default Object name on user form

Thanks for your input here guys but I really am still struggling - I'm
sure that it is just me trying to describe what I am after!

The process that I am trying to emulate is:

1: user places cursor in one of the text boxes and presses a 'copy
button' - this could either store the value in a variable that could
then be used to 'paste' to another location or set the selected text
box as an object that could be referred to in the 'paste' step.

2: user places cursor in another text box and presses a 'paste button'
- this could either cause the value of the variable to be written to
that location or if the previous location has been stored as an object
I could proceed along the lines of textbox2.value=textbox1.value

The above preceedure is totally independant of how many text boxes
there are in total.

Peter T wrote "Me.ActiveControl on its own returns the default
property of the control that
currently has focus, which for most controls is typically False
(unless it
has a 'Value' property = true). Though controls such as Textbox, which
have
no default property, return an empty string. "

Peter, even a text box that contains a text string is returning the
value 'False' in response to Me.ActiveControl - am I missing
something?

Alan