Hello-
How can I update the color of existing borders while maintaining the border formats (i.e. thickness and style).
I am attaching a sample file for testing. Thanks in advance for your help.
P.
Hello-
How can I update the color of existing borders while maintaining the border formats (i.e. thickness and style).
I am attaching a sample file for testing. Thanks in advance for your help.
P.
Last edited by XL_Newbie; 02-26-2012 at 01:25 AM.
Hilight the area you want, right click/format cells/borders...pick the color you want and apply it to the lines you want. This will not change the line thickness etc
1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
2. If your question is resolved, mark it SOLVED using the thread tools
3. Click on the star if you think someone helped you
Regards
Ford
there may be an easier solution, but you could use a macro like this
just need to set the colour, the bellow will make all borders red
Please Login or Register to view this content.
[QUOTE=DGagnon;2717909]there may be an easier solution, but you could use a macro like this
just need to set the colour, the bellow will make all borders red
That's exactly what I need. Thanks much DGagnon. You got a star.
P.
no problem, if you need help finding a colour value please let me know. Also you may need to adjust the ranges in the loop to suit your specific needs.
easiest way to find it would be to record a macro and manualy change one cell to the desired colour. you could then look at the recorded macro in the VB editor and look for the colour attribute. you could also use colorindex instead of color which is a set list of 56 useable colours, that would make the code look like this
list of colour index can be found at http://msdn.microsoft.com/en-us/libr...ffice.12).aspxPlease Login or Register to view this content.
If you liked my solution, please click on the Star -- to add to my reputation
If your issue as been resolved, please clearly state so and mark the thread as [SOLVED] using the thread tools just above the first post.
Thanks again for your help. I did try the macro recording first but I kept getting a value of one for the very light grey color selected then plugged in the value into the first code you sent but it didn't work.
anyway, the later code and color link you sent works fine for me. Thanks again.
P.
any time, glad to help.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks