Wikiposts
Search
Computer/Internet Issues & Troubleshooting Anyone with questions about the terribly complex world of computers or the internet should try here. NOT FOR REPORTING ISSUES WITH PPRuNe FORUMS! Please use the subforum "PPRuNe Problems or Queries."

Macros in Excel ...... ?

Thread Tools
 
Search this Thread
 
Old 27th Jan 2007, 12:05
  #1 (permalink)  
Thread Starter
 
Join Date: Dec 2000
Location: Red Red Back to Bed
Posts: 541
Likes: 0
Received 0 Likes on 0 Posts
Question Macros in Excel ...... ?

Hi

Can someone explain how to design and put a macro in excel that can help automatically draw arrows of specific lengths and fill colours?

TIA

Oggin
Oggin Aviator is offline  
Old 23rd Feb 2007, 00:15
  #2 (permalink)  
 
Join Date: Mar 2002
Location: UK
Age: 62
Posts: 6
Likes: 0
Received 0 Likes on 0 Posts
Go to Menu: Tools/Macro/Record New Macro and draw sample arrows and then format as required, then stop macro recording.

Press Alt + F8 (or Menu: Tools/Macro/Macros) and choose Edit and you will see the macro you have just recorded. You can edit the macro's AddLine Method to change the arrows as required. When you want to run the modified macro you can hit Alt + F8, select the macro and choose Run. You could also assign the macro to a button on your worksheet or to a new toolbar or menu command.

AddLine Method Example:
This example adds a blue dashed line to myDocument.
Set myDocument = Worksheets(1)
With myDocument.Shapes.AddLine(10, 10, 250, 250).Line
.DashStyle = msoLineDashDotDot
.ForeColor.RGB = RGB(50, 0, 128)
End With
Glen Livid is offline  

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



Contact Us - Archive - Advertising - Cookie Policy - Privacy Statement - Terms of Service

Copyright © 2024 MH Sub I, LLC dba Internet Brands. All rights reserved. Use of this site indicates your consent to the Terms of Use.