View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
Jim Rech Jim Rech is offline
external usenet poster
 
Posts: 2,718
Default Control Row Height

I suppose that would work if he also secured the code module.

Well, I design Excel apps with the intent of preventing users from
accidentally destroying them, but if they truly want to muck things up then
they certainly can. In Excel nothing is really 'secure' as you know so
that's all we can do.
--
Jim
"JLGWhiz" wrote in message
...
| Hi Jim, I suppose that would work if he also secured the code module.
The
| OP objective was to lock the row height so that it could not be tampered
| with, but I suppose just making it revert back to the desired setting
would
| work about 99.8% of the time until somebody who really wanted to change it
| came along..
|
| "Jim Rech" wrote:
|
| I don't believe the format facility has an event that can be trapped
|
| You're right so the only option is some other event like
SelectionChange:
|
| Private Sub Worksheet_SelectionChange(ByVal Target As Range)
| If Range("10:10").RowHeight < 15 Then
| Range("10:10").RowHeight = 15
| MsgBox "Please don't change row 10's height"
| End If
| End Sub
|
| This goes in the sheet module.
|
| --
| Jim
| "JLGWhiz" wrote in message
| ...
| | Steven, I don't believe the format facility has an event that can be
| trapped
| | to control the row height. Maybe someone smarter than me could create
| one,
| | but there are no built in methods other than locking the sheet that I
know
| of.
| |
| | "Steven" wrote:
| |
| | And the % view also. Is that controllable. Thank you.
| |
| | "Steven" wrote:
| |
| | I want to control the row height by not allowing a user to chage
it
| but I
| | dont want to protect the worksheet. Can this be done. All I have
| thought of
| | so far is on Auto_Open is to set the row height as I want it but
that
| does
| | not give the user notice as they try to change the row height.
When
| they
| | change it I would like to give a message that the row height
cannot be
| change
| | and then set it back. Even if they have select more than one row
or
| if they
| | do auto wrap...etc.
| |
| | Thank you,
| |
| | Steven
|
|