Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Automatic Bolding and Background Coloring

Private Sub Worksheet_SelectionChange(ByVal Target As Range)

On Error GoTo ws_exit:
Application.EnableEvents = False
If Target.Column = 3 Then
With Target.EntireRow
.Font.Bold = True
.Interior.ColorIndex = 6
End With
End If

ws_exit:
Application.EnableEvents = True
End Sub


'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"OriginalStealth" wrote in
message ...
ID TITLE TitleID

66749 Devil's Advocate 323484
66750 Warner Cable 3 301350
66750 Warner Cable 3 301350
66750 Warner Cable 3 301350
66750 Warner Cable 3 301350
66795 Paycheck 322940

1. How can I double-click on the ID and have the whole
line bold and the row changes to yellow.

2. When I click an ID that has duplicates beneath it, the
first line bolds and all of them turn yellow.

Thanks in advance
OS




  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default Automatic Bolding and Background Coloring

Hi Bob
but this will not reset the color after the selection :-)
(and as a sidenote will not color duplicate rows...)

P.S.: Have you received my second email regarding your website?
--
Regards
Frank Kabel
Frankfurt, Germany


Bob Phillips wrote:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)

On Error GoTo ws_exit:
Application.EnableEvents = False
If Target.Column = 3 Then
With Target.EntireRow
.Font.Bold = True
.Interior.ColorIndex = 6
End With
End If

ws_exit:
Application.EnableEvents = True
End Sub


'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.


"OriginalStealth" wrote

in
message ...
ID TITLE TitleID

66749 Devil's Advocate 323484
66750 Warner Cable 3 301350
66750 Warner Cable 3 301350
66750 Warner Cable 3 301350
66750 Warner Cable 3 301350
66795 Paycheck 322940

1. How can I double-click on the ID and have the whole
line bold and the row changes to yellow.

2. When I click an ID that has duplicates beneath it, the
first line bolds and all of them turn yellow.

Thanks in advance
OS


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I make automatic coloring in a cell vth conditions attache SPM Excel Discussion (Misc queries) 7 May 25th 07 11:56 AM
How do I turn off automatic fill coloring in excel Michael Excel Discussion (Misc queries) 0 March 16th 06 01:36 AM
How do I turn off automatic fill coloring in excel Michael Excel Discussion (Misc queries) 0 March 16th 06 01:34 AM
Automatic coloring of blank cells when sheet work complete bigdaddy3 Excel Worksheet Functions 14 August 5th 05 05:00 PM
Excel should allow automatic tab coloring. Tugboat Setting up and Configuration of Excel 2 February 21st 05 10:45 PM


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

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"