ruby script VBA.
Shell, :
Public Sub RunRuby(file As String, ParamArray args())
Shell "ruby.exe """ & file & """ " & Join(args, " ")
End Sub
Shell, :
Public Sub RunRuby(file As String, ParamArray args())
Shell "rubyw.exe """ & file & """ " & Join(args, " ")
End Function
WScript.Shell, :
Public Function RunRuby(file As String, ParamArray args()) As Long
Dim obj As Object
Set obj = CreateObject("WScript.Shell")
RunRuby = obj.Run("rubyw.exe """ & file & """ " & Join(args, " "), 0, True)
End Function
, :
ChDir "C:\Folder1"
or with the folder of the current book:
ChDir ThisWorkbook.Path
source
share