VBA to remove color from a datalabel???

Lidsavr

Active Member
Joined
Jan 10, 2008
Messages
330
I am running Excel 2003.

I've searched all of my reference books, this forum and the internet and cannot find an answer.

I know I can add color to a data label background (interior fill) with the following code:

Code:
ActiveChart.SeriesCollection(1).DataLabels.Interior.Color = RGB(108, 108, 108)

I cannot figure out how to write the code so the data label fill color is 'none'. (I've tried "None" and the data label fill color becomes black).

Does anyone have any suggestions or a line of code to do it?

Many thanks,

Charles
 

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes
Maybe

Code:
ActiveChart.SeriesCollection(1).DataLabels.Interior.Color = RGB(255, 255, 255)
 
Upvote 0
VoG,
I forgot to add that the datalabels are centered on a red column. My mistake. The code you gave me makes the background 'white', which ends up enhancing the problem, not eliminating it. The best way to describe what I want to do is when you eliminate the color in 2007 manually, you would click format labels - fill = no fill.

I have seen a lot of your posts and you are one of the best code writers on the forum. Do you have any other suggestions?

Thank you,

Charles
 
Upvote 0
Resurrecting an old thread (since I had the exact same question), xlNone made a funky light blue. My only working solution was to not assign a color until I knew I wanted it.
 
Upvote 0

Forum statistics

Threads
1,224,602
Messages
6,179,848
Members
452,948
Latest member
UsmanAli786

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