Sub new_xlwb()
'
' Création d'un classeur Excel dans la présentation avec une propriété .Name
'
ActiveWindow.Selection.SlideRange.Shapes.AddOLEObject(Left:=120, Top:=110, Width:=480, Height:=320, ClassName:="Excel.Sheet.8", Link:=msoFalse).Select
ActiveWindow.Selection.ShapeRange.OLEFormat.Activate
With ActiveWindow.Selection.ShapeRange
.Name = "[COLOR="Red"]Toto[/COLOR]"
.Left = 120.25
.Top = 135
.Width = 480
.Height = 319
End With
End Sub
Static Sub Seek(Vin, Vout As String)
'Déclaration des variables
Dim xlApp As Variant 'Application Excel
Dim xlWbd As Variant 'Classeur Excel
Dim xlWsh As Variant 'Feuille Excel
Dim xlRan As Variant 'Range Excel
' 'Ouverture de l'application
Set xlApp = CreateObject("Excel.Application")
' 'Ouverture d'un fichier Excel
Set xlWbd = ActivePresentation.Slides(44).Shapes("[COLOR="Red"]Toto[/COLOR]").OLEFormat
' Main mise sur la feuille 1
Set xlWsh = xlWbd.Object.Worksheets(1)
' Main mise sur l'adressage de la feuille
Set xlRan = xlWsh.Range("Table")
Excel.Application.Quit
End Sub