Macro to place each cells data into its own shape?

tonywatsonhelp

Well-known Member
Joined
Feb 24, 2014
Messages
3,194
Office Version
  1. 365
  2. 2019
  3. 2016
Platform
  1. Windows
Hi Everyone,
I have a list of sentences (Data) in a range of B2:B28
All I want to do is create a shape for each Cell and add the data from that cell into the shape,
i dont want them linked, i just want a shape (square) ith the data from each cell in it so i have 26 shapes each with data in. it doesnt matter where on the page they apear as i'll be moving them around once done.
Thanks
Tony
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
Tony, try....

VBA Code:
Sub TWHShapes()
Dim Shp As Shape
For Each cell In ActiveSheet.Range("B3:B28").Cells

    Set Shp = ActiveSheet.Shapes.AddShape(msoShapeRectangle, 260.25, 14.25, 96, 51.75)
    
    With Shp
        .TextFrame2.TextRange.Text = cell.Value
   
        .TextFrame.AutoSize = msoAutoSizeShapeToFitText
        .Top = cell.Top
     End With
  Next cell

End Sub
 
Upvote 0

Forum statistics

Threads
1,214,865
Messages
6,121,988
Members
449,060
Latest member
mtsheetz

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