VBA Shapes in Presentation

fedas18

Board Regular
Joined
Jan 21, 2010
Messages
81
Hi,

I have built an excel model that I am planning on presenting to the client. As part of the presentation, I was hoping to draw a circle around certain cells. Then have a line connecting the cirlce to a text box with certain text to appear. I would like this to happen when I press a macro botton.

I hope that made sense, but to give you an alternative way of thinking about it, it is kinda like when you watch sports on TV. When the announcer views the replay and draws on the screen to break down the play in to a simple form.

I tried recording a shape but it did not work.

Any tips or advice?

Thanks!
 

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.
I found this information.

http://msdn.microsoft.com/en-us/library/aa221788(v=office.11).aspx


An Example for a TextBox

Code:
Sub Shape_add()
ActiveSheet.Shapes.AddTextbox(msoTextOrientationHorizontal, [G3].Left, [G3].Top + 5, _
100, 50#).Select
    Selection.Characters.Text = "ABC"
End Sub

You could also look at adding a coloured border or highlighting cells.
 
Last edited:
Upvote 0
I found an example

Code:
Sub Shape_add()
ActiveSheet.Shapes.AddTextbox(msoTextOrientationHorizontal, [G3].Left, [G3].Top + h, _
w, 50#).Select
    Selection.Characters.Text = "Text Box"
 
 
With ActiveSheet.Shapes("TextBox 1")
.Fill.Visible = msoTrue
.Fill.Solid
.Fill.ForeColor.RGB = RGB(255, 255, 0)
.Fill.Transparency = 0#
End With
End Sub
 
Upvote 0

Forum statistics

Threads
1,215,013
Messages
6,122,690
Members
449,092
Latest member
snoom82

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