Call/Execute/Run VBA Macro within Google sheets from/using Matlab
7 次查看(过去 30 天)
显示 更早的评论
Hello everyone,
I am after solving a global optimization problem (using matlab script, and matlab solvers) where I do have parameters (and an internal macro VBA script) that lives and resides in google sheet (*.gs file). My problem is:
- I would like to define my matlab parameters
- Push/write them online to google sheet
- Run internal google sheet macro (VBA, *.gs script) using matlab commands,
- After google sheet macro finishes its calculations, read specific cell in matlab
- And optimize those parameters in matlab by keeping track of cost function, constraints, ...etc, and repeat the process.
I cannnot import google sheet to a local Excel copy because (since google sheet uses *.gs script) it does not import it. So saving a local *xls copy does not work bby any means. My only chance is to read the whole VBA code,spend almost a 1 month to re-write it in matlab, then spend another couple of weeks to debug and retest it in Matlab, and I simply do not have neither time nor the effort to do it.
Simply put, my goal is, define parameters in matlab, write them to a google sheet online, initiate a coogle sheet RUN_MACRO command from matlab, let google sheet do its own internal calculations, read the result, create cost function, and rinse-repeat to optimize parameters, till objective is achieved.
I truly and sincerely appreciate any help in this regard,
Sincerely
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 MATLAB Report Generator 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!