Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default range onclick?

Hi,
I want to run a subroutine onclick in an excel worksheet.
More precise: Onclick in any cell I want to check for that
cells properties and then react depending on them.
Please help, how do I get excel to react on every click in
the active sheet.
Dennis
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default range onclick?

I got it.
sorry to have bothered you for nothing.
But - IŽll be back with more profound questions.

my solution:

"Private Sub Worksheet_SelectionChange(ByVal Target As
Range)"

thanks anyway

dennis


-----Original Message-----
Hi,
I want to run a subroutine onclick in an excel worksheet.
More precise: Onclick in any cell I want to check for

that
cells properties and then react depending on them.
Please help, how do I get excel to react on every click

in
the active sheet.
Dennis
.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 42
Default range onclick?

Hi,

You can you worksheet's SelectionChange event (this is just for a single sheet) or if you want to control this event in workbook base, use Workbook's SheetSelectionChange event.

Target variable represents selected cell(s).

Private Sub Worksheet_SelectionChange(ByVal Target As Range)

if target.count=1 then 'check if just one cell selected.
'Do something
end if


End Sub


OR

Private Sub Workbook_SheetSelectionChange(ByVal Sh As Object, ByVal Target As Range)
if target.count=1 then 'check if just one cell selected.
'Do something
end if
End Sub


--
Regards

Haldun Alay

To e-mail me, please remove AT and DOT from my e-mail address.



"Dennis" , iletide sunu yazdi ...
Hi,
I want to run a subroutine onclick in an excel worksheet.
More precise: Onclick in any cell I want to check for that
cells properties and then react depending on them.
Please help, how do I get excel to react on every click in
the active sheet.
Dennis
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 enter formula sum(range+range)*0.15 sumif(range=3) tkw Excel Discussion (Misc queries) 2 October 1st 09 09:17 PM
Excel Addin:Setting the range to the Excel.Range object range prop Rp007 Excel Worksheet Functions 5 November 24th 06 04:30 PM
OnClick [email protected] Excel Discussion (Misc queries) 1 August 31st 06 06:08 PM
Cell onclick make cell value increase. Cali92 Excel Programming 6 September 28th 03 02:27 AM
how to? set my range= my UDF argument (range vs. value in range) [advanced?] Keith R[_3_] Excel Programming 2 August 11th 03 05:55 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"