Boa noite!!
Veja se te ajuda.
Cole o código dentro do Editor VB,  use Alt + F11 para entrar no Editor, depois olhe do lado esquerdo, vi ver Plan1, Plan2, Plan3 (se a planilha que contém os dados for a Plan1, click nela se não escolha a planilha que tem dados), dê dois clicks e cole o código.
Private Sub Workbook_SheetSelectionChange(ByVal Sh As Object, ByVal Target As Range)
Dim rFormulaCheck As Range
    
    On Error Resume Next
    Sh.Unprotect Password:="Secret"
        With Selection
                .Locked = False
                .FormulaHidden = False
        End With
        
    If Target.Cells.Count = 1 Then
        If Target.HasFormula Then
            With Target
                .Locked = True
                .FormulaHidden = True
            End With
    
            Sh.Protect Password:="Secret", UserInterFaceOnly:=True
        End If
    ElseIf Target.Cells.Count > 1 Then
        Set rFormulaCheck = Selection.SpecialCells(xlCellTypeFormulas)
            If Not rFormulaCheck Is Nothing Then
                With Selection.SpecialCells(xlCellTypeFormulas)
                    .Locked = True
                    .FormulaHidden = True
                End With
                Sh.Protect Password:="Secret", UserInterFaceOnly:=True
            End If
    End If
    On Error GoTo 0
End Sub
                                                                                                	Existem mil maneiras de preparar Neston. Invente a sua!
http://www.youtube.com/ExpressoExcel
 
                    
                    	
                            Postado : 29/03/2012 8:16 pm