Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

help converting WordBasic.FormatMultilevel 1

Status
Not open for further replies.

planetxsolutions

Programmer
Nov 6, 2009
2
CA
hi there,

i have a piece of wordbasic that i need to convert to vba! any clues that you can provide would be most appreciated!

here is the code following the selection. i'm particularily stumped as to what the last WordBasic.FormatMultilevel line in the if statement does?

' Set up a multi-leveling numbering system using the start number
' and prefix string (article number) for first level (left
' justified) clauses only

' ** Level 1 uses numbers x.x
WordBasic.FormatMultilevel Points:="Auto", Color:=0, Before:=sArticleNumber$, Type:=0, After:="", StartAt:=sTagNumberInteger$, Include:=0, Alignment:=0, Indent:="0.5" + Chr(34), Space:="0" + Chr(34), Hang:=1, Level:="1", Font:="", StrikeThrough:=-1, Bold:=-1, Italic:=-1, Underline:=-1

' ** Level 2 uses letters (a)
WordBasic.FormatMultilevel Points:="Auto", Color:=0, Before:="(", Type:=4, After:=")", StartAt:=sStart_Letter$, Include:=0, Alignment:=0, Indent:="0.5" + Chr(34), Space:="0" + Chr(34), Hang:=1, Level:="2", Font:="", StrikeThrough:=-1, Bold:=-1, Italic:=-1, Underline:=-1

' ** Level 3 uses Roman numerals (i)
WordBasic.FormatMultilevel Points:="Auto", Color:=0, Before:="(", Type:=2, After:=")", StartAt:="1", Include:=0, Alignment:=0, Indent:="0.5" + Chr(34), Space:="0" + Chr(34), Hang:=1, Level:="3", Font:="", StrikeThrough:=-1, Bold:=-1, Italic:=-1, Underline:=-1

' Level 4 uses capital letters
WordBasic.FormatMultilevel Points:="Auto", Color:=0, Before:="", Type:=3, After:=".", StartAt:="1", Include:=0, Alignment:=0, Indent:="0.5" + Chr(34), Space:="0" + Chr(34), Hang:=1, Level:="4", Font:="", StrikeThrough:=-1, Bold:=-1, Italic:=-1, Underline:=-1

WordBasic.FormatMultilevel Points:="Auto", Color:=0, Before:="(", Type:=0, After:=")", StartAt:="1", Include:=0, Alignment:=0, Indent:="0.5" + Chr(34), Space:="0" + Chr(34), Hang:=1, Level:="5", Font:="", StrikeThrough:=-1, Bold:=-1, Italic:=-1, Underline:=-1
WordBasic.FormatMultilevel Points:="Auto", Color:=0, Before:="(", Type:=4, After:=")", StartAt:="1", Include:=0, Alignment:=0, Indent:="0.5" + Chr(34), Space:="0" + Chr(34), Hang:=1, Level:="6", Font:="", StrikeThrough:=-1, Bold:=-1, Italic:=-1, Underline:=-1
WordBasic.FormatMultilevel Points:="Auto", Color:=0, Before:="(", Type:=2, After:=")", StartAt:="1", Include:=0, Alignment:=0, Indent:="0.5" + Chr(34), Space:="0" + Chr(34), Hang:=1, Level:="7", Font:="", StrikeThrough:=-1, Bold:=-1, Italic:=-1, Underline:=-1
WordBasic.FormatMultilevel Points:="Auto", Color:=0, Before:="(", Type:=4, After:=")", StartAt:="1", Include:=0, Alignment:=0, Indent:="0.5" + Chr(34), Space:="0" + Chr(34), Hang:=1, Level:="8", Font:="", StrikeThrough:=-1, Bold:=-1, Italic:=-1, Underline:=-1
WordBasic.FormatMultilevel Points:="Auto", Color:=0, Before:="(", Type:=2, After:=")", StartAt:="1", Include:=0, Alignment:=0, Indent:="0.5" + Chr(34), Space:="0" + Chr(34), Hang:=1, Level:="9", Font:="", StrikeThrough:=-1, Bold:=-1, Italic:=-1, Underline:=-1

' Display the level numbers only if there is some selected text
' and the text is not the line that contains <section_?> tag
If InStr(Selection.Text, sSectionStartTag$) = 0 Then
WordBasic.FormatMultilevel
End If
 
Hi planetxsolutions (charlie garrett-jones),

I see you've posted the same question at:
microsoft.public.word.vba.general
where it has already been answered.

Please see:

Cheers
[MS MVP - Word]
 
Hi planetxsolutions,

Perhaps there's a fault in whatever process you're using to view your posts/threads at microsoft.public.word.vba.general.
Even so, you can find copies on other servers, such as:
A web search for 'WordBasic.FormatMultilevel' will turn up plenty of other servers with the same question and answer too.



Cheers
[MS MVP - Word]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top