welshgasman
Well-known Member
- Joined
- May 25, 2013
- Messages
- 1,393
- Office Version
- 2019
- 2007
- Platform
- Windows
Hi all,
I am trying to create a workbook for one of my bosses.
What he wants is a workbook to list various options against various topics of a property. That I can easily do with data validation. However when you use the dropdown, the text is always small and he would be using this on a Surface tablet, and they are small enough as it is.
So I could use something along the lines of the code below, but that has to be in each sheet that has the dropdowns. So I can copy and paste that into each sheet and have done so.
My problem is that my approach at present is to have template sheets for the likes of *******, Bathroom, Bedroom etc
The first sheet (Property) identifies how many of each type there are, and my plan is to create as many sheets as required for each of the above, so there could be 2 bathrooms and 3 bedrooms, and I would name the sheets Bathroom1, Bathroom2, Bedroom1, Bedroom2,Bedroom3 etc
That part I have working. My problem is as these are new sheets there is no code behind them for the dropdown, so whilst the validation works as intended, it is back to small text again.
Is it possible to attach code from one sheet to code on another at all?, or can someone suggest a better approach.?
TIA
I am trying to create a workbook for one of my bosses.
What he wants is a workbook to list various options against various topics of a property. That I can easily do with data validation. However when you use the dropdown, the text is always small and he would be using this on a Surface tablet, and they are small enough as it is.
So I could use something along the lines of the code below, but that has to be in each sheet that has the dropdowns. So I can copy and paste that into each sheet and have done so.
My problem is that my approach at present is to have template sheets for the likes of *******, Bathroom, Bedroom etc
The first sheet (Property) identifies how many of each type there are, and my plan is to create as many sheets as required for each of the above, so there could be 2 bathrooms and 3 bedrooms, and I would name the sheets Bathroom1, Bathroom2, Bedroom1, Bedroom2,Bedroom3 etc
That part I have working. My problem is as these are new sheets there is no code behind them for the dropdown, so whilst the validation works as intended, it is back to small text again.
Is it possible to attach code from one sheet to code on another at all?, or can someone suggest a better approach.?
TIA
Code:
Sub AllWorksheet_SelectionChange(ByVal Target As Range)
'updateby Extendoffice 20160530
On Error GoTo LZoom
Dim xZoom As Long
xZoom = 100
If Target.Validation.Type = xlValidateList Then xZoom = 115
LZoom:
ActiveWindow.Zoom = xZoom
End Sub
Last edited: