1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
| If f2.Cells(id.Row, .Cells(1, j)).HasFormula = False Then
.Cells(i, j).Copy Destination:=f2.Cells(id.Row, .Cells(1, j))
f2.Cells(id.Row, .Cells(1, j)).AddComment vbCrLf & "Valeur : " & tmp & " source : " & f1.Name & Now & Chr(10) & tmp_comment
Else
reponse = MsgBox("Cellule " & id & " Colonne " & f2.Cells(id.Row, .Cells(1, j)).Colonne & " " & "a une formule!! " & "voulez vous continuer ?", vbYesNo + vbCritical)
If reponse = vbYes Then
If f2.Cells(id.Row, .Cells(1, j)).HasFormula = False Then
.Cells(i, j).Copy Destination:=f2.Cells(id.Row, .Cells(1, j))
f2.Cells(id.Row, .Cells(1, j)).AddComment vbCrLf & "Valeur : " & tmp & " source : " & f1.Name & Now & Chr(10) & tmp_comment
End If
Else
Exit Sub
End If
End If |
Partager