Arrows & Text Boxes

Jamey

New Member
Joined
Aug 31, 2012
Messages
22
I have a workbook, each sheet is protected. Each sheet is a report, which includes inserted images. I would like to be able to use arrows and textbox's to annotate the images in a report. I need help with two parts.
1. I need two individual macros. One to generate an Arrow, and the second to Generate a TextBox. Both formatted black, heave, and 3D as in the example. The macros will be launched from the ribbon, so the objects should be launched in the center of whatever the screen is presently displayed.

excelobjects.PNG


2. New reports are generated by a macro that creates a copy of the current report, and deletes data that does not need to be carried over (this include images contained within, and any textbox's / arrows over the images). When new reports are created, I need the TextBox & Arrows to be removed from the new report. So the code would need to be specific for only these two items.

Any help on this would be greatly appreciated!!!! Thanks in advance!
 
Choose Debug, turn on Locals (View | Locals Window) and see what the values of VScreenParameters(0) through (3) are. They should be long numbers representing the rows and columns at the edge of the screen.

This previous code I posted is working on my machine and putting the box and arrow in the center of the screen no mater the zoom or positioning.

This change might help:
Code:
    lTopRow = CLng(vScreenParameters(0))
    lBottomRow = CLng(vScreenParameters(1))
    lLeftCol = CLng(vScreenParameters(2))
    lRightCol = CLng(vScreenParameters(3))
although I don't see why it would be needed.
 
Upvote 0

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
I followed your instructions. The following screen is what I get. Changing the code brought back the same error.
Window.PNG
 
Upvote 0
Can I change the numbers in the Views Local window? I've tried to change the values but they do not hold.
 
Upvote 0
The views local numbers shows the current values of all variables. If you want to make a temporary change, you can type a statement in the Immediate window. For instance, referencing the above screen, if you typed lRightCol = 25 in the immediate window the value in the locals window would change and if you started executing the code, it would use that value as it executed.
 
Upvote 0

Forum statistics

Threads
1,214,393
Messages
6,119,261
Members
448,880
Latest member
aveternik

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