Codesys 3. 如何从ST 中的静态或动态文本文件中获取翻译? [英] Codesys 3. How to get the translations from static or dinamic text file in ST?

查看:36
本文介绍了Codesys 3. 如何从ST 中的静态或动态文本文件中获取翻译?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 Twincat 3 (4024.10) 并尝试了函数GetTextByStringId";和GetText"来自库 SysLibTargetVisu 但编译器已经给了我一个错误:

I am using Twincat 3 (4024.10) and I tried the functions "GetTextByStringId" and "GetText" from the library SysLibTargetVisu but the compiler already gives me an error:

错误未解决的引用:'GETTEXTBYSTRINGID' 0

Error Unresolved reference: 'GETTEXTBYSTRINGID' 0

似乎在 Codesys 2 中有效:https://forge.codesys.com/forge/talk/CODESYS-V2/thread/8f2fc2e158/

It seems that in Codesys 2 works: https://forge.codesys.com/forge/talk/CODESYS-V2/thread/8f2fc2e158/

提前致谢!

推荐答案

我记得我也在这上面浪费了时间.不幸的是,它似乎是一个旧的未记录和未维护的库.

I remember wasting my time on that too. Unfortunately it seems to be an old undocumented and unmantained library.

我在几个小时内解决了这个问题,我用 Java 编写了一个 xml 阅读器,它从文本列表中读取 ID 和文本,并将它们通过广告推送到存储在内存中的 plc.然后可以根据需要使用这些值.

I resolved the issue in a couple of hours by writing an xml reader in Java that reads the ids and the texts from the textlist and pushes them over ads to the plc where they are stored in memory. The values can then be used as needed.

这种方法的另一个优点是您无需购买 plc hmi 许可证.

The other advantage from this approach is that you do not dipend on the plc hmi license.

这篇关于Codesys 3. 如何从ST 中的静态或动态文本文件中获取翻译?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆