NSIS实现ArcEngine Runtime安装和自动注册

Section "ArcEngineSection" SEC03
 SetOutPath "$INSTDIR\EngineRuntime"
 File /r "EngineWindows\*.*"
 nsExec::ExecToLog "$INSTDIR\EngineRumtime\setup.exe";
 Pop $0
 StrCmp $0 "success" +1 +2
 DetailPrint '安装ArcEngine Runtime失败'
 DetailPrint '成功安装ArcEngine Runtime'
 nsExec::ExecToLog "'c:\Program Files\ArcGIS\bin\SoftwareAuthorization.exe' -p Engine -lif '$INSTDIR\EngineRumtime\Engine93.ecp' -s";
 Pop $0
 StrCmp $0 "success" +1 +2
 DetailPrint '安装ArcEngine Runtime Licence注册成功'
 Delete "$INSTDIR\EngineRumtime\*.*"
 Delete "$INSTDIR\EngineRumtime\Documentation\*.*"
 RMDir /r "$INSTDIR\EngineRuntime"
SectionEnd

其中注册LICENCE的部分为

nsExec::ExecToLog “‘c:\Program Files\ArcGIS\bin\SoftwareAuthorization.exe’ -p Engine -lif ‘$INSTDIR\EngineRumtime\Engine93.ecp’ -s”
THE END
喜欢就支持一下吧
点赞5 分享
评论 抢沙发

请登录后发表评论

    暂无评论内容