Text in a Rectangle Object

R

Rob

I have a rectangle in a worksheet "Rectangle 43", I want to copy some text I
have in a cell which is a formula (Sheet1!A5&" "&Sheet2!A5) in to this
rectangle. I select the cell containing the text, copy this and then select
the rectangle but the paste button is not available.
I have tried the following but this fails

ActiveSheet.Shapes("Rectangle 43").TextFrame.Characters.Text = Sheet1!A5&"
"&Sheet2!A5
 
P

Per Jessen

Hi

Try this:

ActiveSheet.Shapes("Rectangle 43").TextFrame.Characters.Text =
Worksheets("Sheet1").Range("A5") & " " & Sheets("Sheet2").Range("A5")

Regards,
Per
 
R

Rob

Thanks for this it works a treat

Per Jessen said:
Hi

Try this:

ActiveSheet.Shapes("Rectangle 43").TextFrame.Characters.Text =
Worksheets("Sheet1").Range("A5") & " " & Sheets("Sheet2").Range("A5")

Regards,
Per
 

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

Top