| 123456789101112131415161718192021 |
- include("scripts/EAction.js");
- include("scripts/simple.js");
- function CsvToZdmConvert(filename) {
- this.filename = filename || "";
- }
- CsvToZdmConvert.includeBasePath = includeBasePath;
- CsvToZdmConvert.prototype.getZdmFileName = function () {
- return this.filename.replace(/.\w+$/i, ".zdm");
- }
- CsvToZdmConvert.prototype.convert = function () {
- var process = new QProcess;
- EAction.handleUserMessage(CsvToZdmConvert.includeBasePath + "/csv2zdm.exe");
- process.setProgram(CsvToZdmConvert.includeBasePath + "/csv2zdm.exe");
- var args = [];
- args.push(this.filename);
- process.setArguments(args);
- process.start();
- process.waitForStarted(); //等待程序启动
- process.waitForFinished(-1);//等待程序关闭
- }
|