Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
Ed Ed is offline
external usenet poster
 
Posts: 279
Default Create or change color of a (line with arrow head) with a Macro en

Hi
Can an item (a line with arrowhead as created by the Drawing function for
example) be created and/or the color of it changed by an entry or entries
in a Macro when certain conditions exist?
If this can be done, how is it done?
Thankyou
Ed
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,588
Default Create or change color of a (line with arrow head) with a Macro en


With ActiveSheet.Shapes.AddLine(240#, 190.5, 432#, 191.25)
.Line.EndArrowheadStyle = msoArrowheadTriangle
.Line.EndArrowheadLength = msoArrowheadLengthMedium
.Line.EndArrowheadWidth = msoArrowheadWidthMedium
.Name = "myLine"
End With

With ActiveSheet.Shapes("myLine")
.Line.ForeColor.RGB = RGB(255, 0, 0)
End With

Tim

--
Tim Williams
Palo Alto, CA


"Ed" wrote in message
...
Hi
Can an item (a line with arrowhead as created by the Drawing function for
example) be created and/or the color of it changed by an entry or

entries
in a Macro when certain conditions exist?
If this can be done, how is it done?
Thankyou
Ed



  #3   Report Post  
Posted to microsoft.public.excel.programming
Ed Ed is offline
external usenet poster
 
Posts: 279
Default Create or change color of a (line with arrow head) with a Macr

Hi Tim
Thanks for the good information. My test Macro tells me I am on the right
track.
I looked for further help on this area of programming in the "Excel Help" on
my computer. I could not find any. Where can I find more information on
this area of programming (such as the line appears properly, but is protected
and can't be removed or replaced with the Macro. Also, information on the
placement of the line and colors.)
I think I need an advanced programming handbook.
Is this information available on the internet?
Or where is one available?
Thanks again
Ed

"Tim Williams" wrote:


With ActiveSheet.Shapes.AddLine(240#, 190.5, 432#, 191.25)
.Line.EndArrowheadStyle = msoArrowheadTriangle
.Line.EndArrowheadLength = msoArrowheadLengthMedium
.Line.EndArrowheadWidth = msoArrowheadWid

thMedium
.Name = "myLine"
End With

With ActiveSheet.Shapes("myLine")
.Line.ForeColor.RGB = RGB(255, 0, 0)
End With

Tim

--
Tim Williams
Palo Alto, CA


"Ed" wrote in message
...
Hi
Can an item (a line with arrowhead as created by the Drawing function for
example) be created and/or the color of it changed by an entry or

entries
in a Macro when certain conditions exist?
If this can be done, how is it done?
Thankyou
Ed




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,588
Default Create or change color of a (line with arrow head) with a Macr

Did you look in help from Excel or from the VB editor ?

I don't know why the line would be protected. Maybe you could show the code
you have so far ?

Lots of VBA help available on the web (searhc Google and you'll find plenty
of tutorials) or in this newsgroup.

Tim

--
Tim Williams
Palo Alto, CA


"Ed" wrote in message
...
Hi Tim
Thanks for the good information. My test Macro tells me I am on the right
track.
I looked for further help on this area of programming in the "Excel Help"

on
my computer. I could not find any. Where can I find more information on
this area of programming (such as the line appears properly, but is

protected
and can't be removed or replaced with the Macro. Also, information on the
placement of the line and colors.)
I think I need an advanced programming handbook.
Is this information available on the internet?
Or where is one available?
Thanks again
Ed

"Tim Williams" wrote:


With ActiveSheet.Shapes.AddLine(240#, 190.5, 432#, 191.25)
.Line.EndArrowheadStyle = msoArrowheadTriangle
.Line.EndArrowheadLength = msoArrowheadLengthMedium
.Line.EndArrowheadWidth = msoArrowheadWid

thMedium
.Name = "myLine"
End With

With ActiveSheet.Shapes("myLine")
.Line.ForeColor.RGB = RGB(255, 0, 0)
End With

Tim

--
Tim Williams
Palo Alto, CA


"Ed" wrote in message
...
Hi
Can an item (a line with arrowhead as created by the Drawing function

for
example) be created and/or the color of it changed by an entry or

entries
in a Macro when certain conditions exist?
If this can be done, how is it done?
Thankyou
Ed






Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
change XL2003 autofilter's arrow color BK Excel Discussion (Misc queries) 9 February 5th 10 11:42 AM
Moving comment box leader arrow head Francisco Rodriguez[_2_] Excel Discussion (Misc queries) 0 January 4th 10 08:31 PM
Mouse pointer (arrow) change color? robert morris Excel Discussion (Misc queries) 3 February 14th 08 03:32 PM
How can I change the color of the drop down arrow on a filter? Stique Excel Discussion (Misc queries) 2 August 8th 05 04:41 PM
How do I change the color of the drop down arrow when using the a. SouthBay588 Excel Discussion (Misc queries) 2 November 27th 04 10:29 AM


All times are GMT +1. The time now is 11:09 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"