Voici la macro:
Cordialement,
--
AP
'----------------------------------
Sub transpose()
Dim rHeureVoyage As Range
Dim rTrace As Range
Worksheets("Test").Activate 'Make it active sheet
For Each rHeureVoyage In Range( _
Cells(4, "C"), _
Cells(Rows.Count, "C").End(xlUp))
For Each rTrace In Range( _
rHeureVoyage.Offset(0, 1), _
rHeureVoyage.Offset(0, 1).End(xlToRight))
If rTrace.Value = 1 Then
Set rdest = Worksheets("Horaires").Cells( _
3, _
rTrace.Column - 2)
Do While rdest.Value < ""
Set rdest = rdest.Offset(1, 0)
Loop
rdest.Value = rHeureVoyage.Value
End If
Next rTrace
Next rHeureVoyage
End Sub
'---------------------------------------
"bambinos83" a
écrit dans le message de
...
I modified the sheet "Horaires" in the foloowing worksheet with an
example of what I'd like to have.
+-------------------------------------------------------------------+
|Filename: ex.zip |
|Download: http://www.excelforum.com/attachment.php?postid=4476 |
+-------------------------------------------------------------------+
--
bambinos83
------------------------------------------------------------------------
bambinos83's Profile:
http://www.excelforum.com/member.php...o&userid=32589
View this thread: http://www.excelforum.com/showthread...hreadid=523875