Private Sub Command1_Click()
Set appwd = CreateObject("Word.Application")
appwd.Visible = True
appwd.Documents.Open "c:\others.doc"
appwd.selection.typetext Text1.Text
appwd.ActiveDocument.SaveAs "c:\others.doc"
appwd.ActiveDocument.Close
appwd.Quit
Set appwd = Nothing
End Sub
Private Sub Form_Load()
Text1.Text = Text1.Text & "line1" & vbCrLf
Text1.Text = Text1.Text & "line2" & vbCrLf
Text1.Text = Text1.Text & "line3" & vbCrLf
Text1.Text = Text1.Text & "line4" & vbCrLf
Text1.Text = Text1.Text & "line5" & vbCrLf
Text1.Text = Text1.Text & "line6" & vbCrLf
Text1.Text = Text1.Text & "line7" & vbCrLf
End Sub