Hi,
be precise, because
>I´m trying to paste two cells (text) from Excel to Word.
you are trying to paste 2 Excel-Ranges, not cells.
Furthermore, if you collapse the range,
it stays collapsed, and you apply your formatting
to a range of length 0.
How about this one, with improvements possible, I think:
Sub TW()
Dim AppWD As Word.Application
Dim DocWD As Word.Document
Dim RangeWD As Word.Range
Set AppWD = CreateObject("Word.Application.10")
AppWD.Visible = True
Set DocWD = AppWD.Documents.Add
With DocWD
Set RangeWD = .Range
Sheets("T").Select
Range("A1:D1").Select
Selection.Copy
With RangeWD
.Font.Name = "Arial"
.Font.Size = 12
.Font.Bold = False
.PasteAndFormat Type:=wdFormatPlainText
.InsertAfter vbCr
.Start = .End + 1
.Collapse wdCollapseEnd
MsgBox Len(RangeWD.Text) ' for testing
Sheets("T").Select
Range("A2:A6").Select
Selection.Copy
.End = DocWD.Content.End ' extent the range
.Font.Bold = True
.PasteAndFormat Type:=wdFormatPlainText
End With
End With
End Sub
Greetings from Bavaria, Germany
Helmut Weber, MVP
"red.sys" & chr(64) & "t-online.de"
Word XP, Win 98
http://word.mvps.org/
TT - 29 Jan 2005 18:35 GMT
Thanks a lot Helmut! Seems to work fine.
This is all new stuff to me. Thanks for helping me out here.
TT
> Hi,
> be precise, because
[quoted text clipped - 47 lines]
> Word XP, Win 98
> http://word.mvps.org/