1. Daniel Vivier
  2. PowerBuilder
  3. Wednesday, 26 May 2021 17:29 PM UTC

I'm thinking about replacing our mail-merge functionality in our application, currently built using a WebBrowser control put into DesignMode for editing, with a RichTextEdit (the built-in TX TextControl type).

For this to work, it would have to be able to load our existing HTML templates from the user's files, and replicate their appearance fairly exactly, and be able to save them to RTF that also replicates the appearance fairly exactly. (According to the Help, there are some issues with images if you save back to HTML, which is why I say we would save back to RTF.)

However, in the Help for the InsertDocument function, it says that there is "No support for formatted tables". We use tables a fair bit in our HTML template layouts.

If I load an HTML file into the RTE, it looks reasonably OK:

But if I print it, I get absolute garbage - either an entirely blank page, if saved to PDF with the Microsoft Print to PDF driver, or just some weird lines and an occasional random letter, if printed to my printer.

Any thoughts? Just give up on this idea immediately? Thanks.

mike S Accepted Answer Pending Moderation
  1. Thursday, 27 May 2021 13:53 PM UTC
  2. PowerBuilder
  3. # 1

there are 2 versions of the built it one.  15 and 28.  I would think 28 would work better than 15.

i have no idea, but maybe the professional one would work best for you, as it is not stripped down   they do have a free trial.

 

Comment
  1. Daniel Vivier
  2. Thursday, 27 May 2021 14:01 PM UTC
That must be in PB2019 R3 or something. We're still on the original PB2019. Can try again when we upgrade sometime this summer.
  1. Helpful
There are no comments made yet.
mike S Accepted Answer Pending Moderation
  1. Wednesday, 26 May 2021 20:12 PM UTC
  2. PowerBuilder
  3. # 2

which built in tx control?  2019R3 has 3 options

Comment
  1. Miguel Leeuwe
  2. Wednesday, 26 May 2021 23:12 PM UTC
Going to be quiet. You the advice I gave you, you're still on time to NOT use the RTE.

:)
  1. Helpful
  1. Miguel Leeuwe
  2. Wednesday, 26 May 2021 23:13 PM UTC
you the advice = you know the advice.

The rte > html is crap.
  1. Helpful
  1. Daniel Vivier
  2. Wednesday, 26 May 2021 23:24 PM UTC
Mike, I'm sorry, I was sure I posted a reply about which control I was using, but it has disappeared. My initial testing was unintentionally done with the "Built in Rich Edit Control" but what I intended to use was the "Built in Rich Text Control" - which is the Appeon-bundled version of TX Text Control.

When I tested with that it was a lot better, but there were still significant problems with tables, margins, and images entirely disappearing when saved or Printed.

So yes, I'm coming to the same conclusion Miguel is saying: for my use case at least, it's not usable. How unfortunate.

Thanks, folks.
  1. Helpful
There are no comments made yet.
Daniel Vivier Accepted Answer Pending Moderation
  1. Wednesday, 26 May 2021 17:46 PM UTC
  2. PowerBuilder
  3. # 3

Setting rte_1.PaperWidth to a reasonable setting for 8" seems to help quite a bit, but the formatting is still off a fair amount, and the images that were in the HTML file disappear in the saved RTF file. And after that a save to PDF changes to just be 5 blank pages!

Comment
  1. Miguel Leeuwe
  2. Saturday, 29 May 2021 10:12 AM UTC
The 28.0 has a reported bug: When you paste copied images (using right mouse button and "paste") and then export the contents to html using SaveDocument(), it can generate an html with a link to a non existing image file, depending on what program you used to copy the image from.

With the 15.0 version, there's other problems, like one image being linked to a temporary file and an image copied and pasted from a different program being embedded in binary. (you can check using a file copied from paint.exe or using the "snipping" tool of windows).

https://www.appeon.com/standardsupport/track/view?id=5954

Then there's other problems like ctrl+Z Undo not working correctly. It's just such a slow never ending process of trying to get a 100% correctly working rich text edit control that personally I've given up after 3 years.

We do still use it, as it's going to cost me quite a bit adapting all of our code and I'm not in a hurry as I would like the new webbrowser control to become a bit more mature first.

regards
  1. Helpful
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.
We use cookies which are necessary for the proper functioning of our websites. We also use cookies to analyze our traffic, improve your experience and provide social media features. If you continue to use this site, you consent to our use of cookies.