Professional Documents
Culture Documents
'
' TableFormat Macro
' Macro recorded 04/10/2006 by minh
'
Selection.SelectRow
Selection.ParagraphFormat.Alignment = wdAlignParagraphCenter
Selection.Tables(1).Select
End Sub
Sub XaoTronDe()
'
' XaoTronDe Macro
' Macro recorded 10/10/2006 by minh
'
Dim C As Cell
Dim cnt As Integer
Dim Col As Column
Selection.Tables(1).Select
Selection.InsertColumnsRight
Set Col = Selection.Columns(1)
cnt = Selection.Cells.Count
For i = 1 To cnt
Set C = Col.Cells(i)
C.Range.ParagraphFormat.Style = "Body Text"
C.Range.Text = 1000 * Rnd()
Next
Selection.Tables(1).Select
Selection.Sort ExcludeHeader:=False, FieldNumber:="Column 2", _
SortFieldType:=wdSortFieldNumeric, SortOrder:=wdSortOrderAscending, _
FieldNumber2:="", SortFieldType2:=wdSortFieldAlphanumeric, SortOrder2:= _
wdSortOrderAscending, FieldNumber3:="", SortFieldType3:= _
wdSortFieldAlphanumeric, SortOrder3:=wdSortOrderAscending, Separator:= _
wdSortSeparateByCommas, SortColumn:=False, CaseSensitive:=False, _
LanguageID:=wdEnglishUS, SubFieldNumber:="Paragraphs",
SubFieldNumber2:= _
"Paragraphs", SubFieldNumber3:="Paragraphs"
Col.Delete
Selection.Tables(1).Select
DinhDang
End Sub
Sub DinhDang()
'
' DinDang Macro
' Macro recorded 10/10/2006 by minh
'
With Selection.ParagraphFormat
.LeftIndent = CentimetersToPoints(0)
.RightIndent = CentimetersToPoints(0)
.SpaceBefore = 0
.SpaceBeforeAuto = False
.SpaceAfter = 0
.SpaceAfterAuto = False
.LineSpacingRule = wdLineSpaceSingle
.Alignment = wdAlignParagraphLeft
.WidowControl = True
.KeepWithNext = False
.KeepTogether = False
.PageBreakBefore = False
.NoLineNumber = False
.Hyphenation = True
.FirstLineIndent = CentimetersToPoints(0)
.OutlineLevel = wdOutlineLevelBodyText
.CharacterUnitLeftIndent = 0
.CharacterUnitRightIndent = 0
.CharacterUnitFirstLineIndent = 0
.LineUnitBefore = 0
.LineUnitAfter = 0
End With
Selection.Rows.HeightRule = wdRowHeightAuto
Selection.Rows.Height = CentimetersToPoints(0)
End Sub