Beiträge von ehimmer

    Installed the 5.16 update, and initially it still appeared to be broken as described previously. However, only the table I had previously built was exhibiting the problem by not showing the color in the cell. If I redid the paragraph color in the cell, it works fine. So, this may have been fixed in a previous release since I had not tried to re-do the color of the cell.

    Thought you'd like to know.
    Eric

    Julian,

    I just installed WPTools 5.15, and the problem still exists. By the sound of your original reply, I think maybe you misunderstood my problem report.

    Everything seems to be fine, the toolbar does what it is supposed to do and sets the table cell color using the paragraph background color tool. It also correctly displays the selected color when positioning the text cursor within each cell.

    However, the background color does not reappear if the RTF is saved and then reloaded. Yet, the toolbar still shows the correct color that should be shown as the backroung color of the cell. Also, if I use WordPad to load the saved RTF, the cell color does show up.

    In other words, it seems that your RTF reader is not refreshing a table's paragraph backround color upon display of the table. (background paragraph color on non-table paragraphs reload fine).

    I hope I was clear this time.
    Eric

    Hmmm...

    I perform the following in the TextObjectPaint event, only because this is what seems to show the linked image.

    But once I do this, and then save the RichText again, the entire image is saved into the blob field instead of just the link. How can I show the linked image without causing this behaviour?

    Thanks.

    I changed the field type from memo to blob, and it is OK now. However, did you mean to have some of the linked image info in binary? Most other values you have are converted to a string.

    Also, it seems if I LoadObjFromFile at any point, and then save... it is no longer a link, but saves the image in its entirety. How do I display the image in the WPRichText yet still allow me to save only the link? I'm still trying to figure it out, but if you can tell me... please fill me in :)

    We use linked images, but I'm having a bit of trouble reloading the image when the WPRichText is reloaded.

    I was thinking that the OnTextObjectPaint was the replacement for OnTextObjectLoadStreamEvent, and sure enough it seems to be it, however, the image doesn't seem to honor the widthTW and heightTW that it was originally saved as.

    So perhaps TextObjectPaint is not the equivalent method to restore the link image.

    Note: I have another post in the WP5 support forum indicating a problem saving text having linked images to a database... seems the text has some binary values in it (even though it is only a link) that might be causing a problem with the .AsString assignment to the memo data, cutting off part of the link and anything that came after the link. So this test above is from reloading the WPRichText from a file which has the link and everything after it fully intact.

    Thanks,
    Eric

    If I set the paragraph background color of a table cell using the standard WPToolbar, it shows up fine. However, when I save and reload the text, the color is no longer visible. Note however that the correct color is still indicated in the toolbar but is not shown in the table cell. Also, if I save the rtf text to a file and load it using Wordpad, the colors show up fine. So I suspect WPTools's read routine is not setting the paragraph color on load.

    WPTools 5.13, Delphi 7

    Eric

    If I insert a linked image with WPTools 5.13 using:
    WPRichText_Cmt.InsertGraphicDialog( '*.bmp;*.jpg', true );

    it seems to insert fine. However, if I then save the text to a database and reload it, all the text after and including the linked image is deleted. I looked at the resulting RTF, and it appears that the save operation did not write out everything... in fact, it only partially wrote the image link.

    I am using Advantage Database, local server, and wrote the data using SQL as:

    SQL.Add( Format( 'UPDATE ReportComments' +
    ' SET Comment = :memoData' +
    ', CheckboxesChecked = ''%s''' +
    ' WHERE ReportID = ''%s''' +
    ' AND CommentID = ''%s''',
    [ cbCheckedList.Text,
    curReport.ReportID,
    curCommentID ] ) );
    end;
    ParamByName( 'memodata' ).DataType := ftMemo;
    ParamByName( 'memoData' ).AsMemo := WPRichText_Cmt.AsString;
    ExecSQL;

    The tail end of the RTF looked like this:
    \pard\plain\fs22\par
    1\par
    2\par
    3\par
    4\par
    5{\*\wptools\wpomode0\wpoframe0{\bin186

    Note however, that if I save it using WPRichText_Cmt.SaveToFile, the output is fine:
    1\par
    2\par
    3\par
    4\par
    5{\*\wptools\wpomode0\wpoframe0{\bin190
    TWPOImage TPF0 TWPOImage WidthTW$HeightTWlWriteRTFModewobBoth
    StreamNameXC:\Documents and Settings\All Users\Documents\My Pictures\Sample Pictures\Blue hills.jpgObjTag }}\par
    6\par
    7\par
    8\par
    9\par
    }}


    Almost as if WPRichText_Cmt.AsString is not working properly, or AsMemo is not appropriate, yet it so far has seemed to work... until now.

    Eric

    We get a lot of requests to have what they refer to as "picklists" embedded in the text of a WPRichText body. A "picklist" is like a dropdownlist, but is part of the text when editing or printing. For example, it could be represented as a word with certain attributes that tells the user that if you click on it, it will popup a list of selections to pick from. When you pick one, the embedded word or phrase changes to the selected word or phrase, and will print as if it was regular text (none of the visible attributes used to indicate "click me").

    What is the best way to create such a thing? I was thinking of using a custom WPTextObj in some way to do this. Does anyone have any insight on the best apprach to take? Or perhaps someone has implemented this already and could share :D

    Thanks,
    Eric

    In WpTools 5.13 under D7, when I add a horizontal line, specifying a specific width, it looks perfect. However, after saving to a database and reloading it, the line ignores the width and the line is drawn to the right margin.

    I can email you before/after images if you would like, but I think you get the idea. Basically my insert horz line routine creates a line the spans the paragraph indents.

    Here is the code I use to insert the line, based in part on your example.

    Any thoughts?
    Eric

    Just had a customer call with a problem viewing a PDF output with Acrobat 7.

    The error was "A Number is out of range"... yet if they click OK, it continues and seems to display fine.

    The same file viewed with Acrobat 6.0.3 has no problems.

    File was created with WPToosl 4 and wPDF 2.4.3

    Any idea?

    I'm probably doing somethign wrong, but I can't figure out how to make an image hyperlinkable. i.e. if I select a series of text that contains an image link (textObject), and then select the Hyperlink toolbar icon, the hyperlink attribute is assigned to the text, but it doesn't seem to assign it to the textObject. (Using WPTools V4)

    Maybe it did but I'm not looking at the right property, or maybe I have to manually add something to the object (like set the tag property).

    Ideas?

    Thanks,
    Eric

    What is the proper installation procedure for installing wPDF v2.5 with WPTools5? The documentation is misleading...

    The Install_wPDF.txt files says to enable the WPTOOLSPDF define in the wpdf_inc file, but when you edit that file, it says to enable the WPDFEX define in the WPINC.INC file instead, but it does not exist in the WPTools5 version that I can see. Enter confusion.

    With WPTools4, all we had to do was install wPDF into the same directory as WPTools4 and compile WPTools. But this does not seem to be the case with WPTools5.

    Sorry if this is documented somewhere, and I overlooked it.

    Eric

    The report has several fonts, and all are acting the same.

    Unfortunately, the MemoryFormat is already set to fmRichText.

    I'm going to check his printer driver tomorrow personally... after talking with the guy who helped him install it, I am not so confident as I was that it was done properly... we'll see.