- ©«¤l
- 91
- ¥DÃD
- 5
- ºëµØ
- 0
- ¿n¤À
- 130
- ÂI¦W
- 0
- §@·~¨t²Î
- Win10
- ³nÅ骩¥»
- Office 2010
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2016-5-14
- ³Ì«áµn¿ý
- 2020-5-17
|
³o°õ¦æ¤§«á²Ä¤@ÓÀɮ׿é¥Xµ²ªG¨S°ÝÃD¡A¦ý²Ä¤GÓÀɮ׿é¥Xµ²ªG³£·|¬O²Ä¤@ÓÀɮתº¥D¦®ªº¤º®e
·Q½Ð±Ð¤@¤U¦U¦ì¤j¤j¡A¬Oþ¸Ì¿ù»~?n¦p¦ó×¥¿³oÓ?- Public Sub ´ú¸Õ4()
- On Error Resume Next 'GoTo 999
- TheFilename = Application.GetOpenFilename("WordÀÉ (*.docx), *.docx", , "½Ð¿ï¾ÜWordÀÉ", , True) '¥i¿ï¨ú¦hÓWordÀÉ
- Arr1 = Array("¤é´Á¡G", "ÀÉ®×½s¸¹¡G", "¥D¦®¡G") 'n´M§ä¦r¦ê
- Set wrdApp = CreateObject("Word.Application")
- If UBound(TheFilename) > 0 Then
- For i0 = 1 To UBound(TheFilename)
- Set wrdDoc = wrdApp.Documents.Open(TheFilename(i0))
- Debug.Print TheFilename(i0)
- For i = 0 To 2
- Set myRange = wrdDoc.Content
- §ä¨ì = myRange.Find.Execute(Arr1(i))
- Debug.Print §ä¨ì
- §ä¨ì¦C = myRange.Paragraphs(1)
- Debug.Print §ä¨ì¦C
- If IsEmpty(§ä¨ì¦C) Then
- MsgBox "§äµL!"
- Exit Sub
- Else
- myStr = Split(§ä¨ì¦C, "¡G")
- myStr2 = myStr(UBound(myStr))
- Debug.Print myStr2 '¿é¥Xnªº¦r¦ê
- Debug.Print "-------" '¤À¹j½u
- End If
- Next
- 999:
- wrdDoc.Close 'close the document
- wrdApp.Quit 'close Word
- Next
- End If
- End Sub
½Æ»s¥N½X |
|