2011-12-14 7 views
0

XLからいくつかのスライドを作成しようとしていますが、脚注に挑戦しています。 私は脚注セクションに複数の脚注を記入しますが、各行は上付き数字で始まります。どのように私はそれを行うことができます誰も教えてくれる?XLからPPTで上書きする

私はオンラインで見つけた解決策をいくつか試しましたが、1文字を上書きすることはできません。あなたの助けのための

おかげで始める必要があり、このような

答えて

0

何か。コードはPPTで実行されるように書かれており、Excelではw /から実行するためのいくつかの改訂が必要になります:

Dim oSl As Slide 
Dim oSh As Shape 
Dim oPres As Presentation 
Dim x As Long 

' for example purposes, we'll do this IN PPT 
' and use the current presentation 
Set oPres = ActivePresentation 

' and we'll work with slide 1 
Set oSl = oPres.Slides(1) 

' rather than using PPT's own footnotes, I'd simply 
' add my own text box ... 
Set oSh = oSl.Shapes.AddTextbox(msoTextOrientationHorizontal, 10, 500, 500, 50) 

' and work with it ... 
With oSh 
    ' add your text: 
    .TextFrame.TextRange = "1One line of text" & vbCrLf _ 
     & "2Two lines of text, the second a bit longer" & vbCrLf _ 
     & "3New we are three lines of text" 

    ' subscript the first character of each line up to 9 
    On Error Resume Next ' in case there are fewer lines 
    For x = 1 To 9 
     .TextFrame.TextRange.Paragraphs(x).Characters(1, 1).Font.Superscript = True 
    Next 
    ' and the first two characters of each line past that 
    For x = 10 To .TextFrame.TextRange.Paragraphs.Count 
     .TextFrame.TextRange.Paragraphs(x).Characters(1, 2).Font.Superscript = True 
    Next 
End With 
+0

ありがとう、ありがとう。 「休日の杭」が処理されるとすぐにそれをテストします:D – seba

関連する問題