Run Script file from Matlab

조회 수: 2 (최근 30일)
Brian
Brian 2012년 3월 16일
I've got a few scripts that I'm currently running in VBA to push files to an FTP site. That said, I am no longer doing any of the work in Excel, so running the VBA code to launch the scrips is a pain. My VBA code is essentially replicating a batch file using a Shell command. I'm wondering if I can utilize similar functionality using Matlab. An example of my VB code would be.
Shell(ftp -n -s:"\\lbprds0262\vol3\Eqprod\FactorModel\BB_BMK_SHS_ftp.scr")
Thanks a lot

채택된 답변

Jacob Halbrooks
Jacob Halbrooks 2012년 3월 16일
Try using MATLAB's FTP function.
doc ftp
  댓글 수: 2
Brian
Brian 2012년 3월 28일
Wow, that was so easy I'm almost embarassed that I had to ask. Thanks for the answer.
The only question that I have is that when I use the close command the ftp object still looks like it's open as a variable. Am I doing something wrong?
Jacob Halbrooks
Jacob Halbrooks 2012년 3월 29일
It is expected that the variable will remain after executing close. If you want the variable gone, use clear after you've used close.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Introduction to Installation and Licensing에 대해 자세히 알아보기

태그

제품

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by