How to create embedded Hyperlinked Text?

  • Hi,

    Trying to link various parts of our available content using embedded Hyperlink but do not know Jack on where to start on this topic !

    I am using the following:

    - WPTOOLS ver 4.?? VCL component (TDBWPRichText)

    - Borland C++ Builder 6

    I like the way MS Word 2003 allows any object to contain an embedded hyperlink and the "Sample Word Processor" example in WPTOOLS ver 5.0 Demo, provides something similar to what I need.

    Is this possible under WPTOOLS ver 4.0?

  • Due to funding shortage my development team was unable to move to WPTools 5.0 , and since I took your replay as a 'Not Possible' I had to shelf the Hyperlink masking for past two years.

    However to my Surprise I managed to get the Hyperlink masked and working as I suspected it would. No Thanks for being a source of a Major Miss-Direction. :-x

    Yet another request after two years, please provide the C++ source code for 'WordProcessor.exe' and any suggestion on how to embbed objects (files) in the RichText.

    • Offizieller Beitrag

    lmco,

    Zitat

    However to my Surprise I managed to get the Hyperlink masked and working as I suspected it would. No Thanks for being a source of a Major Miss-Direction. :-x


    Don't quite understand. Did I misdirect You? As I read my mail it clearly says that a hyperlink consists of 2 parts. I did NOT say "not possible".

    Regards,
    Julian

    • Offizieller Beitrag

    lmco,

    about editing the "stamp" of a hyperlink in the demo exe:

    Internally ModifyThisHyperlinkStamp is called which works when the cursor is on the hyperlink itself (the text marked with afsHyperlink).

    It is also possible to call:

    Code
    function TWPCustomRichText.ModifyHyperlinkStamp(const NewStamp: string): Boolean;
    begin
      Result := afsHyperlink in CPAttr^.Style;
      if Result then
      begin
        FHyperPar := nil;
        ModifyThisHyperlinkStamp(NewStamp);
      end;
      Changed;
    end;

    Julian

    • Offizieller Beitrag

    Your private mail:

    Zitat

    The following call

    RatDBREdit1->InputHyperlink(text, stamp);
    AnsiString text = "Wptools"
    AnsiString stamp = "wpcubed.com"

    printed out Wptools as a hyperlink without any stamp? so the link did not fire. I believe it is a step in the right direction however when I tried to modify

    RatDBREdit1->ModifyThisHyperlink(text, stamp);

    it adds a trailing hyper link "Wptools" but still no stamp

    I am pretty sure it works. Id it does not please check the property ProtectedProp if certain text is protected.

    InputHyperlink should simply create

    text with afsHyprlink attribute and
    stamp with afsHidden text.

    This is because of the old HC help compiler uses this syntax. (afsHyperlink is encoded as double underline in RTF)

    in WPTools 5 we use hyperlink objects.

    <a>text</a>

    PS.: Please don't use private mail for support questions.