ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Drop Down Menu (https://www.excelbanter.com/excel-discussion-misc-queries/216670-drop-down-menu.html)

Diana[_2_]

Drop Down Menu
 
Hi

How can I lock a dropdwown menu only from adding anything other than what I
have on the list. I have the show error alert clicked but it is still
allowing me add to the list. Is there a specific source or data validation I
need to type. I am only want to lock the dropdown menu on my worksheet.

Thank you

ck

Drop Down Menu
 
use protection(Tool, protection). Protect the sheet or the cell or a range
you want to prevent someone from changing. To activate protection, the cell
must be locked(Format, protection, mark locked).
Hope it helps, goodluck
=================
"Diana" wrote:

Hi

How can I lock a dropdwown menu only from adding anything other than what I
have on the list. I have the show error alert clicked but it is still
allowing me add to the list. Is there a specific source or data validation I
need to type. I am only want to lock the dropdown menu on my worksheet.

Thank you


JB

Drop Down Menu
 
Hello,

Suppress error alert in DropDown:

Private Sub Worksheet_Change(ByVal Target As Range)
If Not Intersect(Range("A2,A4"), Target) Is Nothing Then
Application.EnableEvents = False
If Left(Target.Validation.Formula1, 1) = "=" Then ' List in
WorkSheet
NameList = Mid(Target.Validation.Formula1, 2)
If IsError(Application.Match(Target.Value, Range(NameList), 0))
Then
'MsgBox "Error!"
Target = Empty
End If
Else
temp = Target.Validation.Formula1 ' List in
DropDown
p = InStr(temp, Target.Value)
If p = 0 Then
Target = Empty
End If
End If
Application.EnableEvents = True
End If
End Sub

http://cjoint.com/?bsgDYsZG86

JB
http://boisgontierjacques.free.fr

On 16 jan, 05:50, CK wrote:
use protection(Tool, protection). Protect the sheet or the cell or a range
you want to prevent someone from changing. To activate protection, the cell
must be locked(Format, protection, mark locked).
Hope it helps, goodluck
=================



"Diana" wrote:
Hi


How can I lock a dropdwown menu only from adding anything other than what I
have on the list. I have the show error alert clicked but it is still
allowing me add to the list. Is there a specific source or data validation I
need to type. I am only want to lock the dropdown menu on my worksheet.


Thank you- Masquer le texte des messages précédents -


- Afficher le texte des messages précédents -



Debra Dalgleish

Drop Down Menu
 
If your dropdown list is based on a named range on a worksheet, perhaps
there's a blank cell in that named range. If that's the problem, you can
change the Ignore Blank setting, to prevent invalid entries:

http://www.contextures.com/xlDataVal08.html#Invalid

Diana wrote:
Hi

How can I lock a dropdwown menu only from adding anything other than what I
have on the list. I have the show error alert clicked but it is still
allowing me add to the list. Is there a specific source or data validation I
need to type. I am only want to lock the dropdown menu on my worksheet.

Thank you



--
Debra Dalgleish
Contextures
www.contextures.com/tiptech.html
Blog: http://blog.contextures.com



All times are GMT +1. The time now is 12:06 PM.

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