D
DAMIEN
Guest
bonsoir à tous
Sub navcom()
Windows("message.xls").Activate
Dim xlig, xlig1, xlig2, xlig3, xlig4 As Byte
xlig1 = Range("a225").End(xlUp).Row + 1
xlig2 = Range("a225").End(xlUp).Row + 2
xlig3 = Range("a225").End(xlUp).Row + 3
xlig4 = Range("a225").End(xlUp).Row + 4
xlig = ActiveCell.Row
Cells(xlig1, 1).Select
ActiveCell.FormulaR1C1 = Format("MISSION/" + Cells(xlig, 2) + "//")
Cells(xlig2, 1).Select
ActiveCell.FormulaR1C1 = Format("MERCH/" + Cells(xlig, 7) + "/" + Cells(xlig, 9) + "/" + Cells(xlig, 10) + "/" + Cells(xlig, 8) + "//")
Cells(xlig3, 1).Select
ActiveCell.FormulaR1C1 = Format("TMPOS/" + Cells(xlig, 1) + "/" + Cells(xlig, 3) + "/" + Cells(xlig, 4) + "/" + Cells(xlig, 11) + "/" + Cells(xlig, 10) + "//")
Cells(xlig4, 1).Select
ActiveCell.FormulaR1C1 = Format("AMPN/" + Cells(xlig, 13) + "/" + Cells(xlig, 14) + "/" + "te : " + Cells(xlig, 17) + "/" + "pob : " + Cells(xlig, 18) + "//")
Windows("REGISTRE DES MOUVEMENTS.xls").Activate
End Sub
je voudrai que xlig corresponde à la ligne active du registre des mouvements.xls et non du fichier message.xls, MAIS LES CELLULES DU REGISTE SOIENT COPIER DANS MESSAGE
merci
ET 1000 EXCUSES POUR LE DOUBLE POSTE
damien
Sub navcom()
Windows("message.xls").Activate
Dim xlig, xlig1, xlig2, xlig3, xlig4 As Byte
xlig1 = Range("a225").End(xlUp).Row + 1
xlig2 = Range("a225").End(xlUp).Row + 2
xlig3 = Range("a225").End(xlUp).Row + 3
xlig4 = Range("a225").End(xlUp).Row + 4
xlig = ActiveCell.Row
Cells(xlig1, 1).Select
ActiveCell.FormulaR1C1 = Format("MISSION/" + Cells(xlig, 2) + "//")
Cells(xlig2, 1).Select
ActiveCell.FormulaR1C1 = Format("MERCH/" + Cells(xlig, 7) + "/" + Cells(xlig, 9) + "/" + Cells(xlig, 10) + "/" + Cells(xlig, 8) + "//")
Cells(xlig3, 1).Select
ActiveCell.FormulaR1C1 = Format("TMPOS/" + Cells(xlig, 1) + "/" + Cells(xlig, 3) + "/" + Cells(xlig, 4) + "/" + Cells(xlig, 11) + "/" + Cells(xlig, 10) + "//")
Cells(xlig4, 1).Select
ActiveCell.FormulaR1C1 = Format("AMPN/" + Cells(xlig, 13) + "/" + Cells(xlig, 14) + "/" + "te : " + Cells(xlig, 17) + "/" + "pob : " + Cells(xlig, 18) + "//")
Windows("REGISTRE DES MOUVEMENTS.xls").Activate
End Sub
je voudrai que xlig corresponde à la ligne active du registre des mouvements.xls et non du fichier message.xls, MAIS LES CELLULES DU REGISTE SOIENT COPIER DANS MESSAGE
merci
ET 1000 EXCUSES POUR LE DOUBLE POSTE
damien