Pourquoi tu parles de getelementbyid dans le dernier fichier j'ai gardé le code que tu m'a donné il n'y aucun getelementByid !
Sub Lire_Recettes()
Dim URL$, obj As New DataObject
Dim img As Object
Dim ws As Worksheet, Cel As Range
Dim A() As Variant
Dim nomRe As String, nbRe As Byte, numRe As Byte
Dim nomRcet As String, nbRcet As String, Temp As String
On Error Resume Next
Application.ScreenUpdating = False
'Vide - Feuilles Dessert
For Each ws In ThisWorkbook.Worksheets
If ws.Name Like "Dessert*" Then _
ws.[A1].CurrentRegion.Offset(1).ClearContents
Next ws
'Boucle - Liste des noms
With F04
.Activate
Cells.Delete
nbRcet = Val(Right(F03.Cells(F03.[A500].End(xlUp).Row, 1), 2))
For Each Cel In F03.Range("C3:C" & F03.[C500].End(xlUp).Row)
If CBool(Cel.Hyperlinks.Count) Then
nomRe = Cel: nomRcet = Cel.Offset(, -2):
numRe = Val(Cel.Offset(, -1)): nbRe = Val(Cel.Offset(, 3))
URL = Cel.Hyperlinks(1).Address
Application.StatusBar = "Extraction : " & nomRcet & " de " & nbRcet & " - Cheval " & numRe & " de " & nbRe
Cells.Delete
'''''''''''''''''''''''''''''''''''''''''''''''''''' TON CODE EST BIEN LA ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
With CreateObject("MSXML2.XMLHTTP")
.Open "GET", URL, False
.Send
'If .Status = 200 Then
For i = 1 To UBound(Split(.responseText, "<body"))
txt = "<body" & Split(Split(.responseText, "<body")(i), "</body>")(0) & "</body>"
'txt = Replace(txt, "colspan=""15""", "")
'txt = Replace(txt, "<p>", "<tr><td>")
'txt = Replace(txt, "</p>", "</td></tr>")
obj.SetText txt
obj.PutInClipboard
F04.Cells.Clear
With F04.Outline
.AutomaticStyles = False
.SummaryRow = xlAbove
.SummaryColumn = xlLeft
.IndentLevel = 0
End With
F04.Paste
'debut = 3
'For j = debut To F04.Cells(Rows.Count, 1).End(xlUp).Row + 1
'If F04.Cells(j, 1) = "" Then F04.Rows(debut & ":" & j - 1).Rows.Group: Exit For
'If F04.Cells(j, 2) <> "" Then F04.Rows(debut & ":" & j - 1).Rows.Group: debut = j + 1
'Next
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Worksheets("Temp").Activate
Cells.Select
For Each img In ActiveSheet.Pictures
img.Delete
Next img
For Each img In ActiveSheet.Shapes
img.Delete
Next
Cells.Select
'''''''''''''''
'''''''''''''''
'supprime toute les lignes sans [+-]
For j = ActiveSheet.UsedRange.Rows.Count To 1 Step -1
If Not Cells(j, 15) Like "*[+-]*" Then Rows(j).Delete
Next
'supprime les hyperliens
Cells.Select
With Selection
.Hyperlinks.Delete
End With
'supprime ligne 1
Rows("1").Delete
'supprime le retour à la ligne
Range("A1:A").Select
With Selection
.HorizontalAlignment = xlGeneral
.VerticalAlignment = xlBottom
.WrapText = False
.Orientation = 0
.AddIndent = False
.IndentLevel = 0
.ShrinkToFit = False
.ReadingOrder = xlContext
.MergeCells = False
End With
'Columns("F").Delete
Columns("B").Insert
Columns("P").Delete
Columns("A:R").AutoFit
Range("B1:B" & [A500].End(xlUp).Row) = nomRe
'Copie données vers feuille Dessert x
Lig = Sheets(nomRcet).[A65000].End(xlUp).Row + 1
[A1].Resize([A500].End(xlUp).Row, 15).Copy Sheets(nomRcet).Cells(Lig, "A")
Cells.Delete
End If
Next Cel
Application.StatusBar = ""
End With
F04.Select
End Sub