Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 84
Default Highlight Cell

is there a way to have a cell highlighted when it is selected? any cell.
also is it possible to get rid of the thicker border around the cell selected?

Thanks in advance
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default Highlight Cell

Hi Choice,

See Chip Pearson's 'Highlight Active Cell ' page at:

http://www.cpearson.com/excel/excelM...ightActiveCell


---
Regards,
Norman



"choice" wrote in message
...
is there a way to have a cell highlighted when it is selected? any cell.
also is it possible to get rid of the thicker border around the cell
selected?

Thanks in advance



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 747
Default Highlight Cell

The problem with highlight code is that it leaves the cell highlighted on
workbook close and forgets its on subsequent open. Hence, the cell stays
highlighted. This in theory should fix the problems. Granted, I never use it
so maybe it's not that reliable. I hate cell highlighting, sound effects, and
sin of all sins: Flashing Cells !!! Since you've proven you have no taste
whatsoever by asking for cell highlighting then maybe you'll like my code <g.

As far as getting rid of the selection border, I don't think anyone has
found a solution short of colouring all cells dark gray (color index 16 I
think) or other kludge. IMO, this is not supported by VBA and is integral to
Excel, hence API code won't help.

In the ThisWorkbook module paste the following:
Private Sub Workbook_Deactivate()
If Not PrevCell Is Nothing Then _
PrevCell.Interior.ColorIndex = PrevColor
End Sub

In the worksheet code module paste the following:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
On Error Resume Next
If Target.Count 1 Then Exit Sub
If PrevCell Is Nothing Then
Set PrevCell = Target
PrevColor = PrevCell.Interior.ColorIndex
Else
PrevCell.Interior.ColorIndex = PrevColor
Set PrevCell = Target
PrevColor = Target.Interior.ColorIndex
End If
Target.Interior.ColorIndex = 6
End Sub

In a standard module paste the following:
Public PrevCell As Range
Public PrevColor As Integer

Regards,
Greg


"choice" wrote:

is there a way to have a cell highlighted when it is selected? any cell.
also is it possible to get rid of the thicker border around the cell selected?

Thanks in advance

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default Highlight Cell

Hi Greg,

As far as getting rid of the selection border, I don't think anyone has
found a solution


Surely, however, if the sound effects were sufficiently, enterprisingly
selected and the strobic flashing optimally calculated, the selection
borders would be rendered undetectable?

---
Regards,
Norman



"Greg Wilson" wrote in message
...
The problem with highlight code is that it leaves the cell highlighted on
workbook close and forgets its on subsequent open. Hence, the cell stays
highlighted. This in theory should fix the problems. Granted, I never use
it
so maybe it's not that reliable. I hate cell highlighting, sound effects,
and
sin of all sins: Flashing Cells !!! Since you've proven you have no taste
whatsoever by asking for cell highlighting then maybe you'll like my code
<g.

As far as getting rid of the selection border, I don't think anyone has
found a solution short of colouring all cells dark gray (color index 16 I
think) or other kludge. IMO, this is not supported by VBA and is integral
to
Excel, hence API code won't help.

In the ThisWorkbook module paste the following:
Private Sub Workbook_Deactivate()
If Not PrevCell Is Nothing Then _
PrevCell.Interior.ColorIndex = PrevColor
End Sub

In the worksheet code module paste the following:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
On Error Resume Next
If Target.Count 1 Then Exit Sub
If PrevCell Is Nothing Then
Set PrevCell = Target
PrevColor = PrevCell.Interior.ColorIndex
Else
PrevCell.Interior.ColorIndex = PrevColor
Set PrevCell = Target
PrevColor = Target.Interior.ColorIndex
End If
Target.Interior.ColorIndex = 6
End Sub

In a standard module paste the following:
Public PrevCell As Range
Public PrevColor As Integer

Regards,
Greg


"choice" wrote:

is there a way to have a cell highlighted when it is selected? any cell.
also is it possible to get rid of the thicker border around the cell
selected?

Thanks in advance



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 747
Default Highlight Cell

Like your idea about using Ctrl_V better Norman <g.

Regards,
Greg

"Norman Jones" wrote:

Hi Greg,

As far as getting rid of the selection border, I don't think anyone has
found a solution


Surely, however, if the sound effects were sufficiently, enterprisingly
selected and the strobic flashing optimally calculated, the selection
borders would be rendered undetectable?

---
Regards,
Norman



"Greg Wilson" wrote in message
...
The problem with highlight code is that it leaves the cell highlighted on
workbook close and forgets its on subsequent open. Hence, the cell stays
highlighted. This in theory should fix the problems. Granted, I never use
it
so maybe it's not that reliable. I hate cell highlighting, sound effects,
and
sin of all sins: Flashing Cells !!! Since you've proven you have no taste
whatsoever by asking for cell highlighting then maybe you'll like my code
<g.

As far as getting rid of the selection border, I don't think anyone has
found a solution short of colouring all cells dark gray (color index 16 I
think) or other kludge. IMO, this is not supported by VBA and is integral
to
Excel, hence API code won't help.

In the ThisWorkbook module paste the following:
Private Sub Workbook_Deactivate()
If Not PrevCell Is Nothing Then _
PrevCell.Interior.ColorIndex = PrevColor
End Sub

In the worksheet code module paste the following:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
On Error Resume Next
If Target.Count 1 Then Exit Sub
If PrevCell Is Nothing Then
Set PrevCell = Target
PrevColor = PrevCell.Interior.ColorIndex
Else
PrevCell.Interior.ColorIndex = PrevColor
Set PrevCell = Target
PrevColor = Target.Interior.ColorIndex
End If
Target.Interior.ColorIndex = 6
End Sub

In a standard module paste the following:
Public PrevCell As Range
Public PrevColor As Integer

Regards,
Greg


"choice" wrote:

is there a way to have a cell highlighted when it is selected? any cell.
also is it possible to get rid of the thicker border around the cell
selected?

Thanks in advance




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 auto highlight a cell with the same data as another cell john talbot Excel Worksheet Functions 11 February 3rd 09 12:58 AM
how to highlight more related cells if cell highlight Jon Excel Discussion (Misc queries) 5 December 21st 08 01:06 PM
Highlight Cell Based Upon Referenced Cell Data Tee Excel Worksheet Functions 3 September 12th 08 05:26 PM
click on one cell to find and highlight a related cell? JustSomeGuy Excel Discussion (Misc queries) 1 September 3rd 07 03:02 PM
Highlight cells with ctrl-click but only un-highlight one cell hagan Excel Discussion (Misc queries) 5 May 27th 05 06:45 PM


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

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"