Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7903207
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T09:41:25+00:00 2026-06-03T09:41:25+00:00

Using delphi 7 TRichEdit component, RTF data is being imported from a msword document

  • 0

Using delphi 7 TRichEdit component, RTF data is being imported from a msword document through copy and paste, but if data is contained in a box, it is not displaying correctly i.e.

enter image description here

Please assist

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T09:41:27+00:00Added an answer on June 3, 2026 at 9:41 am

    Try to use the following, it should subclass the TRichEdit class to version 4.1. However I don’t know if Delphi 7 supports interposed classes, so just try to paste the following code and try to build the project.
    If it compiles then if you put a TRichEdit component and run the project you should get RichEdit 4.1.

    unit Unit1;
    
    interface
    
    uses
      Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
      Dialogs, StdCtrls, ComCtrls, RichEdit;
    
    type
      TRichEdit = class(ComCtrls.TRichEdit)
      protected
        procedure CreateParams(var Params: TCreateParams); override;
      end;
    
    type
      TForm1 = class(TForm)
      private
        { Private declarations }
      public
        { Public declarations }
      end;
    
    var
      Form1: TForm1;
      FRichEditModule: THandle;
    
    implementation
    
    {$R *.dfm}
    
    { TRichEdit }
    
    procedure TRichEdit.CreateParams(var Params: TCreateParams);
    const
      RichEditClassName = 'RICHEDIT50A';
      RichEditModuleName = 'MSFTEDIT.DLL';
      HideScrollBarsStyle: array[Boolean] of DWORD = (ES_DISABLENOSCROLL, 0);
      HideSelectionsStyle: array[Boolean] of DWORD = (ES_NOHIDESEL, 0);
    begin
      if FRichEditModule = 0 then
      begin
        FRichEditModule := LoadLibrary(RichEditModuleName);
        if FRichEditModule <= HINSTANCE_ERROR then
          FRichEditModule := 0;
      end;
      inherited CreateParams(Params);    
      CreateSubClass(Params, RichEditClassName);
      Params.Style := Params.Style or HideScrollBarsStyle[HideScrollBars] or
        HideSelectionsStyle[HideSelection];
      Params.WindowClass.style := Params.WindowClass.style and
        not (CS_HREDRAW or CS_VREDRAW);
    end;
    
    initialization
    
    finalization
      if FRichEditModule <> 0 then
        FreeLibrary(FRichEditModule);
    
    end.
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

If I am using Delphi at design time, then when I copy/paste a group
I am using Delphi and trying to read from a bar code scanner over
Using Delphi 7, I wonder if there is a free component which will collect
I am using Delphi 7 but I have trialed the Delphi 2005 - 2010
I'm using Delphi 2010 and I'm wondering if there's a way to trace through
Using Delphi XE. When trying to access a Delphi interface object from a DLL,
I'm using TNMHTTP in Delphi to retrieve the code from a webpage. The code
I am using Delphi TApplication.OnException Event to catch unhandled exceptions This works well but
I am using Delphi 2010, latest version (from repository) of JEDI WinAPI and Windows
Using Delphi 7 I am reading from a serial port. The read is always

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.