bonjour à toutes et tous
j'ai plusieurs macro et cetaines après execution reste hord tableau
ex si j'ai un tableau qui me tient pile la taille de mon ecran et que dans la macro j'ai un copie- colle hord tableau ,meme en fin de code si je rajoute
Sheets("feuil1").Select
Range("A1").Select
le curseur est bien en A1 mais sur l'ecran je reste au dernier collage
une macro en exemple
Dim c As Range
If MsgBox("Confirmez vous le lancement de la macro ?", vbOKCancel) = vbCancel Then _
MsgBox "macro annulé !!!": Exit Sub
Range("T31:EX31").Select
Selection.Copy
Range("T32").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.ScreenUpdating = False
With Sheets("source")
.Visible = True
.Unprotect Password:=cedra
lig_nom = .Columns("A").Find([b2].Value, LookIn:=xlValues, lookat:=xlWhole).Row
If lig_nom > 0 Then Range("t32:ez32").Copy .Range("t" & lig_nom & ":ez" & lig_nom)
.Protect Password:=cedra
.Visible = False
End With
Sheets("saisie").Select
Range("A4").Select
merci
phil69
j'ai plusieurs macro et cetaines après execution reste hord tableau
ex si j'ai un tableau qui me tient pile la taille de mon ecran et que dans la macro j'ai un copie- colle hord tableau ,meme en fin de code si je rajoute
Sheets("feuil1").Select
Range("A1").Select
le curseur est bien en A1 mais sur l'ecran je reste au dernier collage
une macro en exemple
Dim c As Range
If MsgBox("Confirmez vous le lancement de la macro ?", vbOKCancel) = vbCancel Then _
MsgBox "macro annulé !!!": Exit Sub
Range("T31:EX31").Select
Selection.Copy
Range("T32").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.ScreenUpdating = False
With Sheets("source")
.Visible = True
.Unprotect Password:=cedra
lig_nom = .Columns("A").Find([b2].Value, LookIn:=xlValues, lookat:=xlWhole).Row
If lig_nom > 0 Then Range("t32:ez32").Copy .Range("t" & lig_nom & ":ez" & lig_nom)
.Protect Password:=cedra
.Visible = False
End With
Sheets("saisie").Select
Range("A4").Select
merci
phil69