Skip to content

Instantly share code, notes, and snippets.

@yosiopp
Created October 19, 2012 01:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yosiopp/3915820 to your computer and use it in GitHub Desktop.
Save yosiopp/3915820 to your computer and use it in GitHub Desktop.
ドロップされたEXCELファイルを処理するvbsの雛形
Option Explicit
Dim args
Dim fileName
Set args = WScript.Arguments
For Each fileName in args
Call proc(fileName)
Next
Sub proc(fileName)
On Error Resume Next
Dim excel
Set excel = CreateObject("Excel.Application")
'excel.Visible = True
excel.Workbooks.Open(fileName)
''
'' Any Code
''
excel.DisplayAlerts = False
excel.Quit
Set excel = Nothing
On Error Goto 0
End Sub
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment