我们可以捕获富文本框文本并将其保存到图像吗? [英] Can we capture a rich text box text and save to an image?
问题描述
大家好,
我只想知道这是否可行.我有一个包含所有格式文本的富文本框.我想将该富文本框的内容另存为硬盘上的图像.
这背后的原因是我使用的是Crystal报表,并且在我传递时,Crystal报表没有采用格式化的文本.因此,我想将该文本保存在临时图像文件中,然后将其传递给Crystal报表,以便可以正确加载.所以我觉得,如果我将其保存为图像,然后将其传递给Crystal Report,它可能会起作用.
有任何想法吗?还是可以?
Hello All,
I just want to know if this is possible or not. I have a rich text box with all formatted text in it. I want to save the content of that rich text box as an image on my hard disk.
The reason behind this is I work with crystal reports and Crystal reports are not taking formatted text when i am passing it. So I want to save that text in a temp image file and pass that to crystal report so that it can load properly. So I felt, if I save it as an image and then pass it to crystal report, it might work.
Any Ideas? or IS IT POSSIBLE?
推荐答案
可以吗?
也许这会有所帮助,而不是在vb中,但我认为您可以遵循以下代码:
http://stackoverflow.com/Questions/5296359/how-to-render-rich-edit-text-to-a-canvas-by-keeping-font-smoothness [
IS IT POSSIBLE?
Perhaps this will help, not in vb but I assume you can follow the code:
http://stackoverflow.com/questions/5296359/how-to-render-richedit-text-to-a-canvas-by-keeping-font-smoothness[^]
Best regards
Espen Harlinn
这篇关于我们可以捕获富文本框文本并将其保存到图像吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!