AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Thema durchsuchen
Ansicht
Themen-Optionen

memo ausdrucken

Ein Thema von MAarkus_R19 · begonnen am 21. Apr 2003 · letzter Beitrag vom 21. Apr 2003
Antwort Antwort
MAarkus_R19

Registriert seit: 7. Apr 2003
2 Beiträge
 
#1

memo ausdrucken

  Alt 21. Apr 2003, 15:15
hi wie kann ich ein einfaches memofeld ausdrucken
aus den delphi büchern werd ich ned schlau
thx
  Mit Zitat antworten Zitat
Haegar

Registriert seit: 10. Dez 2002
Ort: Peitz
319 Beiträge
 
Delphi 7 Professional
 
#2
  Alt 21. Apr 2003, 15:47
kennst du schon so die grundlegenden druckbefehle??
oder noch gar nix in der richtung?

gruss haegar
  Mit Zitat antworten Zitat
Benutzerbild von APP
APP

Registriert seit: 24. Feb 2003
Ort: Graz (A)
705 Beiträge
 
Delphi 7 Enterprise
 
#3
  Alt 21. Apr 2003, 17:22
Hallo,

Zitat:
Q: How can I print all of the lines within a TMemo or TListbox component?

A: The function below accepts a TStrings object as a parameter and prints
out each string to the default printer. Because it uses a TStrings, the
function will work with any type of component that contains a
TStrings-type property, such as a TDBMemo or TOutline.
Delphi-Quellcode:
{ Begin code listing }

uses Printers;

procedure PrintStrings(Strings: TStrings);
var
  Prn: TextFile;
  i: word;
begin
  AssignPrn(Prn);
  try
    Rewrite(Prn);
    try
      for i := 0 to Strings.Count - 1 do
        writeln(Prn, Strings.Strings[i]);
    finally
      CloseFile(Prn);
    end;
  except
    on EInOutError do
      MessageDlg('Error Printing text.', mtError, [mbOk], 0);
  end;
end;

{ End code listing }
Zitat:
To print out the contents of a TMemo or TListbox, use the following
code:
Delphi-Quellcode:
PrintStrings(Memo1.Lines);

or

PrintStrings(Listbox1.Items);
gefunden auf codecentral.borland.com
Armin P. Pressler

BEGIN
...real programmers are using C/C++ - smart developers Delphi;
END;
  Mit Zitat antworten Zitat
Antwort Antwort


Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 20:34 Uhr.
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz