返回列表 上一主題 發帖

[分享] (已解決)感謝版主如何利用Excel VBA開啟讀入文字檔後,指定名稱跳下一行取得資料

回復 1# cmo140497
If mystr Like test & "*" Then Print #2, mystr   改為    If InStr(mystr, test) = 0 Then Print #2, mystr

TOP

回復 3# cmo140497
  1. Do While Not EOF(1)
  2.        Input #1, mystr
  3.        If mystr Like test & "*" Then
  4.             Input #1, mystr   '讀取下一行
  5.             Print #2, mystr
  6.        End If
  7.     Loop
複製代碼

TOP

        靜思自在 : 地上種了菜,就不易長草;心中有善,就不易生惡。
返回列表 上一主題