Probleme

'Option Explicit

Sub export()

Dim a(), i&, n&, j&, k As Byte, C As Byte

'Ddim a(1 To .Cells(Rows.Count, End(xlUp).Row)

With ThisWorkbook.Sheets("BOM")

a = .Range(.[a8], .Range("ZZ" & .Cells.Find("*", , , , xlByRows, xlPrevious).Row)).Value

End With

With ThisWorkbook.Sheets("PDS021 Composants")

.Range(.[a4], .Range("E" & .Cells.Find("*", , , , xlByRows, xlPrevious).Row)).Offset(1).Clear

For i = LBound(a) To UBound(a, 1)

For k = 2 To .End(xlUp).Row

C = 0

If a(i, 63) <> "" Then

If a(k, 8) <> "/" Then

n = n + 1

.[C4].Offset(n).Value = a(i, 4)

.[D4].Offset(n).Value = a(i, 5)

.[E4].Offset(n).Value = a(k, 8)

.[F4].Offset(n).Value = a(i, 63)

'If a(i, 17) <> "" Then

' n = n + 1

' .[B4].Offset(n).Value = a(i, 8)

' .[C4].Offset(n).Value = a(i, 17)

'.[D4].Offset(n).Value = a(i, 18)

'.[F4].Offset(n).Value = a(i, 19)

'End If

' If a(i, 21) <> "" Then

' n = n + 1

' .[B4].Offset(n).Value = a(i, 8)

' .[C4].Offset(n).Value = a(i, 21)

' .[D4].Offset(n).Value = a(i, 22)

'.[F4].Offset(n).Value = a(i, 23)

End If

End If

Next k

Next i

.Range(.[B4], .Range("E" & .Cells.Find("*", , , , xlByRows, xlPrevious).Row)).Offset(1).Sort .[B5], xlAscending

End With

End Sub

j'essaie d'arreter le copiage de cette ligne avec à la dernière ligne du tableau.[E4].Offset(n).Value = a(k, 8)

salutations

option non explicit

if VIE = true then

msgbox "42"

end if

je viens de regarder ton sujet, vu que tu as pas mis de questions ça me fait plaisir de te répondre

salutations

ECG

Rechercher des sujets similaires à "probleme"