PC Review


Reply
Thread Tools Rate Thread

How to do when the Cell is in color jump to next cell?

 
 
jean
Guest
Posts: n/a
 
      13th Apr 2008
Hi,
I have a worksheet with some column in blue color background & when i enter
the data in this worksheet (direction Right when I press the ENTER key) I
would like if the next column is in blue the cursor automaticly jump to the
next column until the cell have no background color.
It is Possible?
Thank you very much

Jean
 
Reply With Quote
 
 
 
 
Rick Rothstein \(MVP - VB\)
Guest
Posts: n/a
 
      13th Apr 2008
I guess you could use SelectionChange event code something like this...

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Target.Cells.Interior.ColorIndex = 41 And _
Target.Column < Columns.Count And Target.Count = 1 Then
Target.Offset(0, 1).Select
End If
End Sub

Change the number 41 I used above to the ColorIndex value for your
particular Blue color.

Rick


"jean" <(E-Mail Removed)> wrote in message
newsF00EB36-077C-4A4F-8721-(E-Mail Removed)...
> Hi,
> I have a worksheet with some column in blue color background & when i
> enter
> the data in this worksheet (direction Right when I press the ENTER key) I
> would like if the next column is in blue the cursor automaticly jump to
> the
> next column until the cell have no background color.
> It is Possible?
> Thank you very much
>
> Jean


 
Reply With Quote
 
jean
Guest
Posts: n/a
 
      13th Apr 2008
Thank you very much.
I copy that in my sheets after changing the number of the colorindex & it
work beautifully.
Thank you again.
Jean

"Rick Rothstein (MVP - VB)" wrote:

> I guess you could use SelectionChange event code something like this...
>
> Private Sub Worksheet_SelectionChange(ByVal Target As Range)
> If Target.Cells.Interior.ColorIndex = 41 And _
> Target.Column < Columns.Count And Target.Count = 1 Then
> Target.Offset(0, 1).Select
> End If
> End Sub
>
> Change the number 41 I used above to the ColorIndex value for your
> particular Blue color.
>
> Rick
>
>
> "jean" <(E-Mail Removed)> wrote in message
> newsF00EB36-077C-4A4F-8721-(E-Mail Removed)...
> > Hi,
> > I have a worksheet with some column in blue color background & when i
> > enter
> > the data in this worksheet (direction Right when I press the ENTER key) I
> > would like if the next column is in blue the cursor automaticly jump to
> > the
> > next column until the cell have no background color.
> > It is Possible?
> > Thank you very much
> >
> > Jean

>
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Active cell is to jump from one cell to another when conditions are met Michael Lanier Microsoft Excel Programming 2 21st Jan 2011 03:15 AM
HELP W/ VBA: SELECT RANGE, ALLCAPS, CELL COLOR, RETURN TO BLANK CELL/PATTERN CELL extremejobtvshow@gmail.com Microsoft Excel Programming 5 28th Jun 2008 07:49 PM
Jump to cell based on cell results created by calendar control too JB Microsoft Excel Misc 3 15th Jan 2008 08:18 PM
How to automatically jump to neighboring cell as active cell? AA Arens Microsoft Excel Discussion 2 1st Jan 2007 12:28 PM
How do I double click a cell and jump to cell's referenced cell =?Utf-8?B?SmVycnlKdWljZQ==?= Microsoft Excel Misc 2 10th Sep 2005 10:24 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 05:20 AM.