ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Formatting Charts Using Macros (https://www.excelbanter.com/excel-discussion-misc-queries/225404-formatting-charts-using-macros.html)

neesie214

Formatting Charts Using Macros
 
Hi,

How do I create and run a macro to format a bar graph in Excel? For example,
I want to change a bar to brown and then apply a gradient. Formatting text
seems easy enough, but I don't know how to create macros to format colors in
charts.

Thanks!

Jon Peltier

Formatting Charts Using Macros
 
If you have Excel 2003 or earlier, you can simply turn on the macro
recorder, perform the formatting manually, then examine the recorded code.
It won't be efficient code, but it will work, and it will give you the
syntax needed. I've written a couple guidelines for fixing up your recorded
macros:

http://peltiertech.com/WordPress/how...ecorded-macro/
http://peltiertech.com/WordPress/mak...dent-of-sheet/

If you are using Excel 2007, you can still use macros from 2003, usually
without major changes. However, the macro recorder doesn't record any
formatting you perform on shapes or charts. You could try using the help
files, but for over two years I've struggled with them.

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services, Inc.
http://PeltierTech.com/WordPress/
_______


"neesie214" wrote in message
...
Hi,

How do I create and run a macro to format a bar graph in Excel? For
example,
I want to change a bar to brown and then apply a gradient. Formatting text
seems easy enough, but I don't know how to create macros to format colors
in
charts.

Thanks!





All times are GMT +1. The time now is 02:43 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com