Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Replace the VBA code with the Qm code error
#5
The following VBA code can run successfully, but the QM code is still error

Sub FormatFirstParagraph()
Dim aRange As Range
Set aRange = ActiveDocument.Range(Start:=ActiveDocument.Paragraphs(2).Range.Start, End:=ActiveDocument.Paragraphs(4).Range.End)
With aRange
.Bold = True
.ParagraphFormat.Alignment = wdAlignParagraphCenter
With .Font
.Name = "Stencil"
.Size = 15
End With
End With
End Sub


Macro Macro1
Trigger SF9     Help - how to add the trigger to the macro
Code:
Copy      Help
;/exe 1
out

typelib Word {00020905-0000-0000-C000-000000000046} 8.0
Word.Application app._getactive ;;connect to Word. Note: need the /exe 1.
Word.Document doc=app.ActiveDocument
;doc.ActiveWindow.Panes(1).Selection.Cut
Word.Range ran=doc.Range(Start=doc.Paragraphs(2).Item.Range.Start, End:=doc.Paragraphs.Item(4).Range.End)
ran.Bold="True"
ran.Font.Size=15
ran.Font.Name="Stencil"


;BEGIN PROJECT
;main_function  Macro1
;exe_file  $my qm$\Macro1.qmm
;flags  6
;guid  {EB126AB4-AFF9-4818-9E31-A62869FFF810}
;END PROJECT


Attached Files Image(s)
   


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)