Private Sub Command2_Click()
Dim thisDoc As Document
Dim thisRange As Range
WordApp.Documents.Open (App.Path & "\test2.doc")
  WordApp.Visible = False
  Set thisDoc = WordApp.ActiveDocument
  Set thisRange = thisDoc.Range
  Text1.Text = thisRange.Text
  WordApp.Quit
  Set WordApp = Nothing
End Sub
請問一下,假設test2.doc其中有個欄位叫做姓名,是以
姓名:peter 性別:xxxxx 的方法表示
請問該如何做,才能取到peter(即所指定欄位內的資料,而其它的不要),多謝.......
arrow
arrow
    全站熱搜

    vbqa 發表在 痞客邦 留言(8) 人氣()