insert text in a sheet textbox

Av8tordude

Well-known Member
Joined
Oct 13, 2007
Messages
978
i have a textbox located on a sheet (Named: Version). Each time A1 is updated with a new number, I have to change the text in the textbox also. Can someone assist me with a macro that will automatically change the text in the textbox to the value in cell A1.

Thanks for you help
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop

Marcelo Branco

MrExcel MVP
Joined
Aug 23, 2010
Messages
16,881
Office Version
  1. 2019
  2. 2010
Platform
  1. Windows
Hi,

I think you can use the LinkedCell property assigning it to A1.

If you have already assigned a LinkedCell and cannot change it, maybe this

Code:
Private Sub Worksheet_Change(ByVal Target As Range)
    If Not Intersect(Target, Range("A1")) Is Nothing Then
        TextBox1.Value = Range("A1")
    End If
End Sub

HTH

M.
 

Av8tordude

Well-known Member
Joined
Oct 13, 2007
Messages
978
Hi,

I think I might have used the wrong terminology. The textbox is not like a userform textbox , but a Box that you right-click inside to insert text.

Thanks
 

Marcelo Branco

MrExcel MVP
Joined
Aug 23, 2010
Messages
16,881
Office Version
  1. 2019
  2. 2010
Platform
  1. Windows
Well, sorry but i never heard about a Box like this. How did you create it?

M.
 

Fazza

MrExcel MVP
Joined
May 17, 2006
Messages
9,368
hi, Select the text box and then in the formula bar enter =A1, then return. HTH
 

Forum statistics

Threads
1,144,515
Messages
5,724,811
Members
422,579
Latest member
parsnipsnatcher

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top