Presumo che tu abbia già una soluzione per Martina (che sarà sicuramente migliore della mia, ammesso che riesca a trovarla
Moderatori: Anthony47, Flash30005
If ActiveSheet.Name = "Master" then
msgbox "Attenzione questo foglio non deve essere cancellato"
exit sub
endifSub copiafogli()
Dim NF As Long, I As Long, Result As String
'
Result = "DatabaseCompleto" '<<< Il foglio dove si creera' il riepilogo
'
NF = ThisWorkbook.Sheets.Count
'
Application.ScreenUpdating = False
Sheets(Result).Select
Sheets(Result).UsedRange.Clear
For I = 1 To NF
If Sheets(I).Name <> Result Then
Sheets(I).Range("a1:iv4").Copy Sheets(Result).Cells(5000, 2).End(xlUp).Offset(1, -1)
Call ReCond(I, Result)
Application.CutCopyMode = False
End If
Next
Application.ScreenUpdating = True
End Sub
Sub ReCond(ByVal SSNum As Long, ByVal DSName As String)
Dim cfArea As Range, CelL As Range
On Error Resume Next
Set cfArea = Sheets(DSName).Range("A1").SpecialCells(xlCellTypeAllFormatConditions) '.Select
On Error GoTo 0
If cfArea Is Nothing Then Exit Sub
For Each CelL In cfArea
CelL.FormatConditions.Delete
If CelL.Value > Sheets(SSNum).Range("A5").Value Then
With CelL.Font
.Color = -16383844
.TintAndShade = 0
End With
With CelL.Interior
.PatternColorIndex = xlAutomatic
.Color = 13551615
.TintAndShade = 0
End With
End If
Next CelL
'
End SubTorna a Applicazioni Office Windows
| copia celle adiacenti da tre fogli Autore: Gianca532011 |
Forum: Applicazioni Office Windows Risposte: 10 |
| confrontare e evidenziare 2 fogli excel Autore: niccia |
Forum: Applicazioni Office Windows Risposte: 7 |
Visitano il forum: Nessuno e 18 ospiti