通过 C# 将 EAP 复制到 EABase.eap

Copy EAP to EABase.eap through c#

我有一个自定义 EAP 文件,我想将其用于创建更多 EAP。 在继续之前,我想将此自定义 EAP 模板复制到任何其他新 EAP。 我正在使用 createModel: 将 BaseEap 复制到目标 EAP。

repository.CreateModel(CreateModelType.cmEAPFromBase, "path EAP currently opened",-1);

如何将我的自定义模板 EAP 复制到基本 EAP?? 是否有使用 C# 将 EAP 复制到 EAP 的直接方法?

您可以使用下面的代码项目转移来实现它

Repository.GetProjectInterface().ProjectTransfer(EAPFilesourcepath,EAPFiletargetpath,EAPFilelogpath);

使用它您可以将您的模板 EAP 转移到您的新 EAP 并进一步工作

Data Transfer may Fail due to one of the following reasons

  1. the Source File does not exist

  2. the Target File already exists

  3. the Target File is not an EAP File, only EAP files are supported in Automation Interface