ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Select a cel on a worksheet (https://www.excelbanter.com/excel-programming/353605-select-cel-worksheet.html)

Tadashii[_5_]

Select a cel on a worksheet
 

Hello,

Is there a function that when called, the user allow to select a cel on
a woorksheet and that the function returns the selected worksheet and
the selected cel (x,y position)?

Tadashii


--
Tadashii
------------------------------------------------------------------------
Tadashii's Profile: http://www.excelforum.com/member.php...o&userid=23918
View this thread: http://www.excelforum.com/showthread...hreadid=513643


Gary''s Student

Select a cel on a worksheet
 
I don't think that Select by single-click is possible. How about double-click:


Private Sub Worksheet_BeforeDoubleClick(ByVal _
Target As Range, Cancel As Boolean)
Cancel = True
MsgBox (Target.Address)
MsgBox (Target.Worksheet.Name)
End Sub


Put this in worksheet code, not a module.
--
Gary''s Student


"Tadashii" wrote:


Hello,

Is there a function that when called, the user allow to select a cel on
a woorksheet and that the function returns the selected worksheet and
the selected cel (x,y position)?

Tadashii


--
Tadashii
------------------------------------------------------------------------
Tadashii's Profile: http://www.excelforum.com/member.php...o&userid=23918
View this thread: http://www.excelforum.com/showthread...hreadid=513643




All times are GMT +1. The time now is 12:33 AM.

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