От нех
(рен) делать решил заморочаться и сделать для народа в отделе небольшой макросик: снизу текста добавляется табличка с невидимыми границами с текстом и полями для заполнения.
Трабла: почему-то в части таблицы кегль шрифта 12, а в другой - 11
Как сие выправить?
Код:
Sub однакомазафако()
'
' однакомазафако Макрос
'
'
Selection.Font.Size = 12
ActiveDocument.Tables.Add Range:=Selection.Range, NumRows:=1, NumColumns:= _
2, DefaultTableBehavior:=wdWord9TableBehavior, AutoFitBehavior:= _
wdAutoFitFixed
Selection.Font.Size = 12
With Selection.Tables(1)
If .Style <> "Сетка таблицы" Then
.Style = "Сетка таблицы"
End If
.ApplyStyleHeadingRows = True
.ApplyStyleLastRow = False
.ApplyStyleFirstColumn = True
.ApplyStyleLastColumn = False
.ApplyStyleRowBands = True
.ApplyStyleColumnBands = False
End With
Selection.Font.Size = 12
With Selection.Tables(1)
.Borders(wdBorderLeft).LineStyle = wdLineStyleNone
.Borders(wdBorderRight).LineStyle = wdLineStyleNone
.Borders(wdBorderTop).LineStyle = wdLineStyleNone
.Borders(wdBorderBottom).LineStyle = wdLineStyleNone
.Borders(wdBorderVertical).LineStyle = wdLineStyleNone
.Borders(wdBorderDiagonalDown).LineStyle = wdLineStyleNone
.Borders(wdBorderDiagonalUp).LineStyle = wdLineStyleNone
.Borders.Shadow = False
End With
With Options
.DefaultBorderLineStyle = wdLineStyleSingle
.DefaultBorderLineWidth = wdLineWidth050pt
.DefaultBorderColor = -587137025
End With
Selection.TypeText Text:="_______пись_________________"
Selection.TypeParagraph
Selection.TypeParagraph
Selection.TypeText Text:="_______пись___________________"
Selection.TypeParagraph
Selection.TypeParagraph
Selection.TypeText Text:=" Бабаков В.О."
Selection.TypeParagraph
Selection.InsertDateTime DateTimeFormat:="dd.MM.yyyy", InsertAsField:= _
False, DateLanguage:=wdRussian, CalendarType:=wdCalendarWestern, _
InsertAsFullWidth:=False
Selection.MoveRight Unit:=wdCharacter, Count:=1
Selection.MoveLeft Unit:=wdCharacter, Count:=1
Selection.MoveUp Unit:=wdLine, Count:=3, Extend:=wdExtend
Selection.MoveLeft Unit:=wdCharacter, Count:=2, Extend:=wdExtend
Selection.HomeKey Unit:=wdLine, Extend:=wdExtend
Selection.Font.Shrink
Selection.MoveRight Unit:=wdCell
Application.Keyboard (1033)
Application.Keyboard (1049)
Application.Keyboard (1033)
Application.Keyboard (1049)
Application.Keyboard (1033)
Application.Keyboard (1049)
Selection.Font.Size = 12
Selection.TypeText Text:="Направлено факсом ""____""_________200__г"
Selection.MoveDown Unit:=wdLine, Count:=0
Selection.MoveUp Unit:=wdLine, Count:=0
Selection.TypeParagraph
Selection.TypeText Text:="____ч. ____мин."
Selection.TypeParagraph
Selection.TypeText Text:="по телефону_______________"
Selection.TypeParagraph
Selection.TypeText Text:="принял(а):_____________________________"
Selection.TypeParagraph
Selection.TypeText Text:="отправил :_____________________________"
End Sub