1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
|
' tableau
'"Tests using table"
T_val = False
If le_style = "Titre 4" Then
pos = InStr(le_texte, "Tests using table")
If pos > 0 Then T_val = True
p_tab = i_para + 2
is_tab = M_objdoc.Paragraphs(p_tab).Range.Tables.Count
End If
If T_val = True And is_tab > 0 Then
titre_tab = test_nu & "_" & n_page & ".xls"
titre_tab = Replace(titre_tab, " ", "")
fich = ThisWorkbook.Path & "\" & titre_tab
n_l = M_objdoc.Paragraphs(p_tab).Range.Tables(is_tab).Rows.Count
n_c = M_objdoc.Paragraphs(p_tab).Range.Tables(is_tab).Columns.Count
le_Dossier.Cells(Position, 7) = fich
ReDim T_test(1 To n_l, 1 To n_c)
M_objdoc.Tables(is_tab).Range.Copy
Workbooks.Add
ActiveSheet.Cells(1, 1).PasteSpecial
ActiveWorkbook.SaveAs Filename:=fich
ActiveWorkbook.Close
End If |
Partager