Invisibleman
New Member
- Joined
- Sep 16, 2015
- Messages
- 13
Dear all,
I have a sheet with multiple colors, that I want to set the color value in. However, no matter what I do the result is always 16777215. And it's strange, that it's only from 1 sheet, that give me this same result no matter which color is selected. The coloring is not done by conditional formatting, but really filled with the colors, I copied from another sheet, where I created these colors.
The code I used, is the following, as it was only for temperary use, it's not the best coding, but still. The result is not what it should be. And I tried multiple ways. See also the picture, for the sheet and the code I have.
For now I did got the color code numbers thru another way, but as you can see in the T column, the colors are always the same but it should show the color number as it is mentioned in the S column.
But if anyone can help/explain to me, why the clor code isn't shown correctly, then this would highly appreciated.
Regards,
Hans
I have a sheet with multiple colors, that I want to set the color value in. However, no matter what I do the result is always 16777215. And it's strange, that it's only from 1 sheet, that give me this same result no matter which color is selected. The coloring is not done by conditional formatting, but really filled with the colors, I copied from another sheet, where I created these colors.
The code I used, is the following, as it was only for temperary use, it's not the best coding, but still. The result is not what it should be. And I tried multiple ways. See also the picture, for the sheet and the code I have.
VBA Code:
Private Sub CommandButton1_Click()
Dim yyFN As Integer, fc, tc, s, t As String
s = Settings_ColorsCharts.Range("U1").Value
For yyFN = 3 To 203
fc = Trim(UCase(s) & yyFN)
tc = "S" & yyFN
t = "T" & yyFN
Settings_ColorsCharts.Range(tc).Value = fc
Settings_ColorsCharts.Range(t).Value = Settings_ChartColors.Range(fc).Interior.Color
Next
End Sub
For now I did got the color code numbers thru another way, but as you can see in the T column, the colors are always the same but it should show the color number as it is mentioned in the S column.
But if anyone can help/explain to me, why the clor code isn't shown correctly, then this would highly appreciated.
Regards,
Hans