Display a TextBox in a Picture based on the value in a cell

PeterMac65

New Member
Joined
May 7, 2020
Messages
17
Office Version
  1. 365
Platform
  1. Windows
Hi,
I know i can show the contents of a textBox in a picture by Naming the Cell and referring to that name in the picture.
eg =Payment_terms


But i have 2 textBoxes that i wish to choose from.
eg =IF(contract_type="TurnKey Contract", TurnKey_Contract, StandardMB_Contract)

I can't do this in the Picture formula, but can i do something with the Text Boxes? Preferably without VBA

Regards Peter
 

Excel Facts

How can you turn a range sideways?
Copy the range. Select a blank cell. Right-click, Paste Special, then choose Transpose.
Hi Peter,

you could add that formula to a new named range, then reference that new named range in the picture/shape so it would update dynamically.
 
Upvote 0
Thanks Craggs82,
I couldn't figure how to make your suggestion work.

So I resorted to VBA
Public Sub Worksheet_Activate()
If ActiveWorkbook.Sheets("Data").Range("contract_type").Value = "TurnKey Contract" Then
ActiveSheet.Shapes.Range(Array("bring_picture")).Visible = msoTrue
Else
ActiveSheet.Shapes.Range(Array("bring_picture")).Visible = msoFalse
End If
End Sub

If your way works feel free to add more detail
Regards Peter
 
Upvote 0

Forum statistics

Threads
1,214,985
Messages
6,122,603
Members
449,089
Latest member
Motoracer88

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
Back
Top