ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Worksheet_BeforeDoubleClick() (https://www.excelbanter.com/excel-programming/427788-worksheet_beforedoubleclick.html)

Jock

Worksheet_BeforeDoubleClick()
 
There are 5 seperate, non adjacent columns in which I'd like the user to be
able to select any cell and double click it resulting in a tick being placed
in that cell.
I can get it to work for a single column, but can't figure out how to apply
the code to include the other columns.
Piece of the code which I use:
......If Not Application.Intersect(Target, Columns("E:E")) Is Nothing Then.....
I also need columns N, P, S and AB included. Any thoughts?
--
Traa Dy Liooar

Jock

Simon Lloyd[_1120_]

Worksheet_BeforeDoubleClick()
 

Like this:

Code:
--------------------

If Not Intersect(Target, Range("E:E,N:N,P:P,S:S,AB:AB")) Is Nothing Then

--------------------

Jock;328271 Wrote:
There are 5 seperate, non adjacent columns in which I'd like the user to
be
able to select any cell and double click it resulting in a tick being
placed
in that cell.
I can get it to work for a single column, but can't figure out how to
apply
the code to include the other columns.
Piece of the code which I use:
......If Not Application.Intersect(Target, Columns("E:E")) Is Nothing
Then.....
I also need columns N, P, S and AB included. Any thoughts?
--
Traa Dy Liooar

Jock



--
Simon Lloyd

Regards,
Simon Lloyd
'The Code Cage' (http://www.thecodecage.com)
------------------------------------------------------------------------
Simon Lloyd's Profile: http://www.thecodecage.com/forumz/member.php?userid=1
View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=91723


Jock

Worksheet_BeforeDoubleClick()
 
Thanks Simon.
--
Traa Dy Liooar

Jock


"Simon Lloyd" wrote:


Like this:

Code:
--------------------

If Not Intersect(Target, Range("E:E,N:N,P:P,S:S,AB:AB")) Is Nothing Then

--------------------

Jock;328271 Wrote:
There are 5 seperate, non adjacent columns in which I'd like the user to
be
able to select any cell and double click it resulting in a tick being
placed
in that cell.
I can get it to work for a single column, but can't figure out how to
apply
the code to include the other columns.
Piece of the code which I use:
......If Not Application.Intersect(Target, Columns("E:E")) Is Nothing
Then.....
I also need columns N, P, S and AB included. Any thoughts?
--
Traa Dy Liooar

Jock



--
Simon Lloyd

Regards,
Simon Lloyd
'The Code Cage' (http://www.thecodecage.com)
------------------------------------------------------------------------
Simon Lloyd's Profile: http://www.thecodecage.com/forumz/member.php?userid=1
View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=91723




All times are GMT +1. The time now is 01:38 AM.

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