![]() |
mouse location
I have a protected worksheet.
How can I insert a Row based on the location of the cursor using a Macro? Need the location of the Row based on the location of the cursor. Thanks |
mouse location
Something like...
Option Explicit Sub testme() Dim myPWD As String myPWD = "hi" ActiveSheet.Unprotect Password:=myPWD ActiveCell.Offset(1, 0).Insert ActiveSheet.Protect Password:=myPWD End Sub (this inserts a row under the activecell. remove .offset(1,0) if you want it above the activecell.) If you're new to macros, you may want to read David McRitchie's intro at: http://www.mvps.org/dmcritchie/excel/getstarted.htm Dennis wrote: I have a protected worksheet. How can I insert a Row based on the location of the cursor using a Macro? Need the location of the Row based on the location of the cursor. Thanks -- Dave Peterson |
All times are GMT +1. The time now is 02:27 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com