[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

Printing contents of RichEdit

Posted on 2000-03-04
3
Medium Priority
?
279 Views
Last Modified: 2013-11-22
Hi Experts,


In my application I have a Form with a PageControl on it.
At runtime I create the TabSheets for the Pagecontrol.
On each TabSheet I put (also at runtime of course) a RichEdit.

Now my question:
  I also have a button on the Form which has to print the contents
  of the RichEdit of the CURRENTLY SELECTED tabsheet.
  How can I do this ?


Thanx in advance,

The Mayor.
0
Comment
Question by:wimmeyvaert
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 17

Accepted Solution

by:
inthe earned 200 total points
ID: 2583399
hi,

you can do like below:
Regards Barry


procedure TForm1.Button1Click(Sender: TObject);
var
  i : integer;
begin
with pagecontrol1.ActivePage do begin
  for i := Controlcount -1 downto 0 do
    begin
      if( Controls[ i ] is TRichedit )then
      begin
        (Controls[ i ] as TRichedit).Print('');
      end;
  end;
 end;
  end;
0
 
LVL 6

Author Comment

by:wimmeyvaert
ID: 2591319
Hi Barry,

Thanks for your answer !

Shortly before you posted your answer, I had found a solution myself, but I have to admit yours is better than mine.

Therefor, I'll accept your answer and give you the points.

Thanx again,

The Mayor.

By the way, do you know the existance of a dbgrid-freeware component (with source) which has more functionality than the one that comes with Delphi (automatically sorting columns, ...) ?
0
 
LVL 17

Expert Comment

by:inthe
ID: 2592403
hi,
i dont use dbgrids much ,i do use a free one but i use it for the memo feild as it has some properties i need.
i would sugest try
www.torry.ru etc that would be best place to start looking(or ask a questio here for 25 or so points asking if anyone knows of one..
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…
Suggested Courses

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question