R
reegon
Unregistered / Unconfirmed
GUEST, unregistred user!
我已经录制了VBA的宏代码,但不知如何才能正确地转化成delphi代码,请大家指教!
定位到第一页,我录制的宏如下:
Selection.GoTo What:=wdGoToPage, Which:=wdGoToNext, Name:="1";(转delphi代码???)
插入索引和目录,录制的宏如下:
With ActiveDocument
.TablesOfContents.Add Range:=Selection.Range, RightAlignPageNumbers:= _
True, UseHeadingStyles:=True, UpperHeadingLevel:=1, _
LowerHeadingLevel:=3, IncludePageNumbers:=True, AddedStyles:="", _
UseHyperlinks:=True, HidePageNumbersInWeb:=True
.TablesOfContents(1).TabLeader = wdTabLeaderDots
.TablesOfContents.Format = wdIndexIndent
End With
以上如何转成delphi代码,能正确地通过调试,达到运行的效果,请大家看看如何解决,谢谢!
定位到第一页,我录制的宏如下:
Selection.GoTo What:=wdGoToPage, Which:=wdGoToNext, Name:="1";(转delphi代码???)
插入索引和目录,录制的宏如下:
With ActiveDocument
.TablesOfContents.Add Range:=Selection.Range, RightAlignPageNumbers:= _
True, UseHeadingStyles:=True, UpperHeadingLevel:=1, _
LowerHeadingLevel:=3, IncludePageNumbers:=True, AddedStyles:="", _
UseHyperlinks:=True, HidePageNumbersInWeb:=True
.TablesOfContents(1).TabLeader = wdTabLeaderDots
.TablesOfContents.Format = wdIndexIndent
End With
以上如何转成delphi代码,能正确地通过调试,达到运行的效果,请大家看看如何解决,谢谢!