请选择 进入手机版 | 继续访问电脑版
 找回密码
 立即注册

QQ登录

只需一步,快速开始

haibo.liu

注册会员

3

主题

5

帖子

20

积分

注册会员

积分
20
最新发帖
haibo.liu
注册会员   /  发表于:2020-3-9 14:57  /   查看:2393  /  回复:2
1金币
设置License如下写法:
public static boolean setLicense() throws Exception{
    File classPath = (new File(OcrUtil.class.getProtectionDomain().getCodeSource().getLocation().getPath())).getParentFile();
    String classPathDecode = URLDecoder.decode(classPath.getAbsolutePath(), "UTF-8");

    String var0 = classPathDecode + "\\classes\\keys\\LEADTOOLS.LIC";
    String var1 = classPathDecode + "\\classes\\keys\\LEADTOOLS.LIC.KEY";

    try {
        RasterSupport.setLicense(var0, var1);
    } catch (Exception var3) {
        System.out.println(var3.getMessage());
        return false;
    }

    return !RasterSupport.getKernelExpired();
}

但是License文件是我们买的,到期时间到2035年。
为什么运行的时候出Invalid runtime license 的错误呢?
我们是V19版本的

2 个回复

正序浏览
Richard.Ma讲师达人认证 悬赏达人认证 SpreadJS 开发认证
超级版主   /  发表于:2020-3-9 16:01:50
沙发
好的
回复 使用道具 举报
haibo.liu
注册会员   /  发表于:2020-3-9 15:32:11
楼主
已经解决了。关闭了
回复 使用道具 举报
您需要登录后才可以回帖 登录 | 立即注册
返回顶部