Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Control Row Height
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 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Control Row Height
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 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Control Row Height
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 |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Control Row Height
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 |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Control Row Height
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 |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
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 | | |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How to control row height and text wrap in non-merged cell ??? | Excel Discussion (Misc queries) | |||
need to know how to control length and height of lines | New Users to Excel | |||
how to increase the height of a check box from the control toolbox | Excel Discussion (Misc queries) | |||
Is there a way that I can control a row's height with programming? (or cell contents) | Excel Programming | |||
Changing the height of a commandbar control (edit box) at runtime | Excel Programming |