问题描述
我只是想知道如何将数据库中上载的文档中的文本和富文本字段转换为html字段.
i just wanted to know how can i convert text and rich text fields in a document uploaded in a database to html fields.
推荐答案
知道我在某处看到过它:
Knew I'd seen it somewhere:
该技巧的核心是将内容另存为MIMEParts.
The core of the trick is to save the content as MIMEParts.
该示例代码已有5年历史,并且是为R6设计的,但是Notes具有相当好的向后兼容性.我也有个人经验,从MIME到RichText的另一种选择很简单,因此您应该可以.
The sample code is 5 years old and was designed for R6 but Notes has pretty good backwards compatibility. I've also had personal experience that going the other way from MIME to RichText is straightforward so you should be ok.
对于普通文本字段,您可能需要将其内容复制到RTF文本字段,或使用上述链接中的功能来呈现整个文档.
For the normal text fields you may want to copy their content to a rich text field or use the feature from the above link that allows you to render entire documents.
这篇关于如何使用LotusScript将文档中的文本和富文本字段转换为html?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!