Here's a macro to clean it all up for you:
Sub foo()
Dim stInput As String, stOutput() As String
Dim lRow As Long, lCol As Long
Application.ScreenUpdating = False
With Sheet1
.Cells.UnMerge
stOutput = Split("0rigin,Intrastat,Quantity,Unit,Unit price,Net price,Total price,VAT Code", ",")
For lCol = LBound(stOutput) To UBound(stOutput)
With .Cells(2, 3 + lCol)
.Clear
.Value = stOutput(lCol)
End With
Next lCol
Erase stOutput
For lRow = 3 To .Cells(Rows.Count, 1).End(xlUp).Row
For lCol = 3 To 9
stInput = Trim(stInput & " " & Replace(.Cells(lRow, lCol).Value, "*", ""))
Next lCol
.Cells(lRow, 3).Resize(1, 8).Clear
stOutput = Split(stInput, " ")
For lCol = LBound(stOutput) To UBound(stOutput)
With .Cells(lRow, lCol + 3)
.Value = stOutput(lCol)
.Value = .Value
End With
Next lCol
stInput = ""
Erase stOutput
Next lRow
End With
Application.ScreenUpdating = True
End Sub
Bookmarks