ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   textBox font colour the same as cell font colour???????? (https://www.excelbanter.com/excel-discussion-misc-queries/219617-textbox-font-colour-same-cell-font-colour.html)

sophie

textBox font colour the same as cell font colour????????
 
Please can anybody help!!!!

How do I copy the font colour of a cell to a textbox.
Say, cell "A1" font colour changed to RED, then the textbox that is linked
to that cell changes as well.
--
Sophie

--
Sophie

curlydave

textBox font colour the same as cell font colour????????
 
This will not work if the cell color is changed using Conditional
Formating,
Place this code in the Worksheet Module

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
TextBox1.BackColor = Range("A1").Interior.Color
End Sub


sophie

textBox font colour the same as cell font colour????????
 
Thanks Curly,
Unfortunately that is what I was looking for. My cells change colour by
using conditional formating.
I take it there isn't a way then?
--
Sophie


"CurlyDave" wrote:

This will not work if the cell color is changed using Conditional
Formating,
Place this code in the Worksheet Module

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
TextBox1.BackColor = Range("A1").Interior.Color
End Sub



curlydave

textBox font colour the same as cell font colour????????
 
Probably not, VBA would be needed to color the cells and textBox
conditionally

sophie

textBox font colour the same as cell font colour????????
 
Thank you Curly. I'll have to dig out a conditional vb code to do this!!!!!
some how!!!
--
Sophie


"CurlyDave" wrote:

Probably not, VBA would be needed to color the cells and textBox
conditionally



All times are GMT +1. The time now is 10:57 PM.

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