Extract Data From Textbox

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Is there a way to extract data from a textbox and use this data in a cell on
a different sheet? The cell would then update when the textbox was changed.
Can the textbox be refecenced with a function or can it be done with VBA?
 
In Properties->Linked cell for the textbox, type the full cell address of
your target eg Sheet2!A1

Ian
 
That will input the value from a cell into a textbox. What I am looking for
is to go the other direction. For example, I want the value of the text
entered into textbox1 to be extracted into cell A!.
Thank You
sea
 
While in design mode, right-click the textbox, go to View
Code, and use:

Private Sub TextBox1_Change()
Range("A1").Value = TextBox1.Value
End Sub

HTH
Jason
Atlanta, GA
 
Thank you!
Works perfect

Jason Morin said:
While in design mode, right-click the textbox, go to View
Code, and use:

Private Sub TextBox1_Change()
Range("A1").Value = TextBox1.Value
End Sub

HTH
Jason
Atlanta, GA
 
It actually works both ways, keeping the textbox and the cell in sync.

Ian
 
Is there any reason this shouldn't work work in Office 2007, with a TextBox
directly on a spreadsheet rather than a form? I can't get this to work and
wonder if I am missing something in my resource references and if anyone
knows what that might be.
 

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

Back
Top