使用QAxWidget嵌入excel窗口后怎么保存数据?

#include "QtWidgetsApplication3.h"

QtWidgetsApplication3::QtWidgetsApplication3(QWidget *parent)
    : QMainWindow(parent)
{
    ui.setupUi(this);

    _excelview = NULL;

    connect(ui.btOpen, SIGNAL(clicked()), this, SLOT(openOffice()));
    connect(ui.btClose, SIGNAL(clicked()), this, SLOT(closeOffice()));
}
    
QtWidgetsApplication3::~QtWidgetsApplication3()
{}

void QtWidgetsApplication3::OpenExcel(QString& fileName)
{

    //实例化一个操作Excel的控件
    _excelview = new QAxWidget("Excel.Application",ui.axWidget);
    _excelview->dynamicCall("SetVisible (bool Visible)", "false");
    
    _excelview->setProperty("DisplayAlerts", true);
    auto rect = ui.axWidget->geometry();
    _excelview->setGeometry(rect);
    _excelview->dynamicCall("Open (const QString&)",fileName);
    _excelview->setControl(fileName);
    _excelview->show();
}
void QtWidgetsApplication3::closeOffice()
{
    if (this->_excelview)
    {
        _excelview->dynamicCall("Save()");
        _excelview->dynamicCall("Close(Boolean)", true);
        _excelview->dynamicCall("Quit()");
        delete _excelview;
        _excelview = NULL;
    }
}


void QtWidgetsApplication3::openOffice()

{

    QFileDialog _dialog;

    _dialog.setFileMode(QFileDialog::ExistingFile);

    _dialog.setViewMode(QFileDialog::Detail);

    _dialog.setOption(QFileDialog::ReadOnly, true);

    _dialog.setDirectory(QString("./"));

    _dialog.setNameFilter(QString("所有文件(*.*);;word(*.docx *.doc);;excel(*.xlsx);;ppt(*.pptx *.ppt)"));

    if (_dialog.exec())
    {
        QStringList files = _dialog.selectedFiles();
        for (auto fileName : files)
        {

            if (fileName.endsWith(".xlsx"))
            {
                this->OpenExcel(fileName);
            }
        }
    }
}

怎么把在窗口的操作保存道xlsx文件中

使用Qaxobject的 dynamicCall函数,
Qaxobject->dynamicCall("SaveAs(const QString&)", QDir::toNativeSeparators(filepaths));