vbs入口参数处理

Set objArgs = WScript.Arguments


If  objArgs.Count <= 0 or objargs.Count > 1 Then
  WScript.Quit
End If

Select Case objArgs(0)

   Case "1" :
    Monday()
   Case "2" :
    Tuesday()
   Case "3" :
    Wednesday()
   Case "4" :
    Thursday()
   Case "5" :
    Friday()
   Case "6" :
    Saturday()
   Case "7" :
    Sunday()
End Select    

Monday() Monday()
  WScript.Echo "周一"
End Function    

Tuesday() Tuesday()
  WScript.Echo "周二"
End Function    

Wednesday() Wednesday()
  WScript.Echo "周三"
End Function    

Thursday() Thursday()
  WScript.Echo "周四"
End Function    

Friday() Friday()
  WScript.Echo "周五"
End Function    

Saturday() Saturday()
  WScript.Echo "周六"
End Function    

Sunday() Sunday()
  WScript.Echo "周日"
End Function

你可能感兴趣的:(脚本,职场,休闲)