Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have this code
Dim Bruger As String Bruger = UCase(InputBox("Indtast brugernavn")) If Bruger = "BUTTERFLY" Then ActiveSheet.Unprotect Range("2:2,4:4,8:8").Select Selection.Locked = False ActiveSheet.Protect Contents:=True ActiveSheet.EnableSelection = xlUnlockedCells Else ActiveSheet.Unprotect Cells.Select Selection.Locked = True ActiveSheet.Protect Exit Sub For some reason it doesn't select anything, though it did on thr very first run. Any ideas. Jan |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
VBA code to select rows | Excel Discussion (Misc queries) | |||
select Range Code | Excel Programming | |||
How do I select this range using code? | Excel Programming | |||
Code to Select Row | Excel Programming |