Stimmen zur vorangegangenen Auflage: „Dieses Buch werde ich meinen Studenten empfehlen, weil es eine gute und übersicht...
285 downloads
2115 Views
7MB Size
Report
This content was uploaded by our users and we assume good faith they have the permission to share this book. If you own the copyright to this book and it is wrongfully on our website, we offer a simple DMCA procedure to remove your content from our site. Start by pressing the button below!
Report copyright / DMCA form
Stimmen zur vorangegangenen Auflage: „Dieses Buch werde ich meinen Studenten empfehlen, weil es eine gute und übersichtliche Einführung in Delphi bietet.“ C. Hoppa, Berufskolleg Niederberg
„Für den Einstieg in die Programmierung mit Delphi gut geeignet. Verständliche Darstellung, gute und nachvollziehbare Beispiele. /. . . / hervorragend – gut lesbar /. . . / Dieses Buch werde ich meinen Studenten empfehlen /. . . /“ Prof. Dr. K. Hardt, Hochschule Niederrhein
„Das Buch erfüllt von der Herangehensweise und der Darstellung genau die Anforderungen, mit denen Nichtinformatiker oder Anfänger einen guten Einstieg in die Problematik finden. Es ist übersichtlich und logisch aufgebaut. Die Beispiele sind gut gewählt, so dass ich eine Empfehlung an die Studenten ausspreche.“ Prof. Dr. Frank Jaeger, HTWK Leipzig
„/. . . / sehr guter systematischer Aufbau.“ Prof. Dr. Jörg Seeländer, FH Merseburg
„/. . . / endlich mal ein Einsteigerbuch für Delphi.“ Prof. Dr.-Ing. Christine Wahmkow, FH Stralsund
Aus dem Bereich IT erfolgreich lernen
Lexikon für IT-Berufe von Peter Fetzer und Bettina Schneider Grundkurs IT-Berufe von Andreas M. Böhm und Bettina Jungkunz Prüfungsvorbereitung für IT-Berufe von Manfred Wünsche Grundlegende Algorithmen von Volker Heun Grundkurs Visual Basic von Sabine Kämper Visual Basic für technische Anwendungen von Jürgen Radel Grundkurs Smalltalk – Objektorientierung von Anfang an von Johannes Brauer Grundkurs JAVA von Dietmar Abts Aufbaukurs JAVA von Dietmar Abts Grundkurs Java-Technologien von Erwin Merker Java ist eine Sprache von Ulrich Grude Middleware in Java von Steffen Heinzl und Markus Mathes Das Linux-Tutorial – Ihr Weg zum LPI-Zertifikat von Helmut Pils Rechnerarchitektur von Paul Herrmann Grundkurs Relationale Datenbanken von René Steiner Grundkurs Datenbankentwurf von Helmut Jarosch Datenbank-Engineering von Alfred Moos Grundlagen der Rechnerkommunikation von Bernd Schürmann Netze – Protokolle – Spezifikationen von Alfred Olbrich Grundkurs Verteilte Systeme von Günther Bengel Grundkurs Mobile Kommunikationssysteme von Martin Sauter Grundkurs Wirtschaftsinformatik von Dietmar Abts und Wilhelm Mülder Grundkurs Theoretische Informatik von Gottfried Vossen und Kurt-Ulrich Witt
www.vieweg-it.de
Anwendungsorientierte Wirtschaftsinformatik von Paul Alpar, Heinz Lothar Grob, Peter Weimann und Robert Winter Business Intelligence – Grundlagen und praktische Anwendungen von Hans-Georg Kemper, Walid Mehanna und Carsten Unger Grundkurs Geschäftsprozess-Management von Andreas Gadatsch Prozessmodellierung mit ARIS ® von Heinrich Seidlmeier ITIL kompakt und verständlich von Alfred Olbrich BWL kompakt und verständlich von Notger Carl, Rudolf Fiedler, William Jórasz und Manfred Kiesel Masterkurs IT-Controlling von Andreas Gadatsch und Elmar Mayer Masterkurs Computergrafik und Bildverarbeitung von Alfred Nischwitz und Peter Haberäcker Grundkurs Mediengestaltung von David Starmann Grundkurs Web-Programmierung von Günter Pomaska Web-Programmierung von Oral Avcı, Ralph Trittmann und Werner Mellis Grundkurs MySQL und PHP von Martin Pollakowski Grundkurs SAP R/3® von André Maassen und Markus Schoenen SAP ®-gestütztes Rechnungswesen von Andreas Gadatsch und Detlev Frick Kostenträgerrechnung mit SAP R/3® von Franz Klenger und Ellen Falk-Kalms Masterkurs Kostenstellenrechnung mit SAP® von Franz Klenger und Ellen Falk-Kalms Controlling mit SAP ® von Gunther Friedl, Christian Hilz und Burkhard Pedell Logistikprozesse mit SAP R/3® von Jochen Benz und Markus Höflinger IT-Projekte strukturiert realisieren von Ralph Brugger Algorithmen für Ingenieure – realisiert mit Visual Basic von Harald Nahrstedt Grundkurs Software-Entwicklung mit C++ von Dietrich May Grundkurs Programmieren mit Delphi von Wolf-Gert Matthäus
Wolf-Gert Matthäus
Grundkurs Programmieren mit Delphi Systematisch programmieren lernen mit interaktiv gestalteten Beispielen – Inklusive PascalProgrammierung, OOP, Grafikprogrammierung Mit 292 Abbildungen 2., überarbeitete und erweiterte Auflage
Bibliografische Information Der Deutschen Bibliothek Die Deutsche Bibliothek verzeichnet diese Publikation in der Deutschen Nationalbibliografie; detaillierte bibliografische Daten sind im Internet über abrufbar.
Die Wiedergabe von Gebrauchsnamen, Handelsnamen, Warenbezeichnungen usw. in diesem Werk berechtigt auch ohne besondere Kennzeichnung nicht zu der Annahme, dass solche Namen im Sinne von Warenzeichen- und Markenschutz-Gesetzgebung als frei zu betrachten wären und daher von jedermann benutzt werden dürfen. Höchste inhaltliche und technische Qualität unserer Produkte ist unser Ziel. Bei der Produktion und Auslieferung unserer Bücher wollen wir die Umwelt schonen: Dieses Buch ist auf säurefreiem und chlorfrei gebleichtem Papier gedruckt. Die Einschweißfolie besteht aus Polyäthylen und damit aus organischen Grundstoffen, die weder bei der Herstellung noch bei der Verbrennung Schadstoffe freisetzen.
1. Auflage Februar 2001 1. Auflage November 2001 3. verbesserte und erweiterte Auflage November 2003 1. Auflage 2004 2., überarbeitete und erweiterte Auflage Januar 2006 Alle Rechte vorbehalten © Friedr. Vieweg & Sohn Verlag /GWV Fachverlage GmbH, Wiesbaden 2006 Lektorat: Dr. Riccardo Mosena / Andrea Broßler Der Vieweg Verlag ist ein Unternehmen von Springer Science+Business Media. www.vieweg.de
Das Werk einschließlich aller seiner Teile ist urheberrechtlich geschützt. Jede Verwertung außerhalb der engen Grenzen des Urheberrechtsgesetzes ist ohne Zustimmung des Verlags unzulässig und strafbar. Das gilt insbesondere für Vervielfältigungen, Übersetzungen, Mikroverfilmungen und die Einspeicherung und Verarbeitung in elektronischen Systemen.
Umschlaggestaltung: Ulrike Weigel, www.CorporateDesignGroup.de Druck und buchbinderische Verarbeitung: MercedesDruck, Berlin Gedruckt auf säurefreiem und chlorfrei gebleichtem Papier. Printed in Germany ISBN 3-8348-0149-6
==
Vorwort bêÑêÉìäáÅÜ=ëÅÜåÉää=ï~ê=ÇáÉ=ÉêëíÉ=^ìÑä~ÖÉ=îÉêÖêáÑÑÉåI=ìåÇ=ÖÉêå=ÑçäÖÉ=áÅÜ=ÇÉê=^ìÑÑçêJ ÇÉêìåÖ=ÇÉë=sÉêä~ÖÉëI=ÉáåÉ=òïÉáíÉI=ïÉëÉåíäáÅÜ=ÉêïÉáíÉêíÉ=ìåÇ=îÉêÄÉëëÉêíÉ=^ìÑä~ÖÉ= îçêòìäÉÖÉåK== páÉ=ìåíÉêëÅÜÉáÇÉí=ëáÅÜ=îçå=ÇÉê=ÉêëíÉå=^ìÑä~ÖÉ=îçê=~ääÉã=ÇìêÅÜ=Ç~ë=åÉì=Üáåòì=ÖÉJ åçããÉåÉ=h~éáíÉä=U=òì=ÇÉå=dêìåÇä~ÖÉå=ÇÉê=dê~ÑáâJmêçÖê~ããáÉêìåÖ=ãáí=aÉäéÜáK== få=ÇáÉëÉã=åÉìÉå=h~éáíÉä=ïáêÇ=îÉêëí®åÇäáÅÜ=ìåÇ=~ìëÑΩÜêäáÅÜ=ÖÉëÅÜáäÇÉêíI=ïáÉ=ÖÉçJ ãÉíêáëÅÜÉ=cáÖìêÉå=~ìÑ=ÇÉã=_áäÇëÅÜáêã=ÉåíëíÉÜÉå=â∏ååÉåI=ïáÉ=^åáã~íáçåÉå=ìåÇ= péáÉäÉ= ÉåíëíÉÜÉå= ìåÇ= ïáÉ= ãáí= aÉäéÜá= ëçÖ~ê= j~äéêçÖê~ããÉ= ÜÉêÖÉëíÉääí= ïÉêÇÉå= â∏ååÉåK== tÉáíÉêÜáå=ÖÉÜí=ÇáÉ=kÉì~ìÑä~ÖÉ=~å=ÇÉå=åçíïÉåÇáÖÉå=píÉääÉå=å~íΩêäáÅÜ=Ç~ê~ìÑ=ÉáåI= ïáÉ= Ç~ë= àΩåÖëí= ~ìÑ= ÇÉå= j~êâí= ÖÉâçããÉåÉ= båíïáÅâäìåÖëëóëíÉã= _çêä~åÇ= aÉäéÜá= OMMR=òìã=báåëíáÉÖ=áå=ÇáÉ=aÉäéÜáJmêçÖê~ããáÉêìåÖ=ÖÉåìíòí=ïÉêÇÉå=â~ååK= aÉå= îáÉäÑ~ÅÜ= ÖÉ®ì≈ÉêíÉå= tΩåëÅÜÉå= ~ìÑ= îÉêÄÉëëÉêíÉ= çåäáåÉJråíÉêëíΩíòìåÖ= ïáêÇ= Ç~ÇìêÅÜ=oÉÅÜåìåÖ=ÖÉíê~ÖÉåI=Ç~ëë=åìåãÉÜê=ìåíÉê=ïïïKïJÖJãKÇÉ=áå=ÇÉê=ÄÉâ~ååJ íÉå= oìÄêáâ= Leser-Service =ÇáÉ=âçãéäÉííÉå= aÉäéÜáJmêçàÉâíÉ= òì= ~ääÉå=mêçÖê~ããJ ÄÉáëéáÉäÉå=ÄÉêÉáíÖÉëíÉääí=ëáåÇI=ìåÇ=Ç~ë=ëçïçÜä=ÑΩê=ÇáÉ=åçÅÜ=ïÉáí=îÉêÄêÉáíÉíÉ=sÉêJ ëáçå=aÉäéÜá=T=~äë=~ìÅÜ=ÑΩê=ÇáÉ=åÉìÉå=sÉêëáçåÉå=aÉäéÜá=ULOMMRK===== == ==========================tÉåå=ÇáÉëÉë=póãÄçä=ÉêëÅÜÉáåíI=Ç~åå=ïáêÇ=ãáíÖÉíÉáäíI=ïç=Ç~ë== âçãéäÉííÉ=aÉäéÜáJmêçàÉâí=ÑΩê=Ç~ë=àÉïÉáäáÖÉ=_ÉáëéáÉä=òì=ÑáåÇÉå=áëí=ìåÇ=ïáÉ=Éë=ÜÉJ êìåíÉêÖÉä~ÇÉå=ïÉêÇÉå=â~ååK== == wïáÉëé®äíáÖ=ï~êÉå=ÇáÉ=iÉëÉêãÉáåìåÖÉå=òìã=äÉíòíÉå=h~éáíÉä=ÇÉê=bêëí~ìÑä~ÖÉI=Ç~ë= ÑΩê=~ääÉ=iÉÜêÉåÇÉå=ìåÇ=iÉêåÉåÇÉå=ÖÉëÅÜêáÉÄÉå=ïìêÇÉI=ÇáÉ=ÇÉã=ÄÉï®ÜêíÉå=qìêJ ÄçJm~ëÅ~ä=Éáå=ïÉåáÖ=å~ÅÜíê~ìÉêåK=fÜåÉå=ïìêÇÉ=Ççêí=ÖÉòÉáÖíI=ïáÉ=~ìÅÜ=ãáí=aÉäJ éÜá= ÇáÉ= âä~ëëáëÅÜÉ= ëíêìâíìêáÉêíÉ= mêçÖê~ããáÉêìåÖ= ÉêÑçäÖêÉáÅÜ= îÉêãáííÉäí= ïÉêÇÉå= â~ååK== t®ÜêÉåÇ= ÉáåáÖÉ= oÉòÉåëÉåíÉå= áå= áÜêÉå= wìëÅÜêáÑíÉå= ÑçêÇÉêíÉåI= ÇáÉëÉë= h~éáíÉä= åáÅÜí=ëç=âìêò=òì=Ü~äíÉåI=ëíÉääÉå=~åÇÉêÉ=ëÉáåÉ=páååÑ®ääáÖâÉáí=êìåÇÜÉê~ìë=áåÑê~ÖÉK== aÉëÜ~äÄ=ïìêÇÉ=Éë=ëçI=ïáÉ=Éë=ï~êI=ÄÉáÄÉÜ~äíÉåI=åìê=ÇáÉ=píêìâíçÖê~ããÉ=ïìêÇÉå= çéíáëÅÜ=îÉêÄÉëëÉêíK=a~òì=åìíòíÉ=áÅÜ=ÇÉå=äÉáÅÜí=òì=ÄÉÇáÉåÉåÇÉå=kpaJbÇáíçê=îçå= j~êÅÉä=h~äí=îçå=ÇÉê=råáîÉêëáí®í=cêáÄçìêÖ=E`eFK== pÅÜäáÉ≈äáÅÜ=ÉêÑçäÖíÉI=ïáÉ=ÄÉá=àÉÇÉê=wïÉáí~ìÑä~ÖÉI=ÉáåÉ=ÖêΩåÇäáÅÜÉ=aìêÅÜëáÅÜí=ìåÇ= cÉÜäÉêÄÉëÉáíáÖìåÖI=~ìÅÜ=ÇáÉ=péê~ÅÜÉ=ïìêÇÉ=îçå=ÉáåáÖÉå=Ä~êçÅâÉå=sÉêòáÉêìåÖÉå= ÖÉêÉáåáÖíK=báå=îÉê®åÇÉêíÉë=i~óçìí=ëçää=ÇáÉ=iÉëÄ~êâÉáí=ÉêÜ∏ÜÉåK=
s =
sçêïçêí== fÅÜ= Ç~åâÉ= ~ääÉåI= ÇÉå= îáÉäÉå= oÉòÉåëÉåíÉå= ìåÇ= îçê= ~ääÉã= ãÉáåÉå= píìÇÉåíáååÉå= ìåÇ=píìÇÉåíÉåI=pÅÜΩäÉêáååÉå=ìåÇ=pÅÜΩäÉêåI=ÑΩê=ÇáÉ=îáÉäÉå=ïÉêíîçääÉå=eáåïÉáëÉ= ìåÇ= ÜçÑÑÉI= Ç~ëë= ÇáÉ= åìå= îçêäáÉÖÉåÇÉ= ^ìÑä~ÖÉ= Éáå= ÉÄÉåëç= ÄêÉáíÉë= bÅÜç= ÑáåÇÉå= ã∏ÖÉ=ïáÉ=áÜêÉ=sçêÖ®åÖÉêáåK=== rÉåÖäáåÖÉåI=áã=kçîÉãÄÉê=OMMR=========================================tçäÑJdÉêí=j~ííÜ®ìë=== =
Vorwort zur 1. Auflage =łaáÉ= aÉäéÜáJbîçäìíáçå= ÑΩê= ÇáÉ= KkbqJoÉîçäìíáçåK= råíÉê= ÇáÉëÉã= päçÖ~å= îÉêíêÉáÄí= _çêä~åÇ= ëÉáí= _ÉÖáåå= ÇáÉëÉë= g~ÜêÉë= ëÉáå= åÉìÉëíÉë= mêçÇìâíI= aÉäéÜá= UK= jáí= Kkbq= ã∏ÅÜíÉ=jáÅêçëçÑí=ÇáÉ=sáëáçå=îÉêïáêâäáÅÜÉåI=ÉáåÉ=mä~ííÑçêã=òì=ëÅÜ~ÑÑÉåI=ÇáÉ=fåÑçêJ ã~íáçåÉåI=jÉåëÅÜÉåI=póëíÉãÉ=ìåÇ=dÉê®íÉ=ãáíÉáå~åÇÉê=îÉêÄáåÇÉíK== aÉäéÜá=U=ÄêáåÖí=ÇáÉ=ÄÉäáÉÄíÉå=aÉäéÜá=s`iJpíÉìÉêÉäÉãÉåíÉ=~ìÑ=ÇáÉ=KkbqJmä~ííÑçêãK= a~ãáí=â~åå=àÉÇÉê=^åïÉåÇÉê=ë®ãíäáÅÜÉ=sçêíÉáäÉ=îçå=aÉäéÜá=ìåÇ=îçå=Kkbq=âçãJ ÄáåáÉêí=ÉáåëÉíòÉå=ìåÇ=ëÅÜäáÉ≈äáÅÜ=ãçÇÉêåÉ=ìåÇ=ÜçÅÜäÉáëíìåÖÑ®ÜáÖÉ=^åïÉåÇìåÖÉå= ÜÉêëíÉääÉåK== aáÉëÉë=_ìÅÜ=ïÉåÇÉí=ëáÅÜ=~å=_ÉÖáååÉêK=sçê~ìëÖÉëÉíòí=ïáêÇ=åáÅÜíëK== sÉêãáííÉäí=ïáêÇ=ÇÉê=äÉáÅÜíÉI=Ñ~ëí=ëéáÉäÉêáëÅÜÉ=báåëíáÉÖ=áå=ÇáÉ=tÉäí=ÇÉê=aÉäéÜáJmêçJ Öê~ããáÉêìåÖI= ÇÉê= ãáí= ÇÉê= eÉêëíÉääìåÖ= îçå= ~ííê~âíáîÉå= _ÉåìíòÉêçÄÉêÑä®ÅÜÉå= ÄÉJ Öáååí=ìåÇ=ëÅÜêáííïÉáëÉ=òì=áããÉê=êÉáòîçääÉêÉå=^åïÉåÇìåÖÉå=ÑΩÜêíK== fããÉê=ïáÉÇÉê=ìåÇ=áããÉê=~ìÑë=kÉìÉ=ïÉêÇÉå=~ìëÑΩÜêäáÅÜ=ÇáÉ=eáåíÉêÖêΩåÇÉ=Éêä®ìJ íÉêíI=ÇáÉ=ÑΩê=Ç~ë=sÉêëí®åÇåáë=ÇÉê=^Ää®ìÑÉ=áã=`çãéìíÉê=åçíïÉåÇáÖ=ëáåÇK== jÉÜê= ~äë= OTM= ^ÄÄáäÇìåÖÉå= áääìëíêáÉêÉå= Ç~ë= sçêÖÉÜÉåI= ëç= Ç~ëë= àÉÇÉê= pÅÜêáíí= ÄÉáã= k~ÅÜîçääòáÉÜÉå=~ìÑ=ÇÉã=ÉáÖÉåÉå=`çãéìíÉê=ÖÉå~ìÉëíÉåë=ΩÄÉêéêΩÑí=ïÉêÇÉå=â~ååK== lÄÖäÉáÅÜ= Ç~ë= _ìÅÜ= ÑΩê= ÇáÉ= åÉìÉëíÉ= aÉäéÜáJsÉêëáçå= ÖÉëÅÜêáÉÄÉå= ïìêÇÉI= ëç= Ü~í= ÇçÅÜ= âÉáå= iÉêåÉåÇÉê= áêÖÉåÇïÉäÅÜÉ= k~ÅÜíÉáäÉI= ÇÉê= ãáí= ®äíÉêÉå= aÉäéÜáJsÉêëáçåÉå= ~êÄÉáíÉå= ïáääK= tç= Éë= åçíïÉåÇáÖ= áëíI= ïáêÇ= ~ìÑ= ÇáÉ= råíÉêëÅÜáÉÇÉ= áã= rãÖ~åÖ= ãáí= ®äíÉêÉå=aÉäéÜáJsÉêëáçåÉå=ìåÇ=aÉäéÜá=U=ÜáåÖÉïáÉëÉåK== a~åâ= ë~ÖÉ= áÅÜ= òìÉêëí= ìåÇ= îçê= ~ääÉã= ÇÉå= qÉáäåÉÜãÉêå= ãÉáåÉê= iÉÜêîÉê~åëí~äíìåJ ÖÉåK= aáÉ= bêÖÉÄåáëëÉ= ÄÉá= ÇÉê= rãëÉíòìåÖ= ÇÉê= îçêÖÉäÉÖíÉå= jÉíÜçÇáâ= Ü~ÄÉå= òìã= dÉäáåÖÉå=ÇÉë=àÉíòáÖÉå=iÉÜêÄìÅÜÉë=ÉêÜÉÄäáÅÜ=ÄÉáÖÉíê~ÖÉåK== jÉáåÉ=äáÉÄÉ=cê~ì=çéÑÉêíÉ=îáÉäÉ=píìåÇÉåI=ìã=hçêêÉâíìê=òì=äÉëÉåK== a~åâÉå= ïÉêÇÉ=áÅÜ= ~ìÅÜ= ~ääÉå= iÉëÉêáååÉå=ìåÇ= iÉëÉêåI=ÇáÉ= ãáÅÜ=~ìÑ= ãÉáåÉê=eçJ ãÉé~ÖÉ=ïïïKïJÖJãKÇÉ=ÄÉëìÅÜÉå=ìåÇ=ãáê=áÜêÉ=jÉáåìåÖI=ëç=çÇÉê=ëçI=âìåÇíìåK=== rÉåÖäáåÖÉåI=áã=g~åì~ê=OMMQ============================================tçäÑJdÉêí=j~ííÜ®ìë= =
sf= =
==
Inhaltsverzeichnis
N= NKN==
_ÉåìíòÉêçÄÉêÑä®ÅÜÉå= KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK N= pí~êíÄáäÇÉê KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK N=
NKNKN= = aÉäéÜá=UKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK N= NKNKO= = aÉäéÜá=OMMRKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK P= NKNKP= = aÉäéÜá=T=ìåÇ=®äíÉêÉ=sÉêëáçåÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK S= NKO==
cçêãìä~ê KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK U=
NKOKN= = báåëíÉääìåÖ=ÇÉê=pí~êíJbáÖÉåëÅÜ~ÑíÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK U= NKOKO= = qÉëí=ÇÉë=cçêãìä~êëKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NM= NKOKP= = péÉáÅÜÉêìåÖ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NN= NKP==
píÉìÉêÉäÉãÉåíÉ=ÑΩê=Ç~ë=cçêãìä~ê KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NP=
NKPKN= = ^ìëï~Üä=ãáí=aÉäéÜá=ULOMMRKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NP= NKPKO= = ^ìëï~Üä=ãáí=®äíÉêÉå=aÉäéÜáJsÉêëáçåÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NQ= NKPKP= = táÅÜíáÖÉ=h~íÉÖçêáÉå=ÄòïK=oÉÖáëíÉêÄä®ííÉêKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NQ= NKQ==
_~ëáëÉäÉãÉåíÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NR=
NKQKN= = sçå=_ìííçå=Äáë=pÅêçääÄ~ê KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NR= NKQKO= = k~ãÉI=_ÉëÅÜêáÑíìåÖI=fåÜ~äíKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NS= NKQKP= = sçêÉáåëíÉääìåÖÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NT=
O
=
lÄàÉâíI=bêÉáÖåáëI=bêÉáÖåáëéêçòÉÇìê KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK ON=
OKN==
aÉê=lÄàÉâíÄÉÖêáÑÑ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK ON=
OKNKN= = a~íÉåçÄàÉâíÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK ON= OKNKO= = sáëìÉääÉ=lÄàÉâíÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK OP= OKNKP= = bêÉáÖåáëÄÉÜ~åÇäìåÖ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK OR= sff =
fåÜ~äíëîÉêòÉáÅÜåáë== OKO==
báåÑ~ÅÜÉ=bêÉáÖåáëéêçòÉÇìêÉå=òìã=pí~åÇ~êÇJbêÉáÖåáëKKKKKKKKKKKKKKKKKKKKKKKKKKK OS=
OKOKN= = _ìííçåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK OT= OKOKO= = qÉñíÑÉåëíÉêKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK OV= OKOKP= = `ÜÉÅâÄçñ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK PM= OKOKQ= = pÅêçääÄ~êKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK PM= OKOKR= = o~ÇáçÄìííçåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK PN= OKOKS= = i~ÄÉä KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK PN= OKOKT= = cçêãìä~ê KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK PN= OKP==
báåÑ~ÅÜÉ=bêÉáÖåáëéêçòÉÇìêÉå=òì=káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉå KKKKKKKKKKKKKK PO=
OKPKN= = oÉ~âíáçåÉå=~ìÑ=j~ìëÄÉïÉÖìåÖÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK PO= OKPKO= = oÉ~âíáçåÉå=~ìÑ=q~ëíÉåÇêìÅâKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK PR= OKPKP= = cçâìëJbêÉáÖåáëëÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK PS=
P
=
tÉáíÉêÉ=píÉìÉêÉäÉãÉåíÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK QN=
PKN==
píÉìÉêÉäÉãÉåí=iáëíÉ=EListBoxF KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK QO=
PKO==
píÉìÉêÉäÉãÉåí=`çãÄçÄçñ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK QQ=
PKP==
píÉìÉêÉäÉãÉåí=o~ÇáçÖêìééÉ=ERadioGroupF KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK QS=
PKQ==
píÉìÉêÉäÉãÉåí=jÉåΩ=EMainMenuFKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK QU=
Q
=
bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë KKKKKKKKKKKKKKKKKKKKK RP=
QKN==
báåÑ~ÅÜÉ=jáííÉáäìåÖÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK RP=
QKO==
m~ëëáîÉê=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK RP=
QKOKN= = báÖÉåÉê=a~íÉåâÉêå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK RQ= QKOKO= = a~íÉåâÉêåÉ=ÑêÉãÇÉê=lÄàÉâíÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK RU= QKP==
^âíáîÉê=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK SM=
QKPKN= = báÖÉåÉê=a~íÉåâÉêå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK SM= QKPKO= = a~íÉåâÉêåÉ=ÑêÉãÇÉê=lÄàÉâíÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK SN=
sfff= =
fåÜ~äíëîÉêòÉáÅÜåáë== QKQ==
^âíáîÉê=ìåÇ=é~ëëáîÉê=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK ST=
QKR==
^âíáîáÉêìåÖ=ìåÇ=aÉ~âíáîáÉêìåÖ=îçå=píÉìÉêÉäÉãÉåíÉå KKKKKKKKKKKKKKKKKKKKKKKKK TM=
QKRKN= = éêçéÉêíó=Enabled KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK TN= QKRKO= = ^âíáîáÉêìåÖ=ÇÉë=píÉìÉêÉäÉãÉåíë KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK TO= QKRKP= = få~âíáîÉ=jÉåΩJbáåíê®ÖÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK TP= QKS==
sÉêëíÉÅâÉå=îçå=píÉìÉêÉäÉãÉåíÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK TP=
QKSKN= = éêçéÉêíó=Visible KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK TP= QKSKO= = píÉìÉêÉäÉãÉåí=ëáÅÜíÄ~ê=ã~ÅÜÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK TQ= QKT==
k~ãÉåëÄÉëÅÜ~ÑÑìåÖ=ÑΩê=é~ëëÉåÇÉ=éêçéÉêíó KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK TQ=
QKTKN= = éêçéÉêíóJk~ãÉå=áã=lÄàÉâíáåëéÉâíçê=ÑáåÇÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK TR= QKTKO= = báÖÉåëÅÜ~Ñí=ÑÉÜäí=áã=lÄàÉâíáåëéÉâíçêKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK TT= QKTKP= = fåÑçêã~íáçå=ÇìêÅÜ=ÇáÉ=mìåâíäáëíÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK TU= QKTKQ= = fåÑçêã~íáçå=ΩÄÉê=ÇáÉ=^êí=ÇÉê=wìïÉáëìåÖ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK TV= QKTKR= = pí~êíJj~êâáÉêìåÖ=áå=iáëíÉå=ëÉíòÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK UM= QKTKS= = m~ëëáîÉê=ìåÇ=~âíáîÉê=wìÖêáÑÑ=~ìÑ=wÉáäÉå=áå=ÉáåÉê=iáëíÄçñKKKKKKKKKKKKKKKKKKK UM= QKTKT= = sÉêÉáåÑ~ÅÜìåÖÉå=ÇìêÅÜ=îÉêâΩêòíÉ=éêçéÉêíó=Items[...]KKKKKKKKKKKKKKKKKKKK UQ=
R
=
báåÑ~ÅÜÉ=qÉëíë=ìåÇ=^äíÉêå~íáîÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK UT=
RKN==
báåÑ~ÅÜÉê=qÉëíKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK UU=
RKNKN= = _ÉÇáåÖíÉë=^âíáîáÉêÉåLaÉ~âíáîáÉêÉå=îçå=_ìííçåë KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK UU= RKNKO= = báåâäáÅâ=çÇÉê=^ìëâäáÅâ\KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK VO= RKNKP= = iáåâëJoÉÅÜíëJpíÉìÉêìåÖKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK VQ= RKNKQ= = q~ëíÉå=ïÉÖÑ~åÖÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK VR= RKO==
^äíÉêå~íáîÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK VU=
RKOKN= = báå=k~ÅÜííáëÅÜä~ãéÉåJpÅÜ~äíÉê KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK VU= RKOKO= = wìJ=ìåÇ=^ÄëÅÜ~äíÉå=îçå=_ìííçåë KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNMM=
fu =
fåÜ~äíëîÉêòÉáÅÜåáë==
S
=
qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NMP=
SKN==
qáãÉêW=_ÉÖêáÑÑ=ìåÇ=_ÉÇÉìíìåÖ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNMP=
SKNKN= = _áëÜÉêáÖÉ=j∏ÖäáÅÜâÉáíÉå=ìåÇ=dêÉåòÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNMP= SKNKO= = qáãÉê KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNMR= SKO==
báåêáÅÜíìåÖ=ìåÇ=pí~êíÉáåëíÉääìåÖ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNMS=
SKOKN= = mä~íòáÉêÉå=ÇÉë=qáãÉêJpóãÄçäë KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNMS= SKOKO= = báåÑ~ÅÜÉ=bêÉáÖåáëéêçòÉÇìêÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNMU= SKP==
^êÄÉáí=ãáí=qáãÉêåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNNM=
SKPKN= = pí~êí=ìåÇ=pÉäÄëíJpíçééKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNNM= SKPKO= = e~äí=ìåÇ=tÉáíÉêã~ÅÜÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNNN= SKPKP= = _äáåâÉåÇÉ=pÅÜêáÑíKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNNP= SKQ==
mÉêã~åÉåíÉ=mêΩÑìåÖ=áã=eáåíÉêÖêìåÇKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNNQ=
SKR==
oçíJdÉäÄJdêΩåW=aáÉ=^ãéÉä=~å=ÇÉê=hêÉìòìåÖ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNNS=
SKRKN= = d~åòÉ=w~ÜäÉå=áå=ïáÉÇÉêÜçäíÉê=cçäÖÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNNS= SKRKO= = aáÉ=sÉêâÉÜêë~ãéÉä KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNNU= SK=S=
aÉê=sáÉêòóäáåÇÉêJjçíçê KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNON=
SK=T=
pí®ÇíÉJo~íÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNOP=
SK=U=
báå=ÉáåÑ~ÅÜÉê=_áäÇëÅÜáêãëÅÜçåÉêKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNOS=
T
=
d~åòÉ=w~ÜäÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NOV=
TKN==
aáÉ=cìåâíáçåÉå=IntToStr=ìåÇ=StrToIntKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNPM=
TKNKN= = d~åòò~ÜäáÖÉ=tÉêíÉ=~ìëÖÉÄÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNPM= TKNKO= = d~åòò~ÜäáÖÉ=tÉêíÉ=ÉêÑ~ëëÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNPN= TKNKP= = ^åïÉåÇìåÖÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNPQ= TKO==
péÉáÅÜÉêéä®íòÉ=ÑΩê=Ö~åòÉ=w~ÜäÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNPU=
TKOKN= = jçíáî~íáçå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNPU=
u= =
fåÜ~äíëîÉêòÉáÅÜåáë== TKOKO= = sÉêïÉåÇìåÖ=ÉáåÉë=péÉáÅÜÉêéä~íòÉë KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNPV= TKP==
sÉêÉáåÄ~êìåÖÉå=îçå=Ö~åòò~ÜäáÖÉå=péÉáÅÜÉêéä®íòÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKNQN=
TKPKN= = _áí=ìåÇ=_óíÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNQN= TKPKO= = IntegerJa~íÉåíóéÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNQP= TKQ==
^åïÉåÇìåÖÉå=îçå=Ö~åòò~ÜäáÖÉå=péÉáÅÜÉêéä®íòÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKNQP=
TKQKN= = dêìåÇë®íòÉI=k~ãÉåëÖÉÄìåÖ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNQP= TKQKO= = bêÜ∏ÜìåÖ=ÇÉê=§ÄÉêëáÅÜíäáÅÜâÉáí KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNQQ= TKQKP= = d~åòÉ=wìÑ~ääëò~ÜäÉåI=päçíJj~ëÅÜáåÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNQR= TKQKQ= = päçíJj~ëÅÜáåÉ=ãáí=_áäÇÉêåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNQU= TKQKR= = qÉáäÄ~êâÉáí KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNRN=
U
=
dê~ÑáâéêçÖê~ããáÉêìåÖ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NRR=
UKN==
dêìåÇÄÉÖêáÑÑÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNRR=
UKO==
dÉçãÉíêáëÅÜÉ=dÉÄáäÇÉ=ÉêòÉìÖÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNRS=
UKOKN= = a~ë=hççêÇáå~íÉåëóëíÉã KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNRS= UKOKO= = báåòÉäåÉê=máñÉä KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNRU= UKOKP= = dÉê~ÇÉ=iáåáÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNRV= UKOKQ= = lÑÑÉåÉë=oÉÅÜíÉÅâ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNRV= UKOKR= = oÉÅÜíÉÅâÑä®ÅÜÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNSM= UKOKS= = nì~Çê~íÑä®ÅÜÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNSN= UKOKT= = bääáéëÉåJrãêáëë KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNSN= UKOKU= = bääáéëÉåJcä®ÅÜÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNSO= UKOKV= = hêÉáëÑä®ÅÜÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNSO= UKOKNM= = qÉñíKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNSP= UKOKNN= = i∏ëÅÜÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNSP= UKOKNO= = ^ÅÜëÉåâêÉìòKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNSQ= UKP==
qÉñí=îÉê®åÇÉêå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNSS=
UKQ==
_áäÇëÅÜáêãëÅÜçåÉêKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNSU= uf =
fåÜ~äíëîÉêòÉáÅÜåáë== UKR==
^åáã~íáçåÉå=ìåÇ=péáÉäÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNTN=
UKRKN= = råÖÉëíÉìÉêíÉ=^åáã~íáçåÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNTN= UKRKO= = dÉëíÉìÉêíÉ=^åáã~íáçå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNTP= UKRKP= = péáÉäÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNTR= UKS==
j~äÉå=~ìÑ=ÇÉã=_áäÇëÅÜáêãKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNTV=
V
=
w®ÜäëÅÜäÉáÑÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NUR=
VKN==
^Äò®ÜäÉå=áå=iáëíÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNUR=
VKO==
jáåáã~ñJ^ìÑÖ~ÄÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNVM=
VKOKN= = dê∏≈íÉå=ìåÇ=âäÉáåëíÉå=tÉêí=ÄÉëíáããÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNVM= VKOKO= = mçëáíáçå=ÇÉë=Öê∏≈íÉå=ìåÇ=âäÉáåëíÉå=tÉêíÉë=ÄÉëíáããÉå KKKKKKKKKKKKKKKKKKNVN= VKP==
pìããÉå=ΩÄÉê=iáëíÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNVP=
NM
=káÅÜíåìãÉêáëÅÜÉ=péÉáÅÜÉêéä®íòÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK NVR=
NMKN== péÉáÅÜÉêéä®íòÉ=ÑΩê=t~ÜêÜÉáíëïÉêíÉ=Eqóé=BooleanFKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNVR= NMKNKN= = pìÅÜÉå=ìåÇ=cáåÇÉå=áå=iáëíÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNVR= NMKNKO= = sÉêÜ~äíÉå=ÉáåÉê=pÅÜ~äíìåÖ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKNVT= NMKO== péÉáÅÜÉêéä®íòÉ=ÑΩê=ÉáåòÉäåÉ=wÉáÅÜÉå=Eqóé=CharF KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOMN= NMKP== péÉáÅÜÉêéä®íòÉ=ÑΩê=wÉáÅÜÉåÑçäÖÉå=Eqóé=StringFKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOMR=
NN
=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëFKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK OMT=
NNKN== StringJcìåâíáçåÉå=ìåÇ=JmêçòÉÇìêÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOMT= NNKNKN= = táÅÜíáÖÉ=StringJcìåâíáçåÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOMT= NNKNKO= = táÅÜíáÖÉ=StringJmêçòÉÇìêÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOMV= NNKO== cáåÇÉåI=w®ÜäÉå=ìåÇ=i∏ëÅÜÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêåKKKKKKKKKKKKKKKKKKKKOMV= NNKOKN= = cáåÇÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOMV=
uff= =
fåÜ~äíëîÉêòÉáÅÜåáë== NNKOKO= = w®ÜäÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKONN= NNKOKP= = i∏ëÅÜÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKONQ= NNKP== bêëÉíòÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKONT= NNKPKN= = cáåÇÉåI=i∏ëÅÜÉå=ìåÇ=báåÑΩÖÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKONU= NNKPKO= = kÉì~ìÑÄ~ì=ÉáåÉë=òïÉáíÉå=píêáåÖë KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOOM= NNKQ== m~äáåÇêçãJqÉëí KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOOP= NNKR== sÉêÖäÉáÅÜÉ=îçå=wÉáÅÜÉåÑçäÖÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOOP= NNKRKN= = iÉñáâçÖê~ÑáëÅÜÉê=sÉêÖäÉáÅÜ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOOP= NNKRKO= = jáåáã~ñ=áå=iáëíÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOOR= NNKRKP= = içííçòáÉÜìåÖ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOOU= NNKS== d~åòÉ=w~ÜäÉå=ãáí=sçêòÉáÅÜÉå=òìä~ëëÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOPO= NNKT== nìÉêëìããÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOPP= NNKTKN= = báåÑ~ÅÜÉ=nìÉêëìããÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOPP= NNKTKO= = dÉïáÅÜíÉíÉ=nìÉêëìããÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOPQ=
NO
=péÉáÅÜÉêéä®íòÉ=ÑΩê=aÉòáã~äÄêΩÅÜÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK OPT=
NOKN== a~íÉåíóéÉå=SingleI=DoubleI=Extended KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOPT= NOKNKN= = mêáåòáéáÉå=ÇÉê=áåíÉêåÉå=péÉáÅÜÉêìåÖ=ìåÇ=sÉê~êÄÉáíìåÖ KKKKKKKKKKKKKKKKKKOPT= NOKNKO= = a~íÉåíóé=Single KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOPU= NOKNKP= = a~íÉåíóé=Double KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOPU= NOKNKQ= = a~íÉåíóé=Extended KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOPV= NOKO== hçãã~=çÇÉê=mìåâí\KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOPV= NOKP== ^ìëÖ~ÄÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOPV= NOKPKN= = mêçòÉÇìê=StrKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOQM= NOKPKO= = cçêã~íëíÉìÉêìåÖ=áå=aÉäéÜá=ìåÇ=aÉäéÜá=ULOMMR KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOQO= NOKPKP= = mìåâí=ìåÇ=hçãã~=áå=ÇÉê=^ìëÖ~ÄÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOQQ= NOKQ== bêÑ~ëëìåÖ=îçå=aÉòáã~äÄêΩÅÜÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOQT= NOKQKN= = mêçòÉÇìê=ValKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOQT= ufff =
fåÜ~äíëîÉêòÉáÅÜåáë== NOKQKO= = ^âíáîáÉêìåÖ=ìåÇ=aÉ~âíáîáÉêìåÖ=îçå=píÉìÉêÉäÉãÉåíÉåKKKKKKKKKKKKKKKKKKKKKOQV= NOKQKP= = kìíòÉêìåíÉêëíΩíòìåÖ=fW=_ÉÜ~åÇäìåÖ=Ñ~äëÅÜÉê=q~ëíÉå KKKKKKKKKKKKKKKKKKKKKKKKORM= NOKQKQ= = kìíòÉêìåíÉêëíΩíòìåÖ=ffW=fåÑçêã~íáçå=ÄÉá=cçâìëîÉêäìëí KKKKKKKKKKKKKKKKKKKKKORN= NOKR== oÉÅÜåÉå=ãáí=aÉäéÜá KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKORS= NOKRKN= = sáÉê=dêìåÇêÉÅÜÉå~êíÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKORS= NOKRKO= = aÉê=táåÇçïëJoÉÅÜåÉê KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKORU=
NP
=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK OSP=
NPKN== dêìåÇë®íòäáÅÜÉë KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOSP= NPKO== mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=îçå=aÉäéÜáJm~ëÅ~ä KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOSQ= NPKOKN= = _áëÜÉê=ÄÉêÉáíë=îÉêïÉåÇÉíÉ=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå KKKKKKKKKKKKKKKKKOSQ= NPKOKO= = a~íìãëJ=ìåÇ=wÉáíÑìåâíáçåÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOSR= NPKOKP= = ^êáíÜãÉíáëÅÜÉ=cìåâíáçåÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOSU= NPKP== mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=îáëìÉääÉê=lÄàÉâíÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOTN= NPKPKN= = táÉÇÉêÜçäìåÖW=sáëìÉääÉ=lÄàÉâíÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOTN= NPKPKO= = báÖÉåëÅÜ~ÑíÉå=~ìë=ÇÉê=mìåâíäáëíÉW=éêçéÉêíáÉëKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOTO= NPKPKP= = cìåâíáçåÉå=~ìë=ÇÉê=mìåâíäáëíÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOTP= NPKPKQ= = mêçòÉÇìêÉå=~ìë=ÇÉê=mìåâíäáëíÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOTR= NPKPKR= = pÅÜåáííëíÉääÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOTT= NPKPKS= = ^ìëå~ÜãÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOTU= NPKQ== páãìä~íáçå=ÉáåÉê=pìéÉêã~êâíJh~ëëÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOUM= NPKQKN= = ^ìÑÖ~ÄÉåëíÉääìåÖ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOUM= NPKQKO= = båíïìêÑ=ÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOUP= NPKQKP= = k~ãÉåëîÉêÖ~ÄÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOUQ= NPKQKQ= = bêÉáÖåáëéêçòÉÇìêÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOUR= NPKQKR= = bêïÉáíÉêìåÖÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOUV= NPKR== báÖÉåÉ=mêçòÉÇìêÉåKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOVM=
ufs= =
fåÜ~äíëîÉêòÉáÅÜåáë==
NQ
=jáí=aÉäéÜáW=m~ëÅ~ä=äÉêåÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK OVR=
NQKN== báåÑ~ÅÜÉ=aÉäéÜáJmêçÖê~ããáÉêìãÖÉÄìåÖ=ÑΩê=m~ëÅ~ä KKKKKKKKKKKKKKKKKKKKKKKKKKKOVS= NQKO== báåJ=ìåÇ=^ìëÖ~ÄÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOVU= NQKOKN= = báåJ=ìåÇ=^ìëÖ~ÄÉ=îçå=wÉáÅÜÉåÑçäÖÉå=EStringFKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKOVV= NQKOKO= = ^ìëÖ~ÄÉ=îçå=Ö~åòÉå=w~ÜäÉå=EIntegerFKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPMM= NQKOKP= = ^ìëÖ~ÄÉ=îçå=aÉòáã~äÄêΩÅÜÉå=ESingleI=DoubleI=ExtendedF KKKKKKKKKKKKKKKPMM= NQKOKQ= = bêÑ~ëëìåÖ=îçå=Ö~åòÉå=w~ÜäÉå=ìåÇ=aÉòáã~äÄêΩÅÜÉå KKKKKKKKKKKKKKKKKKKKKKKPMN= NQKP== píêìâíìêáÉêíÉë=mêçÖê~ããáÉêÉå=ãáí=m~ëÅ~ä KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPMP= NQKPKN= = píêìâíìêÉäÉãÉåíÉ=ìåÇ=áÜêÉ=rãëÉíòìåÖ=áå=m~ëÅ~ä KKKKKKKKKKKKKKKKKKKKKKKKKKKKKPMP= NQKPKO= = ^ìëå~ÜãÉêÉÖÉäìåÖÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPMS= NQKPKP= = qÉëíëKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPMS= NQKPKQ= = báåJ=ìåÇ=^ìëÖ~ÄÉå KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPMT= NQKQ== _ÉáëéáÉäÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPMT= NQKQKN= = píêìâíìêÉäÉãÉåí=cçäÖÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPMT= NQKQKO= = píêìâíìêÉäÉãÉåí=^ÄïÉáëëÅÜäÉáÑÉ=EâçéÑÖÉëíÉìÉêíÉ=pÅÜäÉáÑÉFKKKKKKKKKKKKKKPMU= NQKQKP= = píêìâíìêÉäÉãÉåí=káÅÜí~ÄïÉáëëÅÜäÉáÑÉ=EÑì≈ÖÉëíÉìÉêíÉ=pÅÜäÉáÑÉFKKKKKKKKPMV= NQKQKQ= = píêìâíìêÉäÉãÉåí=qÉëíKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPNM= NQKQKR= = píêìâíìêÉäÉãÉåí=^äíÉêå~íáîÉ KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPNR= NQKQKS= = píêìâíìêÉäÉãÉåí=w®ÜäëÅÜäÉáÑÉKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPNT= NQKR== cÉäÇÉêI=fåëí~åòÉåI=fåëí~åòÉåÑÉäÇÉê KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPNV= NQKRKN= = cÉäÇÉêKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPNV= NQKRKO= = fåëí~åòÉåÑÉäÇÉêKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKPNV= = ====p~ÅÜïçêíîÉêòÉáÅÜåáë KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK PON=
us =
==
1
Benutzeroberflächen
tÉê=ÜÉìíòìí~ÖÉ=Éáå=mêçÖê~ãã=ëÅÜêÉáÄíI=ÇÉê=çêáÉåíáÉêí=ëáÅÜ=~å=táåÇçïëK=lÄ=ÖÉJ ïçääí= çÇÉê= åáÅÜíI= çÄ= ÄÉïìëëí= çÇÉê= åáÅÜíW= aáÉ= Ö®åÖáÖÉ= cçêã= ÇÉê= jÉåëÅÜJoÉÅÜJ åÉêJhçããìåáâ~íáçå= ÄÉëíÉÜí= áå= ÇÉê= ^êÄÉáí= ãáí= j~ìë= ìåÇ= q~ëí~íìêI= áã= îáÉäÑ®äíáJ ÖÉå=rãÖ~åÖ=ãáí=ÇáîÉêëÉå=píÉìÉêJ=çÇÉê=_ÉÇáÉåÉäÉãÉåíÉåI=ÇáÉ=áå=ÉáåÉã=cÉåëíÉê= ~ìÑ=ÉáåÉê=^êÄÉáíëÑä®ÅÜÉ=~åÖÉçêÇåÉí=ëáåÇ=ìåÇ=ÇáÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=EÉåÖäKW=ìëÉê= áåíÉêÑ~ÅÉF=ÄáäÇÉåK== få= ÇáÉëÉã= h~éáíÉä= ïÉêÇÉå= ïáê= òìÉêëí= äÉêåÉåI= ïáÉ= ãáí= aÉäéÜá= U= ÉáåÉ= _ÉåìíòÉêJ çÄÉêÑä®ÅÜÉ= îçêÄÉêÉáíÉíI= ÖÉëí~äíÉíI= ÖÉëéÉáÅÜÉêí= ìåÇ= ÖÉíÉëíÉí= ïáêÇK= ^åëÅÜäáÉ≈ÉåÇ= ÖÉÜÉå= ïáê= ~ìÑ= ÇáÉ= _ÉëçåÇÉêÜÉáíÉå= ìåÇ= ^ÄïÉáÅÜìåÖÉå= ÄÉá= ÇÉê= åÉìÉëíÉå= sÉêJ ëáçå=aÉäéÜá=OMMR=ÉáåK=a~=ëáÉ=áããÉê=åçÅÜ=ïÉáí=îÉêÄêÉáíÉí=áëíI=ïáêÇ=~ìÅÜ=ÇáÉ=®äíÉJ êÉ=sÉêëáçå=aÉäéÜá=T=ÄÉêΩÅâëáÅÜíáÖíK==
1.1
Startbilder
1.1.1
Delphi 8
tÉåå=åáÅÜí=~åÇÉêë=ÉáåÖÉëíÉääí=ÄÉÖêΩ≈í=ìåë=aÉäéÜá=U=ãáí=ÉáåÉã=pí~êíÄáäÇI=áå=ÇÉëJ ëÉå=wÉåíêìã=ëáÅÜ=ÉáåÉ=táääâçããÉåëJpÉáíÉ=ÄÉÑáåÇÉíI=ÇáÉ=ìåë=ΩÄÉê=ÇáÉ=òìäÉíòí=ÄÉJ ~êÄÉáíÉíÉå=mêçàÉâíÉ=áåÑçêãáÉêí=ìåÇ=ïÉáíÉêÉ=iÉáëíìåÖÉå=~åÄáÉíÉíK=== aáÉ=táääâçããÉåëJpÉáíÉ=â~åå=ÖÉåìíòí=ïÉêÇÉåI=ìã=ìåãáííÉäÄ~ê=ãáí=ÇÉê=^êÄÉáí=~å= ÇÉå= òìäÉíòí= ÄÉÜ~åÇÉäíÉå= mêçàÉâíÉå= ÑçêíòìÑ~ÜêÉåI= ÇÉåå= ÇáÉëÉ= ïÉêÇÉå= ΩÄÉêëáÅÜíJ äáÅÜ=~ìÑÖÉäáëíÉíK=^ì≈ÉêÇÉã=ïÉêÇÉå=áå=ÇÉå=cÉåëíÉêå=qo^fkfkdI=_bfpmfbibI=obpplroJ `bk= ìåÇ= jf`olplcqKkbq= plirqflkp= slk= _loi^ka= ìãÑ~åÖêÉáÅÜÉ= ^åÖÉÄçíÉ= òìã= ïÉáíÉêÉå=iÉêåÉå=çÇÉê=òì=ëéÉòáÉääÉê=fåÑçêã~íáçå=ìåíÉêÄêÉáíÉíK= k~ÅÜ=ÇÉã=pÅÜäáÉ≈Éå=ÇÉê=táääâçããÉåëJpÉáíÉ=îçå=aÉäéÜá=UI=ïáÉ=ΩÄäáÅÜ=ãáí=ÇÉê= j~ìë=~å=ÇÉã=âäÉáåÉå=pÅÜäáÉ≈JhêÉìò==x==I=ãΩëëÉå=ïáê=ìåë=å~ÅÜ=a^qbfkbr=ÉåíJ ëÅÜÉáÇÉåI= ïÉäÅÜÉ= ÇÉê= îáÉäÉå= ^åïÉåÇìåÖÉåI= ÇáÉ= ãáí= aÉäéÜá= U= ÜÉêëíÉääÄ~ê= ëáåÇI= ~åÖÉëíêÉÄí=ïáêÇK== cΩê=ÇáÉëÉë=_ìÅÜ=ëçääíÉå=ïáê=ÖêìåÇë®íòäáÅÜ=s`iJcçêãìä~ê~åïÉåÇìåÖÉå=~ìëï®ÜJ äÉå=E_áäÇ=NKOFK== k~ÅÜ= ^ìëï~Üä= ÇÉê= s`iJcçêãìä~ê~åïÉåÇìåÖ= ÉêëÅÜÉáåí= Ç~ë= ÉåíëéêÉÅÜÉåÇÉ= s`iJ ^åïÉåÇìåÖëJpí~êíÄáäÇK== pÉÜÉå=ïáê=ìåë=ÇÉëëÉå=_Éëí~åÇíÉáäÉ=áå=_áäÇ=NKP=ÖÉå~ìÉê=~åK== = N =
N= _ÉåìíòÉêçÄÉêÑä®ÅÜÉå=
= _áäÇ=NKNW=pí~êíÄáäÇ=îçå=aÉäéÜá=U=
== _áäÇ=NKOW=^ìëï~Üä=ÇÉê=îçêÖÉëÉÜÉåÉå=^åïÉåÇìåÖW=s`iJcçêãìä~ê= • iáåâë= áëí= áå= _áäÇ= NKP= Éáå= Öêç≈ÉëI= ä~åÖÉë= cÉåëíÉê= òì= ëÉÜÉåI= Ç~ë= ÇáÉ= §ÄÉêëÅÜêáÑí= lÄàÉâíáåëéÉâíçê=íê®Öí=ìåÇ=ÇáÉ=ÄÉáÇÉå=oÉÖáëíÉêÄä®ííÉê=bfdbkp`e^cqbk=ìåÇ=bobfdJ kfppb=ÉåíÜ®äíK=jáí=eáäÑÉ=ÇÉë=lÄàÉâíáåëéÉâíçêëI=ÉáåÉë=ïáÅÜíáÖÉå=aÉäéÜáJ_Éëí~åÇJ íÉáäëI=â∏ååÉå=ïáê=áã=båíïìêÑ=ÉáåëíÉääÉåI=ïáÉ=ÇáÉ=_ÉÇáÉåÉäÉãÉåíÉ=~ìëëÉÜÉå=ëçäJ äÉåI=ïÉåå=ëáÉ=ÇÉã=kìíòÉê=~ìÑ=ÇÉã=_áäÇëÅÜáêã=éê®ëÉåíáÉêí=ïÉêÇÉåK== O= =
NKN== pí~êíÄáäÇÉê= tÉåå= Ç~ë= cÉåëíÉê= lÄàÉâíáåëéÉâíçê= ÑÉÜäíI= â~åå= Éë= ΩÄÉê= ^kpf`eql_gbhqfkpmbhJ qlo=ïáÉÇÉê=ÄÉëçêÖí=ïÉêÇÉåK= • få=ÇÉê=jáííÉ=ÇÉë=pí~êíÄáäÇÉë=ÄÉÑáåÇÉí=ëáÅÜ=ÉáåÉ=Öê~ìÉI=ÖÉê~ëíÉêíÉ=cä®ÅÜÉ=ãáí=ÇÉê= _ÉëÅÜêáÑíìåÖ= cçêãNK= a~ë= áëí= ÇÉê= båíïìêÑ= ÇÉë= cçêãìä~êëI= Ç~ë= áëí= ÄÉêÉáíë= ÇÉê= dêìåÇÄ~ìëíÉáå=ÑΩê=àÉÇÉ=^åïÉåÇìåÖI=Ç~ë=ïáêÇ=ÇáÉ=^êÄÉáíëÑä®ÅÜÉI=ÇÉê= eáåíÉêJ ÖêìåÇ=àÉÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉK== • oÉÅÜíë=çÄÉå=áëí=Ç~ë=cÉåëíÉê=ÇÉê=mêçàÉâíîÉêï~äíìåÖ=òì=ëÉÜÉåX=ÑΩê=ìåëÉêÉ=báåJ ëíáÉÖëJ^åïÉåÇìåÖÉå= Ü~í= Éë= åçÅÜ= âÉáåÉ= Öêç≈É= _ÉÇÉìíìåÖK= tÉåå= ÇáÉëÉë= cÉåëíÉê=ÑÉÜäíI=â~åå=Éë=ΩÄÉê=^kpf`eqmolgbhqsbot^iqrkd=ÖÉ∏ÑÑåÉí=ïÉêÇÉåK=== =
=
= _áäÇ=NKPW=pí~êíëáíì~íáçå=ÑΩê=ÇáÉ=aÉäéÜáJUJs`iJmêçÖê~ããáÉêìåÖ==
• cΩê=ìåë=~ÄÉê=ÄÉêÉáíë=~åÑ~åÖë=~ì≈ÉêçêÇÉåíäáÅÜ=ïáÅÜíáÖ=ïáêÇ=Ç~ë=cÉåëíÉê=ëÉáåI= Ç~ë= êÉÅÜíë= ìåíÉå= òì= ëÉÜÉå= áëí= ìåÇ= ÇáÉ= _ÉëÅÜêáÑíìåÖ= qççäJm~äÉííÉ= íê®ÖíK= pçääíÉ= ÇáÉëÉë=cÉåëíÉê=åáÅÜí=òì=ëÉÜÉå=ëÉáå=â~åå=Éë=ΩÄÉê=^kpf`eqqlliJm^ibqqb=ÖÉJ ∏ÑÑåÉí=ïÉêÇÉåK==
1.1.2
Delphi 2005
pÉáí= _ÉÖáåå= ÇÉë= g~ÜêÉë= OMMR= ÄÉÑáåÇÉí= ëáÅÜ= Ç~ë= åÉìÉëíÉ= _çêä~åÇJmêçÇìâíI= Ç~ë= ÜçÅÜÖê~ÇáÖ=äÉáëíìåÖëÑ®ÜáÖÉ=båíïáÅâäìåÖëëóëíÉã=aÉäéÜá=OMMRI=~ìÑ=ÇÉã=j~êâíK== _áäÇ=NKQ=òÉáÖí=Ç~ë=pí~êíÄáäÇ=îçå=aÉäéÜá=OMMRI=Ç~ë=ëáÅÜ=îçã=aÉäéÜáJUJpí~êíÄáäÇ=åìê= ÖÉêáåÖÑΩÖáÖ=ìåíÉêëÅÜÉáÇÉíK== P =
N= _ÉåìíòÉêçÄÉêÑä®ÅÜÉå= få= ÇÉê= jáííÉ= ÇÉê= aÉäéÜáJOMMRJtáääâçããÉåëJpÉáíÉ= ÄÉÑáåÇÉí= ëáÅÜ= åÉÄÉå= pÅÜä~ÖòÉáJ äÉå=Éáå=^ìëï~ÜäJcÉåëíÉêI=áå=ÇÉã=ã~å=ìåíÉê=ÉáåÉê=cΩääÉ=îçå=píáÅÜïçêíÉå=~ìëï®ÜJ äÉå=â~ååK==
= _áäÇ=NKQW=pí~êíÄáäÇ=îçå=aÉäéÜá=OMMR== _ÉëíÉÜí= ÉáåÉ= sÉêÄáåÇìåÖ= òìã= fåíÉêåÉíI= ïáêÇ= çåäáåÉ= òìã= àÉïÉáäë= ~ìëÖÉï®ÜäíÉå= _ÉÖêáÑÑ=Ç~ë=kÉìÉëíÉ=~ìë=ÇÉê=_çêä~åÇJtÉäí=ãáíÖÉíÉáäíK=_áäÇ=NKQ=òÉáÖíI=ïáÉ=òìã=_ÉáJ ëéáÉä= òì= aÉäéÜá= OMMR= ÇáÉ= åÉìÉëíÉå= fåÑçêã~íáçåÉå= ~åÖÉÑçêÇÉêí= ïÉêÇÉå= â∏ååÉåK= ^ìÅÜ=ÉáåÉ=çåäáåÉJiÉêåÜáäÑÉ=áëí=îÉêÑΩÖÄ~êK== táÉ=áããÉê=ÄÉá=ëçäÅÜ=âçãéäÉñÉå=póëíÉãÉå=Ü~í=ÇÉê=^åÑ®åÖÉê=~ÄÉê=ÉáåÉå=ä®åÖÉJ êÉå=tÉÖ=òìêΩÅâòìäÉÖÉåI=ÄÉîçê=Éê=ΩÄÉêÜ~ìéí=ãáí=ÇÉê=^êÄÉáí=ÄÉÖáååÉå=â~ååW=_Éá= aÉäéÜá=OMMR=ÜÉá≈í=Ç~ëI=Ç~ëë=òìÉêëí=áã=cÉåëíÉê=ÇÉê=qççäJm~äÉííÉI=Ç~ë=ëáÅÜ=áã=pí~êíJ ÄáäÇ= îçå= aÉäéÜá= OMMR= êÉÅÜíë= ìåíÉå= ÄÉÑáåÇÉíI= ÇáÉ= pÅÜ~äíÑä®ÅÜÉ= Kategorien = ÖÉJ ÑìåÇÉå=ïÉêÇÉå=ãì≈=E_áäÇ=NKRFW=
= _áäÇ=NKRW=pÅÜ~äíÑä®ÅÜÉ=Kategorien=ÇÉê=qççäJm~äÉííÉ==
Q= =
NKN== pí~êíÄáäÇÉê= cΩê=ÇáÉëÉë=_ìÅÜ=ëçääíÉ=Ç~å~ÅÜ=áããÉê=ÇáÉ=h~íÉÖçêáÉ=aÉäéÜáJmêçàÉâíÉ=~ìëÖÉï®Üäí= ïÉêÇÉå=E_áäÇ=NKRFK==
= _áäÇ=NKSW=h~íÉÖçêáÉ=Delphi-Projekte=~ìëï®ÜäÉå= fååÉêÜ~äÄ=ÇÉê=cΩääÉ=ÇÉê=~åÖÉÄçíÉåÉå=^êíÉå=îçå=aÉäéÜáJmêçàÉâíÉå=ÑáåÇÉí=ëáÅÜ=Ç~ë= ÖÉëìÅÜíÉ=^åÖÉÄçí=s`iJcçêãìä~ê~åïÉåÇìåÖ=E_áäÇ=NKTF=
= _áäÇ=NKTW=aÉäéÜáJmêçàÉâí=VCL-Formular-Anwendung= k~ÅÜ= ÇÉã= ÄÉëí®íáÖÉåÇÉå= açééÉäâäáÅâ= ~ìÑ= ÇÉå= báåíê~Ö= s`iJcçêãìä~ê~åïÉåJ ÇìåÖ= ∏ÑÑåÉí= ëáÅÜ= Ç~ë= aÉäéÜáJOMMRJs`iJ^åïÉåÇìåÖëJpí~êíÄáäÇ= E_áäÇ= NKUFI= Ç~ë= ÇÉã=ÉåíëéêÉÅÜÉåÇÉå=_áäÇ=îçå=aÉäéÜá=U=ëÉÜê=®ÜåäáÅÜ=ëáÉÜíW== • iáåâë=áå=_áäÇ=NKU=áëí=ïáÉÇÉê=Ç~ë=cÉåëíÉê=òì=ëÉÜÉåI=Ç~ë=ÇáÉ=§ÄÉêëÅÜêáÑí=lÄàÉâíáåJ ëéÉâíçê=íê®Öí=ìåÇ=ÇáÉ=ÄÉáÇÉå=oÉÖáëíÉêÄä®ííÉê=bfdbkp`e^cqbk=ìåÇ=bobfdkfppb=ÉåíJ Ü®äíK=jáí=eáäÑÉ=ÇÉë=lÄàÉâíáåëéÉâíçêëI=ÉáåÉë=ïáÅÜíáÖÉå=aÉäéÜáJ_Éëí~åÇíÉáäëI=â∏åJ åÉå=ïáê=áã=båíïìêÑ=ÉáåëíÉääÉåI=ïáÉ=ÇáÉ=_ÉÇáÉåÉäÉãÉåíÉ=~ìëëÉÜÉå=ëçääÉåI=ïÉåå= ëáÉ=ÇÉã=kìíòÉê=~åÑ~åÖë=~ìÑ=ÇÉã=_áäÇëÅÜáêã=éê®ëÉåíáÉêí=ïÉêÇÉåK==
R =
N= _ÉåìíòÉêçÄÉêÑä®ÅÜÉå= tÉåå= Ç~ë= cÉåëíÉê= lÄàÉâíáåëéÉâíçê= ÑÉÜäíI= â~åå= Éë= ΩÄÉê= ^kpf`eql_gbhqfkpmbhJ qlo=çÇÉê=ÇìêÅÜ=aêìÅâ=~ìÑ=ÇáÉ=q~ëíÉ= F11 =ïáÉÇÉê=ÄÉëçêÖí=ïÉêÇÉåK= • få=ÇÉê=jáííÉ=ÇÉë=pí~êíÄáäÇÉë=ÄÉÑáåÇÉí=ëáÅÜ=ÉáåÉ=Öê~ìÉI=ÖÉê~ëíÉêíÉ=cä®ÅÜÉ=ãáí=ÇÉê= _ÉëÅÜêáÑíìåÖ= Form1K= a~ë= áëí= ÇÉê= båíïìêÑ= ÇÉë= cçêãìä~êëI= Ç~ë= áëí= ÄÉêÉáíë= ÇÉê= dêìåÇÄ~ìëíÉáå=ÑΩê=àÉÇÉ=^åïÉåÇìåÖI=Ç~ë=ïáêÇ=ÇáÉ=^êÄÉáíëÑä®ÅÜÉI=ÇÉê= eáåíÉêJ ÖêìåÇ=àÉÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉK== • oÉÅÜíë=çÄÉå=áëí=Ç~ë=cÉåëíÉê=ÇÉê=mêçàÉâíîÉêï~äíìåÖ=òì=ëÉÜÉåX=ÑΩê=ìåëÉêÉ=báåJ ëíáÉÖëJ^åïÉåÇìåÖÉå= Ü~í= Éë= åçÅÜ= âÉáåÉ= Öêç≈É= _ÉÇÉìíìåÖK= tÉåå= ÇáÉëÉë= cÉåëíÉê=ÑÉÜäíI=â~åå=Éë=ΩÄÉê=^kpf`eqmolgbhqsbot^iqrkd=ÖÉ∏ÑÑåÉí=ïÉêÇÉåK===
= _áäÇ=NKUW=pí~êíëáíì~íáçå=ÑΩê=aÉäéÜáJOMMRJs`iJmêçÖê~ããáÉêìåÖ=== • táÉÇÉêìã=ëÉÜê=ïáÅÜíáÖ=ïáêÇ=Ç~ë=cÉåëíÉê=ëÉáåI=Ç~ë=êÉÅÜíë=ìåíÉå=òì=ëÉÜÉå=áëí= ìåÇ=ÇáÉ=_ÉëÅÜêáÑíìåÖ=qççäJm~äÉííÉ=íê®ÖíK=açêí=â∏ååÉå=ïáê=å®ãäáÅÜ=ÇáÉ=_ÉÇáÉåJ ÉäÉãÉåíÉ=~ìëï®ÜäÉåI=ÇáÉ=~ìÑ=ÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=éä~íòáÉêí=ïÉêÇÉå=ëçääÉå= EëáÉÜÉ=^ÄëÅÜåáíí=NKPKN=~ìÑ=pÉáíÉ=NPFK== pçääíÉ= Ç~ë= cÉåëíÉê= Tool-Palette= åáÅÜí= òì= ëÉÜÉå= ëÉáå= â~åå= Éë= ΩÄÉê= ^kpf`eq= qlliJm^ibqqb=ÖÉ∏ÑÑåÉí=ïÉêÇÉåK==
1.1.3
Delphi 7 und ältere Versionen
a~ë=pí~êíÄáäÇ=îçå=aÉäéÜá=T=ìåÇ=®äíÉêÉå=sÉêëáçåÉå=îçå=aÉäéÜá=E_áäÇ=NKVF=áëí=áã= tÉëÉåíäáÅÜÉå= ïáÉ= Ç~ë= pí~êíÄáäÇ= ÇÉê= aÉäéÜáJUJs`iJcçêãìä~ê~åïÉåÇìåÖ= E_áäÇ= NKPF=ëíêìâíìêáÉêíX=ÉáåáÖÉ=_ÉòÉáÅÜåìåÖÉå=ëáåÇ=~åÇÉêëK==
S= =
NKN== pí~êíÄáäÇÉê= • ^ìÑÑ®ääáÖ=áëí=áã=wÉåíêìã=ÇÉë=cÉåëíÉêë=ÇáÉ=ëçÑçêí=îçêÜ~åÇÉåÉI=Öê~ì=ÖÉê~ëíÉêíÉ= cä®ÅÜÉ= ãáí= ÇÉê= _ÉëÅÜêáÑíìåÖ= cçêãNK= a~ë= áëí= ïáÉÇÉê= ÇÉê= båíïìêÑ= ÇÉë= cçêãìJ ä~êëI=Ç~ë=áëí=ÄÉêÉáíë=ÇÉê=dêìåÇÄ~ìëíÉáå=ÑΩê=àÉÇÉ=^åïÉåÇìåÖK= • a~ë= âäÉáåÉ= cÉåëíÉê= äáåâë= çÄÉå= íê®Öí= ÇáÉ= _ÉëÅÜêáÑíìåÖ= lÄàÉâíJeáÉê~êÅÜáÉX= Éë= ÉåíëéêáÅÜí=ÇÉê=mêçàÉâíîÉêï~äíìåÖ=îçå=aÉäéÜá=UX=Éë=áëí=ÑΩê=ìåëÉêÉ=^åïÉåÇìåJ ÖÉå=ÉáåëíïÉáäÉå=åáÅÜí=ïáÅÜíáÖK==
= _áäÇ=NKVW=pí~êíÄáäÇ=îçå=aÉäéÜá=T= • iáåâë= Ç~êìåíÉê= áëí= àÉÇçÅÜ= ïáÉÇÉê= Ç~ë= ïáÅÜíáÖÉ= cÉåëíÉê= òì= ëÉÜÉåI= Ç~ë= ÇáÉ= §ÄÉêëÅÜêáÑí= lÄàÉâíáåëéÉâíçê= íê®ÖíK= jáí= eáäÑÉ= ÇáÉëÉë= lÄàÉâíáåëéÉâíçêë= â∏ååÉå= ïáê=ÉáåëíÉääÉåI=ïáÉ=ÇáÉ=_ÉÇáÉåÉäÉãÉåíÉ=~ìëëÉÜÉå=ëçääÉåI=ïÉåå=ëáÉ=ÇÉã=kìíJ òÉê=~åÑ~åÖë=~ìÑ=ÇÉã=_áäÇëÅÜáêã=éê®ëÉåíáÉêí=ïÉêÇÉåK== • ^åëíÉääÉ= ÇÉë= qççäJm~äÉííÉåJcÉåëíÉêë= ÄÉëáíòÉå= ÇáÉ= ®äíÉêÉå= sÉêëáçåÉå= îçå= aÉäJ éÜá= êÉÅÜíë= çÄÉå= ÇáÉ= hçãéçåÉåíÉåäÉáëíÉ= E_áäÇ= NKNMF= ãáí= áÜêÉå= îÉêëÅÜáÉÇÉåÉå= oÉÖáëíÉêÄä®ííÉêå=pq^ka^oaI=wrpûqwif`eI=pvpqbj=ìëïK== == _áäÇ=NKNMW=hçãéçåÉåíÉåäÉáëíÉ=®äíÉêÉê=aÉäéÜáJsÉêëáçåÉå= T =
N= _ÉåìíòÉêçÄÉêÑä®ÅÜÉå=
1.2
Formular
1.2.1
Einstellung der Start-Eigenschaften
^ìÑ=ÇáÉ=cê~ÖÉI=ï~ë=ïáê=áã=båíïìêÑ=~ääÉë=ÑΩê=ÇáÉ=~åÑ®åÖäáÅÜÉ=bêëÅÜÉáåìåÖëÑçêã= ÇÉë=cçêãìä~êëI=ÇÉë=eáåíÉêÖêìåÇÉë=ÇÉê=ÖÉéä~åíÉå=_ÉåìíòÉêçÄÉêÑä®ÅÜÉI=îçêÉáåëíÉäJ äÉå= â∏ååÉåI= ~åíïçêíÉå= ÇáÉ= lÄàÉâíáåëéÉâíçêÉå= îçå= aÉäéÜá= U= ìåÇ= aÉäéÜá= OMMR= ãáí=ãÉÜêÉêÉå=aìíòÉåÇ=wÉáäÉåK=aÉê=lÄàÉâíáåëéÉâíçê=®äíÉêÉê=sÉêëáçåÉå=ÄáÉíÉí=Ç~J ÖÉÖÉå=åìê=ìåÖÉÑ®Üê=ÇáÉ=e®äÑíÉ=~å=báëíÉääìåÖëã∏ÖäáÅÜâÉáíÉå=~åK== _áäÇ=NKNN=îÉêëìÅÜíI=~ääÉ=wÉáäÉå=ÇÉë= aÉäéÜáJUJlÄàÉâíáåëéÉâíçêë=ÇÉë=cçêãìä~êë=mä~íò= ëé~êÉåÇ=~åòìÇÉìíÉåK==
= _áäÇ=NKNNW=lÄàÉâíáåëéÉâíçê=îçå=aÉäéÜá=U=ÑΩê=Ç~ë=cçêãìä~ê= aÉê=rãÖ~åÖ=ãáí=ÇÉã=lÄàÉâíáåëéÉâíçê=ìåíÉêëÅÜÉáÇÉí=ëáÅÜ=áå=aÉäéÜá=ULOMMR=åáÅÜí= îçã= rãÖ~åÖ= ãáí= ÇÉã= lÄàÉâíáåëéÉâíçê= áå= ®äíÉêÉå= sÉêëáçåÉåK= aÉëïÉÖÉå= Äê~ìJ ÅÜÉå=ïáê=ëé®íÉê=åáÅÜí=òì=ÇáÑÑÉêÉåòáÉêÉåK= gÉÇÉ=wÉáäÉ=ÇÉë=lÄàÉâíáåëéÉâíçêë=ÄÉëÅÜêÉáÄí=ÉáåÉ=ÖÉïáëëÉ=báÖÉåëÅÜ~Ñí=ÇÉë=cçêãìJ ä~êëI=ÇáÉ=ïáê=áã=båíïìêÑ=ÉáåëíÉääÉå=â∏ååíÉåK=aÉëÜ~äÄ=â∏ååíÉå=ïáê=ÇÉå=lÄàÉâíáåJ ëéÉâíçê=~ìÅÜ=~äë=báÖÉåëÅÜ~ÑíëÑÉåëíÉê=ÄÉòÉáÅÜåÉåK=== tçääíÉå= ïáê= ÇÉå= sÉêëìÅÜ= ìåíÉêåÉÜãÉåI= ìåë= àÉÇÉ= ÉáåòÉäåÉ= ÇáÉëÉê= mçëáíáçåÉå= îçêòìåÉÜãÉå=ìåÇ=òì=ÉêÑçêëÅÜÉåI=ïÉäÅÜÉ=_ÉÇÉìíìåÖ=ëáÉ=Ü~íI=ï®êÉ=ÄÉêÉáíë=ÜáÉê= Éáå=ÄÉëçåÇÉêÉë=_ìÅÜ=òì=ëÅÜêÉáÄÉåK== hçåòÉåíêáÉêÉå= ïáê= ìåë= ÇÉëÜ~äÄ= ~ìÑ= ïÉåáÖÉ= wÉáäÉå= áã= lÄàÉâíáåëéÉâíçêI= ÇáÉ= ÄÉJ êÉáíë=ÑΩê=ÇÉå=^åÑ®åÖÉê=ïáÅÜíáÖ=ëáåÇK==
U= =
NKO== cçêãìä~ê= _Éîçê=ïáê=ÇáÉëÉ=wÉáäÉå=ÜÉê~ìëëìÅÜÉåI=ëçääíÉå=ïáê=ÇÉå=lÄàÉâíáåëéÉâíçêI=ÇÉëëÉå= báåíê®ÖÉ= ëíÉíë= ~åÑ~åÖë= íÜÉã~íáëÅÜ= ÖÉçêÇåÉí= ~åÖÉÄçíÉå= ïÉêÇÉåI= ~ìÑ= ÇáÉ= ~äéÜ~J ÄÉíáëÅÜÉ=^åçêÇåìåÖ=ìãëíÉääÉåK==
== _áäÇ=NKNOW=lÄàÉâíáåëéÉâíçê=~ìÑ=~äéÜ~ÄÉíáëÅÜÉ=^åçêÇåìåÖ=ìãëíÉääÉå= a~òì=ïáêÇ=ãáí=ÇÉê=êÉÅÜíÉå=j~ìëí~ëíÉ=~ìÑ=ÇáÉ=§ÄÉêëÅÜêáÑí=bfdbkp`e^cqbk=ÖÉâäáÅâí= ìåÇ=~åëÅÜäáÉ≈ÉåÇ=ΩÄÉê=^kloakbk=ÇáÉ=a~êëíÉääìåÖ=k^`e= k^jb=~ìëÖÉï®Üäí=EëáÉJ ÜÉ=_áäÇ=NKNOFK= §ÄÉê= ÇêÉá= ÖêìåÇäÉÖÉåÇÉ= Epí~êíJFbáÖÉåëÅÜ~ÑíÉå= ÇÉë= cçêãìä~êë= ëçääíÉå= ïáê= ìåë= ëíÉíë=dÉÇ~åâÉå=ã~ÅÜÉåW== NK= táÉ= Öêç≈= ëçää= ÇáÉ= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= ïÉêÇÉå\= pçää= ëáÉ= ëíÉíë= _áäÇëÅÜáêã= ÑΩäJ äÉåÇ=ëÉáå=çÇÉê=ëçää=ëáÉ=ëé®íÉê=åìê=ÖÉå~ì=ÇáÉ=dê∏≈É=Ü~ÄÉåI=ãáí=ÇÉê=ëáÉ=áã=båíJ ïìêÑ=~äë=Öê~ì=ÖÉê~ëíÉêíÉ=cä®ÅÜÉ=ÉêëÅÜÉáåí\=råëÉêÉ=båíëÅÜÉáÇìåÖ=Ç~òì=ëíÉääÉå=ïáê= áå= ÇÉê= wÉáäÉ= WindowState= ÉáåK= _áäÇ= NKNP= òÉáÖí= ÇáÉ= ÇêÉá= ÉáåëíÉääÄ~êÉå= j∏ÖäáÅÜâÉáJ íÉåK=
= _áäÇ=NKNPW=sçêÉáåëíÉääìåÖ=ÇÉê=dê∏≈É=ÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ= OK= tÉäÅÜÉ= §ÄÉêëÅÜêáÑíI= ÇK= ÜK= ïÉäÅÜÉ= _ÉëÅÜêáÑíìåÖ= EÉåÖäKW= Å~éíáçåF= ëçää= Ç~ë= cçêJ ãìä~ê= ÄÉâçããÉå\= råëÉêÉ= båíëÅÜÉáÇìåÖ= íê~ÖÉå= ïáê= áå= ÇÉê= wÉáäÉ= Caption= ÇÉë= lÄàÉâíáåëéÉâíçêë=E_áäÇ=NKNQF=ÉáåK== = _áäÇ=NKNQW=t~Üä=ÇÉê=cÉåëíÉêΩÄÉêëÅÜêáÑí= PK= tÉäÅÜÉ= c~êÄÉ= ëçää= ÇáÉ= ^êÄÉáíëÑä®ÅÜÉ= ÄÉâçããÉåI= ÇK= ÜK= ïáÉ= ëçää= ÇÉê= eáåíÉêJ ÖêìåÇ=ìåëÉêÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=~ìëëÉÜÉå\=aáÉ=c~êÄÉ=ëíÉääÉå=ïáê=ãáí=eáäÑÉ=ÇÉê= wÉáäÉ=Color=áã=lÄàÉâíáåëéÉâíçê=ÉáåK=_áäÇ=NKNR=òÉáÖí=ÇáÉ=ÇáÉ=ÄÉáÇÉå=j∏ÖäáÅÜâÉáíÉå= ÇÉê=c~êÄ~ìëï~ÜäW== táêÇ= Ç~ë= å~ÅÜ= ìåíÉå= ÖÉêáÅÜíÉíÉ= aêÉáÉÅâ= áå= ÇÉê= wÉáäÉ= Color= ~åÖÉâäáÅâíI= ∏ÑÑåÉí= ëáÅÜ=ÉáåÉ=iáëíÉ=ãáí=c~êÄJk~ãÉåK=wìÉêëí=âçããÉå=ÇáÉ=dêìåÇÑ~êÄÉåI=å~ÅÜ=eÉääáÖJ âÉáí=ÖÉçêÇåÉíK==
V =
N= _ÉåìíòÉêçÄÉêÑä®ÅÜÉå= ^åëÅÜäáÉ≈ÉåÇ= ëáåÇ= ëéÉòáÉääÉ= c~êÄÉå= EòK_K= clMenuText= çÇÉê= clInfoTextF= ~ìÑÖÉäáëJ íÉíI= ÇáÉ= áåòïáëÅÜÉå= ÑΩê= ÄÉëíáããíÉ= _ÉÇáÉåÉäÉãÉåíÉ= çÇÉê= _ÉÇáÉåëáíì~íáçåÉå= íóJ éáëÅÜ=ìåÇ=ΩÄäáÅÜ=ÖÉïçêÇÉå=ëáåÇK== báå=ëÅÜåÉääÉê=açééÉäâäáÅâ=áå=Ç~ë=fååÉêÉ=ÇÉë=cÉåëíÉêë=êÉÅÜíë=åÉÄÉå= Color=Ç~ÖÉJ ÖÉå= ∏ÑÑåÉí= ÉáåÉ= m~äÉííÉ= òìê= c~êÄ~ìëï~ÜäK= aáÉ= ÖÉòÉáÖíÉå= dêìåÇÑ~êÄÉå= â∏ååÉå= ëçÑçêí=~ìëÖÉï®Üäí=ïÉêÇÉåI=ÄÉäáÉÄáÖÉ=ïÉáíÉêÉ=c~êÄÉå=â∏ååÉå=Ç~òì=ãáí=eáäÑÉ=ÇÉê= pÅÜ~äíÑä®ÅÜÉ= Farben definieren >> =ÑÉëíÖÉäÉÖí=ïÉêÇÉåK==
= _áäÇ=NKNRW=c~êÄJsçêÉáåëíÉääìåÖ=
1.2.2
Test des Formulars
aáÉ=ãÉáëíÉå=báÖÉåëÅÜ~ÑíÉåI=ÇáÉ=ïáê=ãáí=eáäÑÉ=ÇÉë=lÄàÉâíáåëéÉâíçêë=îçêÉáåëíÉääÉåI= ïÉêÇÉå=ìåëI=ïáÉ=áå=ÉáåÉê= sçêëÅÜ~ìI=~ìÅÜ=ëÅÜçå=ëáÅÜíÄ~ê=~åÖÉòÉáÖíK=^ääÉêÇáåÖë= åáÅÜí=~ääÉ=Ó=ïΩêÇÉ=ìåë=ÄÉáëéáÉäëïÉáëÉ=Ç~ë=ã~ñáã~äÉ=cÉåëíÉê=ï®ÜêÉåÇ=ÇÉê=båíJ ïìêÑëí®íáÖâÉáí=ëÅÜçå=ÉáåÖÉëíÉääíI=â∏ååíÉå=ïáê=åáÅÜíë=^åÇÉêÉë=ãÉÜê=ëÉÜÉåK= aáÉ=ÉåÇÖΩäíáÖÉ=hçåíêçääÉI=ïáÉ=ëáÅÜ=Ç~ë=cçêãìä~ê=ëÅÜäáÉ≈äáÅÜ=ÇÉã=kìíòÉê=Ç~êëíÉäJ äÉå=ïáêÇI=äáÉÑÉêí=ÇáÉ=eÉêëíÉääìåÖ=ÇÉë=cçêãìä~êëI=áåÇÉã=ÇáÉ=ëç=ÖÉå~ååíÉ=i~ìÑòÉáí= ÖÉëí~êíÉí=ïáêÇ=Ó=ã~å=ë~Öí=~ìÅÜI=Éë=łïáêÇ=~ìëÖÉÑΩÜêí=çÇÉê=łÇáÉ=^ìëÑΩÜêìåÖ=ïáêÇ= ÖÉëí~êíÉíK== a~òì=ïáêÇ=ÉåíïÉÇÉê=ÇáÉ=q~ëíÉ= F9 =ÄÉí®íáÖí=çÇÉê=ãáí=ÇÉê=äáåâÉå=j~ìëí~ëíÉ=~ìÑ= Ç~ë=å~ÅÜ=êÉÅÜíë=ÖÉêáÅÜíÉíÉ=ÖêΩåÉ=aêÉáÉÅâ=E_áäÇ=NKNSF=ÖÉâäáÅâíK==
== _áäÇ=NKNSW=pí~êí=ÇÉê=i~ìÑòÉáíI=eÉêëíÉääìåÖ=ÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ= NM= =
NKO== cçêãìä~ê= cΩê= ÇáÉ= oΩÅââÉÜê= òìã= båíïìêÑëãçÇìë= E~ìÅÜ= ~äë= båíïìêÑëéÜ~ëÉ= çÇÉê= âìêò= ~äë= båíïìêÑ= ÄÉòÉáÅÜåÉíF= ãìëë= ÇáÉ= i~ìÑòÉáí= ÄÉÉåÇÉí= ïÉêÇÉå= Ó= áå= ÇÉê= péê~ÅÜÉ= îçå= aÉäéÜá=ULOMMR=ÜÉá≈í=Ç~ëI=Ç~ëë=ïáê=ìåë=ÇÉå=aÉëáÖåÉê=ïáÉÇÉê=~åòÉáÖÉå=ä~ëëÉåK=== aáÉ= i~ìÑòÉáí= ä®ëëí= ëáÅÜ= ÄÉÉåÇÉåI= áåÇÉã= ~ã= cçêãìä~ê= Ç~ë= pÅÜäáÉ≈âêÉìò= êÉÅÜíë= çÄÉå=~åÖÉâäáÅâí=ïáêÇ=çÇÉê=ÇáÉ=q~ëíÉåâçãÄáå~íáçå= Alt =H= F4 =ÖÉï®Üäí=ïáêÇK=== pçääíÉ= Ç~åå= ~åëíÉääÉ= ÇÉê= ÖÉê~ëíÉêíÉå= båíïìêÑëÑçêã= ÇÉë= cçêãìä~êë= Éáå= ~åÇÉêÉë= cÉåëíÉê= EòK= _K= ãáí= mêçÖê~ããíÉñíF= òì= ëÉÜÉå= ëÉáåI= â~åå= ãáí= = F12= = çÇÉê= ãáí= ÉáåÉê= pÅÜ~äíÑä®ÅÜÉ=EëK=_áäÇ=NKNTF=òìã=båíïìêÑ=ÇÉë=cçêãìä~êë=ÖÉïÉÅÜëÉäí=ïÉêÇÉåK=
=== _áäÇ=NKNTW=oΩÅââÉÜê=òìã=cçêãìä~ê=áå=aÉäéÜá=ULOMMR=ÄòïK=aÉäéÜá=T= fã= båíïìêÑ= â~åå= Ç~åå= ïÉáíÉê= ~å= ÇÉê= sçêÄÉêÉáíìåÖ= ÇÉë= cçêãìä~êë= ÖÉ~êÄÉáíÉí= ïÉêÇÉåK= bêëÅÜÉáåìåÖëãÉêâã~äÉI= ÇáÉ= åáÅÜí= ÖÉÑ~ääÉå= Ü~ÄÉåI= â∏ååÉå= âçêêáÖáÉêí= ïÉêÇÉåI=ìåÇ=Éë=ëçääíÉ=îçê=~ääÉã=ÇìêÅÜ=péÉáÅÜÉêìåÖ=ÇÉê=ÄáëÜÉêáÖÉ=_É~êÄÉáíìåÖëJ ëí~åÇ=ÖÉëáÅÜÉêí=ïÉêÇÉåK=
= _áäÇ=NKNUW=aÉäéÜáJULOMMRJjÉåΩ=a^qbf=ãáí=péÉáÅÜÉêã∏ÖäáÅÜâÉáíÉå==
1.2.3
Speicherung
aáÉ=®äíÉêÉå=sÉêëáçåÉå=îçå=aÉäéÜá=ìåÇ=îçê=~ääÉã=Ç~åå=aÉäéÜá=ULOMMR=ëáåÇ=äÉáëJ íìåÖëÑ®ÜáÖÉ= båíïáÅâäìåÖëëóëíÉãÉI= ÑçäÖäáÅÜ= ïáêÇ= ÉáåÉ= ÉáåòáÖÉ= a~íÉá= òìã= péÉáJ ÅÜÉêå=âÉáåÉëÑ~ääë=~ìëêÉáÅÜÉåK=dêìåÇë®íòäáÅÜ=ëçääíÉ=ëíÉíë=îÉê~åä~ëëí=ïÉêÇÉåI=Ç~ëë= Ç~ë=aÉäéÜáJpóëíÉã=ëíÉíë=~ääÉë=ëéÉáÅÜÉêíK== NN =
N= _ÉåìíòÉêçÄÉêÑä®ÅÜÉå= a~òì=ÖáÄí=Éë=áã=jÉåΩ=a^qbf=~ääÉê=aÉäéÜáJsÉêëáçåÉå=ëéÉòáÉää=Ç~ë=^åÖÉÄçí=^iibp= pmbf`ebokK= _áäÇ= NKNU= òÉáÖí= Ç~ë= jÉåΩ= a^qbf= îçå= aÉäéÜá= ULOMMRK= få= ®äíÉêÉå= aÉäJ éÜáJsÉêëáçåÉå=ÖáÄí=Éë=Ç~òì=âÉáåÉå=ïÉëÉåíäáÅÜÉå=råíÉêëÅÜáÉÇK== _Éáã=ÉêëíÉå=j~ä=îçå=^iibp= pmbf`ebok=ãΩëëÉå=ïáê=ëíÉíë=òïÉá=îÉêëÅÜáÉÇÉåÉ=a~íÉáJ å~ãÉå=ëÉäÄÉê=îçêÖÉÄÉåW== ^äë= bêëíÉë= îÉêä~åÖí= aÉäéÜá= å®ãäáÅÜ= åçÅÜ= åáÅÜí= ÇÉå= k~ãÉå= ÑΩê= Ç~ë= Ö~åòÉ= mêçJ àÉâíI=ëçåÇÉêå=Éêëí=Éáåã~ä=åìê=ÇÉå=k~ãÉå=ÑΩê=ÇáÉ=a~íÉáI=ÇáÉ=Ç~ë=cçêãìä~ê=ëéÉáJ ÅÜÉêíK= a~= ÇáÉ= éêçÖê~ããíÉÅÜåáëÅÜÉ= _ÉòÉáÅÜåìåÖ= ÑΩê= ÇÉå= qÉñíI= ÇÉê= áååÉêÜ~äÄ= ÇÉë= mêçàÉâíë= ÇáÉ= ^åÖ~ÄÉå= òìã= cçêãìä~ê= ëéÉáÅÜÉêíI= ãáí= ÇÉê= sçâ~ÄÉä= Unit= ÄÉJ ÖáååíI=ëçääíÉ=ëáÅÜ=òïÉÅâã®≈áÖ=ÇÉê=k~ãÉ=ÇÉê=cçêãìä~êJa~íÉá=îçã=mêçàÉâíå~ãÉå= ÇìêÅÜ=Éáå=~åÖÉÜ®åÖíÉë=łì=ìåíÉêëÅÜÉáÇÉåK== pçää=òìã=_ÉáëéáÉä=Ç~ë=ÖÉë~ãíÉ=ÉêëíÉ=mêçàÉâí=ìåíÉê= ÇÉã=k~ãÉå= kap01=ÖÉëáÅÜÉêí= ïÉêÇÉåI=ÉãéÑáÉÜäí=ëáÅÜ=ÑΩê=ÇáÉ=cçêãìä~êJa~íÉá=ÇÉê=k~ãÉ=kap01uK= bêëí=~åëÅÜäáÉ≈ÉåÇ=îÉêä~åÖí=aÉäéÜá=ÇÉå=k~ãÉå=ÑΩê=Ç~ë=Ö~åòÉ=mêçàÉâíK=eáÉê=ï®êÉ= áå=ìåëÉêÉã=c~ää= kap01=ëáååîçääK=aáÉ=àÉïÉáäáÖÉå=båÇìåÖÉå=ÉêÖ®åòí=aÉäéÜá=ëÉäÄëíJ í®íáÖK==== _áäÇ=NKNV=ä®ëëí=ÉêâÉååÉåI=Ç~ëë=aÉäéÜá=U=ìåÇ=Éêëí=êÉÅÜí=aÉäéÜá=OMMR=ãáí=ÇÉå=òïÉá= îÉêÖÉÄÉåÉå=k~ãÉå=ëçÑçêí=ÉáåÉ=cΩääÉ=~å=a~íÉáÉå=~åÖÉäÉÖí=Ü~í=Ó=~ìÅÜ=ïÉåå=Ç~ë= mêçàÉâí=ÄáëÜÉê=äÉÇáÖäáÅÜ=Éáå=ÉáåòáÖÉë=cçêãìä~ê=ÉåíÜ®äíK==
=== _áäÇ=NKNVW=a~íÉáÉå=ÇÉë=mêçàÉâíëI=îçå=aÉäéÜá=U=ÄòïK=aÉäéÜá=OMMR=~åÖÉäÉÖí= aáÉ=®äíÉêÉå=sÉêëáçåÉå=îçå=aÉäéÜá=äÉÖÉå=éêç=mêçàÉâí=~ìÅÜ=ãÉÜêÉêÉ=a~íÉáÉå=~åI= ÑΩê=ëáÉ=Öáäí=Ç~ë=dÉë~ÖíÉ=ÉÄÉåëçK== ^ääÉêÇáåÖë=J=ÇáÉ= bdsprojJa~íÉáÉå=ÖáÄí=Éë=áå=ÇÉå=®äíÉêÉå=aÉäéÜáJsÉêëáçåÉå=åáÅÜíK= aÉëÜ~äÄ=ãΩëëÉå=ïáê=ìåíÉêëÅÜÉáÇÉåW== • aáÉ=ÉåíëÅÜÉáÇÉåÇÉ=a~íÉá=ÑΩê=Éáå=aÉäéÜáJTJmêçàÉâí=EçÇÉê=Éáå=mêçàÉâí=ÉáåÉê=åçÅÜ= ®äíÉêÉå=aÉäéÜáJsÉêëáçåF=áëí=áããÉê=ÇáÉ=mêçàÉâíJa~íÉá=ãáí=ÇÉê=båÇìåÖ=.dprK== • aáÉ=ÉåíëÅÜÉáÇÉåÇÉ=a~íÉá=ÑΩê=Éáå=aÉäéÜáJULOMMRJmêçàÉâí=áëí=áããÉê=ÇáÉ=mêçàÉâíJ a~íÉá=ãáí=ÇÉê=båÇìåÖ=.bdsprojK==
NO= =
NKP== píÉìÉêÉäÉãÉåíÉ=ÑΩê=Ç~ë=cçêãìä~ê= tÉåå= ëé®íÉê= ãáííÉäë= a^qbfmolgbhq= £cckbk= Éáå= îçêÜ~åÇÉåÉë= mêçàÉâí= ÖÉ∏ÑÑåÉí= ïÉêÇÉå= ëçääI= ïÉêÇÉå= áå= ÇÉã= ÉåíëéêÉÅÜÉåÇÉå= ^ìëï~ÜäJcÉåëíÉê= E_áäÇ= NKOMF= îçå= ÇÉå=îáÉäÉå=a~íÉáÉå=ÇÉë=mêçàÉâíÉë=çÜåÉÜáå=åìê=ÇáÉ=mêçàÉâíÇ~íÉáÉå=ëçïáÉ=ÇáÉ=cçêJ ãìä~êJa~íÉáEÉåF=òìê=^ìëï~Üä=~åÖÉÄçíÉåK== a~åå= ëçääíÉ= Ç~åå= áããÉê= ÇáÉ= dprJa~íÉá= EÑΩê= sÉêëáçåÉå= Äáë= aÉäéÜá= TF= ÄòïK= ÇáÉ= bdsprojJa~íÉá=ÇÉë=mêçàÉâíë=~ìëÖÉï®Üäí=ïÉêÇÉåK==
== _áäÇ=NKOMW=^åÖÉÄçí=ÄÉá=a^qbfJ[molgbhq=£cckbk=áå=aÉäéÜá=T=ÄòïK=ULOMMR=
1.3
Steuerelemente für das Formular
1.3.1
Auswahl mit Delphi 8/2005
táÉ= ÄÉâçããí= ã~å= òìã= _ÉáëéáÉä= ÉáåÉå= _ìííçå= EpÅÜ~äíÑä®ÅÜÉFI= ÉáåÉ= pÅêçääÄ~ê= EpÅÜáÉÄÉêÉÖäÉêFI=Éáå=qÉñíÑÉåëíÉê=çÇÉê=~ää=ÇáÉ=~åÇÉêÉå=_ÉÇáÉåÉäÉãÉåíÉI=~å=ÇáÉ=ïáê= áåòïáëÅÜÉå= ÖÉï∏Üåí= ëáåÇ= ìåÇ= ãáí= ÇÉåÉå= ïáê= ÉáåÉ= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= ÖÉëí~äíÉå= ïçääÉåI=áã=båíïìêÑ=~ìÑ=Ç~ë=cçêãìä~ê\== tÉåå= ïáê= ãáí= aÉäéÜá= ULOMMR= ~êÄÉáíÉåI= ÄÉå∏íáÖÉå= ïáê= ÜáÉêòì= ÇáÉ= qççäJm~äÉííÉI= ÇáÉ= áå= ãÉÜêÉêÉå= h~íÉÖçêáÉå= EëK= _áäÇ= NKONF= ~ääÉ= ^êíÉå= îçå= píÉìÉêÉäÉãÉåíÉ= òìê= sÉêÑΩÖìåÖ=ëíÉääíI=ÇáÉ=ã~å=ëáÅÜ=ÑΩê=ÜÉìíáÖÉ=^åïÉåÇìåÖÉå=ïΩåëÅÜÉå=â~ååK===
=== _áäÇ=NKONW=qççäJm~äÉííÉ=îçå=aÉäéÜá=U= báåÉ= h~íÉÖçêáÉ= ïáêÇ= ÉåíïÉÇÉê= ΩÄÉê= ÇÉå= táåâÉä= åÉÄÉå= = Kategorien= = çÇÉê= ÇìêÅÜ= häáÅâ=~ìÑ=ÇÉå=açééÉäïáåâÉä=åÉÄÉå=ÇÉã=àÉïÉáäáÖÉå=h~íÉÖçêáÉå~ãÉå=~ìëÖÉï®ÜäíK==
NP =
N= _ÉåìíòÉêçÄÉêÑä®ÅÜÉå=
1.3.2
Auswahl mit älteren Delphi-Versionen
få= aÉäéÜá= T= ìåÇ= ÑêΩÜÉêÉå= sÉêëáçåÉå= îçå= aÉäéÜá= ëáåÇ= Ç~ÖÉÖÉå= ÇáÉ= póãÄçäÉ= ÑΩê= ÇáÉ=píÉìÉêÉäÉãÉåíÉ=áå=oÉÖáëíÉêÄä®ííÉêå=~ìÑ=ÇÉê=hçãéçåÉåíÉåäÉáëíÉ=E_áäÇ=NKOOF=~åJ ÖÉçêÇåÉíK==
1.3.3
Wichtige Kategorien bzw. Registerblätter
få=aÉäéÜá=ULOMMR= ïáêÇ=îçå= h~íÉÖçêáÉå=áå=ÇÉê=qççäJm~äÉííÉ=ÖÉëéêçÅÜÉåI=áå= ®äíÉJ êÉå=aÉäéÜáJsÉêëáçåÉå=Ç~ÖÉÖÉå=îçå=oÉÖáëíÉêÄä®ííÉêå=ÇÉê=hçãéçåÉåíÉåäÉáëíÉK=fåJ Ü~äíäáÅÜ=ÖáÄí=Éë=~ÄÉê=âÉáåÉ=råíÉêëÅÜáÉÇÉK== = _áäÇ=NKOOW=hçãéçåÉåíÉåäÉáëíÉ=îçå=aÉäéÜá=T== cΩê=ìåë=ïáêÇ=Ü~ìéíë®ÅÜäáÅÜ=ÇáÉ=h~íÉÖçêáÉ=ÄòïK=Ç~ë=oÉÖáëíÉêÄä~íí=pq^ka^oa=ÄÉJ ÇÉìíë~ã= ëÉáå= E_áäÇÉê= NKOP= ìåÇ= NKOQFX= Ççêí= ÄÉÑáåÇÉå= ëáÅÜI= ïáÉ= ïáê= ÖäÉáÅÜ= ëÉÜÉå= ïÉêÇÉåI=ÇáÉ=ÖêìåÇë®íòäáÅÜÉå=_ÉÇáÉåìåÖëÉäÉãÉåíÉK== t®ÜêÉåÇ= ÄÉá= aÉäéÜá= ULOMMR= åÉÄÉå= ÇÉã= àÉïÉáäáÖÉå= páååÄáäÇ= ÉáåÉ= _ÉëÅÜêáÑíìåÖ= îçêÖÉåçããÉå=ïìêÇÉI= ãìëë= ã~å=ÄÉá= ÑêΩÜÉêÉå=aÉäéÜáJsÉêëáçåÉå=ÇáÉ=ÄÉêΩÜãíÉ= pÉâìåÇÉ=ï~êíÉåI=Äáë=Ç~ë=âäÉáåÉ=ÖÉäÄÉ=cÉåëíÉê=~ìÑÄäÉåÇÉí=ìåÇ=ìåë=ΩÄÉê=ÇáÉ=_ÉJ ÇÉìíìåÖ=ÇÉë=póãÄçäë=áåÑçêãáÉêíK==
=== _áäÇ=NKOPW=h~íÉÖçêáÉ=pq^ka^oa=áå=aÉäéÜá=ULOMMR=
= _áäÇ=NKOQW=oÉÖáëíÉêÄä~íí=pq^ka^oa=áå=aÉäéÜá=T=ìåÇ=ÑêΩÜÉêÉå=sÉêëáçåÉå== ^ìë=ÇÉê=h~íÉÖçêáÉLÇÉã=oÉÖáëíÉêÄä~íí=pvpqbj=ïÉêÇÉå=ïáê=~Ä=h~éáíÉä=S=ÇÉå=ïáÅÜJ íáÖÉå=Timer=ÄÉå∏íáÖÉå=ìåÇ=~ìë=ÇÉê=h~íÉÖçêáÉ=wrpûqwif`e=ÉåíåÉÜãÉå=ïáê=áã=^ÄJ ëÅÜåáíí=TKQKQ=Ç~ë=bäÉãÉåí=Image=ìåÇ=áã=^ÄëÅÜåáíí=NMKNKO=Ç~ë=bäÉãÉåí=ShapeK===
NQ= =
NKQ== _~ëáëÉäÉãÉåíÉ=
1.4
Basiselemente
1.4.1
Von Button bis Scrollbar
fã= _áäÇ= NKOR= ëáåÇ= ÇáÉ= páååÄáäÇÉê= ~ìë= ÇÉê= h~íÉÖçêáÉ= ÄòïK= ÇÉã= oÉÖáëíÉêÄä~íí= pq^ka^oa=îçå=aÉäéÜá=ÜÉêîçêÖÉÜçÄÉåI=ãáí=ÇÉåÉå=ïáê=ÇáÉ=ëÉÅÜë=ÖêìåÇäÉÖÉåÇÉå= _ÉÇáÉåìåÖëÉäÉãÉåíÉ= pÅÜ~äíÑä®ÅÜÉ= E_ìííçåFI= qÉñíÑÉåëíÉê= EbÇáíFI= g~JkÉáåJléíáçå= E`ÜÉÅâÄçñFI= ÉñâäìëáîÉ= g~JkÉáåJléíáçå= Eo~Çáç_ìííçåFI= qÉñí~åòÉáÖÉ= Ei~ÄÉäF= ìåÇ= pÅÜáÉÄÉêÉÖäÉê=EpÅêçääÄ~êF=~ìëï®ÜäÉå=â∏ååÉåK=_áäÇ=NKOS=òÉáÖí=ÇáÉëÉ=bäÉãÉåíÉ=~ìÑ= ÇÉã=cçêãìä~êI=ÄáëÜÉê=åçÅÜ=çÜåÉ=ïÉáíÉêÉ=sçêÉáåëíÉääìåÖÉåK=====
== _áäÇ=NKORW=páååÄáäÇÉê=ÑΩê=ÇáÉ=ëÉÅÜë=_~ëáëÉäÉãÉåíÉ==
= _áäÇ=NKOSW=_ÉÇáÉåìåÖëÉäÉãÉåíÉ=~ìÑ=ÇÉã=cçêãìä~ê= cΩê=ÇÉå=ïÉáíÉêÉå=péê~ÅÜÖÉÄê~ìÅÜ=ÑçäÖÉå=ïáê=ÇÉã=qêÉåÇW=kìê=ÑΩê=Ç~ë=qÉñíÑÉåëJ íÉê= ïÉêÇÉå= ïáê= ïÉáíÉêÜáå= ÇáÉ= ÇÉìíëÅÜÉ= _ÉòÉáÅÜåìåÖ= îÉêïÉåÇÉå= Eã~åÅÜã~ä= ïáêÇ=ëáÅÜ=~ìÅÜ=qÉñíÄçñ=ÉáåëÅÜäÉáÅÜÉåFK== ^åëçåëíÉå=ëéêÉÅÜÉå=ïáê=îçå=ÉáåÉã=i~ÄÉäI=ÉáåÉê=`ÜÉÅâÄçñI=ÉáåÉã=_ìííçåI=ÉáåÉê= pÅêçääÄ~ê=ìåÇ=ÉáåÉã=o~ÇáçÄìííçåK=a~åå=ÄäÉáÄÉå=ïáê=ãáí=ìåëÉêÉê=péê~ÅÜÉ=~ìÅÜ= ÖäÉáÅÜ= å~ÜÉ= ÄÉá= ÇÉå= pí~åÇ~êÇJk~ãÉåI= ÇáÉ= aÉäéÜá= ëçïáÉëç= ÑΩê= ÇáÉëÉ= _ÉÇáÉJ åìåÖëÉäÉãÉåíÉ=îÉêÖáÄíK==
NR =
N= _ÉåìíòÉêçÄÉêÑä®ÅÜÉå= aáÉ=mä~íòáÉêìåÖ=~ìÑ=ÇÉã= cçêãìä~ê=áëí= ÇÉåâÄ~ê=ÉáåÑ~ÅÜW=jáí=ÇÉê= j~ìë=ïáêÇ=Ç~ë= póãÄçä=~ìë=ÇÉê=h~íÉÖçêáÉ=ÄòïK=îçã=oÉÖáëíÉêÄä~íí=~å=ÇáÉ=ÖÉïΩåëÅÜíÉ=píÉääÉ=ÖÉJ òçÖÉåI=ÇáÉ=dê∏≈É=ïáêÇ=ÉáåÖÉêáÅÜíÉíI=ÑÉêíáÖK== fã= ëÉäÄÉå= jçãÉåí= ëíÉääí= ëáÅÜ= ~ìÅÜ= ÄÉêÉáíë= ÇÉê= lÄàÉâíáåëéÉâíçê= ~ìÑ= Ç~ë= ëçÉÄÉå= éä~íòáÉêíÉ=_ÉÇáÉåìåÖëÉäÉãÉåí=ÉáåI=íÉáäí=ÇÉëëÉå=îçã=aÉäéÜáJpóëíÉã=îçêÖÉëÅÜä~ÖÉJ åÉå=k~ãÉå=ãáí=ìåÇ=ÄáÉíÉí=ÇÉå=h~í~äçÖ=~ääÉê=báÖÉåëÅÜ~ÑíÉå=~åI=ÇáÉ=ÑΩê=ÇáÉ=i~ìÑJ òÉáí=~åÑ~åÖë=îçêÉáåÖÉëíÉääí=ïÉêÇÉå=â∏ååÉåK===
1.4.2
Name, Beschriftung, Inhalt
få=ÇÉã=^ìÖÉåÄäáÅâI=áå=ÇÉã=ïáê=áã=båíïìêÑ=Éáå=píÉìÉêJ=çÇÉê=_ÉÇáÉåÉäÉãÉåí=~ìÑ= ÇÉã= cçêãìä~ê= éä~íòáÉêÉåI= ãìëë= Éë= ÉáåÉå= k~ãÉå= ÄÉâçããÉåK= aáÉëÉê= k~ãÉ= áëí= _Éëí~åÇíÉáä=ÇÉê=áåíÉêåÉå=lêÖ~åáë~íáçå=ÇÉë=ÖÉë~ãíÉå=aÉäéÜáJmêçàÉâíëK== • aÉäéÜá=ëÅÜä®Öí=ìåë=ÑΩê=àÉÇÉë=píÉìÉêÉäÉãÉåí=ëçÑçêí=~ìíçã~íáëÅÜ=ÉáåÉå=k~ãÉå= îçêK== cΩê= ÇáÉ= _ìííçåë= ïáêÇ= Button1I= Button2= ìëïK= îçêÖÉëÅÜä~ÖÉåI= ÑΩê= ÇáÉ= qÉñíÑÉåëíÉê= äÉëÉå=ïáê=Edit1I=Edit2=ìëïKI=ÑΩê=`ÜÉÅâÄçñÉå=ïáêÇ=ìåë=Checkbox1I=Checkbox2=ìëïK= îçêÖÉëÅÜä~ÖÉåI= ÑΩê= o~ÇáçÄìííçåë= ä~ìíÉí= ÇÉê= aÉäéÜáJsçêëÅÜä~Ö= Radiobutton1I= Radiobutton2= ìëïKI= ìåÇ= àÉÇÉ= pÅêçääÄ~ê= ïáêÇ= Éêëí= Éáåã~ä= ãáí= ÇÉã= ÉåíëéêÉÅÜÉåÇÉå= k~ãÉå=Scrollbar1=ìëïK=îÉêëÉÜÉåK=== aÉå=aÉäéÜáJk~ãÉåëîçêëÅÜä~Ö=â∏ååÉå=ïáê=ëçïçÜä=ÑÉííÖÉÇêìÅâí=áå=ÇÉê=hçéÑòÉáäÉ= ÇÉë=òìÖÉÜ∏êáÖÉå=lÄàÉâíáåëéÉâíçêë=~äë=~ìÅÜ=áå=ÇÉê=wÉáäÉ=Name=äÉëÉå=E_áäÇ=NKOTFK==
=== _áäÇ=NKOTW=aÉäéÜá=ëÅÜä®Öí=ÉáåÉå=k~ãÉå=ÑΩê=Éáå=_ÉÇáÉåÉäÉãÉåí=îçê= k~íΩêäáÅÜ=ãìëë=ÇÉê=aÉäéÜáJk~ãÉåëîçêëÅÜä~Ö=åáÅÜí=~âòÉéíáÉêí=ïÉêÇÉåX=ïáê=â∏ååJ íÉå= ìåîÉêòΩÖäáÅÜ= áã= lÄàÉâíáåëéÉâíçê= ÇáÉ= báÖÉåëÅÜ~Ñí= Name= ~åÇÉêëI= áåÇáîáÇìÉää= ÄÉäÉÖÉåK=aÉäéÜá=ïΩêÇÉ=~ìÅÜ=ÇÉå=îçå=ìåë=îÉêÖÉÄÉåÉå=k~ãÉå=~âòÉéíáÉêÉå=Ó=ëçJ ÑÉêå=ëÉáå=^ìÑÄ~ì=ÖÉïáëëÉå=oÉÖÉäå=ÖÉåΩÖíK== açÅÜ= ÑΩê= ÇÉå= ^åÑ®åÖÉê= ÉêÖáÄí= ëáÅÜ= Ç~ãáí= ÉáåÉ= ïÉáíÉêÉ= pÅÜïáÉêáÖâÉáí= ìåÇ= cÉÜJ äÉêèìÉääÉI=~ì≈ÉêÇÉã=â~åå=äÉáÅÜí=ÇáÉ=§ÄÉêëáÅÜí=îÉêäçêÉå=ïÉêÇÉåK== NS= =
NKQ== _~ëáëÉäÉãÉåíÉ= • aÉëïÉÖÉå=ïáêÇ=áå=ÇáÉëÉã=_ìÅÜ=Eãáí=^ìëå~ÜãÉ=ÉáåÉê=ÉáåòáÖÉå=píÉääÉ=áã=^ÄJ ëÅÜåáíí=NPKQKPF=ÖÉåÉêÉää=ÉãéÑçÜäÉåI=ÇáÉ=k~ãÉåëîçêëÅÜä®ÖÉ=îçå=aÉäéÜá=òì=~âJ òÉéíáÉêÉå=ìåÇ=ãáí=ÇÉå=aÉäéÜáJk~ãÉå=òì=~êÄÉáíÉåK== ^ìÑ=ÉáåÉ=_ÉëçåÇÉêÜÉáí=ãìëë=àÉÇçÅÜ=ìåÄÉÇáåÖí=ÜáåÖÉïáÉëÉå=ïÉêÇÉåW=tÉåå=aÉäJ éÜá=ÉáåÉå=k~ãÉå=ÑΩê=Éáå=_ÉÇáÉåìåÖëÉäÉãÉåí=îçêëÅÜä®Öí=ìåÇ=áå=ÇáÉ=wÉáäÉ= Name= Éáåíê®ÖíI=íê®Öí=aÉäéÜá=ÇáÉëÉå=k~ãÉå=~ìíçã~íáëÅÜ=~ìÅÜ=~äë=_ÉëÅÜêáÑíìåÖ=îçå=cçêJ ãìä~êI=_ìííçåI=`ÜÉÅâÄçñI=i~ÄÉä=çÇÉê=o~ÇáçÄìííçå=áå=ÇáÉ=wÉáäÉ= Caption=çÇÉê=~äë= fåÜ~äí=ÉáåÉë=qÉñíÑÉåëíÉêë=áå=ÇáÉ=wÉáäÉ=Text=ÉáåK== a~ë=ÑΩÜêí=ÄÉá=^åÑ®åÖÉêå=ÖÉêå=Ç~òìI=Ç~ëë=ëáÉ=ÇáÉ=^ìÑÖ~ÄÉ=łûåÇÉêÉ=ÇáÉ=pí~êíJ_ÉJ ëÅÜêáÑíìåÖ=çÇÉê=ÇÉå=pí~êíJfåÜ~äí=Ñ~äëÅÜ=Ç~ÇìêÅÜ=ä∏ëÉåI=Ç~ëë=ëáÉ=ÇÉå=k~ãÉå=®åJ ÇÉêåK====
1.4.3
Voreinstellungen
aÉê=lÄàÉâíáåëéÉâíçê=ÉáåÉë=_ìííçåë=E_áäÇ=NKOUF=ÄáÉíÉí=~ää=Ç~ë=~åI=ï~ë=áå=ÇÉê=båíJ ïìêÑëéÜ~ëÉ= ~äë= báÖÉåëÅÜ~Ñí= ÉåíëéêÉÅÜÉåÇ= ÇÉã= ÖÉïΩåëÅÜíÉå= bêëÅÜÉáåìåÖëÄáäÇ= ÄÉáã=pí~êí=ÉáåÖÉëíÉääí=ïÉêÇÉå=â~ååK=aáÉ=ÄÉáÇÉå=ãÉáëíÖÉÄê~ìÅÜíÉå=báÖÉåëÅÜ~ÑíÉå= ëáåÇ=áã=_áäÇ=ÜÉêîçêÖÉÜçÄÉåW=aáÉ=_ÉëÅÜêáÑíìåÖ=ÇÉë=_ìííçåë=ΩÄÉê=Caption=ìåÇ=ÇáÉ= báåëíÉääìåÖ=îçå=pÅÜêáÑíÖê∏≈É=ìåÇ=Óëíáä=ΩÄÉê=FontK=
= _áäÇ=NKOUW=lÄàÉâíáåëéÉâíçê=ÉáåÉë=_ìííçåë=áå=aÉäéÜá=ULOMMR= aáÉ=ÇêÉá=ïáÅÜíáÖëíÉå=wÉáäÉå=ÇÉë=lÄàÉâíáåëéÉâíçêë=ÉáåÉë=qÉñíÑÉåëíÉêë=ëáåÇW== • Text=òìê=sçêÉáåëíÉääìåÖ=ÇÉë=fåÜ~äíë=ÄÉáã=pí~êí=ÇÉê=i~ìÑòÉáíI== • Color=òìê=sçêÉáåëíÉääìåÖ=ÇÉê=cÉåëíÉêÑ~êÄÉ=ìåÇ== • Font=òìê=sçêÉáåëíÉääìåÖ=ÇÉê=pÅÜêáÑíK==== NT =
N= _ÉåìíòÉêçÄÉêÑä®ÅÜÉå= fã=lÄàÉâíáåëéÉâíçê=ÉáåÉê=`ÜÉÅâÄçñ=ëáåÇ=ÄÉëçåÇÉêë=ÜÉêîçêòìÜÉÄÉåW== • ÇáÉ=j∏ÖäáÅÜâÉáí=ÇÉê=c~êÄJsçêï~Üä=ΩÄÉê=ColorI== • ÇáÉ= t~Üä= ÇÉê= pí~êíJ_ÉëÅÜêáÑíìåÖ= ΩÄÉê= Caption= ÉáåëÅÜäáÉ≈äáÅÜ= ÇÉê= pÅÜêáÑí~ìëJ ï~Üä=ãáííÉäë=FontI== • ÇáÉ=j∏ÖäáÅÜâÉáíI=ÇáÉ=`ÜÉÅâÄçñ=ãáí=çÇÉê=çÜåÉ=ÖÉëÉíòíÉå= e~âÉå=EbáÖÉåëÅÜ~Ñí= CheckedF= ~ìÑ= ÇÉê= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= ÄÉáã= pí~êí= ÇÉê= i~ìÑòÉáí= ÉêëÅÜÉáåÉå= òì= ä~ëëÉåK== báå= i~ÄÉä= áëí= Éáå= êÉáåÉë= ^ìëÖ~ÄÉãÉÇáìãX= Éë= ïáêÇ= òìÉêëí= Éáåã~ä= Ç~ÑΩê= ÄÉåìíòíI= ìã=fåÑçêã~íáçåëJqÉñíÉ=~ìÑ=Ç~ë=cçêãìä~ê=òì=ëÅÜêÉáÄÉåK=aÉëÜ~äÄ=â~åå== • ΩÄÉê= ÇáÉ= báÖÉåëÅÜ~Ñí= Transparent= ÉáåÖÉëíÉääí= ïÉêÇÉåI= çÄ= Ç~ë= i~ÄÉä= ÇìêÅÜJ ëÅÜÉáåÉåÇ=áëí=çÇÉê=ÉáåÉå=ÉáÖÉåÉå=eáåíÉêÖêìåÇ=Ü~ÄÉå=ëçääI== • ãáí=Caption=ÇáÉ=pí~êíÄÉëÅÜêáÑíìåÖ=ÖÉï®Üäí=ïÉêÇÉåI== • ãáí=Font=ÇáÉ=pÅÜêáÑí~êíI=ãáí=Color=ÇáÉ=c~êÄÉ=îçêÉáåÖÉëíÉääí=ïÉêÇÉåK=== tÉáíÉêÜáå= ïáêÇ= Ó= áã= dÉÖÉåë~íò= òìã= qÉñíÑÉåëíÉê= Ó= Éáå= i~ÄÉä= áããÉê= Ç~åå= ÄÉJ åìíòíI=ïÉåå=Éáå=kìíòÉê=Éáå=bêÖÉÄåáë=çÜåÉ=ûåÇÉêìåÖëã∏ÖäáÅÜâÉáí=òìê=hÉååíåáë= åÉÜãÉå=ëçääK=få=ÇáÉëÉã=c~ää=â~åå=ΩÄÉê=ÇáÉ=báÖÉåëÅÜ~Ñí= AutoSize=ÉáåÖÉëíÉääí=ïÉêJ ÇÉåI=çÄ=ëáÅÜ=Ç~ë=i~ÄÉä=ÇÉã=~ìëòìÖÉÄÉåÇÉå=fåÜ~äí=áå=ÇÉê=dê∏≈É=~åé~ëëÉå=ëçää= çÇÉê=áããÉê=ÇáÉëÉäÄÉI=áã=båíïìêÑ=îçêÉáåÖÉëíÉääíÉ=dê∏≈É=ÄÉëáíòíK== báå= pÅÜáÉÄÉêÉÖäÉêI= ~ääÖÉãÉáå= ~äë= pÅêçääÄ~ê= ÄÉòÉáÅÜåÉíI= ã~åÅÜã~ä= îçå= hÉååÉêå= ~ìÅÜ=mçíÉåíáçãÉíÉê=ÖÉå~ååíI=áëí=Éáå=ëÉÜê=ïáêâë~ãÉë=_ÉÇáÉåìåÖëÉäÉãÉåíK=aÉåå= ãáí=ëÉáåÉê=eáäÑÉ=â~åå=ã~å=Éáå=jáííÉä=~ìÑ=ÇÉã=cçêãìä~ê=éä~íòáÉêÉåI=ÄÉá=ÇÉã=ÉáåÉ= cÉÜäÄÉÇáÉåìåÖ=ÇìêÅÜ=ÇÉå=kìíòÉê=~Äëçäìí=~ìëÖÉëÅÜäçëëÉå=áëíK== táê=Äê~ìÅÜÉå=ìåë=òìã=_ÉáëéáÉä=åìê=ÉáåÉ=^åïÉåÇìåÖ=îçêòìëíÉääÉåI=ÄÉá=ÇÉê=Éáå= kìíòÉê= åìê= Ö~åòò~ÜäáÖÉ= tÉêíÉ= òïáëÅÜÉå= M= ìåÇ= ORR= EëK= ^ÄëÅÜåáíí= TKNKPF= ÉáåÖÉJ ÄÉå=Ç~êÑK== i~ëëÉå=ïáê=ÇÉå=kìíòÉê=E~ìÅÜ=ãáí=ÉåíëéêÉÅÜÉåÇÉã=eáåïÉáëF=ëÉáåÉå=tÉêí=áå=Éáå= qÉñíÑÉåëíÉê= Éáåíê~ÖÉåI= â∏ååÉå= ïáê= ãáí= ~å= páÅÜÉêÜÉáí= ÖêÉåòÉåÇÉê= t~ÜêëÅÜÉáåJ äáÅÜâÉáí= Ç~îçå= ~ìëÖÉÜÉåI= Ç~ëë= Éê= ~ìë= råâçåòÉåíêáÉêíÜÉáí= çÇÉê= jΩÇáÖâÉáí= çÇÉê= _∏ë~êíáÖâÉáí= ÇçÅÜ= ÄáëïÉáäÉå= Éíï~ë= páååäçëÉë= Éáåíê®ÖíK= báåÉ= cÉÜäÉêãÉäÇìåÖI= ïÉåå=åáÅÜí=ëçÖ~ê=Éáå=mêçÖê~ãã~Äëíìêò=ëáåÇ=ÇáÉ=cçäÖÉåK=cçêÇÉêå=ïáê=ÇÉå=kìíJ òÉê=Ç~ÖÉÖÉå=~ìÑI=áå=ÉáåÉê=pÅêçääÄ~êI=ÇÉêÉå=jáåáãìã=~ìÑ=M=ìåÇ=ÇÉêÉå=j~ñáãìã= ~ìÑ= ORR= îçêÉáåÖÉëíÉääí= ïìêÇÉI= ÇÉå= oÉÖäÉê= ÉáåòìëíÉääÉå= Ó= Ç~= â~åå= Éê= ~Äëçäìí= åáÅÜíë=Ñ~äëÅÜ=ã~ÅÜÉåK== aÉê= lÄàÉâíáåëéÉâíçê= ÇÉê= pÅêçääÄ~ê= äáÉÑÉêí= ïáÉÇÉê= ÇáÉ= ïáÅÜíáÖëíÉå= j∏ÖäáÅÜâÉáíÉå= ÇÉê=sçêÉáåëíÉääìåÖK== • aáÉ=^ìëêáÅÜíìåÖ=ÇÉê=pÅêçääÄ~ê=ïáêÇ=ãáí=ÇÉê=báÖÉåëÅÜ~Ñí=Kind=ÖÉï®ÜäíK== • jáåáãìãI= j~ñáãìã= ìåÇ= pí~êíéçëáíáçå= ÇÉë= oÉÖäÉêë= ÑçäÖÉå= ~ìë= ÇÉå= báÖÉåJ ëÅÜ~ÑíÉå=MinI=Max=ÄòïK=PositionK== NU= =
NKQ== _~ëáëÉäÉãÉåíÉ= • SmallChange= äÉÖí= ÑÉëíI= çÄ= ÇÉê= oÉÖäÉê= áå= âäÉáåÉå= çÇÉê= Öêç≈Éå= pÅÜêáííÉå= łëéêáåÖíI= ïÉåå= ÇÉê= kìíòÉê= ÇáÉ= dêáÑÑÉ= ~å= ÇÉå= pÉáíÉå= ÇÉê= pÅêçääÄ~ê= ãáí= ÇÉê= j~ìë=ÄÉí®íáÖíK== báå= o~ÇáçÄìííçå= ~ääÉáå= áëí= ÉáÖÉåíäáÅÜ= ëáååäçëK= aÉåå= ÇÉê= kìíòÉê= â~åå= áÜå= òï~ê= łÉáåëÅÜ~äíÉå=EÑ~ääë=Éê=åáÅÜí=ëçÖ~ê=ëÅÜçå=ÇáÉëÉ=pí~êíÉáÖÉåëÅÜ~Ñí=ΩÄÉê= Checked=ÄÉJ âçããÉå=Ü~ííÉFI=~ÄÉê=Éê=â~åå=áÜå=åáÉ=ïáÉÇÉê=ł~ìëëÅÜ~äíÉåK=^ìë=táåÇçïë=áëí=Éë= ìåë= ~ääÖÉãÉáå= ÄÉâ~ååíW= o~ÇáçÄìííçåë= íêÉíÉå= ÉáÖÉåíäáÅÜ= áããÉê= áå= dêìééÉå= ~ìÑK= fååÉêÜ~äÄ=ÇÉê=dêìééÉå=â~åå=ÇÉê=kìíòÉê=Ç~åå=ìãëÅÜ~äíÉåK==
= _áäÇ=NKOV=póãÄçä=òìê=dêìééáÉêìåÖ=îçå=o~ÇáçÄìííçåë=áå=aÉäéÜá=ULOMMR=
= _áäÇ=NKPM=póãÄçä=òìê=dêìééáÉêìåÖ=îçå=o~ÇáçÄìííçåë=áå=aÉäéÜá=T= rã=ëçäÅÜÉ=dêìééÉå=îçå=o~ÇáçÄìííçåë=~ìÑ=ÇÉã=cçêãìä~ê=òì=éä~íòáÉêÉåI=ÄÉå∏íáÖí= ã~å=òìÉêëí=~ìë=ÇÉê=h~íÉÖçêáÉ=ÄòïK=ÇÉã=oÉÖáëíÉêÄä~íí=pq^ka^oa=ÉáåÉå=o~ÜãÉå= E_áäÇÉê=NKOV=ìåÇ=NKPMFK== ^å= ÉáåÉã= ëçäÅÜÉå= o~ÜãÉåI= ÇÉê= îçå= aÉäéÜá= ãáí= ÇÉã= k~ãÉå= GroupBox1= ìëïK= îÉêëÉÜÉå=ïáêÇI=â~åå=å~íΩêäáÅÜ=~ìÅÜ=ΩÄÉê=ÇÉå=lÄàÉâíáåëéÉâíçê=ÇáÉ=_ÉëÅÜêáÑíìåÖ= ãáí= Caption=ìåÇ= Font=ëçïáÉ=ÇáÉ=eáåíÉêÖêìåÇÑ~êÄÉ=ãáí= Color=îçêÉáåÖÉëíÉääí=ïÉêJ ÇÉåK= ^åëÅÜäáÉ≈ÉåÇ= ïÉêÇÉå= Ç~åå= ÇáÉ= o~ÇáçÄìííçåë= áå= ÇÉåLÇáÉ= o~ÜãÉå= ÜáåÉáåJ ÖÉòçÖÉåK=rãÖÉâÉÜêí=ÖÉÜí=Éë=åáÅÜíK== _áäÇ=NKPN=òÉáÖí=ìåë=ÉáåÉ=dêìééÉ=îçå=o~ÇáçÄìííçåëI=ÇáÉ=ãáí=áÜêÉå=_ÉëÅÜêáÑíìåÖÉå= áå=ÇÉã=o~ÜãÉå=~åÖÉçêÇåÉí=ïìêÇÉåK=aÉê=çÄÉêëíÉ=o~ÇáçÄìííçå=íê®Öí=ÄÉáã=pí~êí= ÇáÉ=j~êâáÉêìåÖK==
= _áäÇ=NKPN=dêìééáÉêíÉ=o~ÇáçÄìííçåë=ãáí=pí~êíã~êâáÉêìåÖ= NV =
N= _ÉåìíòÉêçÄÉêÑä®ÅÜÉå= _áäÇ=NKPO=òÉáÖíI=ïáÉ=ÇáÉ=ÖÉëÉíòíÉ=pí~êíJj~êâáÉêìåÖ=ÇÉë=ÉêëíÉå=o~ÇáçÄìííçåëI=ÇÉê= ÇÉå= k~ãÉå= RadioButton1= ÉêÜáÉäíI= áã= lÄàÉâíáåëéÉâíçê= ÇáÉëÉë= _ÉÇáÉåÉäÉãÉåíë= ÉáåÖÉëíÉääí=ïáêÇK=
= _áäÇ=NKPOW=aáÉ=j~êâáÉêìåÖ=áå=Radiobutton1=ïáêÇ=ÖÉëÉíòí=== = =
OM= =
==
2
Objekt, Ereignis, Ereignisprozedur fã=îçêáÖÉå=h~éáíÉä=ïìêÇÉ=ÖÉëÅÜáäÇÉêíI=ïáÉ=aÉäéÜá=ÖÉëí~êíÉí=ïáêÇI=ïáÉ=ÇáÉ=pí~êíJ ÉáÖÉåëÅÜ~ÑíÉå= ÇÉê= ÖêìåÇäÉÖÉåÇÉå= ^êÄÉáíëÑä®ÅÜÉI= ÇÉë= cçêãìä~êëI= îçêÉáåÖÉëíÉääí= ïÉêÇÉåI=ïáÉ=ã~å=òïÉÅâã®≈áÖ=ëéÉáÅÜÉêíK=tÉáíÉê=ïìêÇÉ=Éêä®ìíÉêíI=ïáÉ=ÇáÉ=ëç=ÖÉJ å~ååíÉ= i~ìÑòÉáí= ÖÉëí~êíÉí= ïáêÇI= áå= ÇÉê= ÇáÉ= îçêÄÉêÉáíÉíÉ= ^êÄÉáíëÑä®ÅÜÉ= Ç~åå= í~íJ ë®ÅÜäáÅÜ= ÉêëÅÜÉáåí= ìåÇ= áå= ÇÉê= ã~å= âçåíêçääáÉêÉå= â~ååI= çÄ= ÇáÉ= îçêÄÉêÉáíÉíÉ= bêJ ëÅÜÉáåìåÖëÑçêã=ÇÉë=cçêãìä~êë=ïáÉ=ÖÉïΩåëÅÜí=òì=ëÉÜÉå=áëíK== a~ê~å= ~åëÅÜäáÉ≈ÉåÇ= ÑçäÖíÉå= ÉêëíÉ= ^åäÉáíìåÖÉåI= ïáÉ= ïáÅÜíáÖÉ= píÉìÉêÉäÉãÉåíÉ= ~ìÑ= ÇÉã= cçêãìä~ê= éä~íòáÉêí= ìåÇ= áÜêÉêëÉáíë= ÑΩê= áÜêÉ= ïÉëÉåíäáÅÜÉå= pí~êíÉáÖÉåëÅÜ~ÑíÉå= îçêÉáåÖÉëíÉääí= ïÉêÇÉå= â∏ååÉåW= = _ìííçå= EpÅÜ~äíÑä®ÅÜÉFI= i~ÄÉä= E_ÉëÅÜêáÑíìåÖëÑÉäÇFI= bÇáí=EqÉñíÉáåÖ~ÄÉÑÉäÇI=qÉñíÑÉåëíÉêFI=`ÜÉÅâÄçñ=Eg~JkÉáåJléíáçåFI=pÅêçääÄ~ê=EpÅÜáÉJ ÄÉêÉÖäÉêF=ëçïáÉ=o~ÇáçÄìííçåë=áå=dêçìé_çñÉå=EÖêìééáÉêíÉ=^ìëï~ÜäFK=== _áë= ÜáÉêÜÉê= äáÉ≈= ëáÅÜ= ~ääÉë= ëÅÜ∏å= ÉáåÑ~ÅÜI= łêÉáå= Ü~åÇïÉêâäáÅÜI= ëÅÜáäÇÉêåK= j~å= åÉÜãÉI= ã~å= íìÉK= _áë= ~ìÑ= ÇÉå= rãÖ~åÖ= ãáí= ÉáåáÖÉå= ÉåÖäáëÅÜÉ= sçâ~ÄÉäåI= ÇÉêÉå= hÉååíåáë= ÑΩê= ÇáÉ= pìÅÜÉ= å~ÅÜ= ÇÉå= báÖÉåëÅÜ~ÑíÉå= ìåÇ= ÇÉêÉå= _ÉÇÉìíìåÖ= áã= lÄJ àÉâíáåëéÉâíçê=ÜáäÑêÉáÅÜ=áëíI=ïìêÇÉ=ìåëÉê=aÉåâîÉêã∏ÖÉå=åçÅÜ=åáÅÜí=~ìÑ=Ü~êíÉ=mêçJ ÄÉå=ÖÉëíÉääíK== açÅÜ=ïÉåå=ïáê=áåÜ~äíäáÅÜ=îÉêëíÉÜÉå=ïçääÉåI=ï~ë=í~íë®ÅÜäáÅÜ=ÄÉá=ÇÉê=aÉäéÜáJmêçJ Öê~ããáÉêìåÖ= îçê= ëáÅÜ= ÖÉÜíI= ïÉåå= ïáê= ÉáÖÉåÉå= ^åíÉáä= ìåÇ= ÇáÉ= iÉáëíìåÖÉå= ÇÉë= aÉäéÜáJpóëíÉãë= áå= áÜêÉã= wìë~ããÉåÜ~åÖ= ìåÇ= tÉÅÜëÉäëéáÉä= ÉáåçêÇåÉå= ã∏ÅÜJ íÉåI=ãΩëëÉå=ïáê=ìåë=å®ÜÉê=ãáí=ÇÉã=_ÉÖêáÑÑ=ÇÉë=lÄàÉâíÉë=ÄÉÑ~ëëÉåK== aÉåå=ëÅÜäáÉ≈äáÅÜ=ïÉêÇÉå=ïáê=áå=táêâäáÅÜâÉáí=åáÅÜíë=^åÇÉêÉë=~äë=llm=ÄÉíêÉáÄÉå= Ó= lÄàÉâíçêáÉåíáÉêíÉ= PêçÖê~ããáÉêìåÖK= kìê= ÑΩåÑ= h~éáíÉä= ïÉêÇÉå= ïáê= ÄÉå∏íáÖÉåI== ìåÇ=Ç~åå=ïÉêÇÉå=ïáê=ïáëëÉåI=ï~ë=ïáê=íìåK== táê=ÖÉÜÉå=áå=âäÉáåÉå=pÅÜêáííÉå=îçêK=_ÉÑ~ëëÉå=ïáê=ìåë=òìÉêëí=ãáí=ÇÉå=_ÉÖêáÑÑÉå= lÄàÉâíI=bêÉáÖåáë=ìåÇ=bêÉáÖåáëéêçòÉÇìêK==
2.1
Der Objektbegriff
2.1.1
Datenobjekte
báå=a~íÉåçÄàÉâí=ÄÉëíÉÜí=òì~ääÉêÉêëí=~ìë=ÉáåÉã=ÖÉëÅÜΩíòíÉå=a~íÉåâÉêåK=j~å=ë~Öí= ~ìÅÜI=ÇáÉ=Ççêí=ÉåíÜ~äíÉåÉå=a~íÉå=ëáåÇ=ÖÉâ~éëÉäíK== táÉ= ÇÉê= a~íÉåâÉêå= áã= báåòÉäåÉå= ~ìÑÖÉÄ~ìí= áëíI= Ç~ë= ïÉá≈= åìê= ÇÉêàÉåáÖÉ= mêçJ Öê~ããáÉêÉêI=ÇÉê=ÇáÉëÉë=a~íÉåçÄàÉâí=áêÖÉåÇï~åå=Éáåã~ä=îçêÄÉêÉáíÉí=Ü~íK= ON =
O= lÄàÉâíI=bêÉáÖåáëI=bêÉáÖåáëéêçòÉÇìê= fëí= Éáå= lÄàÉâí= îçêÄÉêÉáíÉí= EìåÇ= ÄÉáëéáÉäëïÉáëÉ= áå= ÉáåÉ= lÄàÉâíë~ããäìåÖ= ~ìÑÖÉJ åçããÉå=ïçêÇÉåFI=ëç=â∏ååÉå=îáÉäÉ=~åÇÉêÉ=mêçÖê~ããáÉêÉê=Ç~ãáí=~êÄÉáíÉåK=táê= ïçääÉå= ÇáÉëÉ= òìã= råíÉêëÅÜáÉÇ= òì= ÇÉã= sçêÄÉêÉáíÉê= ÇÉë= lÄàÉâíë= ~äë= kìíòJmêçJ Öê~ããáÉêÉê= ÄÉòÉáÅÜåÉåK= hÉáå= kìíòJmêçÖê~ããáÉêÉê= â~åå= ~ÄÉê= ìåãáííÉäÄ~ê= ~ìÑ= ÇáÉ=_Éëí~åÇíÉáäÉ=ÇÉë=a~íÉåâÉêåë=òìÖêÉáÑÉåK== e®ííÉ= Éáå= lÄàÉâí= åìê= ÇÉå= ÖÉëÅÜΩíòíÉå= a~íÉåâÉêåI= ëç= ï®êÉ= Éë= çÑÑÉåëáÅÜíäáÅÜ= ëáååäçëK=káÉã~åÇI=âÉáå=kìíòJmêçÖê~ããáÉêÉêI=â∏ååíÉ=ãáí=ÇÉå=a~íÉå=~êÄÉáíÉåK== aÉëÜ~äÄ=ÉåíÜ®äí=àÉÇÉë=lÄàÉâí=òìë®íòäáÅÜ=ÖÉïáëëÉ=jÉÅÜ~åáëãÉåI=ãáí=ÇÉêÉå=eáäÑÉ= àÉÇÉê=kìíòJmêçÖê~ããáÉêÉê=ãáí=ÇÉã=a~íÉåâÉêå=ìãÖÉÜÉå=â~ååK==
= _áäÇ=OKNW=lÄàÉâíÉ=áå=aÉäéÜá= få= _áäÇ= OKN= ëáåÇ= ÇáÉëÉ= ÇêÉá= jÉÅÜ~åáëãÉå= ÉáåÖÉòÉáÅÜåÉíI= ÇáÉ= òì= àÉÇÉã= aÉäéÜáJ lÄàÉâí=ÖÉÜ∏êÉå=â∏ååÉåW== • báåÉ=éêçéÉêíó=EbáÖÉåëÅÜ~ÑíF=ÇáÉåí=ÇÉã=ëÅÜåÉääÉå=~âíáîÉå=ìåÇ=é~ëëáîÉå=wìÖêáÑÑ= ~ìÑ=ÉáåòÉäåÉ=_Éëí~åÇíÉáäÉ=ÇÉë=a~íÉåâÉêåëK=sÉêïÉåÇÉí=Éáå=kìíòJmêçÖê~ããáÉêÉê= ÉáåÉ=éêçéÉêíó=~âíáîI=îÉê®åÇÉêí=Éê=ãáí=áÜêÉê=eáäÑÉ=ÉáåÉå=ÉáåòÉäåÉå=tÉêí=áã=a~J íÉåâÉêåK= m~ëëáîÉ= sÉêïÉåÇìåÖ= Ç~ÖÉÖÉå= áåÑçêãáÉêí= ΩÄÉê= ÇáÉ= ~âíìÉääÉ= páíì~íáçå= áã=a~íÉåâÉêåI=çÜåÉ=Ç~êáå=òì=®åÇÉêåK== tÉåå=òK=_K=áã=a~íÉåâÉêå=ÇáÉ=rÜêòÉáí=ãáí=píìåÇÉ=ìåÇ=jáåìíÉ=îÉêï~äíÉí=ïáêÇI= â∏ååíÉå=ΩÄÉê=òïÉá=éêçéÉêíáÉë=ëçïçÜä=ÇáÉ=báåòÉäïÉêíÉ=~ÄÖÉÑê~Öí=~äë=~ìÅÜ=îÉêJ ®åÇÉêí=ïÉêÇÉåK=mêçéÉêíáÉë=ïÉêÇÉå=îÉêïÉåÇÉíK= • báåÉ=ÑìåÅíáçå=EcìåâíáçåF=äáÉÑÉêí=ëíÉíë=ÉáåÉå=ÉáåòÉäåÉå=tÉêíI=ÇÉå=bêÖÉÄåáëïÉêíI= ÇÉê=áå=wìë~ããÉåÜ~åÖ=ãáí=ÇÉã=fåÜ~äí=ÇÉë=a~íÉåâÉêåë=ëíÉÜíK== táêÇ=òK=_K=áã=a~íÉåâÉêå=Éáå=qÉñí=îÉêï~äíÉíI=ëç=â∏ååíÉ=ÉáåÉ=cìåâíáçå=ÇáÉ=~âJ íìÉääÉ=^åò~Üä=ÇÉê=wÉáÅÜÉå=äáÉÑÉêåK=cìåâíáçåÉå=ïÉêÇÉå=áK=~ääÖK=é~ëëáî=îÉêïÉåJ ÇÉíK= cìåâíáçåÉå= â∏ååÉå= ~ìÅÜ= áã= a~íÉåâÉêå= îÉê®åÇÉêåK= fÜê= bêÖÉÄåáëïÉêí= ãìëë= Ç~åå= åáÅÜí= áããÉê= îÉê~êÄÉáíÉí= ïÉêÇÉå= EëáÉÜÉ= ÇáÉ= cìåâíáçå= AddI= ^ÄJ ëÅÜåáíí=NPKPKSFK=a~åå=ïáêÇ=ÇáÉ=cìåâíáçå=~ìëå~ÜãëïÉáëÉ=~ìÑÖÉêìÑÉåK== • báåÉ= éêçÅÉÇìêÉ= EmêçòÉÇìêF= â~åå= ÉáåÉ= sáÉäÑ~äí= ~å= táêâìåÖÉå= Ü~ÄÉåW= páÉ= â~åå= áã= a~íÉåâÉêå= îÉê®åÇÉêåI= ëáÉ= â~åå= îáÉäÉ= tÉêíÉ= äáÉÑÉêåI= âìêòI= ëáÉ= Ü~í= ÉáåÉ= ÄÉJ ëíáããíÉ=táêâìåÖK=mêçòÉÇìêÉå=ïÉêÇÉå=~ìÑÖÉêìÑÉåK==
OO= =
OKN== aÉê=lÄàÉâíÄÉÖêáÑÑ=
2.1.2
Visuelle Objekte
aÉäéÜá=ÉåíÜ®äí=ÉáåÉ=ÄÉ~ÅÜíäáÅÜÉ= p~ããäìåÖ=îçå=îçêÄÉêÉáíÉíÉå=lÄàÉâíÉåK=fã=ÉêëJ íÉå=h~éáíÉä=Ü~ÄÉå=ïáê=Ç~îçå=ëÅÜçå=Ó=ìåÄÉïìëëí=Ó=dÉÄê~ìÅÜ=ÖÉã~ÅÜíK=táê=Ü~J ÄÉå=å®ãäáÅÜ=ÄÉëçåÇÉêÉ=lÄàÉâíÉI=ÇáÉ=~äë=îáëìÉääÉ=lÄàÉâíÉ=ÄÉòÉáÅÜåÉí=ïÉêÇÉåI=áã= båíïìêÑ=îçêÄÉêÉáíÉí=ìåÇ=òìê=i~ìÑòÉáí=ÉêòÉìÖÉå=ä~ëëÉåK==
= _áäÇ=OKOW=sáëìÉääÉë=lÄàÉâí=áå=aÉäéÜá= sáëìÉääÉ=lÄàÉâíÉ=ÄÉëáíòÉå=òìë®íòäáÅÜ=ÉáåÉå=ëáÅÜíÄ~êÉå=qÉáäI=ÇÉå=ïáê=~äë=píÉìÉêÉäÉJ ãÉåí=~ìÑ=ÇÉã=cçêãìä~ê=ÉêäÉÄÉåK=^ìÅÜ=Ç~ë=cçêãìä~ê=ëÉäÄëí=áëí=åáÅÜíë=~åÇÉêÉë=~äë= ÇÉê= ëáÅÜíÄ~êÉ= qÉáä= ÉáåÉë= ÉåíëéêÉÅÜÉåÇÉå= îáëìÉääÉå= lÄàÉâíÉëK= ^ääÉ= tÉêíÉI= ÇáÉ= òìã=ëáÅÜíÄ~êÉå=qÉáä=ÖÉÜ∏êÉåI=ëáåÇ=áã=a~íÉåâÉêå=~ÄÖÉëéÉáÅÜÉêíK== a~òì= ÖÉÜ∏êÉå= òìã= _ÉáëéáÉä= mçëáíáçåI= dê∏≈É= ìåÇ= c~êÄÉ= àÉÇÉë= píÉìÉêÉäÉãÉåíëI= c~êÄÉ= ìåÇ= pí~êíJpí~íìë= ÇÉë= cçêãìä~êëI= _ÉëÅÜêáÑíìåÖ= ÇÉë= i~ÄÉäë= çÇÉê= fåÜ~äí= ÇÉë= qÉñíÑÉåëíÉêëI= Ç~òì= ÖÉÜ∏êÉå= ÇáÉ= _ÉäÉÖìåÖ= ÄÉá= ÇÉê= `ÜÉÅâÄçñ= çÇÉê= ÇÉã= o~ÇáçJ ÄìííçåI=ÇáÉ=mçëáíáçå=ÇÉë=oÉÖäÉêë=ÄÉá=ÉáåÉê=pÅêçääÄ~ê=ìëïK= táêÇ= ÑçäÖäáÅÜ= áã= a~íÉåâÉêå= ÉáåÉë= îáëìÉääÉå= lÄàÉâíë= áêÖÉåÇÉáå= tÉêí= îÉê®åÇÉêíI= ÇÉê=ãáí=ÇÉã=ëáÅÜíÄ~êÉå=qÉáä=áå=_ÉòáÉÜìåÖ=ëíÉÜíI=ëÉÜÉå=ïáê=ëçÑçêí=ÉáåÉ=ûåÇÉêìåÖ= ~å=ÇÉã=píÉìÉêÉäÉãÉåíK== råÇ=ëÅÜçå=ä®ëëí=ëáÅÜ=~ìÅÜ=Éêâä®êÉåI=ï~ë=ïáê=ÉáÖÉåíäáÅÜ=í~íÉåI=~äë=ïáê=ìåíÉê=kìíJ òìåÖ=ÇÉê=oìÄêáâ=bfdbkp`e^cqbk=ÇÉë=lÄàÉâíáåëéÉâíçêë=áå=ÇÉå=^ÄëÅÜåáííÉå=NKOKN= ìåÇ=NKQKP=àÉïÉáäë=ÇáÉ=pí~êíëáíì~íáçå=ÑΩê=cçêãìä~ê=ìåÇ=píÉìÉêÉäÉãÉåíÉ=ÑÉëíäÉÖíÉåK= _áäÇ= OKP= òÉáÖí= ÉëW= báåáÖÉ= ÇÉê= éêçéÉêíáÉëI= ÇáÉ= áå= ÇÉå= a~íÉåâÉêå= ÑΩÜêÉåI= â∏ååÉå= îçå= ìåë= ÄÉêÉáíë= áå= ÇÉê= båíïìêÑëéÜ~ëÉ= ãáí= eáäÑÉ= ÇÉë= lÄàÉâíáåëéÉâíçêë= îçêÉáåÖÉJ ëíÉääí=ïÉêÇÉåK=wì=_ÉÖáåå=ÇÉê=i~ìÑòÉáíI=ïÉåå=Ç~åå=Ç~ë=îáëìÉääÉ=lÄàÉâí=í~íë®ÅÜJ äáÅÜ=ÉêòÉìÖí=ïáêÇI=íê~åëéçêíáÉêí=aÉäéÜá=ÇáÉ=îçêÉáåÖÉëíÉääíÉå=tÉêíÉ=ΩÄÉê=ÇáÉ=éêçJ éÉêíáÉë=áå=ÇÉå=a~íÉåâÉêåK== açêí= ëçêÖÉå= ëáÉ= ëçÑçêí= ÑΩê= ÉåíëéêÉÅÜÉåÇÉ= a~êëíÉääìåÖ= ÇÉë= píÉìÉêÉäÉãÉåíëI= ~äëç= ÇÉë=ëáÅÜíÄ~êÉå=qÉáäë=ÇÉë=îáëìÉääÉå=lÄàÉâíëW=a~ë=i~ÄÉä=ÉêÜ®äí=ÇáÉ=îçêÉáåÖÉëíÉääíÉ= _ÉëÅÜêáÑíìåÖI=ÇáÉ=`ÜÉÅâÄçñ=ÇáÉ=îçêÉáåÖÉëíÉääíÉ=_ÉäÉÖìåÖI=ÇáÉ=pÅêçääÄ~ê=ÇáÉ=îçêJ ÉáåÖÉëíÉääíÉ=mçëáíáçåI=Ç~ë=cçêãìä~ê=ÇáÉ=îçêÉáåÖÉëíÉääíÉ=c~êÄÉ=ìåÇ=ëç=ïÉáíÉêK== káÅÜí=~ääÉI=ëçåÇÉêå=åìê=ÇáÉ=ïáÅÜíáÖëíÉå=_Éëí~åÇíÉáäÉ=ÇÉë=a~íÉåâÉêåë=ëáåÇ=îçê~Ä= ÇìêÅÜ=ÇÉå=lÄàÉâíáåëéÉâíçê=ãáí=eáäÑÉ=îçå=éêçéÉêíáÉë=ÉáåëíÉääÄ~êK==
OP =
O= lÄàÉâíI=bêÉáÖåáëI=bêÉáÖåáëéêçòÉÇìê= fã= ^ÄëÅÜåáíí= QKTKO= ïÉêÇÉå= ïáê= ÉêÑ~ÜêÉåI= ïáÉ= ïÉáíÉêÉ= éêçéÉêíáÉë= ÖÉÑìåÇÉå= ìåÇ= ÖÉåìíòí=ïÉêÇÉå=â∏ååÉåK=
= _áäÇ=OKPW=sçêÉáåëíÉääìåÖ=ÇÉê=pí~êíÉáÖÉåëÅÜ~ÑíÉå=áã=lÄàÉâíáåëéÉâíçê= pç= ïÉáíI= ëç= ÖìíK= açÅÜ= ï~ë= é~ëëáÉêí= òìê= i~ìÑòÉáíI= ïÉåå= Ç~ë= cçêãìä~ê= ãáí= ÇÉå= Ç~ê~ìÑ= éä~íòáÉêíÉå= píÉìÉêÉäÉãÉåíÉå= ÜÉêÖÉëíÉääí= áëí\= a~åå= ÖáÄí= Éë= ÇáÉ= kìíòÉêáå= çÇÉê=ÇÉå=kìíòÉê=EÇÉê=báåÑ~ÅÜÜÉáí=Ü~äÄÉê=ëçää=ÖÉåÉêÉää=åìê=âìêò=îçå=ÇÉã=kìíòÉê= ÖÉëéêçÅÜÉå=ïÉêÇÉåFK== k~íΩêäáÅÜ=â~åå=ÇÉê=kìíòÉêI=Éê=ïáêÇ=Éë=ëçÖ~êI=~ìÑ=ÇáÉ=píÉìÉêÉäÉãÉåíÉ=ÉáåïáêâÉåW=bê= ïáêÇ=~ìÑ=ÇÉå=_ìííçå=âäáÅâÉåI=áå=Ç~ë=qÉñíÑÉåëíÉê=Éáåíê~ÖÉåI=áå=ÇÉê=`ÜÉÅâÄçñ=ÇÉå= e~âÉå=ëÉíòÉå=çÇÉê=ïÉÖåÉÜãÉåI=áå=ÇÉê=pÅêçääÄ~ê=ÇÉå=oÉÖäÉê=îÉêëÅÜáÉÄÉå=ìëïK==
== _áäÇ=OKQW=kìíòÉêÉáåïáêâìåÖ=áëí=Éáå=bêÉáÖåáë= a~ë=áëí=ëÉáå=ÖìíÉë=oÉÅÜíI=Ç~ë=ëçää=Éê=~ìÅÜK=pÅÜäáÉ≈äáÅÜ=ïáêÇ=ÇáÉ=_ÉåìíòÉêçÄÉêÑä®J ÅÜÉ=åáÅÜí=òìã=ÄÉÖÉáëíÉêåÇÉå=^åëÉÜÉå=îçêÄÉêÉáíÉí=ìåÇ=ÜÉêÖÉëíÉääíI=ëçåÇÉêå=òìã= båíÖÉÖÉååÉÜãÉå=îçå=kìíòÉêÉáåïáêâìåÖÉåK== fã=_áäÇ=OKQ=Ü~ÄÉå=ïáê=ÑçäÖäáÅÜ=Ç~ë=pÅÜÉã~=ÇÉë=îáëìÉääÉå=aÉäéÜáJlÄàÉâíë=ÉêïÉáJ íÉêí= ÇìêÅÜ= ÇÉå= kìíòÉê= ìåÇ= ëÉáåÉ= j∏ÖäáÅÜâÉáíI= ~ìÑ= Éáå= píÉìÉêÉäÉãÉåí= ÉáåòìïáêJ âÉåK=gÉÇÉ=kìíòÉêÉáåïáêâìåÖ=ïáêÇ=Ç~ÄÉá=~äë=bêÉáÖåáë=ÄÉòÉáÅÜåÉíK== OQ= =
OKN== aÉê=lÄàÉâíÄÉÖêáÑÑ= a~ãáí=â∏ååÉå=ïáê=ìåë=Ç~ë=tÉÅÜëÉäëéáÉä=îçêëíÉääÉåW== • táêÇ= áã= a~íÉåâÉêå= Éáå= _Éëí~åÇíÉáäI= ÇÉê= òìê= ëáÅÜíÄ~êÉå= hçãéçåÉåíÉ= ÖÉÜ∏êíI= ÖÉ®åÇÉêíI=®åÇÉêí=ëáÅÜ=~ìíçã~íáëÅÜ=ÇÉê=ëáÅÜíÄ~êÉ=qÉáäI=Ç~ë=píÉìÉêÉäÉãÉåíK= • bêÑçäÖí=~åÇÉêÉêëÉáíë=ÉáåÉ=®åÇÉêåÇÉ=kìíòÉêÉáåïáêâìåÖ=~ìÑ=Éáå=píÉìÉêÉäÉãÉåíI= ®åÇÉêí= ëáÅÜ= åáÅÜí= åìê= ÇáÉëÉëI= ëçåÇÉêå= ëçÑçêí= ïáêÇ= ~ìÅÜ= áã= a~íÉåâÉêå= ÇáÉëÉ= ûåÇÉêìåÖ=êÉÖáëíêáÉêíK== açÅÜ=åáÅÜí=àÉÇÉ=kìíòÉêÉáåïáêâìåÖ=®åÇÉêí=Éíï~ë=Ó=ëç=â~åå=ÇÉê=kìíòÉê=~ìÑ=ÉáåÉå= _ìííçå= âäáÅâÉåI= ÇáÉ= j~ìë= ΩÄÉê= ÇÉã= cçêãìä~ê= ÄÉïÉÖÉåI= ~ìÑ= Éáå= i~ÄÉä= âäáÅâÉå= ìëïK=a~ÄÉá=ïáêÇ=åáÅÜíë=páÅÜíÄ~êÉë=é~ëëáÉêÉåI=çÄïçÜä=òïÉáÑÉäëçÜåÉ=ÉáåÉ=^âíáîáJ í®í=ÇÉë=kìíòÉêë=ëí~ííÖÉÑìåÇÉå=Ü~íK== táê=Äê~ìÅÜÉå=ÉáåÉå=ΩÄÉêÖÉçêÇåÉíÉå=_ÉÖêáÑÑI=ìåÇ=Ç~ë=áëí=ÉÄÉå=Ç~ë=bêÉáÖåáëK== • gÉÇÉ=kìíòÉêÜ~åÇäìåÖ=~ã=cçêãìä~ê=çÇÉê=~å=ÉáåÉã=Ç~ê~ìÑ=ÄÉÑáåÇäáÅÜÉå=píÉìJ ÉêÉäÉãÉåí=áëí=Éáå=bêÉáÖåáëK= • báåáÖÉ=ÇáÉëÉê=bêÉáÖåáëëÉ=â∏ååÉå=òìë®íòäáÅÜ=åçÅÜ=ûåÇÉêìåÖÉå=~å=ÇÉå=píÉìÉêJ ÉäÉãÉåíÉå= ÄÉïáêâÉåK= cáåÇÉå= ëçäÅÜÉ= ûåÇÉêìåÖÉå= ëí~íí= ïÉêÇÉå= ëáÉ= ëçÑçêí= áã= a~íÉåâÉêå=ÇÉë=àÉïÉáäáÖÉå=îáëìÉääÉå=lÄàÉâíë=ÄÉêΩÅâëáÅÜíáÖíK==
2.1.3
Ereignisbehandlung
häáÅâí=Éáå=kìíòÉê=~ìÑ=ÉáåÉå=_ìííçå=ïáää=ÉêI=Ç~ëë=Éíï~ë=é~ëëáÉêíI=Ç~ëë=ÉáåÉ=oÉ~âJ íáçå=ÉáåíêáííK=a~ë=áëí=ëÉáå=ÖìíÉë=oÉÅÜí=Ó=ìåÇ=ï~êìã=Ö®ÄÉ=Éë=ëçåëí=ΩÄÉêÜ~ìéí=ÇáÉJ ëÉë=píÉìÉêÉäÉãÉåí=_ìííçå\= a~ë=_áäÇ=OKR=îÉêëìÅÜí=Ç~êòìëíÉääÉåI=ïáÉ=Éë=ΩÄÉêÜ~ìéí=Ç~òì=âçããÉå=â~ååI=Ç~ëë= ~ìÑ=Éáå=îçã=kìíòÉê=~ìëÖÉä∏ëíÉë=bêÉáÖåáë=ëÅÜäáÉ≈äáÅÜ=ÉáåÉ=oÉ~âíáçå=ÉêÑçäÖíK== • tÉåå=ïáê=Éáå=píÉìÉêÉäÉãÉåí=áå=ÇÉê=båíïìêÑëéÜ~ëÉ=~ìÑ=ÇÉã=cçêãìä~ê=éä~íòáÉJ êÉåI=ÄÉêÉáíÉå=ïáê=Ç~ãáí=Éáå=îáëìÉääÉë=lÄàÉâí=îçêK=a~ë=cçêãìä~ê=ëÉäÄëí=ïáêÇ=Ç~J ÄÉá=~ìÅÜ=Éáå=îáëìÉääÉë=lÄàÉâíK== • däÉáÅÜòÉáíáÖ=ïáêÇ=àÉÇÉë=îçêÄÉêÉáíÉíÉ=îáëìÉääÉ=lÄàÉâí=ÇìêÅÜ=aÉäéÜá=ÄÉáã=bêÉáÖJ åáëÜ®åÇäÉê=~åÖÉãÉäÇÉí=Ó=ïáê=ãΩëëÉå=Ç~ë=åáÅÜí=íìå=ìåÇ=ãÉêâÉå=~ìÅÜ=åáÅÜíë= Ç~îçåK=aáÉ=^åãÉäÇìåÖ=ÉêÑçäÖí=~ìíçã~íáëÅÜK=== • wìê=i~ìÑòÉáíI=ïÉåå=ÇáÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=Ecçêãìä~ê=ãáí=Ç~ê~ìÑ=ÄÉÑáåÇäáÅÜÉå= píÉìÉêÉäÉãÉåíÉåF= í~íë®ÅÜäáÅÜ= ÜÉêÖÉëíÉääí= áëíI= ï~êíÉí= ÇÉê= bêÉáÖåáëÜ®åÇäÉê= ~ìÑ= k~ÅÜêáÅÜíÉå=îçå=ÇÉå=îáëìÉääÉå=lÄàÉâíÉåK== • i∏ëí=Éáå=kìíòÉê=ÇìêÅÜ=ÉáåÉ=_ÉÇáÉåÜ~åÇäìåÖ=Éáå=bêÉáÖåáë=~å=ÉáåÉã=îáëìÉääÉå= lÄàÉâí=~ìëI=ÉêÜ®äí=ÇÉê=bêÉáÖåáëÜ®åÇäÉê=ÉáåÉ=ÉåíëéêÉÅÜÉåÇÉ=k~ÅÜêáÅÜíK= • aÉê=bêÉáÖåáëÜ®åÇäÉê=éêΩÑíI=çÄ=Éë=òì=ÇáÉëÉã=bêÉáÖåáë=~å=ÇáÉëÉã=îáëìÉääÉå=lÄJ àÉâí=ÉáåÉ=îçêÄÉêÉáíÉíÉ=bêÉáÖåáëéêçòÉÇìê=ÖáÄíK== • tÉåå=Éë=ÉáåÉ=îçêÄÉêÉáíÉíÉ=bêÉáÖåáëéêçòÉÇìê=ÑΩê=ÇáÉëÉë=ÄÉëíáããíÉ=bêÉáÖåáë=~å= ÇáÉëÉã=lÄàÉâí=ÖáÄíI=ïáêÇ=ëáÉ=ÖÉëí~êíÉíK== OR =
O= lÄàÉâíI=bêÉáÖåáëI=bêÉáÖåáëéêçòÉÇìê= a~ê~ìë= ÑçäÖíW= tçääÉå= ïáêI= Ç~ëë= ÉáåÉ= oÉ~âíáçå= ~ìÑ= ÉáåÉ= ÄÉëíáããíÉ= kìíòÉêÜ~åÇJ äìåÖ=~å=ÇÉã=ëáÅÜíÄ~êÉå=qÉáä=ÉáåÉë=ÄÉëíáããíÉå=îáëìÉääÉå=lÄàÉâíë=ÉáåíêáííI=ãΩëëÉå= ïáê=Ç~ÑΩê=ëçêÖÉåI=Ç~ëë=Ç~ÑΩê=ÉáåÉ=bêÉáÖåáëéêçòÉÇìê=ÉñáëíáÉêíK==
== _áäÇ=OKRW=bêÉáÖåáëI=bêÉáÖåáëÜ®åÇäÉê=ìåÇ=bêÉáÖåáëéêçòÉÇìêÉå= a~ë=ÄÉÇÉìíÉíI=Ç~ëë=ïáê=ìåë=åìå=ãáí=ÇÉê=cê~ÖÉ=ÄÉëÅÜ®ÑíáÖÉå=ãΩëëÉåI=ïáÉ=ïáê=bêJ ÉáÖåáëéêçòÉÇìêÉå=ÜÉêëíÉääÉå=â∏ååÉåK==
2.2
Einfache Ereignisprozeduren zum Standard-Ereignis gÉÇÉ=bêÉáÖåáëéêçòÉÇìê=ÄÉëíÉÜí=~ìë=ÇÉã=o~ÜãÉå=ìåÇ=ÇÉã=fåÜ~äíK=rã=ÇÉå=o~ÜJ ãÉå=Äê~ìÅÜÉå=ïáê=ìåë=ÄÉá=aÉäéÜá=åáÅÜí=òì=âΩããÉêåI=ÇÉê=ïáêÇ=ìåë=ëíÉíë=èì~ëá= łÖÉëÅÜÉåâíK== wì=àÉÇÉã=îáëìÉääÉå=lÄàÉâí=ÖáÄí=Éë=òïÉá=^êíÉå=îçå=bêÉáÖåáëëÉåW=a~ë=pí~åÇ~êÇJbêJ ÉáÖåáë=ìåÇ=îáÉäÉ=~åÇÉêÉ=bêÉáÖåáëëÉK=a~ë=ëáåÇ=Ç~åå=ÇáÉ=káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉK== a~ë= pí~åÇ~êÇJbêÉáÖåáë= áëí= Ç~ëàÉåáÖÉI= Ç~ë= áå= ÇÉê= oÉÖÉä= çÇÉê= ~ã= Ü®ìÑáÖëíÉå= ÇÉê= ^ìëÖ~åÖëéìåâí= ÑΩê= ÉáåÉ= oÉ~âíáçå= ëÉáå= ïáêÇK= _Éáã= píÉìÉêÉäÉãÉåí= _ìííçå= ï®êÉ= Éë=òáÉãäáÅÜ=îÉêÄäΩÑÑÉåÇI=ïÉåå=åáÅÜí=ÇÉê=häáÅâ=ãáí=ÇÉê=äáåâÉå=Ee~ìéíJF=j~ìëí~ëíÉ= ~äë=pí~åÇ~êÇJbêÉáÖåáë=ÄÉíê~ÅÜíÉí=ïΩêÇÉK== _ÉÖáååÉå= ïáêK= wìÉêëí= ïÉêÇÉå= ïáê= ÉáåÉ= oÉ~âíáçå= ~ìÑ= Ç~ë= pí~åÇ~êÇJbêÉáÖåáë= ~å= ÉáåÉã=îáëìÉääÉå=lÄàÉâí=áå=ÉáåÉê=bêÉáÖåáëéêçòÉÇìê=éêçÖê~ããáÉêÉåK=
OS= =
OKO== báåÑ~ÅÜÉ=bêÉáÖåáëéêçòÉÇìêÉå=òìã=pí~åÇ~êÇJbêÉáÖåáë= aÉå= o~ÜãÉå= ÑΩê= bêÉáÖåáëéêçòÉÇìêÉå= òìã= pí~åÇ~êÇJbêÉáÖåáë= ÉêÜ~äíÉå= ïáê= áå= ÇáÉëÉã=c~ää=Ö~åò=ÉáåÑ~ÅÜW=aìêÅÜ=açééÉäâäáÅâ=áã=båíïìêÑ=~ìÑ=ÇÉå=ëáÅÜíÄ~êÉå=qÉáä= ÇÉë=îáëìÉääÉå=lÄàÉâíëK== pÉÜÉå= ïáê= ìåë= Ç~ë= áã= báåòÉäåÉå= ÑΩê= ìåëÉêÉ= ÄáëÜÉê= îÉêïÉåÇÉíÉå= îáëìÉääÉå= lÄJ àÉâíÉ=~åI=ÇK=ÜK=ÑΩê=ÇáÉ=ëÉÅÜë=píÉìÉêÉäÉãÉåíÉ=ìåÇ=Ç~ë=cçêãìä~êK==
2.2.1 ==
Button
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 2= ÇáÉ= zipJa~íÉá= DKap02.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap02= ÇáÉ= mêçàÉâíJa~íÉá= proj_221.dpr= ~ìëòìï®ÜäÉåK= táêÇ= ãáí= aÉäéÜá= ULOMMR= ÖÉ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbf= molgbhq=£cckbk=áã=lêÇåÉê=D8Kap02=ÇáÉ=a~íÉá=proj_221.bdsproj=~ìëòìï®ÜäÉåK== == ^ìÑ= ÉáåÉã= âäÉáåÉå= cçêãìä~ê= EÉë= ãìëë= ÄÉáã= pí~êí= ÇáÉëã~ä= åáÅÜí= ÇÉå= Ö~åòÉå= _áäÇëÅÜáêã= ~ìëÑΩääÉåF= éä~íòáÉêÉå= ïáê= Éáå= píÉìÉêÉäÉãÉåí= _ìííçå= ìåÇ= ®åÇÉêå= ãáí= ÇÉê= báÖÉåëÅÜ~Ñí= Caption= ÇáÉ= _ÉëÅÜêáÑíìåÖ= ~ìÑ= Start= EëáÉÜÉ= _áäÇ= OKSFK= aÉäéÜá= ëÅÜä®Öí=ÑΩê=ÇáÉëÉë=_ÉÇáÉåÉäÉãÉåí=ÇÉå=k~ãÉå=Button1=îçêK=
= _áäÇ=OKSW=píÉìÉêÉäÉãÉåí=pÅÜ~äíÑä®ÅÜÉ=E_ìííçåF=== kìå=ïáêÇ=Ç~òì=ÇáÉ=^ìÑÖ~ÄÉ=ÑçêãìäáÉêíW=_Éá=ÉáåÑ~ÅÜÉã= häáÅâ=~ìÑ=ÇáÉëÉå=_ìííçå= ëçää=ÇÉê=kìíòÉê=ÉáåÉ=jáííÉáäìåÖ=łaÉê=_ìííçå=ïìêÇÉ=ÖÉâäáÅâí=ÉêÜ~äíÉåK=jÉÜê=ÉêëíJ ã~ä=åáÅÜíK== aÉê=ÉáåÑ~ÅÜÉ=häáÅâ=áëí=Ç~ë=pí~åÇ~êÇJbêÉáÖåáë=ÑΩê=Ç~ë=píÉìÉêÉäÉãÉåí=_ìííçåK=cçäÖJ äáÅÜ=ÄÉëÅÜ~ÑÑÉå=ïáê=ìåë=ÇÉå=o~ÜãÉå=ÑΩê=ÇáÉ=bêÉáÖåáëéêçòÉÇìêI=áåÇÉã=ïáê=ãáí=ÇÉê= äáåâÉå=j~ìëí~ëíÉ=ÇçééÉäí=~ìÑ=ÇÉå=_ìííçå=âäáÅâÉåW==
= _áäÇ=OKTW=o~ÜãÉå=ÑΩê=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=łhäáÅâ=~ìÑ=Button1== OT =
O= lÄàÉâíI=bêÉáÖåáëI=bêÉáÖåáëéêçòÉÇìê= bë=∏ÑÑåÉí=ëáÅÜ=ëçÑçêí=Éáå=ëç=ÖÉå~ååíÉë= nìÉääíÉñíÑÉåëíÉê=E_áäÇ=OKTFI==áå=ÇÉã=ëáÅÜ= ÄÉêÉáíë=ÇêÉáI=ã~åÅÜã~ä=îáÉê=mêçÖê~ããòÉáäÉå=ÄÉÑáåÇÉåK== aáÉ= procedureJwÉáäÉ= ìåÇ= ÇáÉ= wÉáäÉ= ãáí= begin= ÄáäÇÉå= ÇáÉ= ÄÉáÇÉå= hçéÑòÉáäÉå= ÇÉë= o~ÜãÉåëK= aáÉ= wÉáäÉ= ãáí= end;= ãáí= ÇÉã= pÉãáâçäçå= ÄáäÇÉí= ÇáÉ= cì≈òÉáäÉ= ÇÉë= o~ÜJ ãÉåëK=a~ë=äÉíòíÉ=end.=ãáí=ÇÉã=mìåâí=Ü~í=ãáí=ÇÉã=o~ÜãÉå=ÇÉê=bêÉáÖåáëéêçòÉÇìê= åáÅÜíë=òì=íìå=Ó=Éë=Ç~êÑ=~ÄÉê=åáÉã~äë=ÖÉä∏ëÅÜí=ïÉêÇÉåK=== få= ÇÉê= ÉêëíÉå= hçéÑòÉáäÉ= äÉëÉå= ïáê= êÉÅÜíë= åÉÄÉå= ÇÉã= mìåâí= ÇáÉ= sçâ~ÄÉä= Button1Click=Ó=Ç~ãáí=ÉêâÉååÉå=ïáê=òìê=hçåíêçääÉI=Ç~ëë=ïáê=í~íë®ÅÜäáÅÜ=ÇÉå=o~ÜãÉå= ÇÉê=bêÉáÖåáëéêçòÉÇìê=ÑΩê=Ç~ë=bêÉáÖåáë=häáÅâ=~ìÑ=Button1=îçê=ìåë=Ü~ÄÉåK== aÉê=wïáëÅÜÉåê~ìã=òïáëÅÜÉå= begin=ìåÇ=end;=áëí=îçå=ìåë=ãáí=ÇÉã=fåÜ~äí=ÇÉê=bêJ ÉáÖåáëéêçòÉÇìê= òì= ÑΩääÉåK= eáÉê= ãΩëëÉå= ïáê= éêçÖê~ããáÉêÉåI= ÇK= ÜK= ïáê= ãΩëëÉå= ÇáÉ=é~ëëÉåÇÉå=_ÉÑÉÜäÉ=áå=ÇÉê=êáÅÜíáÖÉå=oÉáÜÉåÑçäÖÉ=Éáåíê~ÖÉåI=ïçÄÉá=ïáê=ìåë=~å= ÇáÉ=oÉÖÉäå=ÇÉê=péê~ÅÜÉ=m~ëÅ~ä=Ü~äíÉå=ãΩëëÉåW== procedure TForm1.Button1Click(Sender: TObject);
//1. Kopfzeile
begin
//2. Kopfzeile Showmessage('Der Buttopn wurde geklickt')
end;
//Inhalt //Fußzeile
_Éîçê= ïáê= ãÉÜê= òì= ÇÉå= ÉêëíÉå= m~ëÅ~äJoÉÖÉäå= ÉêÑ~ÜêÉåI= ïçääÉå=ïáê= ìåë= Ç~ë= bêJ ÖÉÄåáë=áå=_áäÇ=OKU=~åëÉÜÉåW=_Éá=häáÅâ=~ìÑ=ÇÉå=_ìííçå=òìê=i~ìÑòÉáí=ÉêëÅÜÉáåí=í~íJ ë®ÅÜäáÅÜ= áå= ÇÉê= jáííÉ= ÇÉë= _áäÇëÅÜáêãë= Ç~ë= îçå= ìåë= îÉêä~åÖíÉ= jáííÉáäìåÖëÑÉåëíÉê= EShowMessageF=ãáí=ÇÉã=éêçÖê~ããáÉêíÉå=fåÜ~äíK=
= _áäÇ=OKUW=bêÑçäÖêÉáÅÜÉ=^ìëÑΩÜêìåÖ=ÇÉê=bêÉáÖåáëéêçòÉÇìê= aÉê=îçå=ìåë=éêçÖê~ããáÉêíÉ=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ÄÉëíÉÜí=Éêëí=Éáåã~ä=åìê= ~ìë=ÉáåÉã=ÉáåòáÖÉå=_ÉÑÉÜä=Ó=âÉáåÉ=pçêÖÉI=Ç~ë=ïáêÇ=ëáÅÜ=Ä~äÇ=®åÇÉêåK== aáÉ=òïÉá=pÅÜê®ÖëíêáÅÜÉ=ã~ÅÜÉå=ÇÉå=oÉëí=ÇÉê=wÉáäÉ=éêçÖê~ããíÉÅÜåáëÅÜ=ìåïáêâJ ë~ã=Ó=Ç~ÜáåíÉê=â~åå=ã~å=ÑçäÖäáÅÜ=_ÉãÉêâìåÖÉå=EhçããÉåí~êÉF=Éáåíê~ÖÉåK== dêç≈J= ìåÇ= häÉáåëÅÜêÉáÄìåÖ= ÇÉê= _ÉÑÉÜäÉ= ëáåÇ= áå= m~ëÅ~ä= åáÅÜí= ïáÅÜíáÖI= ÇáÉëÉäÄÉ= bêÉáÖåáëéêçòÉÇìê=â∏ååíÉå=ïáê=~ìÅÜ=ëç=ëÅÜêÉáÄÉåW== procedure TForm1.Button1Click(Sender: TObject)
// 1. Kopfzeile
begin showmessage('Der Button wurde geklickt') end;
OU= =
//Inhalt
OKO== báåÑ~ÅÜÉ=bêÉáÖåáëéêçòÉÇìêÉå=òìã=pí~åÇ~êÇJbêÉáÖåáë= táê=îÉêäáÉêÉå=~ÄÉê=Ç~ÄÉá=ëÉÜê=îáÉä=~å=§ÄÉêëáÅÜíäáÅÜâÉáíX=ÇÉê=~ìëòìÖÉÄÉåÇÉ=qÉñí= ãìëë=å~íΩêäáÅÜ=íêçíòÇÉã=ÇÉå=oÉÖÉäå=ÇÉê=ÇÉìíëÅÜÉå=péê~ÅÜÉ=ÖÉåΩÖÉåK=aáÉ=§ÄÉêJ ëáÅÜí=ÖÉÜí=ÉÄÉåëç=îÉêäçêÉåI=ïÉåå=ïáê=Ç~ê~ìÑ=îÉêòáÅÜíÉå=ïΩêÇÉåI=ÉáåÖÉêΩÅâí=òì= ëÅÜêÉáÄÉåK== procedure TForm1.Button1Click(Sender: TObject); begin ShowMessage(‘Der Button wurde geklickt‘)
//Inhalt
end;
lÇÉê= ïÉåå= ã~å= Ö~ê= Ç~ê~ìÑ= îÉêòáÅÜíÉíI= ÇáÉ= ïáÅÜíáÖÉå= o~ÜãÉåJpÅÜäΩëëÉäï∏êíÉê= begin=ìåÇ=end;=~ääÉáå=~ìÑ=àÉ=ÉáåÉ=wÉáäÉ=òì=ëÅÜêÉáÄÉåW= procedure TForm1.Button1Click(Sender: TObject); begin ShowMessage(‘Der Button wurde geklickt‘) end;
få=m~ëÅ~ä=áëí=Ç~ë=pÉãáâçäçå=ëíÉíë=Éáå=qêÉååòÉáÅÜÉåK=a~=ÇÉê=fåÜ~äí=ìåëÉêÉê=bêÉáÖJ åáëéêçòÉÇìê= ÇáÉëã~ä= åìê= ~ìë= ÉáåÉã= _ÉÑÉÜä= ÄÉëí~åÇI= ï~ê= Éë= ΩÄÉêÜ~ìéí= åáÅÜí= åçíïÉåÇáÖI=Éáå=pÉãáâçäçå=òì=ëÉíòÉåK=táê=ïÉêÇÉå=áå=ïÉáíÉêÉå=h~éáíÉäå=ëçïáÉëç= åçÅÜ=ÖÉåìÖ=ûêÖÉê=ãáí=ÇáÉëÉã=pÉãáâçäçå=ÄÉâçããÉåK= aÉê=_ÉÑÉÜä= ShowMessage(‘Der Button wurde geklickt‘)=ëíÉääí=áå=táêâäáÅÜâÉáí=ÇÉå= ^ìÑêìÑ= ÇÉê= mêçòÉÇìê= ShowMessage= Ç~êK= a~ÄÉá= ïáêÇ= ÇÉê= qÉñíI= ÇÉê= áå= ÇÉã= jáííÉáJ äìåÖëÑÉåëíÉê=ÉêëÅÜÉáåÉå=ëçääI=áå=ÉáåÑ~ÅÜÉ=eçÅÜâçãã~ë= ‘ ‘=ÖÉëÉíòí=E~ìÑ=ÇÉê=q~ëJ í~íìê=ãÉáëí=ÖÉãÉáåë~ã=ãáí=ÇÉã=wÉáÅÜÉå==# =òì=ÑáåÇÉåFK=
2.2.2 ==
Textfenster
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 2= ÇáÉ= zipJa~íÉá= DKap02.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap02= ÇáÉ= mêçàÉâíJa~íÉá= proj_222.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap02=ÇáÉ=a~íÉá=proj_222.bdsproj=~ìëòìï®ÜäÉåK== = o~ëÅÜ=ïáêÇ=Éáå=qÉñíÑÉåëíÉê=~ìÑ=ÇÉã=cçêãìä~ê=éä~íòáÉêí=EÉë=ÄÉâçããí=îçå=aÉäéÜá= ~ìíçã~íáëÅÜ= ÇÉå= k~ãÉå= Edit1FI= ìåÇ= ãáí= ëÉáåÉã= lÄàÉâíáåëéÉâíçê= ïáêÇ= áå= ÇÉê= wÉáäÉ= Text= ÑΩê= ÇÉå= pí~êíJfåÜ~äí= ÉáåÉ= wÉáÅÜÉåÑçäÖÉI= òìã= _ÉáëéáÉä= rÉåÖäáåÖÉåI= îçêÄÉêÉáíÉí=E_áäÇ=OKVFK== a~åå=ïáêÇ=ãáí=ÇÉê=äáåâÉå=j~ìëí~ëíÉ=ÇçééÉäí=~ìÑ=Ç~ë=qÉñíÑÉåëíÉê=ÖÉâäáÅâíK=pÅÜçå= ÉêÜ~äíÉå=ïáê=ÇÉå=o~ÜãÉå=ÑΩê=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=pí~åÇ~êÇJbêÉáÖåáë=ÄÉáã= qÉñíÑÉåëíÉêK=tÉäÅÜÉë=bêÉáÖåáë=ïáêÇ=Éë=ïçÜä=ëÉáå\=== aÉê=çÄÉêëíÉå=wÉáäÉ=ÇÉë=łÖÉëÅÜÉåâíÉå=o~ÜãÉåë=â∏ååÉå=ïáê=êÉÅÜíë=îçã=mìåâí= ÇáÉ=sçâ~ÄÉä=Edit1Change=~ÄäÉëÉåK= OV =
O= lÄàÉâíI=bêÉáÖåáëI=bêÉáÖåáëéêçòÉÇìê= a~ë= ÜÉá≈íI= Ç~ëë= ÇáÉ= mêçÖê~ããáÉêÉê= îçå= aÉäéÜá= ÇÉê= jÉáåìåÖ= ï~êÉåI= Ç~ëë= ÉáåÉ= ®åÇÉêåÇÉ= kìíòÉêÉáåïáêâìåÖI= ÇK= ÜK= Ç~ë= bêÉáÖåáë= Change= EûåÇÉêìåÖF= ÄÉá= ÉáåÉã= qÉñíÑÉåëíÉêI=ïçÜä=~ã=Ü®ìÑáÖëíÉå=ÇÉê=^ìëÖ~åÖëéìåâí=ÑΩê=ÉáåÉ=oÉ~âíáçå=ëÉáå=ïáêÇK==
= _áäÇ=OKVW=píÉìÉêÉäÉãÉåí=qÉñíÑÉåëíÉê=(Edit)== kìå= Äê~ìÅÜÉå= ïáê= åìê= åçÅÜ= ÇÉå= ÉáåÉå= fåÑçêã~íáçåëJ_ÉÑÉÜä= ÑΩê= ÇÉå= fåÜ~äí= òì= ëÅÜêÉáÄÉåW= procedure TForm1.Edit1Change(Sender: TObject); begin ShowMessage('Es wurde geändert')
// Inhalt
end;
i~ëëÉå= ïáê= ~ìëÑΩÜêÉå= ëíÉääÉå= ïáê= í~íë®ÅÜäáÅÜ= ÑÉëíI= Ç~ëë= Ç~ë= ÉáåÑ~ÅÜÉ= eáåÉáåâäáJ ÅâÉå= áå= ÇáÉ= qÉñíÄçñ= åçÅÜ= åáÅÜí= òìê= ^ìëÑΩÜêìåÖ= ÇáÉëÉê= bêÉáÖåáëéêçòÉÇìê= ÑΩÜêíK= a~ë=bêÉáÖåáë=häáÅâ=áëí=ÉÄÉå=Éáå=~åÇÉêÉë=bêÉáÖåáë=~äë=ûåÇÉêìåÖK=
2.2.3
Checkbox
mêÉáëÑê~ÖÉW=tÉäÅÜÉ=kìíòÉêÉáåïáêâìåÖ=ïáêÇ=ïçÜä=ÄÉá=ÇÉã=píÉìÉêÉäÉãÉåí=`ÜÉÅâJ Äçñ=~ã=Ü®ìÑáÖëíÉå=~ìÑíêÉíÉå=ìåÇ=çÑí=òì=ÉáåÉê=oÉ~âíáçå=^åä~ëë=ÖÉÄÉå\== procedure TForm1.CheckBox1Click(Sender: TObject); begin ShowMessage('Es wurde geklickt')
// Inhalt
end;
k~íΩêäáÅÜ= Ó= áå= ÇÉê= ÉêëíÉå= hçéÑòÉáäÉ= áëí= Éë= ~ÄäÉëÄ~êW= a~ë= pí~åÇ~êÇÉêÉáÖåáë= ÄÉáã= píÉìÉêÉäÉãÉåí=`ÜÉÅâÄçñ=áëí=ÇÉê=ÉáåÑ~ÅÜÉ=häáÅâK=tçÄÉá=ÇáÉëÉë=bêÉáÖåáë=å~íΩêäáÅÜ= ëçïçÜä= ÉáåíêáííI= ïÉåå= ÇÉê= kìíòÉê= ÇÉå= e~âÉå= áå= ÇÉê= `ÜÉÅâÄçñ= ëÉíòíI= ~äë= ~ìÅÜI= ïÉåå=Éê=ÇÉå=e~âÉå=ïÉÖåáããíK=häáÅâ=áëí=häáÅâK=
2.2.4
Scrollbar
cΩê=Ç~ë=píÉìÉêÉäÉãÉåí=pÅêçääÄ~ê=ÄÉëíÉÜí=Ç~ë=pí~åÇ~êÇJbêÉáÖåáë=áå=ÇÉê=ûåÇÉêìåÖ= ÇÉê= mçëáíáçå= ÇÉë= oÉÖäÉêëK= aÉê= açééÉäâäáÅâ= ~ìÑ= ÇáÉëÉë= píÉìÉêÉäÉãÉåí= áã= båíJ ïìêÑëãçÇìë=äáÉÑÉêí=ëçÑçêí=ÇÉå=o~ÜãÉå=ÑΩê=ÉáåÉ=bêÉáÖåáëéêçòÉÇìêI=ãáí=ÇÉê=ã~å= ~ìÑ=ÇáÉëÉ=kìíòÉêÉáåïáêâìåÖ=êÉ~ÖáÉêÉå=â∏ååíÉW=
PM= =
OKO== báåÑ~ÅÜÉ=bêÉáÖåáëéêçòÉÇìêÉå=òìã=pí~åÇ~êÇJbêÉáÖåáë= procedure TForm1.ScrollBar1Change(Sender: TObject); begin ShowMessage('Es wurde am Regler geschoben') end;
2.2.5
// Inhalt
Radiobutton
cΩê= Éáå= píÉìÉêÉäÉãÉåí= o~ÇáçÄìííçåI= Ç~ë= ïçÜä= åáÉã~äë= ~ääÉáå= ~ìÑíêÉíÉå= ïáêÇI= ëçåÇÉêå=áããÉê=ãáí=~åÇÉêÉå=òìë~ããÉå=áå=ÉáåÉê=dêìééÉ=EGroupBoxFI=áëí=ÉÄÉåÑ~ääë= ÇÉê=ÉáåÑ~ÅÜÉ=häáÅâ=Ç~ë=pí~åÇ~êÇJbêÉáÖåáëK== a~ë=ÉêÑ®Üêí=ã~å=~ìë=ÇÉã=òìÖÉÜ∏êáÖÉå=o~ÜãÉå=ÇÉê=bêÉáÖåáëéêçòÉÇìêW== procedure TForm1.RadioButton1Click(Sender: TObject); begin ShowMessage('Es wurde geklickt') end;
2.2.6
// Inhalt
Label
tÉäÅÜÉ=^åíïçêí=ëçääíÉå=ïáê=ÖÉÄÉåI=ïÉåå=ïáê=å~ÅÜ=ÇÉã=pí~åÇ~êÇJbêÉáÖåáë=òìã= píÉìÉêÉäÉãÉåí=i~ÄÉä=ÖÉÑê~Öí=ïÉêÇÉå\=lÇÉê=Ó=~åÇÉêë=ÑçêãìäáÉêí=Ó=ïÉäÅÜÉ=kìíòÉêJ Ü~åÇäìåÖ=áëí=~å=ÉáåÉã=i~ÄÉä=~ã=ï~ÜêëÅÜÉáåäáÅÜëíÉå=ìåÇ=ëçääíÉ=òì=ÉáåÉê= oÉ~âJ íáçå=ÑΩÜêÉå\== báå= i~ÄÉä= ïáêÇ= ÉáÖÉåíäáÅÜ= åìê= é~ëëáî= ÄÉåìíòíI= ìã= Éíï~ë= ãáíòìíÉáäÉåK= cçäÖäáÅÜ= ä~ìíÉí=ÇáÉ=ëéçåí~åÉ=^åíïçêíW=hÉáåÉK=tÉäÅÜÉê=kìíòÉê=âäáÅâí=ëÅÜçå=Éáå=i~ÄÉä=~å\= t~êìã=ëçääíÉ=Éê=Ç~ë=íìå\== qêçíòÇÉã=Ü~ÄÉå=ÇáÉ=båíïáÅâäÉê=îçå=aÉäéÜá=~ìÅÜ=ÑΩê=Éáå=i~ÄÉä=Éáå=pí~åÇ~êÇJbêJ ÉáÖåáë=ÑÉëíÖÉäÉÖíK=i~ëëÉå=ïáê=ìåë=ΩÄÉêê~ëÅÜÉåW=Label1Click=ëíÉÜí=áå=ÇÉê=hçéÑòÉáäÉ= ÇÉë= o~ÜãÉåë= ÑΩê= ÇáÉ= bêÉáÖåáëéêçòÉÇìêK= a~ë= ÄÉëÅÜêÉáÄí= Ç~ë= i~ÄÉäJpí~åÇ~êÇJbêJ ÉáÖåáëK=kÉÜãÉå=ïáê=Éë=òìê=hÉååíåáëK= pçääíÉå=ïáê=Éáåã~ä=~ìë=áêÖÉåÇÉáåÉã=dêìåÇÉ=ÑΩê=ÇÉå=häáÅâ=ÉáåÉë=kìíòÉêë=~ìÑ=Éáå= i~ÄÉä= ÉáåÉ= bêÉáÖåáëéêçòÉÇìê= òì= ëÅÜêÉáÄÉå= Ü~ÄÉå= ïáëëÉå= ïáê= ÑçäÖäáÅÜI= Ç~ëë= ïáê= Ç~ãáí=Ç~ë=pí~åÇ~êÇJbêÉáÖåáë=~ã=i~ÄÉä=ÄÉÜ~åÇÉäåK===
2.2.7
Formular
tÉåå=ïáê=áã=båíïìêÑ=~ìÑ=Ç~ë=äÉÉêÉ=cçêãìä~ê=ÇçééÉäí=âäáÅâÉå=ÉêÜ~äíÉå=ïáê=ëçJ Ñçêí=ÑçäÖÉåÇÉå=bêÉáÖåáëéêçòÉÇìêJo~ÜãÉåW== procedure TForm1.FormCreate(Sender: TObject); begin // Inhalt end;
PN =
O= lÄàÉâíI=bêÉáÖåáëI=bêÉáÖåáëéêçòÉÇìê= a~ë= ÄÉÇÉìíÉíI= Ç~ëë= ÄÉá= ÇÉã= ÖêìåÇäÉÖÉåÇÉå= îáëìÉääÉå= lÄàÉâíI= ÇÉã= cçêãìä~êI= Ç~ë=bêòÉìÖÉå=ECreateF=Ç~ë=pí~åÇ~êÇÉêÉáÖåáë=áëíK=eáÉê=Ü~ÄÉå=ÇáÉ=mêçÖê~ããáÉêÉê= îçå=aÉäéÜá=âÉáåÉ=ÇáêÉâíÉ=kìíòÉêÉáåïáêâìåÖ=~ìÑ=Ç~ë=cçêãìä~ê=òìã=pí~åÇ~êÇJbêJ ÉáÖåáë=Éêâä®êíK== pí~ííÇÉëëÉå= â~åå= ã~å= ~äë= fåÜ~äí= ÇÉê= bêÉáÖåáëéêçòÉÇìê= ëçäÅÜÉ= _ÉÑÉÜäÉ= ÜáåÉáåJ ëÅÜêÉáÄÉåI= ÇáÉ= ~ìíçã~íáëÅÜ= ~ìëÖÉÑΩÜêí= ïÉêÇÉåI= ïÉåå= Ç~ë= cçêãìä~ê= ÜÉêÖÉëíÉääí= ïáêÇK=táê=ïÉêÇÉå=Ç~îçå=Ä~äÇI=å®ãäáÅÜ=áã=^ÄëÅÜåáíí=QKTKRI=dÉÄê~ìÅÜ=ã~ÅÜÉåK==
2.3
Einfache Ereignisprozeduren zu Nicht-Standard-Ereignissen táÉ=ÉêÑ®Üêí=ã~å=ΩÄÉêÜ~ìéíI=ÑΩê=ïÉäÅÜÉ=bêÉáÖåáëëÉ=ã~å=fåÜ~äíÉ=îçå=bêÉáÖåáëéêçJ òÉÇìêÉå=éêçÖê~ããáÉêÉå=â~åå\== jáí=~åÇÉêÉå=tçêíÉåW=cΩê=ïÉäÅÜÉ=kìíòÉêÉáåïáêâìåÖÉå=~ìÑ=Éáå=píÉìÉêÉäÉãÉåí=áëí= áå=aÉäéÜá=ÉáåÉ=oÉ~âíáçå=éêçÖê~ããáÉêÄ~ê\== _áëÜÉê= ïáëëÉå= ïáê= ÇçÅÜ= åìêI= ïáÉ= ïáê= ÉáåÉ= oÉ~âíáçå= ÄÉáã= àÉïÉáäáÖÉå= pí~åÇ~êÇJ bêÉáÖåáë=ÉêòÉìÖÉå=â∏ååÉåK=
2.3.1
Reaktionen auf Mausbewegungen
t~ë=áëí=òì=íìåI=ïÉåå=ïáê=ÄÉáëéáÉäëïÉáëÉ=ÉáåÉ=oÉ~âíáçå=éêçÖê~ããáÉêÉå=ïçääÉåI= ÇáÉ=ëí~ííÑáåÇÉíI=ïÉåå=ÇÉê=kìíòÉê=ÇáÉ=j~ìë=äÉÇáÖäáÅÜ=ΩÄÉê=ÉáåÉå=_ìííçå=ÄÉïÉÖí\== wïÉá=cê~ÖÉå=ãΩëëÉå=Ç~òì=ÄÉ~åíïçêíÉí=ïÉêÇÉåW= • bêëíÉ=cê~ÖÉW=dáÄí=Éë=ΩÄÉêÜ~ìéí=ÇáÉ=j∏ÖäáÅÜâÉáí=áå=aÉäéÜáI=òìã=bêÉáÖåáë=j~ìëJ ÄÉïÉÖìåÖ=ΩÄÉê=ÉáåÉã=_ìííçå=ÉáåÉ=bêÉáÖåáëéêçòÉÇìê=ëÅÜêÉáÄÉå=òì=â∏ååÉå\== • wïÉáíÉ=cê~ÖÉW=táÉ=ÉêÜ®äí=ã~å=Ç~åå=ÇÉå=o~ÜãÉå=ÑΩê=ÇáÉ=bêÉáÖåáëéêçòÉÇìê\== _ÉáÇÉ=^åíïçêíÉå=ëáåÇ=åáÅÜí=ëÅÜïáÉêáÖ=òì=ÉêÜ~äíÉåW== k~ÅÜÇÉã=ïáê=ÉáåÉå=_ìííçå=~ìÑ=ÇÉã=cçêãìä~ê=éä~íòáÉêí=Ü~ÄÉå=EòK=_K=ãáí=ÇÉê=_ÉJ ëÅÜêáÑíìåÖ=k=l=o=aFI=ï®ÜäÉå=ïáê=áã=lÄàÉâíáåëéÉâíçê=Ç~ë=êÉÅÜíÉ=oÉÖáëíÉêÄä~íí=ãáí= ÇÉê=§ÄÉêëÅÜêáÑí=bobfdkfppb=~ìëK== råÇ=Ç~=áëí=ëáÉ=ëÅÜçåI=ÇáÉ=iáëíÉ=~ääÉê=áå=aÉäéÜá=ÄÉÜ~åÇÉäÄ~êÉå=_ìííçåJbêÉáÖåáëëÉI= ÇK= ÜK= ÇáÉ= iáëíÉ= ~ääÉê= ^êíÉå= îçå= kìíòÉêÉáåïáêâìåÖÉå= ~ã= _ìííçåI= ÑΩê= ÇáÉ= ïáê= áå= aÉäéÜá=oÉ~âíáçåÉå=éêçÖê~ããáÉêÉå=â∏ååÉåK=§ÄÉê=ÇáÉ=êÉÅÜíÉ=j~ìëí~ëíÉ=ä®ëëí=ëáÅÜ= ÇáÉ=^åçêÇåìåÖ=ÉåíïÉÇÉê=~äéÜ~ÄÉíáëÅÜ=çÇÉê=å~ÅÜ=h~íÉÖçêáÉå=ÖÉçêÇåÉí=~åòÉáÖÉå= EëK=_áäÇ=OKNMFK== råÇ= áå= ÇáÉëÉã= _áäÇ= â∏ååÉå= ïáê= ÉêâÉååÉåW= tÉáí= ãÉÜê= ~äë= Éáå= aìíòÉåÇ= bêÉáÖJ åáëëÉ= ~ã= _ìííçå= ëáåÇ= ÄÉÜ~åÇÉäÄ~êX= ÑΩê= ëáÉ= â∏ååíÉå= ïáê= ÑçäÖäáÅÜ= bêÉáÖåáëéêçòÉJ ÇìêÉå= îçêÄÉêÉáíÉåK= báåÉë= Ç~îçå= áëí= Ç~ë= ÄÉâ~ååíÉ= pí~åÇ~êÇJbêÉáÖåáë= häáÅâI= Ç~ë= ëáÅÜ=å~íΩêäáÅÜ=~ìÅÜ=áå=ÇÉê=iáëíÉ=ÄÉÑáåÇÉíK== cçäÖäáÅÜ= ÖáÄí= Éë= ÄÉáã= îáëìÉääÉå= lÄàÉâí= _ìííçå= ÉáåÉ= cΩääÉ= ÄÉÜ~åÇÉäÄ~êÉê= káÅÜíJ pí~åÇ~êÇJbêÉáÖåáëëÉK== PO= =
OKP== báåÑ~ÅÜÉ=bêÉáÖåáëéêçòÉÇìêÉå=òì=káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉå= tçÜäÖÉãÉêâíW= aáÉëÉ= ^ìëë~ÖÉ= ÄÉòáÉÜí= ëáÅÜ= ~ìÑ= Ç~ë= ~âíìÉääÉ= aÉäéÜáI= áå= ~åÇÉêÉå= båíïáÅâäìåÖëëóëíÉãÉå= ãáí= ®ÜåäáÅÜÉã= ^ìÑÄ~ì= â~åå= Éë= ÇìêÅÜ~ìë= ïÉåáÖÉê= çÇÉê= ãÉÜê=ÄÉÜ~åÇÉäÄ~êÉ=bêÉáÖåáëëÉ=ÖÉÄÉåK=^ìÅÜ=â∏ååÉå=âΩåÑíáÖÉ=aÉäéÜáJsÉêëáçåÉå= ÇìêÅÜ~ìë=ãáí=ä®åÖÉêÉå=iáëíÉå=îÉêëÉÜÉå=ëÉáåK== gÉÇÉë=bêÉáÖåáë=ÄÉÖáååí=ãáí=ÇÉå=òïÉá=_ìÅÜëí~ÄÉå= On=Ó=áåë=aÉìíëÅÜÉ=~ã=ÄÉëíÉå= ΩÄÉêëÉíòÄ~ê=ãáí=beiK= få=ÇÉê=ÉáåÉê=wÉáäÉ=ÉêâÉååÉå=ïáê=Ç~ë=bêÉáÖåáë= OnMouseMoveK=wì=ÇÉìíëÅÜW=Bei-MausBewegungK=a~=Ü~ÄÉå=ïáê=Éë=ÇçÅÜI=ïçå~ÅÜ=ïáê=ëìÅÜÉå>== cçäÖäáÅÜ=áëí=ÇáÉ=ÉêëíÉ=cê~ÖÉ=ÄÉ~åíïçêíÉíW=táê=â∏ååÉå=ÇìêÅÜ~ìë=~ìÅÜ=òìã=bêÉáÖJ åáë=j~ìëÄÉïÉÖìåÖ=ΩÄÉê=ÇÉã=_ìííçå=ÉáåÉ=bêÉáÖåáëéêçòÉÇìê=ëÅÜêÉáÄÉåK==
== _áäÇ=OKNMW=lÄàÉâíáåëéÉâíçê=ÇÉë=_ìííçåëI=oÉÖáëíÉêÄä~íí=bobfdkfppb= a~òì=ï®ÜäÉå=ïáê=áå=ÇÉê=iáëíÉ=~ääÉê=ÄÉÜ~åÇÉäÄ~êÉå=bêÉáÖåáëëÉ=Ç~ë=bêÉáÖåáë=OnMouseMove=~ìëK=a~åå=∏ÑÑåÉí=ëáÅÜ=êÉÅÜíë=Éáå=äÉÉêÉë=ïÉá≈Éë=cÉäÇ=E_áäÇ=OKNNFK==
=
== _áäÇ=OKNNW=^ìëï~Üä=ÇÉë=ÖÉïΩåëÅÜíÉå=káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉë== PP =
O= lÄàÉâíI=bêÉáÖåáëI=bêÉáÖåáëéêçòÉÇìê= == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 2= ÇáÉ= zipJa~íÉá= DKap02.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap02= ÇáÉ= mêçàÉâíJa~íÉá= proj_231.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap02=ÇáÉ=a~íÉá=proj_231.bdsproj=~ìëòìï®ÜäÉåK== == tÉáíÉê=ÖÉÜí=Éë=ëÅÜäáÉ≈äáÅÜ=ãáí=ÉáåÉã=ëÅÜåÉääÉå=açééÉäâäáÅâ=áå=ÇáÉëÉë=äÉÉêÉ=ïáÉJ ≈É=cÉäÇ=Ó=ìåÇ=ëÅÜçå=∏ÑÑåÉí=ëáÅÜ=ïáÉÇÉê=ïáÉ=ÄÉá=ÇÉå=pí~åÇ~êÇJbêÉáÖåáëëÉå= Ç~ë= nìÉääíÉñíÑÉåëíÉê= ãáí= ÇÉã= o~ÜãÉå= ÇÉê= bêÉáÖåáëéêçòÉÇìêK= a~ãáí= áëí= ~ìÅÜ= ÇáÉ= òïÉáíÉ=cê~ÖÉ=ÄÉ~åíïçêíÉíK= få= ÇÉê= çÄÉêëíÉå= hçéÑòÉáäÉ= ÇÉë= o~ÜãÉåë= ÇÉê= bêÉáÖåáëéêçòÉÇìê= äáÉëí= ã~å= êÉÅÜíë= îçã= mìåâí= ÇáÉ= wÉáÅÜÉåÑçäÖÉ= Button1MouseMoveI= Éë= Ü~åÇÉäí= ëáÅÜ= í~íë®ÅÜäáÅÜ= ìã= ÇÉå= o~ÜãÉå= ÑΩê= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= bêÉáÖåáë= j~ìëÄÉïÉÖìåÖ= ΩÄÉê= ÇÉã= _ìííçåK= cΩê=ÇÉå=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ïçääÉå=ïáê=îçêÉêëí=ïáÉÇÉê=åìê=ÉáåÉ=ÉáåÑ~J ÅÜÉ=jáííÉáäìåÖ=ï®ÜäÉåK== procedure TForm1.Button1MouseMove( Sender:TObject; Shift:TShiftState; X,Y:Integer ); begin ShowMessage('Der Mauszeiger bewegt sich über dem Button NORD') //Inhalt end;
a~ÄÉá=áëí=ÇáÉ=ä~åÖÉ=hçéÑòÉáäÉ=ÜáÉê=~ìë=ëÅÜêÉáÄíÉÅÜåáëÅÜÉå=dêΩåÇÉå=òÉêäÉÖí=ïçêJ ÇÉåX= áã= ÉáÖÉåíäáÅÜÉå= aÉäéÜáJnìÉääíÉñíÑÉåëíÉê= áëí= Ç~ë= åáÅÜí= å∏íáÖK= wìê= §ÄìåÖ= â∏ååíÉå=ïÉáíÉêÉ=ÇêÉá=_ìííçåë=ãáí=ÇÉå=_ÉëÅÜêáÑíìåÖÉå= lpqI=tbpq=ìåÇ=p§a=~å= ÇÉå= ÉåíëéêÉÅÜÉåÇÉå= píÉääÉåI= Éíï~ë= ÉåíÑÉêåí= îçåÉáå~åÇÉêI= ~ìÑ= ÇÉã= cçêãìä~ê= éä~íòáÉêí= ïÉêÇÉåK= wì= àÉÇÉã= _ìííçå= ïáêÇ= Ç~åå= ÑΩê= Ç~ë= bêÉáÖåáë= j~ìëÄÉïÉÖìåÖ= ÇÉê= o~ÜãÉå= ÇÉê= òìÖÉÜ∏êáÖÉå= bêÉáÖåáëéêçòÉÇìê= ÄÉëÅÜ~ÑÑíI= ìåÇ= ~åëÅÜäáÉ≈ÉåÇ= ïáêÇ=àÉïÉáäë=ÇáÉ=é~ëëÉåÇÉ=jáííÉáäìåÖ=éêçÖê~ããáÉêíK== t~ë=áëí=~ÄÉêI=ïÉåå=ëáÅÜ=ÇÉê=j~ìòÉáÖÉê=åáÅÜí=ΩÄÉê=ÉáåÉã=ÇÉê=_ìííçåë=ÄÉÑáåÇÉí\= a~åå=Ó=äçÖáëÅÜ=Ó=ÄÉÑáåÇÉí=Éê=ëáÅÜ=ΩÄÉê=ÇÉã=cçêãìä~êK=aáÉ=iáëíÉ=ÇÉê=cçêãìä~êJ bêÉáÖåáëëÉI=òì=ÇÉåÉå=ÉáåÉ=bêÉáÖåáëéêçòÉÇìê=ÖÉëÅÜêáÉÄÉå=ïÉêÇÉå=â~ååI=áëí=ä~åÖI= ëÉÜê= ä~åÖK= jÉÜê= ~äë= ÇêÉá≈áÖ= báåíê®ÖÉ= ìãÑ~ëëí= ëáÉX= å~íΩêäáÅÜ= ÄÉÑáåÇÉí= ëáÅÜ= ~ìÅÜ= ÇÉê=báåíê~Ö=OnMouseMove=áå=ÇáÉëÉê=iáëíÉK= tÉê=àÉÇçÅÜ=~ìÑ=ÇáÉ=äçÖáëÅÜÉ=fÇÉÉ=âçããíI=ÑçäÖäáÅÜ=ÉáåÉ=ÑΩåÑíÉ=bêÉáÖåáëéêçòÉÇìê= òìã=bêÉáÖåáë=j~ìëÄÉïÉÖìåÖ= ΩÄÉê=ÇÉã=cçêãìä~ê= òì=éêçÖê~ããáÉêÉåI=ÇÉê= ïáêÇ= ÉáåëíïÉáäÉå=îáÉä=ûêÖÉê=ÄÉâçããÉåK=t~êìã\== PQ= =
OKP== báåÑ~ÅÜÉ=bêÉáÖåáëéêçòÉÇìêÉå=òì=káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉå= kìåI=Ç~ë=jáííÉáäìåÖëÑÉåëíÉêI=Ç~ë=ãáí=ÇÉã=^ìÑêìÑ=ÇÉê=mêçòÉÇìê=ShowMessage=~åÖÉJ ÑçêÇÉêí=ïáêÇI==ïáêÇ=îçå=aÉäéÜá=ëíÉíë=áå=ÇÉê=jáííÉ=ÇÉë=_áäÇëÅÜáêãë=ÖÉ∏ÑÑåÉíI=~äëç= ΩÄÉê=ÇÉã=cçêãìä~êK== tÉåå= ã~å= ÇáÉëÉ= jáííÉáäìåÖ= ãáí= = OK= = ÄÉëí®íáÖí= ìåÇ= Ç~ë= jáííÉáäìåÖëÑÉåëíÉê= îÉêJ ëÅÜïáåÇÉí=Ó=ïç=ÄÉÑáåÇÉí=ëáÅÜ=Ç~åå=ÇÉê=j~ìëòÉáÖÉê\=k~íΩêäáÅÜ=Ó=ïáÉÇÉê=ΩÄÉê=ÇÉã= cçêãìä~ê>=a~ë=jáííÉáäìåÖëÑÉåëíÉê=ÉêëÅÜÉáåí=ìåîÉêòΩÖäáÅÜ=ïáÉÇÉê=ìåÇ=ëç=ïÉáíÉêK== j~å= âçããí= ~ìë= ÇÉã= qÉìÑÉäëâêÉáë= åìê= ÜÉê~ìëI= ïÉåå= Ç~ë= jáíÉáäìåÖëÑÉåëíÉê= îçê= ÇÉã= pÅÜäáÉ≈Éå= îçêëáÅÜíáÖ= Ö~åò= ~å= ÇÉå= çÄÉêÉå= o~åÇ= ÇÉë= _áäÇëÅÜáêãë= ÖÉòçÖÉå= ïáêÇK=báå=ëÅÜ∏åÉê=bÑÑÉâíI=~ìë=ÇÉã=ã~å=îáÉä=äÉêåÉå=â~ååK= cΩê=ÇáÉ=ÄÉáÇÉå=~åÇÉêÉå=ÄÉÜ~åÇÉäÄ~êÉå=j~ìëÉêÉáÖåáëëÉ=ãáí=ÇÉå=_ÉòÉáÅÜåìåÖÉå= OnMouseDown= ìåÇ= OnMouseUp= â∏ååíÉå= ïáê= ÉÄÉåëç= áåíÉêÉëë~åíÉ= oÉ~âíáçåÉå= éêçJ Öê~ããáÉêÉåK== §ÄÉêëÉíòÉå=ïáê=ÇáÉ=ÄÉáÇÉå=ÉåÖäáëÅÜÉå=sçâ~ÄÉäå=áå=ÇáÉ=ÇÉìíëÅÜÉ=péê~ÅÜÉW== • OnMouseDown= Z= _Éáã= oìåíÉêÇêΩÅâÉå= ÇÉê= äáåâÉå= j~ìëí~ëíÉI= ï®ÜêÉåÇ= ëáÅÜ= ÇÉê= j~ìëòÉáÖÉê=ΩÄÉê=ÇÉã=píÉìÉêÉäÉãÉåí=çÇÉê=ÇÉã=cçêãìä~ê=ÄÉÑáåÇÉíK== • OnMouseUp=Z=_Éáã=içëä~ëëÉå=ÇÉê=äáåâÉå=j~ìëí~ëíÉI=ï®ÜêÉåÇ=ëáÅÜ=ÇÉê=j~ìëòÉáJ ÖÉê=ΩÄÉê=ÇÉã=píÉìÉêÉäÉãÉåí=çÇÉê=ÇÉã=cçêãìä~ê=ÄÉÑáåÇÉíK====
2.3.2
Reaktionen auf Tastendruck
== ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 2= ÇáÉ= zipJa~íÉá= DKap02.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap02= ÇáÉ= mêçàÉâíJa~íÉá= proj_232.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap02=ÇáÉ=a~íÉá=proj_232.bdsproj=~ìëòìï®ÜäÉåK== == _Éíê~ÅÜíÉå=ïáê=Éáå= cçêãìä~ê= ãáí=ÉáåÉã=Ç~ê~ìÑ=ÄÉÑáåÇäáÅÜÉå= qÉñíÑÉåëíÉê=EEditFI= áå=Ç~ë=ÇÉê=kìíòÉê=ëÉäÄëí=Éíï~ë=Éáåíê~ÖÉå=â~åå=çÇÉê=áå=ÇÉã=Éê=ÉáåÉ=îçêÜ~åÇÉåÉ= báåíê~ÖìåÖ= îÉê®åÇÉêå= â~ååK= a~ë= bêÉáÖåáë= ûåÇÉêìåÖ= áëí= Ç~ë= pí~åÇ~êÇJbêÉáÖåáë= ~ã= píÉìÉêÉäÉãÉåí= qÉñíÑÉåëíÉêI= ïáê= Ü~ÄÉå= Éë= áã= ^ÄëÅÜåáíí= OKOKO= ëÅÜçå= âÉååÉå= ÖÉäÉêåíK== táê=ëíÉääÉå=ìåë=ÇáÉ=cê~ÖÉW=cΩê=ïáÉ=îáÉäÉ=ìåÇ=ïÉäÅÜÉ=káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉ= ~ã=qÉñíÑÉåëíÉê=â∏ååíÉå=ïáê=oÉ~âíáçåÉå=éêçÖê~ããáÉêÉå\== få=ÇÉê=oÉÖáëíÉêâ~êíÉ=bobfdkfppb=ëáåÇ=ïáÉÇÉêìã=îáÉäÉ=báåíê®ÖÉ=ÉåíÜ~äíÉåK=cΩê=ÇáÉ= kìíòÉêÉáåïáêâìåÖ=q~ëíÉ=ïìêÇÉ=ÖÉÇêΩÅâíI=~ìÑ=ÉåÖäáëÅÜ= OnKeyPressI=áëí=ÄÉêÉáíë=ÇÉê= o~ÜãÉå=ÇÉê=bêÉáÖåáëéêçòÉÇìê=~åÖÉÑçêÇÉêí=ïçêÇÉå=Ó=áå=_áäÇ=OKNO=ÉêâÉååÄ~ê=~å= ÇÉã=báåíê~Ö=áå=ÇÉã=ïÉá≈Éå=cÉäÇ=åÉÄÉå=OnKeyPressK= PR =
O= lÄàÉâíI=bêÉáÖåáëI=bêÉáÖåáëéêçòÉÇìê= aÉê=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ÄÉëíÉÜí=ïáÉÇÉê=îçêÉêëí=åìê=~ìë=ÇÉã=ÉáåÑ~ÅÜÉå= ^ìÑêìÑ=ÇÉê=mêçòÉÇìê=ShowMessageI=ãáí=ÇÉã=ÇÉê=kìíòÉê=ΩÄÉê=Ç~ë=báåíêÉíÉå=ÇÉë=bêJ ÉáÖåáëëÉë=áåÑçêãáÉêí=ïáêÇK== procedure TForm1.Edit1KeyPress(Sender: TObject; var Key: Char); begin ShowMessage('Eine Taste wurde gedrückt') end;
tÉê=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=íÉëíÉíI=ïáêÇ=Éêëí~ìåí=ÑÉëíëíÉääÉåI=Ç~ëë=âÉáåÉëÑ~ääë=àÉÇÉê= q~ëíÉåÇêìÅâ=ÇáÉ=éêçÖê~ããáÉêíÉ=oÉ~âíáçå=ÜÉêîçêêìÑíK==
= _áäÇ=OKNOW=bêÉáÖåáëëÉ=~ã=qÉñíÑÉåëíÉê= tÉÇÉê=~ìÑ=ÇáÉ= Shift Jq~ëíÉ=åçÅÜ=~ìÑ=ÇáÉ=q~ëíÉ= Strg =åçÅÜ=~ìÑ=ÇáÉ=cìåâíáçåëJ í~ëíÉå= F1 =Äáë= F12 =ÖáÄí=Éë=ÉáåÉ=oÉ~âíáçåK= fëí= Ç~ë= ëÅÜäÉÅÜí\= páÅÜÉê= åáÅÜíI= ÇÉåå= ëçåëí= â∏ååíÉ= àÉÇÉê= mêçÖê~ããáÉêÉê= ãáííÉäë= ÉáåÉê=bêÉáÖåáëéêçòÉÇìê=ÇáÉëÉ=ïáÅÜíáÖÉå=q~ëíÉåI=ÇáÉ=ÑΩê=ÇáÉ=^êÄÉáí=ÇÉë= _ÉíêáÉÄëJ ëóëíÉãë= ìåîÉêòáÅÜíÄ~ê= ëáåÇI= ÉáåÑ~ÅÜ= ~ì≈Éê= _ÉíêáÉÄ= åÉÜãÉå= çÇÉê= áå= áÜêÉê= táêJ âìåÖ=îÉêÑ®äëÅÜÉåK= cΩê=ÇáÉ=ÄÉáÇÉå=~åÇÉêÉå=q~ëí~íìêJbêÉáÖåáëëÉ== • OnKeyDown=Z=_Éá=ÜÉêìåíÉêÖÉÇêΩÅâíÉê=q~ëíÉ= • OnKeyUp=Z=_Éá=äçëÖÉä~ëëÉåÉê=q~ëíÉ= ïÉêÇÉå= ïáê= ëé®íÉê= îáÉääÉáÅÜí= áåíÉêÉëë~åíÉ= ^åïÉåÇìåÖÉå= ÑáåÇÉåX= áÜêÉ= kìíòìåÖ= áã=wìë~ããÉåÜ~åÖ=ãáí=ÇÉê=mêçòÉÇìê=ShowMessage=áëí=åáÅÜí=ÖΩåëíáÖK==
2.3.3 ==
Fokus-Ereignisse
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 2= ÇáÉ= zipJa~íÉá= DKap02.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap02= ÇáÉ= mêçàÉâíJa~íÉá= proj_233.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap02=ÇáÉ=a~íÉá=proj_233.bdsproj=~ìëòìï®ÜäÉåK== == PS= =
OKP== báåÑ~ÅÜÉ=bêÉáÖåáëéêçòÉÇìêÉå=òì=káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉå= _Éîçê= ïáê= ìåë= ÇÉå= ÄÉáÇÉå= káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉå= OnEnter= ìåÇ= OnExit= òìJ ïÉåÇÉåI=ÇáÉ=ÑΩê=àÉÇÉë=píÉìÉêÉäÉãÉåí=ÄÉÜ~åÇÉäÄ~ê=ëáåÇI=ãΩëëÉå=ïáê=Éêëí=Éáåã~ä= ÇÉå=ïáÅÜíáÖÉå=_ÉÖêáÑÑ=ÇÉë=cçâìë=âä®êÉåK== wìê= fääìëíê~íáçå= éä~íòáÉêÉå= ïáê= ~ìÑ= ÉáåÉã= cçêãìä~ê= ÑΩåÑ= píÉìÉêÉäÉãÉåíÉI= ìåÇ= ï®ÜäÉå= Ç~ÄÉáI= ìã= ëé®íÉê= ÇÉå= tÉÅÜëÉä= ÇÉë= cçâìë= Öìí= ÄÉçÄ~ÅÜíÉå= òì= â∏ååÉåI= ÉáåÉ=Ö~åò=ÄÉëíáããíÉ=oÉáÜÉåÑçäÖÉW== wìÉêëí= âçããí= å~ÅÜ= äáåâë= çÄÉå= ÇáÉ= pÅÜ~äíÑä®ÅÜÉ= Button1K= oÉÅÜíë= Ç~åÉÄÉå= ïáêÇ= Ç~ë=qÉñíÑÉåëíÉê=Edit1=~åÖÉçêÇåÉíK== bêåÉìíÉê=dêáÑÑ=áå=ÇáÉ=iáëíÉ=ÇÉê=píÉìÉêÉäÉãÉåíÉI=ìåÇ=äáåâë=ìåíÉå=ïáêÇ=ïÉáíÉê=ÇáÉ= ï~~ÖÉêÉÅÜíÉ= Scrollbar1= ~åÖÉçêÇåÉíK= oÉÅÜíë= ìåíÉå= ïáêÇ= Ç~å~ÅÜ= ÇÉê= Button2= éä~íòáÉêíI= ìåÇ= òìã= pÅÜäìëë= çêÇåÉå= ïáê= êÉÅÜíë= çÄÉå= ÇáÉ= Checkbox1= ÉáåK= aáÉ= båíJ ïìêÑëéÜ~ëÉ= áëí= ÄÉÉåÇÉíI= ïáê= ëéÉáÅÜÉêå= Unit= ìåÇ= Projekt= å~ÅÜÉáå~åÇÉê= ëçI= ïáÉ= Éë=áå=^ÄëÅÜåáíí=NKOKP=ÄÉëÅÜêáÉÄÉå=ïìêÇÉK== báå=häáÅâ=~ìÑ=ÇáÉ=pÅÜ~äíÑä®ÅÜÉ=ãáí=ÇÉã=å~ÅÜ=êÉÅÜíë=ÖÉêáÅÜíÉíÉå=aêÉáÉÅâ=çÇÉê=Éáå= aêìÅâ=~ìÑ=ÇáÉ=q~ëíÉ= F9 =Ó=ÇáÉ=i~ìÑòÉáí=ÄÉÖáååíK== pÉÜÉå=ïáê=áå=_áäÇ=OKNP=ÖÉå~ì=ÜáåW=rã=ÇáÉ=_ÉëÅÜêáÑíìåÖ=îçå= Button1=òáÉÜí=ëáÅÜ= ÉáåÉ=ÖÉëíêáÅÜÉäíÉ=iáåáÉK=a~ë=ÄÉÇÉìíÉíW=aÉê=ÉêëíÉ=_ìííçå=ÄÉëáíòí=ÇÉå=cçâìëK== kìå= ëçääíÉå= ïáê= ÇáÉ= j~ìë= ïÉÖäÉÖÉå= ìåÇ= ÇáÉ= q~Äìä~íçêJq~ëíÉ= ~ìÑ= ÇÉê= q~ëí~íìê= ëìÅÜÉåK= páÉ= ÄÉÑáåÇÉí= ëáÅÜ= Ö~åò= äáåâë= ìåÇ= áëí= ÄÉëÅÜêáÑíÉí= ãáí= òïÉá= ΩÄÉêÉáå~åÇÉê= äáÉÖÉåÇÉåI=ÉåíÖÉÖÉåÖÉëÉíòíÉå=mÑÉáäÉåK== _áäÇ=OKNQ=òÉáÖí=ìåëI=ï~ë=ëáÅÜ=å~ÅÜ=aêìÅâ=~ìÑ=ÇáÉ=q~Äìä~íçêí~ëíÉ=®åÇÉêíW=aáÉ=iáJ åáÉ=ìã=ÇáÉ=_ÉëÅÜêáÑíìåÖ=îçå= Button1=áëí=îÉêëÅÜïìåÇÉåI=ÇÉê=fåÜ~äí=îçå= Edit1=áëí= Ç~ÑΩê=Ää~ì=ìåíÉêäÉÖíK=
= _áäÇ=OKNPW=aÉê=_ìííçå=çÄÉå=äáåâë=ÄÉëáíòí=ÇÉå=cçâìë=
= _áäÇ=OKNQW=a~ë=qÉñíÑÉåëíÉê=ÄÉëáíòí=ÇÉå=cçâìë= == = PT =
O= lÄàÉâíI=bêÉáÖåáëI=bêÉáÖåáëéêçòÉÇìê= =
= _áäÇ=OKNRW=aáÉ=pÅêçääÄ~ê=áëí=åìå=ÑçâìëëáÉêí=
= _áäÇ=OKNSW=aÉê=_ìííçå=ìåíÉå=êÉÅÜíë=Ü~í=ÇÉå=cçâìë==
= _áäÇ=OKNTW=cçâìëëáÉêíÉ=`ÜÉÅâÄçñ= aáÉ=råíÉêëÅÜêáÑí=îçå=_áäÇ=OKNQ=Éêâä®êí=ÉëW=aÉê=cçâìëI=ÇK=ÜK=ÇáÉ=j~êâáÉêìåÖ=ÇÉëàÉJ åáÖÉå=píÉìÉêÉäÉãÉåíëI=Ç~ë=~âíìÉää=ÄÉÇáÉåÄ~ê=áëí=ìåÇ=kìíòÉêÉáåÖ~ÄÉå=ÉåíÖÉÖÉåJ åÉÜãÉå=â~ååI=áëí=òìê=qÉñíÄçñ=ÖÉï~åÇÉêíK== tçÜáå=ï~åÇÉêí=ÇÉê=cçâìë=ÄÉáã=å®ÅÜëíÉå=aêìÅâ=~ìÑ=ÇáÉ=q~Äìä~íçêí~ëíÉ\=táêÇ=Éê= çÄÉå= ïÉáíÉêï~åÇÉêå= çÇÉê= ïáêÇ= Éáå= ~åÇÉêÉë= píÉìÉêÉäÉãÉåí= ÑçâìëëáÉêí\= få= _áäÇ= OKNR=ëÉÜÉå= ïáê=ÇáÉ=^åíïçêíW=aáÉ= pÅêçääÄ~ê=ÄÉâçããí=ÇÉå=cçâìëK=t~êìã\=bêáåJ åÉêå= ïáê= ìåë= ~å= ÇáÉ= oÉáÜÉåÑçäÖÉI= áå= ÇÉê= ïáê= ÇáÉ= píÉìÉêÉäÉãÉåíÉ= ~ìÑ= ÇÉã= cçêJ ãìä~ê=éä~íòáÉêíÉåK=eáÉê=òÉáÖí=ëáÉ=ëáÅÜK= t~ë= âçããí= ~äë= k®ÅÜëíÉë\= bêáååÉêå= ïáê= ìåë= Ó= Ç~å~ÅÜ= Ü~ííÉå= ïáê= ÇÉå= òïÉáíÉå= _ìííçå=~ìÑ=Ç~ë=cçêãìä~ê=ÖÉòçÖÉåK=bêåÉìíÉê=aêìÅâ=~ìÑ=ÇáÉ=q~Äìä~íçêí~ëíÉ=ÑçâìëJ ëáÉêí=ÑçäÖäáÅÜ=ÇÉå=òïÉáíÉå=_ìííçå=êÉÅÜíë=ìåíÉå=EëáÉÜÉ=_áäÇ=OKNSFK== ^äë= äÉíòíÉë= Ü~ííÉå= ïáê= ÇáÉ= `ÜÉÅâÄçñ= ~åÖÉçêÇåÉíI= ÇÉãå~ÅÜ= ÉêÜ®äí= ëáÉI= ïáÉ= _áäÇ= OKNT= òÉáÖíI= Éêëí= ÄÉáã= äÉíòíÉå= aêìÅâ= ~ìÑ= ÇáÉ= q~Äìä~íçêí~ëíÉ= ÇÉå= cçâìëK= tÉê= Éë= ~ìëéêçÄáÉêíI=ÇÉê=ëíÉääí=å~íΩêäáÅÜ=ëçÑçêí=ÑÉëíI=Ç~ëë=ÄÉá=ÉêåÉìíÉã=aêìÅâ=~ìÑ=ÇáÉ=q~ÄìJ ä~íçêí~ëíÉ=ÇÉê=cçâìë=ïáÉÇÉê=êÉáÜìã=ï~åÇÉêíK== tÉåå=ÇÉê=kìíòÉê=ÇÉå=cçâìë=~ìÑ=Éáå=píÉìÉêÉäÉãÉåí=ëÉíòí=ïáää=Éê=Éë=~åëÅÜäáÉ≈ÉåÇ= ÄÉÇáÉåÉåK==
PU= =
OKP== báåÑ~ÅÜÉ=bêÉáÖåáëéêçòÉÇìêÉå=òì=káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉå= ^ã=ÇÉìíäáÅÜëíÉå=ïáêÇ=Ç~ë=ÄÉá=ÉáåÉã=qÉñíÑÉåëíÉêK=bêëí=ïáêÇ=ÑçâìëëáÉêí=Ó=ãáí=q~ÄìJ ä~íçêí~ëíÉ=çÇÉê=j~ìë=ïáêÇ=ÉÇáíáÉêíI=ÉáåÖÉíê~ÖÉå=çÇÉê=ÖÉ®åÇÉêí=çÇÉê=ÖÉä∏ëÅÜíK== ^êÄÉáíÉí=ÇÉê=kìíòÉê=ãáí=ÇÉê=j~ìë=îÉêÄáåÇÉí=Éê=áã=oÉÖÉäÑ~ää=Ç~ë=pÉíòÉå=ÇÉë=cçâìë= ëçÑçêí=ãáí=ÇÉê=_ÉÇáÉåìåÖW=báå=j~ìëâäáÅâ=~ìÑ=ÉáåÉå=_ìííçå=ëÉíòí=ÇÉå=cçâìë=~ìÑ= ÇáÉëÉå= _ìííçåI= ÖäÉáÅÜòÉáíáÖ= ÉêÑçäÖí= ÄÉêÉáíë= ÇÉê= häáÅâK= táêÇ= Ç~ÖÉÖÉå= ÇÉê= _ìííçå= åáÅÜí=ãáí=ÇÉê=j~ìëI=ëçåÇÉêå=ãáí=ÇÉê=q~Äìä~íçêJq~ëíÉ=ÑçâìëëáÉêí=ä∏ëí=ÇáÉ=iÉÉêí~ëíÉ= çÇÉê=EnterJq~ëíÉ=ÇÉå=häáÅâ=~ìëK==
= _áäÇ=OKNUW=bêÉáÖåáë=łcçâìë=ÉêÜ~äíÉå=ÇÉë=ÉêëíÉå=_ìííçå= wì=àÉÇÉã=píÉìÉêÉäÉãÉåí=â~åå=ÑÉëíÖÉëíÉääí=ïÉêÇÉåI=çÄ=Éáå=kìíòÉê=ÇÉå=cçâìë=~ìÑ= ÇáÉëÉë= píÉìÉêÉäÉãÉåí= ëÉíòíK= aáÉëÉë= bêÉáÖåáë= ÜÉá≈í= ÄÉá= aÉäéÜá= OnEnter= Ó= Éë= áëí= çÑÑÉåëáÅÜíäáÅÜ=ìåíÉê=ÇÉê=iáëíÉ=ÇÉê=káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉ=òì=ëìÅÜÉåK== i~ëëÉå=ïáê=ìåë=òìã=_ÉáëéáÉä=ãáííÉäë=ÉáåÉê=bêÉáÖåáëéêçòÉÇìê=ãáííÉáäÉåI=ïÉåå=ÇÉê= ÉêëíÉ=_ìííçå=ãáí=ÇÉã=k~ãÉå=Button1=ÇÉå=cçâìë=ÉêÜ®äíK=t~ë=áëí=òì=íìå\== fã=båíïìêÑëãçÇìë=ïáêÇ=Button1=ìåÇ=áå=ÇÉê=oÉÖáëíÉêâ~êíÉ=bobfdkfppb=ÇÉë=lÄàÉâíJ áåëéÉâíçêë=ïáêÇ=Ç~ë=bêÉáÖåáë=OnEnter=~ìëÖÉï®Üäí=E_áäÇ=OKNUFK= báå=açééÉäâäáÅâ=áå=Ç~ë=äÉÉêÉ=ïÉá≈É=cÉäÇI=ìåÇ=ëÅÜçå=ÉêÜ~äíÉå=ïáê=ÇÉå=o~ÜãÉå= ÑΩê=ÇáÉ=ÉåíëéêÉÅÜÉåÇÉ=bêÉáÖåáëéêçòÉÇìêI=ÇÉå=ïáê=ïáÉ=ÄáëÜÉê=åìê=ãáí=ÉáåÉã=^ìÑJ êìÑ=ÇÉê=mêçòÉÇìê=ShowMessage=ÑΩääÉåW== procedure TForm1.Button1Enter(Sender: TObject); begin ShowMessage('Button1 hat den Fokus') end;
få=ÖäÉáÅÜÉê=tÉáëÉ=â∏ååÉå=ïáê=ìåë=å~íΩêäáÅÜ=ãáí=ÉáåÉê=bêÉáÖåáëéêçòÉÇìê=òìã=bêJ ÉáÖåáë=OnExit=~ìÅÜ=ë~ÖÉå=ä~ëëÉåI=ïÉåå=Éáå=píÉìÉêÉäÉãÉåí=ÇÉå=cçâìë=îÉêäáÉêíK=pÉJ ÜÉå=ïáê=ìåë=ÄÉáëéáÉäÜ~Ñí=~ìÅÜ=Ç~òì=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=~åK== procedure TForm1.Button2Exit(Sender: TObject); begin ShowMessage('Button 2 verlor den Fokus') end;
PV =
O= lÄàÉâíI=bêÉáÖåáëI=bêÉáÖåáëéêçòÉÇìê= pé®íÉêI=áã=^ÄëÅÜåáíí=QKQI= ïÉêÇÉå=ïáê= ÇÉê~êíáÖÉ=bêÉáÖåáëéêçòÉÇìêÉå=åìíòÉåI= ìã= ÇÉå=kìíòÉê=ÄÉáã=sÉêëìÅÜ=òì=Éêí~ééÉåI=ÉáåÉ=qÉñíÄçñ=òì=îÉêä~ëëÉåI=çÜåÉ=Ç~ëë=Éê= Ç~êáå=ÇáÉ=ÖÉïΩåëÅÜíÉ=^åÖ~ÄÉ=ÉáåÖÉíê~ÖÉå=Ü~íK== aÉåå=ÄÉáã=tÉÅÜëÉä=òì=ÉáåÉã=~åÇÉêÉå=píÉìÉêÉäÉãÉåí=íêáíí=ÖÉê~ÇÉ=Ç~ë=bêÉáÖåáë= cçâìëîÉêäìëí= ÇÉë= qÉñíÑÉåëíÉêë= Éáå= Ó= ìåÇ= Ç~ë= â∏ååÉå= ïáê= åìå= ÄÉÜ~åÇÉäåK= táê= ïÉêÇÉå=Ç~åå=ÇÉå=kìíòÉê=òìã=âçêêÉâíÉå=báåíê~Ö=òïáåÖÉåI=áåÇÉã=ïáê=áÜã=ÉáåÉ= ÉåíëéêÉÅÜÉåÇÉ=jáííÉáäìåÖ=òìâçããÉå=ä~ëëÉå=ìåÇ=Ç~åå=ÇÉå=cçâìë=òìêΩÅâëÉíòÉå>= hçããÉå= ïáê= òìã= pÅÜäìëë= ÇáÉëÉë= ^ÄëÅÜåáííë= åçÅÜ= Éáåã~ä= òìê= oÉáÜÉåÑçäÖÉ= ÇÉê= cçâìëëáÉêìåÖ=òìêΩÅâK= aáÉëÉ= oÉáÜÉåÑçäÖÉ= áëí= ÇÉëÜ~äÄ= ëç= ÄÉÇÉìíë~ãI= ïÉáä= Éë= áããÉê= åçÅÜ= ìåÇ= áããÉê= ïáÉÇÉê=kìíòÉê=ÖáÄíI=ÇáÉ=ãáí=eáäÑÉ=ÇÉê=q~Äìä~íçêí~ëíÉ=îçå=píÉìÉêÉäÉãÉåí=òì=píÉìJ ÉêÉäÉãÉåí=ïÉÅÜëÉäåI=îçê=~ääÉã=Ç~ååI=ïÉåå=Éë=ëáÅÜ=ìã=qÉñíÑÉåëíÉê=Ü~åÇÉäíI=áå= ÇáÉ=Éíï~ë=Éáåòìíê~ÖÉå=áëí=çÇÉê=áå=ÇÉåÉå=báåíê®ÖÉ=òì=îÉê®åÇÉêå=ëáåÇK== aÉåå=ÇáÉëÉ=^êí=ÇÉê=_ÉÇáÉåìåÖ=ÖÉÜí=ïÉëÉåíäáÅÜ=ëÅÜåÉääÉê=~äë=ÇÉê=dêáÑÑ=å~ÅÜ=ÇÉê= j~ìë=ìåÇ=Ç~ë=pìÅÜÉå=ãáí=ÇÉã=j~ìëòÉáÖÉêK== lÑÑÉåÄ~ê= ïÉêÇÉå= ÇáÉ= píÉìÉêÉäÉãÉåíÉ= ~ÄÉê= îçå= aÉäéÜá= ëç= ÑçâìëëáÉêíI= ïáÉ= ëáÉ= ~åÑ~åÖë=~ìÑ=ÇÉã=cçêãìä~ê=éä~íòáÉêí=ïìêÇÉåK== a~ë=ÄÉÇÉìíÉíI=Ç~ëë=Ç~ë=òìäÉíòí=ÉáåÖÉÑΩÖíÉ=píÉìÉêÉäÉãÉåí=~ìÅÜ=òìäÉíòí=ÑçâìëëáÉêí= ïáêÇI=ëÉäÄëí=ïÉåå=Éë=çÄÉå=äáåâë=ëíÉÜÉå=ëçääíÉK= jáí= _b^o_bfqbkq^_ri^qloobfebkclidb= ä®ëëí= ëáÅÜ= Ç~ë= àÉÇçÅÜ= éêçÄäÉãäçë= ®åJ ÇÉêåI=ïáÉ=áå=_áäÇ=OKNV=ÉêâÉååÄ~ê=áëíK=
=== _áäÇ=OKNVW=oÉáÜÉåÑçäÖÉ=ÇÉê=cçâìëëáÉêìåÖ=îÉê®åÇÉêå= =
QM= =
==
3
Weitere Steuerelemente k~ÅÜÇÉã= Ç~ë= îçêáÖÉ= h~éáíÉä= ~å= ÇÉå= o~åÇ= ÇÉë= qÜÉçêÉíáëÅÜÉå= â~ã= ãáí= ëÉáåÉå= îáÉäÉå=åÉìÉå=_ÉÖêáÑÑÉåI=ïçääÉå=ïáê=ÉáåÉ=âìêòÉ=ÖÉáëíáÖÉ=oìÜÉé~ìëÉ=ÉáåäÉÖÉåK== ^ÄÉê=ï~ê=Éë=ÇÉåå=ïáêâäáÅÜ=ëç=ëÅÜäáãã\=tÉåå=ÉáåÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=ÉåíïçêÑÉå= ìåÇ=ëÅÜ∏å=ÖÉëí~äíÉí=áëí=â~åå=ÇçÅÜ=ÇáÉ=å®ÅÜëíÉ=^êÄÉáíëÉí~ééÉ=åìê=Ç~êáå=ÄÉëíÉÜÉåI= Ç~ëë= ã~å= ÇáÉ= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= ãáí= iÉÄÉå= ÉêÑΩääíK= a~ë= ÜÉá≈íI= Ç~ëë= ã~å= ëáÅÜ= ΩÄÉêäÉÖíI=ÄÉá=ïÉäÅÜÉê=kìíòÉêÉáåïáêâìåÖ=~å=ïÉäÅÜÉã=píÉìÉêÉäÉãÉåí=ïÉäÅÜÉ=oÉ~âJ íáçå=ÉêÑçäÖÉå=ëçääK== aêÉá=cê~ÖÉå=tç=Ó=tçÄÉá=Ó=t~ë=ëçääíÉ=ã~å=ëáÅÜ=ÇÉëÜ~äÄ=áããÉê=ëíÉääÉåW== • tçW=tÉäÅÜÉë=píÉìÉêÉäÉãÉåí=ëçää=ΩÄÉêÜ~ìéí=^ìëÖ~åÖëéìåâí=ÑΩê=ÉáåÉ=oÉ~âíáçå= ëÉáå\=pçää=Éíï~ë=é~ëëáÉêÉåI=ïÉåå=ÇÉê=kìíòÉê=ëáÅÜ=ãáí=ÇÉã=_ìííçå=ÄÉëÅÜ®ÑíáÖí= çÇÉê= ïÉåå= Éê= áã= qÉñíÑÉåëíÉê= ®åÇÉêí= çÇÉê= ïÉåå= Éê= ãáí= ÇÉã= j~ìëòÉáÖÉê= ~ã= pÅÜáÉÄÉêÉÖäÉê=Ü~åíáÉêí=çÇÉê=KKK=çÇÉê=KKK=çÇÉê=\== • tçÄÉáW=tÉäÅÜÉ= kìíòÉêÉáåïáêâìåÖ=ëçää=ÉáåÉ=oÉ~âíáçå=ÜÉêîçêêìÑÉå\=fëí= Éë=Ç~ë= ΩÄäáÅÜÉ=pí~åÇ~êÇJbêÉáÖåáëI=~ìÑ=Ç~ë=ïáê=ÉáåÉ=^åíïçêí=ÑáåÇÉå=ëçääÉåI=ÇÉê=häáÅâI= ÇáÉ=ûåÇÉêìåÖ=Ó=çÇÉê=ïçääÉå=ïáêI=Ç~ëë=ÄÉá=ÉñçíáëÅÜÉå= káÅÜíJpí~åÇ~êÇJbêÉáÖJ åáëëÉå= EòK= _K= j~ìëÄÉïÉÖìåÖI= cçâìëîÉêäìëíI= q~ëíÉ= âçããí= ÜçÅÜF= Éíï~ë= é~ëJ ëáÉêí\= • t~ëW= táÉ= ëçää= ÇáÉ= oÉ~âíáçå= Ç~åå= ~ìëëÉÜÉå\= eáÉê= ëáåÇ= ïáê= Éêëí= ~ã= ^åÑ~åÖI= ÄáëÜÉê=â∏ååÉå=ïáê=~äë=ÉáåòáÖÉ=oÉ~âíáçå=åìê=ÇáÉ= ShowMessageJmêçòÉÇìê=~ìÑêìJ ÑÉåK=aÉã=ï~ë=ïÉêÇÉå=ïáê=åçÅÜ=îáÉäÉ=h~éáíÉä=ïáÇãÉåK= råÇ=ïÉáä=~ìÅÜ=Ç~ë=ÖêìåÇäÉÖÉåÇÉ=cçêãìä~êI=~ìÑ=ÇÉã=ÇáÉ=píÉìÉêÉäÉãÉåíÉ=~åÖÉJ çêÇåÉí=ïÉêÇÉåI=ëÉäÄëí=òìã=^ìëÖ~åÖëéìåâí=ÑΩê=oÉ~âíáçåÉå=ïÉêÇÉå=â~ååI=ãìëëJ íÉå= ïáê= ìåë= îçã= ÉåÖÉå= _ÉÖêáÑÑ= ÇÉë= píÉìÉêÉäÉãÉåíë= ä∏ëÉå= ìåÇ= îáÉäãÉÜê= îçã= ëáÅÜíÄ~êÉå=qÉáä=ÉáåÉë=îáëìÉääÉå=lÄàÉâíë=ëéêÉÅÜÉåK== tÉáíÉê=ÉêÑìÜêÉå=ïáê=Ç~ååI=Ç~ëë=ÇáÉ=ÄÉ~ÄëáÅÜíáÖíÉ=oÉ~âíáçå=ëíÉíë=ÇìêÅÜ=ÇÉå= pí~êí= ÉáåÉê=bêÉáÖåáëéêçòÉÇìê=ÉêÑçäÖíK=bêÉáÖåáëéêçòÉÇìêÉå=ÄÉëíÉÜÉå=~ìë=o~ÜãÉå=ìåÇ=fåJ Ü~äíK=råÇ=ÇÉå=o~ÜãÉå=Ó=aÉäéÜá=ëÉá=a~åâ=Ó=ÄÉâçããÉå=ïáê=áããÉê=ÖÉëÅÜÉåâíK=a~= Äê~ìÅÜíÉå=ïáê=ÇçÅÜ=åìê=åçÅÜ=òì=ÉêÑ~ÜêÉåI=ïáÉ=ã~å=ÇáÉëÉë=dÉëÅÜÉåâ=ÄÉëíÉääíW=báå= açééÉäâäáÅâ=~å=ÇÉê=êáÅÜíáÖÉå=píÉääÉ=êÉáÅÜíK=bÜêäáÅÜI=ï~ê=Ç~ë=ïáêâäáÅÜ=ëç=ëÅÜïÉê\=== kìå= ~ÄÉêI= ïáÉ= ~åÖÉâΩåÇáÖíI= òìã= ÖÉáëíáÖÉå= ^ìëêìÜÉå= Éáå= Ü~åÇïÉêâäáÅÜÉê= báåJ ëÅÜìÄW== táÉ=éä~íòáÉêí=ã~å=iáëíÉå=ìåÇ=jÉåΩë=~ìÑ=ÉáåÉã=cçêãìä~ê=ìåÇ=ëíÉääí=áÜêÉ=pí~êíÉáJ ÖÉåëÅÜ~ÑíÉå=Éáå\== QN =
P= tÉáíÉêÉ=píÉìÉêÉäÉãÉåíÉ=
3.1
Steuerelement Liste (ListBox) tÉåå= ïáê= ÉáåÉ= E^ìëï~ÜäJFiáëíÉ= EListBoxF= ~ìÑ= Ç~ë= cçêãìä~ê= ÄêáåÖÉå= ïçääÉåI= ãΩëëÉå=ïáê=ÄÉáã=~äíÉå=aÉäéÜá=áã=oÉÖáëíÉêÄä~íí=pq^ka^oa=ÇÉê=hçãéçåÉåíÉåé~J äÉííÉ= ÇáÉ= ÉåíëéêÉÅÜÉåÇÉ= pÅÜ~äíÑä®ÅÜÉ= ~ìëï®ÜäÉå= E_áäÇ= PKNFI= ÄÉá= aÉäéÜá= ULOMMR= ÑáåÇÉå=ïáê=Ç~ë=ÉåíëéêÉÅÜÉåÇÉ=póãÄçä=áå=h~íÉÖçêáÉ=pq^ka^oa=ÇÉê=qççäJm~äÉííÉW===
== _áäÇ=PKNW=pÅÜ~äíÑä®ÅÜÉ=ÑΩê=ÉáåÉ=iáëíÉ=áå=aÉäéÜá=T=ìåÇ=aÉäéÜá=ULOMMR= a~åå=ïáêÇ=Ç~ë=píÉìÉêÉäÉãÉåí=iáëíÉ=~ìÑ=ÇÉã=cçêãìä~ê=éä~íòáÉêíX=Éë=ÄÉâçããí=îçå= aÉäéÜá=ÇÉå=k~ãÉå= ListBox1K=aáÉ=dê∏≈É=ïáêÇ=ëç=ÉáåÖÉëíÉääíI=Ç~≈=ÇáÉ=ëé®íÉê=ÖÉJ ïΩåëÅÜíÉ=^åò~Üä=îçå=báåíê®ÖÉå=ëáÅÜíÄ~ê=ëÉáå=ïáêÇK== táÉ=_áäÇ=PKO=ÉêâÉååÉå=ä®ëëíI=ä~ëëÉå= ëáÅÜ=ΩÄÉê=ÇÉå= lÄàÉâíáåëéÉâíçê=ÇÉê=iáëíÉ=çÑJ ÑÉåÄ~ê=ëÉÜê=îáÉäÉ=pí~êíÉáÖÉåëÅÜ~ÑíÉå=îçêÉáåëíÉääÉåK=
= _áäÇ=PKOW=sáëìÉääÉë=lÄàÉâí=Listbox=ìåÇ=lÄàÉâíáåëéÉâíçê=E^ìëëÅÜåáííF= a~òì= ÖÉÜ∏êÉå= å~íΩêäáÅÜ= ÇáÉ= eáåíÉêÖêìåÇÑ~êÄÉ= EColorF= ìåÇ= ÇáÉ= pÅÜêáÑí= EFontFK= açÅÜ=ïáÉ=â∏ååÉå=ïáê=ÉáåÉ=pí~êíÄÉäÉÖìåÖ=ÑΩê=ÇáÉ=^ìëï~ÜääáëíÉ=ÉêÜ~äíÉå\== _áäÇÉê=PKO=ìåÇ=PKP=òÉáÖÉå=ÇÉå=tÉÖW=wìÉêëí=áëí=ÇáÉ=báÖÉåëÅÜ~Ñí= Items=~ìëòìï®ÜJ äÉåI= Ç~åå= ïáêÇ= ãáí= ÇÉê= j~ìë= ~ìÑ= ÇáÉ= ÇêÉá= mìåâíÉ= êÉÅÜíë= åÉÄÉå= ETStringsF= ÖÉJ âäáÅâíK=pÅÜçå=∏ÑÑåÉí=ëáÅÜ=ÇÉê=píêáåÖäáëíÉåJbÇáíçê=E_áäÇ=PKPFI=áå=ÇÉëëÉå=cÉåëíÉê=ÄÉáJ ëéáÉäëïÉáëÉ= ÇáÉ= k~ãÉå= ÇÉê= ëÉÅÜòÉÜå= _ìåÇÉëä®åÇÉê= ÉáåÖÉíê~ÖÉå= ïÉêÇÉå= â∏åJ åÉåK=táÉ=ΩÄäáÅÜI=ïáêÇ=Ç~ÄÉá=ÇÉê=wÉáäÉåïÉÅÜëÉä=ÇìêÅÜ=ÇáÉ=ENTERJq~ëíÉ=îçêÖÉåçãJ ãÉåK= hìêòÉ= _Éëí®íáÖìåÖ= ãáí= OK = I= ìåÇ= ëÅÜçå= Ü~í= ÇáÉ= ^ìëï~ÜääáëíÉ= ÇáÉ= ÖÉJ ïΩåëÅÜíÉ=pí~êíÄÉäÉÖìåÖ=E_áäÇ=PKQFK== QO= =
PKN== píÉìÉêÉäÉãÉåí=iáëíÉ=Eiáëí_çñF= bêëí~ìåäáÅÜI= ~ÄÉê= îçêÉêëí= åáÅÜí= òì= ®åÇÉêåW= aÉê= lÄàÉâíáåëéÉâíçê= ÇÉê= iáëíÉ= ÄáÉíÉí= ìåë= äÉáÇÉê= âÉáåÉ= j∏ÖäáÅÜâÉáí= ~åI= Ç~ÑΩê= òì= ëçêÖÉåI= Ç~ëë= áå= ÇÉê= ^ìëï~ÜääáëíÉ= òì= _ÉÖáåå= ÇÉê= i~ìÑòÉáí= Éáå= ÄÉëíáããíÉë= _ìåÇÉëä~åÇI= òK= _K= p~ÅÜëÉåJ^åÜ~äíI= ÄÉêÉáíë= ~ìëÖÉï®Üäí=áëíK=pÅÜ~ÇÉK=t~êíÉå=ïáê=~ìÑ=ÇÉå=^ÄëÅÜåáíí=QKTKRK=
= _áäÇ=PKPW=píêáåÖäáëíÉåJbÇáíçê= ^ÄÉê=Éíï~ë= ~åÇÉêÉë=ïçääÉå=ïáê=åáÅÜí=îÉêÖÉëëÉåW= pÉáí=^ÄëÅÜåáíí=OKO=ïáëëÉå= ïáêI= Ç~ëë=ÇÉê=açééÉäâäáÅâ=~ìÑ=Éáå=píÉìÉêÉäÉãÉåí=ìåë=ëçÑçêí=ÇÉå=o~ÜãÉå=ÑΩê=ÇáÉ=bêJ ÉáÖåáëéêçòÉÇìê=òìã=pí~åÇ~êÇJbêÉáÖåáë=äáÉÑÉêíW== procedure TForm1.ListBox1Click(Sender: TObject); begin ShowMessage('Klick in der Listbox') end;
bíï~ë=Éêëí~ìåäáÅÜW=káÅÜí=ÇáÉ=ûåÇÉêìåÖ=ÇÉê=^ìëï~ÜäI=ëçåÇÉêå=ÄÉêÉáíë=ÇÉê=ÉáåÑ~J ÅÜÉ=häáÅâ=ïáêÇ=~äë=pí~åÇ~êÇJbêÉáÖåáë=ÇÉê=iáëíÉ=~åÖÉëÉÜÉåK== §ÄÉêòÉìÖÉå=ïáê=ìåëW=wì=_ÉÖáåå=ÇÉê=i~ìÑòÉáí=áëí=åáÅÜíë=~ìëÖÉï®Üäí=Ó=Ç~ë=â∏ååÉå= ïáê=åçÅÜ=åáÅÜíK=häáÅâÉå=ïáê=p~ÅÜëÉåJ^åÜ~äí=~åW=aáÉ=jÉäÇìåÖ= Klick in der Listbox=âçããíI=ìåÇ=p~ÅÜëÉåJ^åÜ~äí=áëí=ãáí=ÉáåÉã=_~äâÉå=ã~êâáÉêí=E_áäÇ=PKQFK== == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 3= ÇáÉ= zipJa~íÉá= DKap03.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap03= ÇáÉ= mêçàÉâíJa~íÉá= proj_31.dpr= ~ìëòìï®ÜäÉåK= táêÇ= ãáí= aÉäéÜá= ULOMMR= ÖÉ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap03=ÇáÉ=a~íÉá=proj_31.bdsproj=~ìëòìï®ÜäÉåK== == QP =
P= tÉáíÉêÉ=píÉìÉêÉäÉãÉåíÉ= häáÅâÉå= ïáê= åçÅÜ= Éáåã~ä= ~ìÑ= p~ÅÜëÉåJ^åÜ~äíW= táê= ÄÉëí®íáÖÉå= Ç~ãáí= åìê= åçÅÜ= Éáåã~ä= ÇáÉ= ÖÉíêçÑÑÉåÉ= ^ìëï~ÜäI= îÉê®åÇÉêå= åáÅÜíëK= q~íë®ÅÜäáÅÜI= ÇáÉ= jÉäÇìåÖ= Klick in der Listbox=âçããí=ïáÉÇÉêK== a~ë= ÄÉÇÉìíÉíI= Ç~ëë= ïáê= ìåë= ëé®íÉê= ÄÉëçåÇÉêÉ= jΩÜÉ= ÖÉÄÉå= ãΩëëÉåI= ïÉåå= ïáê= åìê=ÑΩê=ÉÅÜíÉ=ûåÇÉêìåÖ=ÇÉê=^ìëï~Üä=ÉáåÉ=oÉ~âíáçå=éêçÖê~ããáÉêÉå=ïçääÉåK=
== _áäÇ=PKQW=^ìëï~ÜääáëíÉ=å~ÅÜ=häáÅâ=~ìÑ=łp~ÅÜëÉåJ^åÜ~äí== §ÄêáÖÉåë=ÄÉÑáåÇÉí=ëáÅÜ=~ìÅÜ=ìåíÉê=ÇÉå=káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉå=ÇÉë=îáëìÉääÉå= lÄàÉâíë= ListBox1= âÉáå= OnChangeK= kÉÜãÉå= ïáê= ã~ä= ~åI= Ç~ëë= ÇáÉ= pÅÜ∏éÑÉê= îçå= aÉäéÜá=ëáÅÜ=Ç~ÄÉá=ëÅÜçå=Éíï~ë=ÖÉÇ~ÅÜí=Ü~ÄÉå=ïÉêÇÉåKKK=
3.2
Steuerelement Combobox tÉåå= ïáê= ÉáåÉ= ÉÇáíáÉêÄ~êÉ= ^ìëï~ÜääáëíÉ= EComboBoxF= ~ìÑ= Ç~ë= cçêãìä~ê= ÄêáåÖÉå= ïçääÉåI=ãΩëëÉå=ïáê=ÄÉá=aÉäéÜá=T=áã=oÉÖáëíÉêÄä~íí=pq^ka^oa=ÇÉê=hçãéçåÉåíÉåJ é~äÉííÉ=ÄòïK=ÄÉá=aÉäéÜá=ULOMMR=áå=ÖäÉáÅÜå~ãáÖÉå=h~íÉÖçêáÉ=pq^ka^oa=ÇÉê=qççäJ m~äÉííÉ=ÇáÉ=ÉåíëéêÉÅÜÉåÇÉ=pÅÜ~äíÑä®ÅÜÉ=~ìëï®ÜäÉå=E_áäÇ=PKRFK=
== _áäÇ=PKRW=pÅÜ~äíÑä®ÅÜÉ=ÑΩê=ÉáåÉ=ÉÇáíáÉêÄ~êÉ=^ìëï~ÜääáëíÉ=E`çãÄç_çñF===== aáÉëÉë= píÉìÉêÉäÉãÉåí= âçãÄáåáÉêí= ÉáåÉ= ÉáåÑ~ÅÜÉ= ^ìëï~ÜääáëíÉ= ãáí= ÉáåÉã= qÉñíJ ÑÉåëíÉêK= aáÉ= ÄÉáÇÉå= ïáÅÜíáÖëíÉå= pí~êíÉáÖÉåëÅÜ~ÑíÉåI= ÇáÉ= ÜáÉê= îçê~Ä= ÉáåÖÉëíÉääí= ïÉêÇÉå=â∏ååÉåI=ëáåÇ=áå=_áäÇ=PKS=~åÖÉÖÉÄÉåK=
= _áäÇ=PKSW=sçê~ìëï~Üä=ÇÉë=ÉêëíÉå=^åòÉáÖÉíÉñíÉë=ìåÇ=ÇÉê=i®åÖÉ== QQ= =
PKO== píÉìÉêÉäÉãÉåí=`çãÄçÄçñ= jáí=ÇÉê=báÖÉåëÅÜ~Ñí=Text=ïáêÇ=ÇáÉ=pí~êíÄÉëÅÜêáÑíìåÖ=ÑÉëíÖÉäÉÖíI=ìåÇ=ÇáÉ=báÖÉåëÅÜ~Ñí= DropDownCount=ëíÉìÉêíI=ïáÉ=îáÉäÉ=wÉáäÉå=ëé®íÉê= ~ìÑÖÉÄä®ííÉêí=ïÉêÇÉåK=táÉ= ÄÉá= ÇÉê= ÉáåÑ~ÅÜÉå= ^ìëï~ÜääáëíÉ= ïáêÇ= ÇáÉ= pí~êíÄÉäÉÖìåÖ= ÇÉê= iáëíÉ= ΩÄÉê= ÇáÉ= báÖÉåëÅÜ~Ñí= Items=ìåÇ=Ç~åå=ãáí=ÇÉã=píêáåÖäáëíÉåJbÇáíçê=îçêÖÉÖÉÄÉåK== == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 3= ÇáÉ= zipJa~íÉá= DKap03.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap03= ÇáÉ= mêçàÉâíJa~íÉá= proj_32.dpr= ~ìëòìï®ÜäÉåK= táêÇ= ãáí= aÉäéÜá= ULOMMR= ÖÉ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap03=ÇáÉ=a~íÉá=proj_32.bdsproj=~ìëòìï®ÜäÉåK== == _áäÇ=PKT=òÉáÖí=Ç~ë=píÉìÉêÉäÉãÉåíI=Ç~ë=îçå=aÉäéÜá=ÇÉå=k~ãÉå= ComboBox1=ÄÉâ~ãI= òì=i~ìÑòÉáíÄÉÖáåå=ìåÇ=~åëÅÜäáÉ≈ÉåÇ=å~ÅÜ=^ìëï~Üä=ÉáåÉë=~åÇÉêÉå=báåíê~ÖëK==
== _áäÇ=PKTW=píÉìÉêÉäÉãÉåí=ComboBox=òìê=i~ìÑòÉáí= i~ëëÉå= ïáê= ìåë= ~ìÅÜ= ÜáÉê= ΩÄÉêê~ëÅÜÉåI= ïÉäÅÜÉ= ^êí= ÇÉê= kìíòÉêÉáåïáêâìåÖ= ÇáÉ= pÅÜ∏éÑÉê=îçå=aÉäéÜá=ÜáÉê=~äë=pí~åÇ~êÇJbêÉáÖåáë=~åëÉÜÉåK== báå=açééÉäâäáÅâ=áã=båíïìêÑ=~ìÑ=Ç~ë=píÉìÉêÉäÉãÉåíI=ìåÇ=ëÅÜçå=ëÉÜÉå=ïáê=ÉëW== procedure TForm1.ComboBox1Change(Sender: TObject); begin ShowMessage('Es wird irgendwas geändert') end;
aáÉëã~ä=ïìêÇÉ=í~íë®ÅÜäáÅÜ=Ç~ë=bêÉáÖåáë=ûåÇÉêìåÖ=EChangeF=òìã=pí~åÇ~êÇJbêÉáÖåáë= ÉêÜçÄÉåX=ÇáÉ=jÉäÇìåÖ=bë=ïáêÇ=áêÖÉåÇï~ë=ÖÉ®åÇÉêí=âçããí=ëçÖ~ê=òïÉáã~äW=tÉåå= ÇÉê= kìíòÉê= ÇáÉ= iáëíÉ= ~ìÑÄä®ííÉêí= ìåÇ= Éáå= ~åÇÉêÉë= i~åÇ= ï®ÜäíX= ëáÉ= ÉêëÅÜÉáåí= ~ÄÉê= ~ìÅÜI=ïÉåå=ÇÉê=kìíòÉê=ÇÉå=k~ãÉå=ÇÉë=~åÖÉòÉáÖíÉå=i~åÇÉë=îÉê®åÇÉêå=ïáääK== QR =
P= tÉáíÉêÉ=píÉìÉêÉäÉãÉåíÉ=
3.3
Steuerelement Radiogruppe (RadioGroup) bêáååÉêå= ïáê= ìåë= ~å= ÇÉå= ^ÄëÅÜåáíí= NKQKPI= áå= ÇÉã=ÇáÉëÉ= ÜΩÄëÅÜÉå= âäÉáåÉå= êìåJ ÇÉå= ÉñâäìëáîÉå= g~JkÉáåJléíáçåÉåI= ÇáÉ= o~ÇáçÄìííçåëI= îçêÖÉëíÉääí= ïìêÇÉåK= báåÉå= o~ÇáçÄìííçå= â~åå= ã~å= ëíÉíë= åìê= ÉáåëÅÜ~äíÉåI= ëÉáåÉ= _ÉäÉÖìåÖ= îÉêäáÉêí= Éê= ~ìíçJ ã~íáëÅÜI=ïÉåå=Éáå=~åÇÉêÉê=o~ÇáçÄìííçå=ÇÉêëÉäÄÉå=dêìééÉ=ÉáåÖÉëÅÜ~äíÉí=ïáêÇK== aáÉ=dêìééÉåÄáäÇìåÖ=áëí=ÇÉãå~ÅÜ=òïáåÖÉåÇ=åçíïÉåÇáÖI=ïÉåå=ã~åI=ïáÉ=áå=_áäÇ= PKU=òì=ëÉÜÉåI=îÉêëÅÜáÉÇÉå=báÖÉåëÅÜ~ÑíÉå=~ÄÑê~ÖÉå=ä~ëëÉå=ïáääK=
== _áäÇ=PKUW=dêìééáÉêìåÖ=îçå=o~ÇáçÄìííçåë== lÜåÉ= dêìééÉåÄáäÇìåÖ= â∏ååíÉ= ëíÉíë= åìê= Éáå= ÉáåòáÖÉê= îçå= ÇáÉëÉå= ~ÅÜí= o~ÇáçJ Äìííçåë=ÉáåÉ=j~êâáÉêìåÖ=ÄÉëáíòÉåK=aáÉ=sÉêïÉåÇìåÖ=ÇÉë=píÉìÉêÉäÉãÉåíë=dêìééÉ== EGroupBoxF= áëí= ÉáåÉ= i∏ëìåÖ= ÇÉë= mêçÄäÉãëK= ^ÄÉê= Éë= áëí= òì= ÄÉ~ÅÜíÉåW= qêçíò= ÇÉê= dêìééáÉêìåÖ=ÄÉÜ®äí=àÉÇÉê=o~ÇáçÄìííçå=ëÉáåÉå=ÉáÖÉåÉå=k~ãÉåK== tÉåå= ã~å= ÄÉáëéáÉäëïÉáëÉ= ïáëëÉå= ïáääI= ï~ë= ÇÉê= kìíòÉê= ÖÉê~ÇÉ= ~ìëÖÉï®Üäí= Ü~í= ãìëë= ã~å= ÜáÉê= ~ÅÜí= bêÉáÖåáëéêçòÉÇìêÉå= ëÅÜêÉáÄÉåW= cΩê= ÇáÉ= fåÑçêã~íáçå= ΩÄÉê= Ç~ë=pí~åÇ~êÇJbêÉáÖåáë=~ã=o~ÇáçÄìííçå=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ= unter 70 kg=ãΩëëJ íÉå=ïáê=ëÅÜêÉáÄÉå== procedure TForm1.RadioButton1Click(Sender: TObject); begin ShowMessage('1. Gruppe, oben, wurde ausgewählt') end;
ìåÇ=ëç=ïÉáíÉê=Äáë== procedure TForm1.RadioButton8Click(Sender: TObject); begin ShowMessage('3. Gruppe, unten, wurde ausgewählt') end;
açÅÜ=Éë=ÖÉÜí=~ìÅÜ=ÉáåÑ~ÅÜÉêK=a~ÑΩê=ëíÉääí=aÉäéÜá=Ç~ë=îáëìÉääÉ=lÄàÉâí=o~ÇáçÖêìéJ éÉ=ERadioGroupF=òìê=sÉêÑΩÖìåÖK=
== _áäÇ=PKVW=pÅÜ~äíÑä®ÅÜÉ=ÑΩê=ÉáåÉ=o~ÇáçÖêìééÉ=EaÉäéÜá=ÄòïK=aÉäéÜá=ULEOMMRF= QS= =
PKP== píÉìÉêÉäÉãÉåí=o~ÇáçÖêìééÉ=Eo~ÇáçdêçìéF= _Éá= ÇÉê= mä~íòáÉêìåÖ= ÇÉê= ÇêÉá= píÉìÉêÉäÉãÉåíÉ= ÇÉê= ^êí= o~ÇáçÖêìééÉ= ëáÉÜí= Éë= ~åJ Ñ~åÖë=ëç=~ìëI=~äë=çÄ=åìê=ÇêÉá=ÉáåÑ~ÅÜÉ=dêìééÉå=~ìÑ=Ç~ë=cçêãìä~ê=ÖÉòçÖÉå=ïçêJ ÇÉå=ëáåÇ=E_áäÇ=PKNMFK=
= _áäÇ=PKNMW=mä~íòáÉêìåÖ=îçå=o~ÇáçÖêìééÉå==== fã= lÄàÉâíáåëéÉâíçê= â∏ååÉå= òìÉêëí= ÇáÉ= ΩÄäáÅÜÉå= báÖÉåëÅÜ~ÑíÉå= îçêÉáåÖÉëíÉääí= ïÉêÇÉåW=jáí=ÇÉê=báÖÉåëÅÜ~Ñí= Caption=ïáêÇ=ÑΩê=àÉÇÉ=o~ÇáçÖêìééÉ=ÇáÉ=dêìééÉåÄÉJ ëÅÜêáÑíìåÖ=ÑÉëíÖÉäÉÖíI=ãáí=ÇÉê=báÖÉåëÅÜ~Ñí=Color=ÇáÉ=eáåíÉêÖêìåÇÑ~êÄÉK== _Éíê~ÅÜíÉå=ïáê=ÇáÉ=jÉåÖÉ=ÇÉê=báÖÉåëÅÜ~ÑíÉå=ÖÉå~ìÉê=E_áäÇ=PKNNFI=ÑáåÇÉå=ïáê=ÇáÉ= ~ìë=ÇÉå=ÄÉáÇÉå=îçêáÖÉå=^ÄëÅÜåáííÉå=ÄÉâ~ååíÉ=ÇáÉ=báÖÉåëÅÜ~Ñí= ItemsI=ìåÇ=êÉÅÜíë= Ç~åÉÄÉå=ëíÉÜí=ïáÉÇÉê=ETStringsF=ãáí=ÇÉå=ÄÉâ~ååíÉå=ÇêÉá=mìåâíÉåK==
= _áäÇ=PKNNW=báåíê®ÖÉ=ãáí=ÇÉã=píêáåÖäáëíÉåJbÇáíçê=~ìëï®ÜäÉå= aÉëÜ~äÄ=ïÉêÇÉå=Ó=Ö~åò=~åÇÉêë=~äë=îçêÜáå=Ó=âÉáåÉ=ÉáÖÉåëí®åÇáÖÉå=o~ÇáçÄìííçåë= áå= ÇÉå= o~ÜãÉå= ÉáåÖÉÑΩÖíI= ëçåÇÉêå= ÇáÉ= o~ÇáçÖêìééÉ= ÉêÜ®äí= ÉáåÉ= áåíÉêåÉ= iáëíÉK= oÉáå=®ì≈ÉêäáÅÜ=Ç~ëëÉäÄÉI=~ÄÉê=áåíÉêå=ÉáåÉ=~åÇÉêÉ=^êÄÉáíëïÉáëÉW=kìå=â~åå=ã~å= bêÉáÖåáëëÉ=~å=ÇÉå=ÉáåòÉäåÉå=o~ÇáçÄìííçå=áå=ÉáåÉê=o~ÇáçÖêìééÉ=åáÅÜí=ãÉÜê=ÄÉJ Ü~åÇÉäåI=ëçåÇÉêå=åìê=Ç~ë=dêìééÉåJpí~åÇ~êÇJbêÉáÖåáëW== procedure TForm1.RadioGroup1Click(Sender: TObject); begin ShowMessage('Innerhalb dieser Gruppe wurde irgendwie geklickt') end;
a~ë=áëí=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=pí~åÇ~êÇJbêÉáÖåáëK=få=^ÄëÅÜåáíí=QKTKN=ïÉêÇÉå= ïáê=âÉååÉå=äÉêåÉåI=ïáÉ=ã~å=ÉêÑ®ÜêíI=ïÉäÅÜÉ=wÉáäÉ=~ìëÖÉï®Üäí=ïìêÇÉK== QT =
P= tÉáíÉêÉ=píÉìÉêÉäÉãÉåíÉ= §ÄêáÖÉåë= ëíÉääí= ÜáÉê= ÇÉê= lÄàÉâíáåëéÉâíçê= ãáí= ÇÉê= báÖÉåëÅÜ~Ñí= ItemIndex= Eáå= _áäÇ= PKNN= Öìí= òì= ëÉÜÉåF= ÇáÉ= j∏ÖäáÅÜâÉáí= ÄÉêÉáíI= Ç~ÑΩê= òì= ëçêÖÉåI= Ç~ëë= ÄÉêÉáíë= ÄÉáã= _ÉÖáåå=ÇÉê=i~ìÑòÉáí=Éáå=ÄÉëíáããíÉê=báåíê~Ö=ÇÉê=dêìééÉ=~ìëÖÉï®Üäí=áëíK== == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 3= ÇáÉ= zipJa~íÉá= DKap03.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap03= ÇáÉ= mêçàÉâíJa~íÉá= proj_33.dpr= ~ìëòìï®ÜäÉåK= táêÇ= ãáí= aÉäéÜá= ULOMMR= ÖÉ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap03=ÇáÉ=a~íÉá=proj_33.bdsproj=~ìëòìï®ÜäÉåK== == a~ÄÉá=áëí=~ÄÉê=ìåÄÉÇáåÖí=òì=ÄÉ~ÅÜíÉåI=Ç~ëë=ÄÉá=ÇÉå=îáëìÉääÉå=aÉäéÜáJlÄàÉâíÉå= ÇáÉ=w®ÜäìåÖ=áããÉê=ãáí=kìää=ÄÉÖáååíW=pçää=ÄÉáëéáÉäëïÉáëÉ=áå=ÇÉê=dêìééÉ=dÉïáÅÜí= ÇáÉ=wÉáäÉ=ìåíÉê=TM=âÖ=ÄÉáã=pí~êí=ÇÉê=i~ìÑòÉáí=ÄÉêÉáíë=~ìëÖÉï®Üäí=ëÉáåI=áëí=ÇáÉ=báJ ÖÉåëÅÜ~Ñí= ItemIndex= áã= lÄàÉâíáåëéÉâíçê= ~ìÑ= kìää= òì= ëÉíòÉå= E_áäÇ= PKNOFK= pçääíÉ= Ç~ÖÉÖÉå= ÇáÉ= ìåíÉêëíÉ= wÉáäÉ= ãáí= ÇÉê= _ÉëÅÜêáÑíìåÖ= ΩÄÉê= NMM= âÖ= òì= _ÉÖáåå= ÇÉê= i~ìÑòÉáí= ~ìëÖÉï®Üäí= ëÉáåI= ï®êÉ= ÇáÉ= báÖÉåëÅÜ~Ñí= ItemIndex= áã= lÄàÉâíáåëéÉâíçê= ~ìÑ=wïÉá=òì=ëÉíòÉå>==
= _áäÇ=PKNOW=sçê~ìëï~Üä=ÇÉê=pí~êíÄÉäÉÖìåÖ=
3.4
Steuerelement Menü (MainMenu) aÉåâÉå=ïáê=ÉáåÑ~ÅÜ=~å=Ç~ë=ÖìíÉ=~äíÉ=táåÇçïëW=báåÉ=çêÇÉåíäáÅÜÉ=_ÉåìíòÉêçÄÉêJ Ñä®ÅÜÉ=âçããí=ÜÉìíòìí~ÖÉ=çÜåÉ=Éáå=jÉåΩ=åáÅÜí=ãÉÜê=~ìëK=aáÉ=kìíòÉê=ëáåÇ=Ç~J ê~å= ÖÉï∏ÜåíX= aÉäéÜá= ÄáÉíÉí= ìåë= å~íΩêäáÅÜ= ~ìÅÜ= áã= oÉÖáëíÉêÄä~íí= pq^ka^oa= ÇÉê= hçãéçåÉåíÉåé~äÉííÉ= ÄòïK= aÉäéÜá= ULOMMR= áå= ÇÉê= ÖäÉáÅÜå~ãáÖÉå= h~íÉÖçêáÉ= ÇÉê= qççäJm~äÉííÉ=ÇáÉ=ÉåíëéêÉÅÜÉåÇÉ=pÅÜ~äíÑä®ÅÜÉ=~åK==
= _áäÇ=PKNPW=pÅÜ~äíÑä®ÅÜÉ=ÑΩê=Ç~ë=píÉìÉêÉäÉãÉåí=Ee~ìéíJFjÉåΩ= QU= =
PKQ== píÉìÉêÉäÉãÉåí=jÉåΩ=Ej~áåjÉåìF= dÉÜÉå=ïáê=ÇáÉëã~ä=îçã=wáÉä=~ìëW=táê=ã∏ÅÜíÉå=ÖÉêå=ìåëÉêÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ= ÇìêÅÜ=ÉáåÉ=jÉåΩäÉáëíÉ=ãáí=ëç=ÖÉå~ååíÉå=aêçéaçïåJjÉåΩë=~ííê~âíáîÉê=ÖÉëí~äíÉå= EëáÉÜÉ=_áäÇ=PKNQFK== hÉáå=mêçÄäÉãI=Éáåã~ä=ÖÉΩÄíI=ìåÇ=ëÅÜçå=â~åå=ã~å=íçääÉ=jÉåΩë=ÜÉêëíÉääÉåW==
= _áäÇ=PKNQW=cçêãìä~ê=ãáí=jÉåΩ= pÅÜêáíí=NW=aáÉ=pÅÜ~äíÑä®ÅÜÉ=ÑΩê=Ç~ë=píÉìÉêÉäÉãÉåí=ïáêÇ=~ìÑ=Ç~ë=cçêãìä~ê=ÖÉòçÖÉå= EïáÉ=òK=_K=áã=_áäÇ=PKNR=Ó=ëáÉ=îÉêëÅÜïáåÇÉí=ëçïáÉëç=òìê=i~ìÑòÉáíFK==
== _áäÇ=PKNRW=a~ë=jÉåΩJpóãÄçä=ïáêÇ=ÄÉäáÉÄáÖ=éä~íòáÉêí= pÅÜêáíí=OW=fã=oÉÖáëíÉêÄä~íí=bfdbkp`e^cqbk=ÇÉë=òìÖÉÜ∏êáÖÉå=lÄàÉâíáåëéÉâíçêë=ïáêÇ= ~åëÅÜäáÉ≈ÉåÇ=ÇáÉ=báÖÉåëÅÜ~Ñí=Items=~ìëÖÉï®Üäí=E_áäÇ=PKNSFK=
== _áäÇ=PKNSW=báÖÉåëÅÜ~Ñí=Items== pÅÜêáíí=PW=aÉê=häáÅâ=~ìÑ=ÇáÉ=ÇêÉá=mìåâíÉ=åÉÄÉå= (Menü)=∏ÑÑåÉí=ÇÉå=jÉåΩJbÇáíçêK= däÉáÅÜòÉáíáÖ=®åÇÉêí=ëáÅÜ=Ç~ë=oÉÖáëíÉêÄä~íí=bfdbkp`e^cqbk=áã=lÄàÉâíJfåëéÉâíçêX=Éë= ÉêëÅÜÉáåí=Éáå=äÉÉêÉë=ïÉá≈Éë=cÉäÇ=åÉÄÉå=CaptionK= pÅÜêáíí= QW= få= ÇáÉëÉë= äÉÉêÉI= ïÉá≈É= cÉäÇ= ïáêÇ= ÇáÉ= §ÄÉêëÅÜêáÑí= ÑΩê= Ç~ë= ÉêëíÉ= jÉåΩ= ÉáåÖÉíê~ÖÉå=ìåÇ=ãáí=Enter=ÄÉëí®íáÖíK=páÉ=ÉêëÅÜÉáåí=~å=ÇÉê=êáÅÜíáÖÉå=píÉääÉK== däÉáÅÜòÉáíáÖ= ÉêëÅÜÉáåí= êÉÅÜíë= Ç~åÉÄÉå= Éáå= åÉìÉëI= äÉÉêÉë= cÉäÇ= ÑΩê= ÇÉå= å®ÅÜëíÉå= báåíê~Ö=ÇÉê=jÉåΩäÉáëíÉ=E_áäÇ=PKNUFK== QV =
P= tÉáíÉêÉ=píÉìÉêÉäÉãÉåíÉ= pÅÜêáíí= RW= báå= j~ìëâäáÅâ= áå= Ç~ë= äÉÉêÉ= cÉäÇ= êÉÅÜíë= åÉÄÉå= łbìêçé~I= ëÅÜçå= ïáêÇ= Ç~ë= cÉäÇ= åÉÄÉå= ÇÉê= báÖÉåëÅÜ~Ñí= Caption= ïáÉÇÉê= äÉÉêI= ìåÇ= Éë= â~åå= ÇáÉ= å®ÅÜëíÉ= _ÉëÅÜêáÑíìåÖ=ÇÉê=jÉåΩäÉáëíÉ=ÉáåÖÉíê~ÖÉå=ïÉêÇÉå=E_áäÇ=PKNVFK==
== _áäÇ=PKNTW=jÉåΩJbÇáíçê=
== _áäÇ=PKNUW=^ìÑÄ~ì=ÇÉê=jÉåΩòÉáäÉ==
== _áäÇ=PKNVW=^ìÑÄ~ì=ÇÉë=ÉêëíÉå=jÉåΩë=
== _áäÇ=PKOMW=bêÖ®åòìåÖ=áã=ÉêëíÉå=aêçéaçïåJjÉåΩ= pÅÜêáíí= SW= tÉåå= ÇáÉ= çÄÉêÉ= jÉåΩäÉáëíÉ= ÑÉêíáÖ= áëí= ÄÉÖáååí= ÇÉê= ^ìÑÄ~ì= ÇÉê= ëç= ÖÉJ å~ååíÉå=aêçéaçïåJjÉåΩëI=Ç~ë=ëáåÇ=ÇáÉ=báåíê®ÖÉI=ÇáÉ=å~ÅÜ=ìåíÉå=~ìÑÖÉÄä®ííÉêí= ïÉêÇÉåK== pçää=ìåíÉê= Europa=Éáå=ëçäÅÜÉë=jÉåΩ=~ìÑÖÉÄ~ìí=ïÉêÇÉå=Äê~ìÅÜí=ã~å=Ç~òì=äÉÇáÖJ äáÅÜ=ãáí=ÇÉê=j~ìë=~ìÑ=ÇáÉ=_ÉëÅÜêáÑíìåÖ= Europa=òì=âäáÅâÉåK=_áäÇ=PKNV=òÉáÖíI=Ç~ëë= Éáå=äÉÉêÉê=o~ÜãÉå=ÑΩê=ÇáÉ=Ç~êìåíÉê=Éáåòìíê~ÖÉåÇÉ=_ÉëÅÜêáÑíìåÖ=ÉêëÅÜÉáåíK== tÉåå=Éê=ïáêÇ=~ìëÖÉï®Üäí=ìåÇ= Frankreich=ÉáåÖÉíê~ÖÉå=ïáêÇI=ÉêëÅÜÉáåí=Ç~êìåíÉê= ïáÉÇÉê=Éáå=äÉÉêÉê=o~ÜãÉå=ÑΩê=Finnland=E_áäÇ=PKOMFI=ìåÇ=ëç=ïÉáíÉêK== RM= =
PKQ== píÉìÉêÉäÉãÉåí=jÉåΩ=Ej~áåjÉåìF= == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 3= ÇáÉ= zipJa~íÉá= DKap03.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap03= ÇáÉ= mêçàÉâíJa~íÉá= proj_34.dpr= ~ìëòìï®ÜäÉåK= táêÇ= ãáí= aÉäéÜá= ULOMMR= ÖÉ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap03=ÇáÉ=a~íÉá=proj_34.bdsproj=~ìëòìï®ÜäÉåK== == a~åå=â~åå=Afrika=å~ÅÜ=ìåíÉå=ÉêÖ®åòí=ïÉêÇÉåI=~åëÅÜäáÉ≈ÉåÇ=AsienI=Amerika=ìåÇ= AustralienK===== cΩê=ïÉäÅÜÉ=kìíòÉêÉáåïáêâìåÖ=ëçääíÉå=ïáê=oÉ~âíáçåÉå=éêçÖê~ããáÉêÉå\== bêëáÅÜíäáÅÜ=áëíI=Ç~ëë=Éáå=kìíòÉêâäáÅâ= ~ìÑ= EuropaI= Afrika=ìëïKI=ÇK=ÜK=~ìÑ=ÉáåÉ= _ÉJ ëÅÜêáÑíìåÖ= ÇÉê= çÄÉêÉåI= ëáÅÜíÄ~êÉå= jÉåΩäÉáëíÉI= äÉÇáÖäáÅÜ= Ç~ë= ^ìÑÄä®ííÉêå= ÇÉë= àÉJ ïÉáäáÖÉå= jÉåΩë= òìê= cçäÖÉ= Ü~ÄÉå= ãìëë= Ó= Ç~ë= ~ÄÉê= ÉêäÉÇáÖí= aÉäéÜá= ëÅÜçå= ÑΩê= ìåëK== tÉåå=ïáê=ΩÄÉêÜ~ìéí=bêÉáÖåáëéêçòÉÇìêÉå=ÜÉêëíÉääÉå=ãΩëëÉåI=Ç~åå=ÑΩê=ÇÉå=häáÅâ= ~ìÑ=ÉáåÉå=ÇÉê=~ìÑÖÉÄä®ííÉêíÉå=báåíê®ÖÉ=áå=ÉáåÉã=aêçéaçïåJjÉåΩK=aáÉëÉê=kìíJ òÉêâäáÅâ=ïáêÇ=ãáí=páÅÜÉêÜÉáí=~äë=pí~åÇ~êÇJbêÉáÖåáë=ÉáåÖÉëíÉääí=ëÉáåK= mêçÄáÉêÉå= ïáê= Éë= ~ìëI= âäáÅâÉå= ïáê= áã= båíïìêÑ= ÇçééÉäí= ~ìÑ= FrankreichK= pÅÜçå= ÄÉâçããÉå=ïáê=ÇÉå=o~ÜãÉå=ÑΩê=ÇáÉ=òìÖÉÜ∏êáÖÉ=bêÉáÖåáëéêçòÉÇìê=ÖÉëÅÜÉåâíW== procedure TForm1.Frankreich1Click(Sender: TObject); begin ShowMessage('Der Nutzer hat >Frankreich< ausgewählt’) end;
t~ë=ÑÉÜäí=åçÅÜ\=k~íΩêäáÅÜ=Ó=ÇáÉ=pÅÜåÉääï~ÜäÄìÅÜëí~ÄÉå=ÑÉÜäÉåK== t®ÜäÉå= ïáê= ÉáåÑ~ÅÜ=åçÅÜ=Éáåã~ä=Ç~ë= póãÄçä= ÑΩê=Ç~ë= jÉåΩ= ~ìÑ=ÇÉã=cçêãìä~ê= ìåÇ= åçÅÜ= Éáåã~ä= ÇÉå= jÉåΩJbÇáíçêK= a~åå= ®åÇÉêå= ïáê= ÇáÉ= _ÉëÅÜêáÑíìåÖÉå= ÇÉê= jÉåΩòÉáäÉ=áå=ÑçäÖÉåÇÉê=tÉáëÉ=~ÄW== Europa
&Europa,
Afrika
A&frika,
Asien
A&sien,
Amerika
A&merika
Australien A&ustralien.
a~ãáí=ëáåÇ=ÇáÉ=pÅÜåÉääï~ÜäÄìÅÜëí~ÄÉå=ÑÉëíÖÉäÉÖí=EëáÉÜÉ=_áäÇ=PKONFK== jáí=ÇÉê=ΩÄäáÅÜÉå=q~ëíÉåâçãÄáå~íáçå= Alt =H=pÅÜåÉääï~ÜäÄìÅÜëí~ÄÉ=â∏ååÉå=ÇáÉ= jÉåΩë=Ç~åå=ÇáêÉâí=ìåÇ=ëÅÜåÉää=~åÖÉï®Üäí=ìåÇ=~ìÑÖÉÄä®ííÉêí=ïÉêÇÉåK=
RN =
P= tÉáíÉêÉ=píÉìÉêÉäÉãÉåíÉ=
== _áäÇ=PKONW=pÅÜåÉääï~ÜäÄìÅÜëí~ÄÉå= =
RO= =
==
4
Ereignisprozeduren: Verwendung von properties kìå=áëí=ÇáÉ=wÉáí=êÉáÑK=i~åÖë~ã=ïáêÇ=Éë=ä~åÖïÉáäáÖI=áããÉê=åìê=~äë=fåÜ~äí=ÉáåÉê=bêJ ÉáÖåáëéêçòÉÇìê=ÇáÉ=wÉáäÉ== ShowMessage(‘dies oder das ist passiert‘)
òì= éêçÖê~ããáÉêÉåK= fëí= Ç~ë= ΩÄÉêÜ~ìéí= ëÅÜçå= êáÅÜíáÖÉë= łmêçÖê~ããáÉêÉå\= lÇÉê= ãΩëëÉå=ïáê=ÄÉáã=êáÅÜíáÖÉå=mêçÖê~ããáÉêÉå=ãÉÜê=ÇÉåâÉå\=táê=ïÉêÇÉå=ëÉÜÉåK= aáÉ= ^åÑ~åÖëëÅÜïáÉêáÖâÉáíÉå= ÄÉáã= rãÖ~åÖ= ãáí= aÉäéÜá= Ü~ÄÉå= ïáê= ëçìîÉê®å= ΩJ ÄÉêïìåÇÉåK=táê=â∏ååÉå=ÇáÉ=ÉáåÑ~ÅÜÉå=píÉìÉêÉäÉãÉåíÉ=_ìííçåI=i~ÄÉäI=qÉñíÑÉåëJ íÉêI=`ÜÉÅâÄçñI=pÅêçääÄ~êI=dêìééÉ=ãáí=o~ÇáçÄìííçåë=~ìÑ=ÇÉã=cçêãìä~ê=éä~íòáÉêÉå= ìåÇ=áã=lÄàÉâíáåëéÉâíçê=àÉïÉáäë=îçêÉáåëíÉääÉåI=ïÉäÅÜÉ=pí~êíÉáÖÉåëÅÜ~ÑíÉå=ëáÉ=ìåÇ= Ç~ë=cçêãìä~ê=Ü~ÄÉå=ëçääÉåK== táê= â∏ååÉå= ~ìÅÜ= ÇáÉ= ~åëéêìÅÜëîçääÉêÉå= píÉìÉêÉäÉãÉåíÉ= iáëíÉI= `çãÄçÄçñI= o~J ÇáçÖêìééÉ=ìåÇ=ëçÖ~ê=Éáå=jÉåΩ=áå=ìåëÉêÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=~ìÑåÉÜãÉåK= báÖÉåíäáÅÜ=ïáëëÉå=ïáê=~ìÅÜ=ëÅÜçåI=ïáÉ=ïáê=ÑΩê=~ääÉëI=ï~ë=Éáå=kìíòÉê=ëç=íìå=ìåÇ= ã~ÅÜÉå=â~ååI=ÉáåÉ=oÉ~âíáçå=ÉêòÉìÖÉå=â∏ååÉåW=aÉê=o~ÜãÉå=ÑΩê=ÇáÉ=é~ëëÉåÇÉ= bêÉáÖåáëéêçòÉÇìê=áëí=òì=ÄÉëÅÜ~ÑÑÉåI=ÇÉê=fåÜ~äí=áëí=òì=ëÅÜêÉáÄÉåK=cÉêíáÖK== açÅÜ=Ç~=ëáåÇ=ïáê=ïáÉÇÉê=ÄÉáã= fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìêÉåK=a~ë=ïáêÇ=ìåëÉê= qÜÉã~=ïÉêÇÉåK=_ÉÖáååÉå=ïáê=ÉêåÉìí=ãáí=ÇÉå=_áäÇÉêå=~ìë=ÇÉã=h~éáíÉä=OK==
4.1
Einfache Mitteilungen báåÉ=bêÉáÖåáëéêçòÉÇìê=â~åå=áã=ÉáåÑ~ÅÜëíÉå=c~ää=äÉÇáÖäáÅÜ=Éáå= jáííÉáäìåÖëÑÉåëíÉê= ~ìÑ=ÇÉã=_áäÇëÅÜáêã=ÉêëÅÜÉáåÉå=ä~ëëÉåK=a~ë=Ü~ÄÉå=ïáê=ÄáëÜÉê=~ìëÑΩÜêäáÅÜ=ÉêäÉÄíK== _áäÇ= QKN= ä®ëëí= Ç~ë= ~ìÅÜ= ÉêâÉååÉåW= aáÉëÉ= bêÉáÖåáëéêçòÉÇìêÉå= ÜçäÉå= åáÅÜíë= ~ìë= a~íÉåâÉêåÉå=ìåÇ=äáÉÑÉêí=åáÅÜíë=áå=a~íÉåâÉêåÉK=páÉ=ëçêÖÉå=ÉÄÉå=åìê=ÑΩê=Éáå=jáíJ íÉáäìåÖëÑÉåëíÉêK=jÉÜê=åáÅÜíK=
4.2
Passiver Zugriff auf Datenkerne báåÉ= éêçéÉêíó= EbáÖÉåëÅÜ~ÑíF= áëí= Éáå= ÇáêÉâíÉê= wìÖêáÑÑëãÉÅÜ~åáëãìëI= ãáí= ÇÉëëÉå= eáäÑÉ= ëÅÜåÉää= ~âíáî= ìåÇ= é~ëëáî= ~ìÑ= ÉáåòÉäåÉ= _Éëí~åÇíÉáäÉ= ÇÉë= a~íÉåâÉêåë= òìÖÉJ ÖêáÑÑÉå=ïÉêÇÉå=â~ååK=páÉ=â~åå=áå=bêÉáÖåáëéêçòÉÇìêÉå=îÉêïÉåÇÉí=ïÉêÇÉåK= iÉêåÉå= ïáê= òìÉêëí= âÉååÉåI= ïáÉ= ÉáåÉ= bêÉáÖåáëéêçòÉÇìê= é~ëëáî= ãáí= ÇÉã= ÉáÖÉåÉå= a~íÉåâÉêå=ìãÖÉÜÉå=â~ååK== ==
RP =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë=
= _áäÇ=QKNW=bêÉáÖåáëéêçòÉÇìêÉå=ÉáåÑ~ÅÜëíÉê=^êí=
4.2.1
Eigener Datenkern
a~ë= oÉÖáëíÉêÄä~íí= bfdbkp`e^cqbk= ÇÉë= lÄàÉâíáåëéÉâíçêë= áåÑçêãáÉêí= ìåë= ÑΩê= àÉÇÉë= îáëìÉääÉ= lÄàÉâí= ΩÄÉê= ÇáÉ= k~ãÉå= ÇÉê= ïáÅÜíáÖëíÉå= éêçéÉêíáÉëW= aÉåå= Ç~ë= ëáåÇ= ÖÉJ å~ì= ÇáÉ= _ÉòÉáÅÜåìåÖÉå= ÇÉê= ÉåíëéêÉÅÜÉåÇÉå= wÉáäÉåK= _ÉáëéáÉäëïÉáëÉ= ïáëëÉå= ïáê= ~ìë= ÇÉã= rãÖ~åÖ= ãáí= ÇÉã= lÄàÉâíáåëéÉâíçêI= Ç~ëë= ÇÉê= fåÜ~äí= ÉáåÉë= qÉñíÑÉåëíÉêë= E_áäÇ=QKOF=ãáí=ÇÉê=éêçéÉêíó=Text=îçêÄÉêÉáíÉí=ïÉêÇÉå=â~ååK==
= _áäÇ=QKOW=k~ãÉ=ÇÉê=éêçéÉêíóI=~ìë=ÇÉã=lÄàÉâíáåëéÉâíçê=òì=ÉêÑ~ÜêÉå== aÉê=fåÜ~äí=ÇÉë=qÉñíÑÉåëíÉêë=ÄÉÑáåÇÉí=ëáÅÜ=áêÖÉåÇïç=áã=a~íÉåâÉêåK=^ÄÉê=ïÉáä=ïáê= ïáëëÉåI=Ç~ëë=ÉáåÉ=éêçéÉêíó=ëíÉíë=òïÉáëÉáíáÖ=ïáêâíI=â∏ååíÉå=ïáê=ãáí= Text=ÖÉå~ì=ëç= Öìí=~ìÅÜ=ÇÉå=cÉåëíÉêáåÜ~äí=~ìë=ÇÉã=a~íÉåâÉêå=ÜÉê~ìëÜçäÉå=ìåÇ=îÉê~êÄÉáíÉåK== dÉë~Öí=Ó=ÖÉí~åK=pÅÜåÉää=ÇÉå=o~ÜãÉå=ÑΩê=ÇáÉ=ãÉáëíÄÉÜ~åÇÉäíÉ=kìíòÉêÉáåïáêâìåÖ= ~å= ÇÉã= qÉñíÑÉåëíÉêI= ÇK= ÜK= ÑΩê= Ç~ë= pí~åÇ~êÇJbêÉáÖåáëI= ÇìêÅÜ= açééÉäâäáÅâ= ÄÉJ ëÅÜ~ÑÑí=EëáÉÜÉ=^ÄëÅÜåáíí=OKOFK== RQ= =
QKO== m~ëëáîÉê=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉ= kìå= ïáêÇ= îÉêä~åÖíI= ~ìë= ÇÉã= a~íÉåâÉêå= ÇÉë= îáëìÉääÉå= lÄàÉâíë= Edit1= ãáí= eáäÑÉ= ÇÉê= é~ëëÉåÇÉå= éêçéÉêíóI= ÇÉêÉå= k~ãÉå= ïáê= ~äë= báÖÉåëÅÜ~Ñí= Text= åçÅÜ= ~ìë= ÇÉê= sçêÉáåëíÉääìåÖ= áå= bêáååÉêìåÖ= Ü~ÄÉåI= ÇÉå= ~âíìÉääÉå= fåÜ~äí= òì= ÉêÑ~ÜêÉåK= pÉÜÉå= ïáê=ìåë=~åI=ïáÉ=Ç~ë=ÖÉëÅÜêáÉÄÉå=ïáêÇW= procedure TForm1.Edit1Change(Sender: TObject); begin ShowMessage('Inhalt aktuell: '+ Edit1.Text) end;
== ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 4= ÇáÉ= zipJa~íÉá= DKap04.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap04= ÇáÉ= mêçàÉâíJa~íÉá= proj_421.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap04=ÇáÉ=a~íÉá=proj_421.bdsproj=~ìëòìï®ÜäÉåK== = tÉáä= Ç~ë= ÑìåâíáçåáÉêíI= â∏ååÉå= ïáê= ãáí= _áäÇ= QKP= ìåëÉê= pÅÜÉã~= ÉêÖ®åòÉåW= báåÉ= sÉêÄáåÇìåÖ=~ìë=ÇÉã=a~íÉåâÉêå=áå=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=áëí=ÜáåòìÖÉâçããÉåK=
= _áäÇ=QKPW=m~ëëáîÉê=wìÖêáÑÑ=~ìÑ=ÇÉå=ÉáÖÉåÉå=a~íÉåâÉêå= RR =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= pÉÜÉå= ïáê= ìåë= ÇáÉ= táêâìåÖ= ÇÉê= bêÉáÖåáëéêçòÉÇìê= ~åW= _Éá= àÉÇÉê= ûåÇÉêìåÖI= ÇáÉ= ÇÉê= kìíòÉê= ~ã= fåÜ~äí= ÇÉë= qÉñíÑÉåëíÉêë= ãáí= ÇÉã= k~ãÉå= Edit1= îçêåáããíI= ïáêÇ= ÇáÉ=bêÉáÖåáëéêçòÉÇìê=ÇìêÅÜ=ÇÉå=bêÉáÖåáëÜ®åÇäÉê=ÖÉëí~êíÉíK== aáÉ= bêÉáÖåáëéêçòÉÇìê= Üçäí= Ç~åå= ~ìë= ÇÉã= a~íÉåâÉêå= ãáí= eáäÑÉ= ÇÉê= báÖÉåëÅÜ~Ñí= EéêçéÉêíóF= Text= ÇÉå= ~âíìÉääÉå= fåÜ~äí= ÇÉë= qÉñíÑÉåëíÉêë= ìåÇ= âÉííÉí= áÜå= êÉÅÜíë= ~å= ÇÉå=ëí~íáëÅÜÉå=qÉñí='Inhalt aktuell: '=ÇÉë=jáííÉáäìåÖëÑÉåëíÉêë=~åK== _áäÇ= QKQ= áëí= ëçãáí= Éåíëí~åÇÉåI= ~äë= ÇÉê= kìíòÉê= ÖÉê~ÇÉ= ÇÉå= äÉíòíÉå= _ìÅÜëí~ÄÉå= îçã= k~ãÉå= ÇáÉëÉ= åÉííÉå= ^äíã~êâJaçêÑÉë= ÖÉä∏ëÅÜí= Ü~ííÉ= Ó= ~ìÅÜ= Ç~ë= ï~ê= ÉáåÉ= ûåÇÉêìåÖK==
== _áäÇ=QKQW=^ìëÑΩÜêìåÖ=ÇÉê=bêÉáÖåáëéêçòÉÇìê== báå= òïÉáíÉë= _ÉáëéáÉäW= aÉê= lÄàÉâíáåëéÉâíçê= áåÑçêãáÉêí= ìåëI= Ç~ëë= ÇáÉàÉåáÖÉ= éêçJ éÉêíóI=ãáí=ÇÉêÉå=eáäÑÉ=~ìÑ=ÇÉå=qÉáä= _ÉëÅÜêáÑíìåÖ=ÇÉë=a~íÉåâÉêåë=ÉáåÉë=_ìííçåJ lÄàÉâíë=òìÖÉÖêáÑÑÉå=ïÉêÇÉå=â~ååI=ÇÉå=k~ãÉå= Caption=íê®Öí=Ó=ÇÉåå=ÇáÉëÉ=wÉáäÉ= ÇÉë= lÄàÉâíáåëéÉâíçêë= ÄÉåìíòíÉå= ïáê= ÄÉêÉáíë= ÄÉá= ÇÉå= sçêÉáåëíÉääìåÖÉåK= aáÉëÉ= fåÑçêã~íáçå=áëí=~ìëêÉáÅÜÉåÇK==
== _áäÇ=QKRW=fåÑçêã~íáçå=ΩÄÉê=ÇáÉ=_ìííçåJ_ÉëÅÜêáÑíìåÖ== §ÄÉêòÉìÖÉå= ïáê= ìåëW= mä~íòáÉêÉå= ïáê= òìê= ^åïÉåÇìåÖ= òìë®íòäáÅÜ= òì= ÇÉã= qÉñíJ ÑÉåëíÉê= Edit1= ÉáåÉå= _ìííçå= EÉê= ÄÉâçããí= îçå= aÉäéÜá= ÇÉå= k~ãÉå= Button1F= ãáí= ÇÉê=_ÉëÅÜêáÑíìåÖ=rÉåÖäáåÖÉå=~ìÑ=ÇÉã=cçêãìä~êK=kìå=â∏ååÉå=ïáê=Ç~ÑΩê=ëçêÖÉåI= Ç~ëë= ÄÉá= häáÅâ= ÇÉë= kìíòÉêë= ~ìÑ= ÇÉå= _ìííçå= Epí~åÇ~êÇJbêÉáÖåáëF= áå= ÉáåÉã= jáííÉáJ äìåÖëÑÉåëíÉê=ΩÄÉê=ÇáÉ=_ÉëÅÜêáÑíìåÖ=ÇÉë=_ìííçåë=áåÑçêãáÉêí=ïáêÇW== RS= =
QKO== m~ëëáîÉê=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉ= procedure TForm1.Button1Click(Sender: TObject); begin ShowMessage('Beschriftung:'+ Button1.Caption) end;
_áäÇ=QKR=ä®ëëí=ÉêâÉååÉåI=Ç~ëë=~ääÉë=~ìÅÜ=ëç=ÑìåâíáçåáÉêíI=ïáÉ=ïáê=ìåë=Ç~ë=îçêÖÉJ ëíÉääí=Ü~ÄÉåK== hçããÉå=ïáê=òìã=oÉÖÉäïÉêâW== • wìÉêëí=ãΩëëÉå=ïáê=ÇÉå=k~ãÉå=ÇÉë=îáëìÉääÉå=lÄàÉâíë=~åÖÉÄÉåI=~ìë=ÇÉëëÉå=a~J íÉåâÉêå=ïáê=Éíï~ë=ÉêÑ~ÜêÉå=ïçääÉåK== jáí= ÇÉå= j∏ÖäáÅÜâÉáíÉå= ÇÉê= k~ãÉåëï~Üä= ÇÉê= îáëìÉääÉå= lÄàÉâíÉ= EÉáÖÉåÉ= t~Üä= çÇÉê= ^âòÉéíáÉêÉå= ÇÉë= îçå= aÉäéÜá= îçêÖÉëÅÜä~ÖÉåÉå= k~ãÉåëF= Ü~ííÉ= ëáÅÜ= ëÅÜçå= ÇÉê= ^ÄëÅÜåáíí= NKQKO= ÄÉëÅÜ®ÑíáÖíK= _áëÜÉê= ~êÄÉáíÉíÉå= ïáê= âçåëÉèìÉåí= ãáí= ÇÉå= îçå= aÉäéÜá=îçêÖÉëÅÜä~ÖÉåÉå=k~ãÉåK==
= _áäÇ=QKSW=k~ãÉ=ÉáåÉë=îáëìÉääÉå=lÄàÉâíë== aÉê=k~ãÉ=ÉáåÉë=îáëìÉääÉå=lÄàÉâíë=áëí=áã=lÄàÉâíáåëéÉâíçê=ëçïçÜä=áå=ÇÉê=hçéÑòÉáäÉ= ìåÇ= òìë®íòäáÅÜ= åçÅÜ= åÉÄÉå= ÇÉê= báÖÉåëÅÜ~Ñí= EéêçéÉêíóF= NameI= ÇK= ÜK= áå= ÇÉê= wÉáäÉ= ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ=NameI=~ÄòìäÉëÉå=E_áäÇ=QKSFK= • k~ÅÜ=ÇÉã=k~ãÉå=âçããí=áããÉê=Éáå=mìåâíK=a~ë=ÖÉÜ∏êí=òìã=oÉÖÉäïÉêâK== • oÉÅÜíë=îçã=mìåâí=âçããí=Ç~åå=ÇÉê=k~ãÉ=ÇÉêàÉåáÖÉå=éêçéÉêíó=EbáÖÉåëÅÜ~ÑíFI= ÇáÉ=ÇÉå=qê~åëéçêíîçêÖ~åÖ=~ìë=ÇÉã=a~íÉåâÉêå=îçêåáããíK== aÉå=k~ãÉå=ÇÉê=éêçéÉêíó=ÉêÑìÜêÉå=ïáê=ÄáëÜÉê=ëíÉíë=~ìë=ÇÉê=oÉÖáëíÉêâ~êíÉ=bfdbkJ p`e^cqbk= ÇÉë= lÄàÉâíáåëéÉâíçêëI= áåëÄÉëçåÇÉêÉ= îçå= ÇÉå= Ççêí= îçêÖÉåçããÉåÉå= sçêÉáåëíÉääìåÖÉåK== ^ÄÉê= åáÅÜí= ~ääÉ= éêçéÉêíáÉëI= ÇáÉ= áå= aÉäéÜá= ÇÉå= ÇáêÉâíÉå= ~âíáîÉå= ìåÇ= é~ëëáîÉå= wìÖêáÑÑ= ~ìÑ= ÇÉå= a~íÉåâÉêå= ÉáåÉë= lÄàÉâíÉë= Éêä~ìÄÉåI= ëáåÇ= áã= lÄàÉâíáåëéÉâíçê= ìåíÉê=bfdbkp`e^cqbk=~ìÑÖÉäáëíÉíK=açêí=ëíÉÜÉå=åìê=ÇáÉ=ïáÅÜíáÖëíÉåK== fã=^ÄëÅÜåáíí=QKTKP=ÉêÑ~ÜêÉå=ïáêI=ïáÉ=ã~å=ÇáÉ=k~ãÉå=ïÉáíÉêÉê=éêçéÉêíáÉë=ÑáåÇÉå= â~ååK= iáÉÑÉêí=ÇáÉ=éêçéÉêíó=ÉáåÉ=wÉáÅÜÉåÑçäÖÉ=EÉáåÉå=qÉñíF=â~åå=ÇáÉëÉ=áå=ÉáåÉê= ShowMessageJmêçòÉÇìê= ëçÑçêí= îÉêïÉåÇÉí= ïÉêÇÉåI= ÖÉÖÉÄÉåÉåÑ~ääë= áå= sÉêÄáåÇìåÖ= ãáí= ÉáJ åÉã=Éêä®ìíÉêåÇÉå=ëí~íáëÅÜÉå=qÉñí=Ó=ëáÉÜÉ=ìåëÉêÉ=ÄÉáÇÉå=_ÉáëéáÉäÉK== ^äë=sÉêâÉííìåÖëòÉáÅÜÉå=ÇáÉåí=Ç~ÄÉá=Ç~ë=ÄÉâ~ååíÉ=mäìëòÉáÅÜÉåK= RT =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë=
4.2.2
Datenkerne fremder Objekte
tÉê=ë~Öí=ÇÉåå=ÉáÖÉåíäáÅÜI=Ç~ëë=ÉáåÉ=bêÉáÖåáëéêçòÉÇìê=åáÅÜí=~ìÅÜ=áå=ÇáÉ=a~íÉåJ âÉêåÉ= ÑêÉãÇÉê= îáëìÉääÉê= lÄàÉâíÉ= ÜáåÉáåÖêÉáÑÉå= Ç~êÑ\= péêáÅÜí= áêÖÉåÇÉíï~ë= Ç~ÖÉJ ÖÉå\= a~ë=_áäÇ=QKT=ëâáòòáÉêí=ìåë=ÇÉå=jÉÅÜ~åáëãìëI=ìåÇ=~å=ÉáåÉã=ÉáåÑ~ÅÜÉå=_ÉáëéáÉä= ïÉêÇÉå=ïáê=ìåë=ΩÄÉêòÉìÖÉåI=Ç~ëë=ïáê=Ç~ÑΩê=~Äëçäìí=åáÅÜíë=ÜáåòìäÉêåÉå=ãΩëëÉåK==
= _áäÇ=QKTW=mêáåòáéW=m~ëëáîÉê=wìÖêáÑÑ=~ìÑ=ÉáåÉå=ÑêÉãÇÉå=a~íÉåâÉêå= _Éíê~ÅÜíÉå=ïáê=ÑçäÖÉåÇÉ=ÉáåÑ~ÅÜÉ=^ìÑÖ~ÄÉW=^ìÑ=ÉáåÉã=cçêãìä~ê=ëáåÇ=êáåÖë=ìã= ÉáåÉå=_ìííçå=Éáå=i~ÄÉäI=Éáå=qÉñíÑÉåëíÉêI=ÉáåÉ=`ÜÉÅâÄçñ=ìåÇ=Éáå=o~ÇáçÄìííçå=ãáí= áÜêÉå=fåÜ~äíÉå=ÄòïK=_ÉëÅÜêáÑíìåÖÉå=~åÖÉçêÇåÉí=E_áäÇ=QKUFK== _Éá=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ëçääÉå=áå=ÉáåÉê=jáííÉáäìåÖ=ÇÉê=fåÜ~äí=ÇÉê=qÉñíÄçñ=ëçJ ïáÉ=ÇáÉ=ÇêÉá=_ÉëÅÜêáÑíìåÖÉå=îçå=i~ÄÉäI=`ÜÉÅâÄçñ=ìåÇ=o~ÇáçÄìííçå=òìë~ããÉåJ ÖÉÑ~ëëí=ïÉêÇÉåK==
==
RU= =
QKO== m~ëëáîÉê=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉ= _áäÇ=QKUW=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ= táÉ= ëáÉÜí= ÇÉê= òìÖÉÜ∏êáÖÉ= fåÜ~äí= ÇÉê= bêÉáÖåáëéêçòÉÇìê= òìã= bêÉáÖåáë= häáÅâ= ~ìÑ= ÇÉå=_ìííçå=~ìë\=lÑÑÉåÄ~ê=ãΩëëÉå=áå=áÜê=ãáí=eáäÑÉ=ÇÉê=îáÉê=é~ëëÉåÇÉå=qê~åëéçêíJ éêçéÉêíáÉë= ÇáÉ= àÉïÉáäáÖÉå= _ÉëÅÜêáÑíìåÖÉå= ÄòïK= ÇÉê= fåÜ~äí= ÇÉë= qÉñíÑÉåëíÉêë= ~ìë= ÇÉå=a~íÉåâÉêåÉå=ÖÉÜçäí=ïÉêÇÉåW== procedure TForm1.Button1Click(Sender: TObject); begin ShowMessage( Label1.Caption
+
Checkbox1.Caption +
Edit1.Text
+
RadioButton1.Caption)
end;
hçåíêçääáÉêÉå=ïáê=Ç~ë=bêÖÉÄåáë=Ó=áå=_áäÇ=QKV=ëÉÜÉå=ïáê=ÉëK=
== _áäÇ=QKVW=häáÅâ=~ìÑ=ÇÉå=_ìííçå= få=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ïìêÇÉ=ÇìêÅÜ=sÉêíÉáäìåÖ=~ìÑ=ãÉÜêÉêÉ=wÉáäÉå=ΩÄÉêëáÅÜíJ äáÅÜ=ÖÉëÅÜêáÉÄÉåI=Ç~ë=áëí=~ìÅÜ=Éêä~ìÄíK== == == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 4= ÇáÉ= zipJa~íÉá= DKap04.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap04= ÇáÉ= mêçàÉâíJa~íÉá= proj_422.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap04=ÇáÉ=a~íÉá=proj_422.bdsproj=~ìëòìï®ÜäÉåK== = aáÉ=îáÉê=wÉáÅÜÉåÑçäÖÉåI=ÇáÉ=~ìë=ÇÉå=îáÉê=a~íÉåâÉêåÉå=ÖÉÜçäí=ïìêÇÉåI=ïÉêÇÉå= áå= _áäÇ= QKV= ìåãáííÉäÄ~ê= ~åÉáå~åÇÉê= ÖÉëÅÜêáÉÄÉåK= içÖáëÅÜ= Ó= ïáê= Ü~ÄÉå= ~ìÅÜ= åáÅÜíë=^åÇÉêÉë=éêçÖê~ããáÉêíK== bêïÉáíÉêå= ïáê= ~ÄÉê= ÇÉå= fåÜ~äí= ÇÉê= bêÉáÖåáëéêçòÉÇìê= ÇêÉáã~ä= ÇìêÅÜ= ÇÉå= ëí~íáJ ëÅÜÉå=qÉñí= '>>'=ÉêÜ~äíÉå=ïáê=ÄÉáã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=å~íΩêäáÅÜ=ÉáåÉ=~åÇÉêÉI= ÄÉëëÉêÉ=^ìëÖ~ÄÉI=ïáÉ=áå=_áäÇ=QKNM=âçåíêçääáÉêí=ïÉêÇÉå=â~ååK== RV =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= procedure TForm1.Button1Click(Sender: TObject); begin ShowMessage( Label1.Caption+'>>'+ Edit1.Text+'>>'+ Checkbox1.Caption+'>>'+ RadioButton1.Caption ) end;
§ÄêáÖÉåë= Ó= ïÉã= ÇÉê= k~ãÉ= çÇÉê= òìãáåÇÉëí= ÇáÉ= pÅÜêÉáÄïÉáëÉ= ÇÉë= ÉáåÉå= çÇÉê= ~åÇÉêÉå=îáëìÉääÉå=lÄàÉâíë=ÉåíÑ~ääÉå=ëçääíÉW=fã=hçéÑ=ÇÉë=lÄàÉâíáåëéÉâíçêë=ÄÉÑáåÇÉí= ëáÅÜ= ÉáåÉ= `çãÄçÄçñ= ãáí= ~ääÉå= k~ãÉå= ~ääÉê= lÄàÉâíÉI= ÇáÉ= ëáÅÜ= ÇÉêòÉáí= ~ìÑ= ÇÉã= cçêãìä~ê=ÄÉÑáåÇÉåI=ÉáåëÅÜäáÉ≈äáÅÜ=ÇÉë=cçêãìä~êå~ãÉåë=E_áäÇ=QKNNFK==
= _áäÇ=QKNMW=sÉêÄÉëëÉêíÉ=^ìëÖ~ÄÉ=ÇìêÅÜ=báåÑΩÖÉå=ëí~íáëÅÜÉê=qÉñíÉ==
== _áäÇ=QKNNW=k~ãÉåëΩÄÉêëáÅÜí=ΩÄÉê=~ääÉ=îáëìÉääÉå=lÄàÉâíÉ=
4.3
Aktiver Zugriff auf Datenkerne
4.3.1 =
Eigener Datenkern
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 4= ÇáÉ= zipJa~íÉá= DKap04.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap04= ÇáÉ= mêçàÉâíJa~íÉá= proj_431.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap04=ÇáÉ=a~íÉá=proj_431.bdsproj=~ìëòìï®ÜäÉåK== = SM= =
QKP== ^âíáîÉê=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉ= báåÉ= Ö~åò= ÉáåÑ~ÅÜÉ= ^ìÑÖ~ÄÉåëíÉääìåÖ= ëçää= ìåë= ÇÉå= wìÖ~åÖ= òìê= i∏ëìåÖ= ÇÉê~êíáJ ÖÉê= mêçÄäÉãÉ= ∏ÑÑåÉåW= ^ìÑ= ÉáåÉã= cçêãìä~ê= ÄÉÑáåÇÉí= ëáÅÜ= Éáå= _ìííçåI= ~åÑ~åÖë= íê®Öí=Éê=ÇáÉ=_ÉëÅÜêáÑíìåÖ=pí~êíK== _Éáã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ëçää=ëáÅÜ=ëÉáåÉ=ÉáÖÉåÉ=_ÉëÅÜêáÑíìåÖ=áå=píçé=®åÇÉêåK= _Éíê~ÅÜíÉå=ïáê=Ç~òì=ÖäÉáÅÜ=ÇáÉ=bêÉáÖåáëéêçòÉÇìêK== procedure TForm1.Button1Click(Sender: TObject); begin Button1.Caption:='Stop' end;
aÉê=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ÄÉëíÉÜí=~ìë=ÇÉã=_ÉÑÉÜä== Button1.Caption:='Stop'
a~ë=áëí=Éáå=wìïÉáëìåÖëÄÉÑÉÜäK=oÉÅÜíë=ëíÉÜí=ÇáÉ=nìÉääÉI=äáåâë=ëíÉÜí=Ç~ë=wáÉäK=a~ë= wÉáÅÜÉå=:==ïáêÇ=ÉêÖáÄí=ëáÅÜ=~ìë=ÖÉëéêçÅÜÉåK= aáÉëÉê=wìïÉáëìåÖëÄÉÑÉÜä=ëçêÖí=Ç~ÑΩêI=Ç~ëë=ÇÉê=ëí~íáëÅÜÉ=qÉñí= ‘Stop‘=ãáííÉäë=ÇÉê= báÖÉåëÅÜ~Ñí=EéêçéÉêíóF= Caption=áå=ÇÉå=a~íÉåâÉêå=ÇÉë=îáëìÉääÉå= lÄàÉâíë= Button1= ÜáåÉáå=íê~åëéçêíáÉêí=ïáêÇK=hçããí=ÇÉê=åÉìÉ=qÉñí=Ççêí=~åI=ïáêÇ=ëçÑçêí=ÇÉê=ëáÅÜíJ Ä~êÉ=qÉáä=îÉê®åÇÉêí=Ó=ÇáÉ=_ÉëÅÜêáÑíìåÖ=ïÉÅÜëÉäí=E_áäÇ=QKNOFK= táêÇ= ~åëÅÜäáÉ≈ÉåÇ= åçÅÜ= Éáåã~ä= ~ìÑ= ÇÉå= _ìííçå= ÖÉâäáÅâíI= é~ëëáÉêí= å~íΩêäáÅÜ= åáÅÜíë= ãÉÜêK= lÇÉê= ÇçÅÜ\= §ÄÉêäÉÖÉå= ïáêW= _Éáã= òïÉáíÉå= häáÅâ= ïáêÇ= ïáÉÇÉêìã= ÇÉê=ëí~íáëÅÜÉ=qÉñí= ‘Stop‘=îá~=a~íÉåâÉêå=òìê=_ÉëÅÜêáÑíìåÖ=ÇÉë=_ìííçåë=ÖÉëÅÜáÅâíK= táê=ãÉêâÉå=Ç~ë=åìê=åáÅÜíI=ïÉáä=ëáÅÜ=Ç~åå=ÇáÉ=_ÉëÅÜêáÑíìåÖ=åáÅÜí=ãÉÜê=®åÇÉêíK= a~ëëÉäÄÉ=ÄÉáã=ÇêáííÉåI=îáÉêíÉåI=ÑΩåÑíÉå=häáÅâ=ìëïK=cçäÖäáÅÜ=é~ëëáÉêí=ÇçÅÜ=àÉÇÉë= j~ä=Éíï~ëI=ïáê=ãÉêâÉå=Éë=åìê=åáÅÜíK=
== _áäÇ=QKNOW=sçê=ìåÇ=å~ÅÜ=ÇÉã=ÉêëíÉå=häáÅâ====
4.3.2
Datenkerne fremder Objekte
gÉíòí=ïáêÇ=Éë=ä~åÖë~ã=áåíÉêÉëë~åíK=bÄÉå=Ü~ÄÉå=ïáê=ÉêäÉÄíI=ïáÉ=ãáííÉäë=ÉáåÉê=bêÉáÖJ åáëéêçòÉÇìê= ÉáåÉ= ÄÉëíáããíÉ= _ÉäÉÖìåÖ= áå= ÉáåÉå= a~íÉåâÉêå= ÜáåÉáåÖÉÄê~ÅÜí= ïÉêJ ÇÉå=â~åå=ìåÇ=ÑçäÖäáÅÜ=~ã=àÉïÉáäáÖÉå=píÉìÉêÉäÉãÉåí=ëáÅÜíÄ~êÉ=sÉê®åÇÉêìåÖÉå=ÉêJ òÉìÖÉå= â~ååK= k~íΩêäáÅÜ= ÑìåâíáçåáÉêí= Ç~ë= ~ìÅÜ= áå= ÑêÉãÇÉå= a~íÉåâÉêåÉå= Ó= ïáê= Äê~ìÅÜÉå=ìåë=Ç~òì=åìê=åçÅÜ=Éáåã~ä=ÇáÉ=pâáòòÉ=áå=_áäÇ=QKT=~åòìëÉÜÉåK== báå=é~~ê=_ÉáëéáÉäÉ=Ç~òìW=wìÉêëí=éä~íòáÉêÉå=ïáê=~ìÑ=ÇÉã=cçêãìä~ê=ÉáåÉå= _ìííçå= ìåÇ=Éáå=i~ÄÉäK=a~ë=i~ÄÉä=çÜåÉ=pí~êíÄÉëÅÜêáÑíìåÖK== SN =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 4= ÇáÉ= zipJa~íÉá= DKap04.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap04= ÇáÉ= mêçàÉâíJa~íÉá= proj_432.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap04=ÇáÉ=a~íÉá=proj_432.bdsproj=~ìëòìï®ÜäÉåK== = _Éáã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=Epí~åÇ~êÇÉêÉáÖåáëF=ëçää=Ç~ë=i~ÄÉä=ÄÉëÅÜêáÑíÉí=ïÉêÇÉå= ãáí=ÇÉê=ëÅÜ∏åÉå=wÉáÅÜÉåÑçäÖÉ=UenglingenK=aáÉ=i∏ëìåÖW= procedure TForm1.Button1Click(Sender: TObject); begin Label1.Caption:='Uenglingen' end;
k®ÅÜëíÉë=_ÉáëéáÉäW=^ìÑ=ÇÉã=cçêãìä~ê=ïÉêÇÉå=òìë®íòäáÅÜ=Éáå=òïÉáíÉê=_ìííçå=ìåÇ= ÉáåÉ= ï~~ÖÉêÉÅÜíÉ= pÅêçääÄ~ê= ~åÖÉçêÇåÉíK= pí~êíÉáåëíÉääìåÖ= ÇÉê= pÅêçääÄ~êW= j~ñáJ ãìãZNMMI= jáåáãìãZMI= mçëáíáçåZM= EïáÉ= áå= áÜêÉã= lÄàÉâíáåëéÉâíçê= åÉÄÉå= ÇÉå= báÖÉåëÅÜ~ÑíÉå= MaxI= Min=ìåÇ= Position=~åÖÉÄçíÉåFK=^ìÑÖ~ÄÉW=_Éáã=häáÅâ=~ìÑ=ÇÉå= _ìííçå=ëçää=ÇáÉ=mçëáíáçå=ÇÉë=oÉÖäÉêë=~ìÑ=TR=ïÉÅÜëÉäåK=bêÉáÖåáëéêçòÉÇìêW== procedure TForm1.Button2Click(Sender: TObject); begin ScrollBar1.Position:=75 end;
kìå=ëíÉÜí=~ìÑ=ÇÉê=êÉÅÜíÉå=EnìÉääJF=pÉáíÉ=ÇÉë=wìïÉáëìåÖëÄÉÑÉÜäë=ÉáåÉ=w~ÜäX=Ç~ë= áëí=~ìÅÜ=âçêêÉâíI=ïÉáä=ÇáÉ=mçëáíáçå=ÇÉë=oÉÖäÉêë=áå=ÇÉê=pÅêçääÄ~ê=ÉÄÉå=ÇìêÅÜ=ÉáåÉå= w~ÜäÉåïÉêí=ÄÉëÅÜêáÉÄÉå=ïáêÇK=
= _áäÇ=QKNPW=sçê=ìåÇ=å~ÅÜ=ÇÉã=häáÅâ= fã=å®ÅÜëíÉå=_ÉáëéáÉä=ïçääÉå=ïáê=ÇáÉ=^ìÑÖ~ÄÉ=~ìë=_áäÇ=QKU=ìãÖÉâÉÜêí=ä∏ëÉåK=^ìÑ= ÇÉã=cçêãìä~ê=ëáåÇ=êáåÖë=ìã=ÉáåÉå=ïÉáíÉêÉå=_ìííçå=Éáå= i~ÄÉäI= ÉáåÉ=`ÜÉÅâÄçñI= Éáå=o~ÇáçÄìííçå=ãáí=áÜêÉå=_ÉëÅÜêáÑíìåÖÉå=ìåÇ=Éáå=qÉñíÑÉåëíÉê=ãáí=ëÉáåÉã=pí~êíJ= fåÜ~äí=~åÖÉçêÇåÉí=E_áäÇ=QKUFK= SO= =
QKP== ^âíáîÉê=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉ= aáÉ= _ÉëÅÜêáÑíìåÖÉå= ä~ìíÉå= NordenI= WestenI= OstenI= Ç~ë= qÉñíÑÉåëíÉê= Ü~í= ~åÑ~åÖë= ÇÉå=fåÜ~äí= SüdenK=_Éáã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=Epí~åÇ~êÇJbêÉáÖåáëF=ëçääÉå=ëáÉ=ëí~ííJ ÇÉëëÉå= ÇáÉ= _ÉëÅÜêáÑíìåÖÉå= NordI= WestI= Ost= ÄòïK= ÇÉå= fåÜ~äí= Süd= ÉêÜ~äíÉå= E_áäÇ= QKNQFK=
== _áäÇ=QKNQW=sçê=ìåÇ=å~ÅÜ=ÇÉã=häáÅâ=~ìÑ=ÇÉå=_ìííçå= få= ÇÉê= òìÖÉÜ∏êáÖÉå= bêÉáÖåáëéêçòÉÇìê= ëÉÜÉå= ïáê= Éêëíã~äáÖ= Ç~ë= pÉãáâçäçå= ~äë= qêÉååòÉáÅÜÉå=òïáëÅÜÉå=ÇÉå=wìïÉáëìåÖëÄÉÑÉÜäÉåK=^ìÅÜ=ïÉåå=ÇáÉ=_ÉÑÉÜäÉ=ìåJ íÉêÉáå~åÇÉê=ëíÉÜÉå=ëçääíÉå=Ó=Ç~ë=wÉáäÉåÉåÇÉ=â~åå=åáÉã~äë=Ç~ë=íêÉååÉåÇÉ=pÉãáJ âçäçå=ÉêëÉíòÉåK== procedure TForm1.Button3Click(Sender: TObject); begin Label2.Caption:='Nord'; RadioButton1.Caption:='Ost'; Edit1.Text:='Süd'; CheckBox1.Caption:='West'
//Trennzeichen nötig //Trennzeichen nötig //Trennzeichen nötig
end;
bêïÉáíÉêå= ïáê= ÇáÉ= ^ìÑÖ~ÄÉåëíÉääìåÖW= kìå= ëçää= òìë®íòäáÅÜ= ÄÉáã= häáÅâ= ~ìÑ= ÇÉå= _ìííçå=EÇK=ÜK=ÄÉá=ÇÉãëÉäÄÉå=bêÉáÖåáëF=ÇáÉ=`ÜÉÅâÄçñ=ÇÉå=e~âÉå=ìåÇ=ÇÉê=o~ÇáçJ Äìííçå=ÇáÉ=j~êâáÉêìåÖ=ÄÉâçããÉå=E_áäÇ=QKNRFK==
= _áäÇ=QKNRW=k~ÅÜ=ÇÉã=häáÅâ=~ìÑ=ÇÉå=_ìííçåI=ÉêïÉáíÉêíÉ=^ìÑÖ~ÄÉåëíÉääìåÖ= SP =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= tÉäÅÜÉ= wìïÉáëìåÖëÄÉÑÉÜäÉ= ãΩëëÉå= ïáê= ÑΩê= ÇáÉëÉ= ÉêïÉáíÉêíÉ= ^ìÑÖ~ÄÉåëíÉääìåÖ= òìë®íòäáÅÜ=áå=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=~ìÑåÉÜãÉå\== pÉÜÉå=ïáê=ìåë=òìÉêëí=ÇáÉ=i∏ëìåÖ=~åK== procedure TForm1.Button3Click(Sender: TObject); begin Label2.Caption:='Nord';
//Trennzeichen nötig
RadioButton1.Caption:='Ost';
//Trennzeichen nötig
Edit1.Text:='Süd';
//Trennzeichen nötig
CheckBox1.Caption:='West';
//Trennzeichen nötig
Checkbox1.Checked:=True;
//Trennzeichen nötig
RadioButton1.Checked:=True end;
t~êìã= ãìëëíÉå= ïáê= ÇáÉ= sçâ~ÄÉä= True= ~ìÑ= ÇáÉ= êÉÅÜíÉå= pÉáíÉå= ÇÉê= ÄÉáÇÉå= ÜáåòìÖÉâçããÉåÉå=wìïÉáëìåÖÉå=ëÅÜêÉáÄÉå\== aáÉ= ^åíïçêí= Ç~ê~ìÑ= ÑáåÇÉå= ïáêI= ïáÉÇÉê= Éáåã~äI= áã= oÉÖáëíÉêÄä~íí= bfdbkp`e^cqbk= ÇÉê= lÄàÉâíáåëéÉâíçêÉå= ÑΩê= `ÜÉÅâÄçñ= ìåÇ= o~ÇáçÄìííçåK= açêí= ÑáåÇÉå= ïáê= òìÉêëíI= Ç~ëë= ÇáÉ= ÄÉáÇÉå= báÖÉåëÅÜ~ÑíÉå= EéêçéÉêíáÉëFI= ÇáÉ= ÇáÉ= _ÉäÉÖìåÖÉå= áã= a~íÉåâÉêå= îÉê~åä~ëëÉå=EçÇÉê=äáÉÑÉêåFI=ÄÉáÇÉ=j~äÉ=~ìÑ=ÇÉå=k~ãÉå= Checked=Ü∏êÉå=E_áäÇ=QKNSX= îÉêÖäÉáÅÜÉ=~ìÅÜ=ÇÉå=^ÄëÅÜåáíí=OKQKPFK===
== _áäÇ=QKNSW=_ÉäÉÖìåÖëéêçéÉêíó=îçå=`ÜÉÅâÄçñ=ìåÇ=o~ÇáçÄìííçå= t~ë= áëí= Ççêí= òì= ÉêâÉååÉå\= aáÉ= éêçéÉêíó= Checked= ãìëë= ÄÉá= ÄÉáÇÉå= píÉìÉêÉäÉJ ãÉåíÉå=ãáí=ÉáåÉã=ÇÉê=ÄÉáÇÉå=äçÖáëÅÜÉå=tÉêíÉ= False=EÑ~äëÅÜF=çÇÉê= True=Eï~ÜêF= ÄÉäÉÖí=ïÉêÇÉåK== sçêäÉíòíÉë=_ÉáëéáÉä=áå=ÇáÉëÉã=^ÄëÅÜåáííW=^ìÑ=ÇÉã=cçêãìä~ê=ÄÉÑáåÇÉí=ëáÅÜ=ïÉáíÉê= ÉáåÉ= o~ÇáçÖêìééÉ= EîÖäK= ^ÄëÅÜåáíí= PKPFI= ÄÉäÉÖí= ãáí= ÇÉå= k~ãÉå= ÇÉê= ëÉÅÜòÉÜå= ÇÉìíëÅÜÉå= i~åÇÉëÜ~ìéíëí®ÇíÉK= wì= _ÉÖáåå= ÇÉê= i~ìÑòÉáí= ëçää= âÉáåÉ= i~åÇÉëÜ~ìéíJ ëí~Çí=ÇáÉ=j~êâáÉêìåÖ=ÄÉëáíòÉåK== SQ= =
QKP== ^âíáîÉê=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉ= kìå= ÇáÉ= ^ìÑÖ~ÄÉW= _Éá= àÉÇÉã= häáÅâ= áå= ÇÉê= o~ÇáçÖêìééÉ= Epí~åÇ~êÇJbêÉáÖåáëF= ëçää= åáÅÜí=Éíï~=ÇáÉ=~ìëÖÉï®ÜäíÉ=i~åÇÉëÜ~ìéíëí~Çí=ÇáÉ=j~êâáÉêìåÖ=ÄÉâçããÉåI=ëçåJ ÇÉêå=ëíÉíë=ÇáÉ=wÉåíê~äÉI= BerlinK=t~ë=~ìÅÜ=ÇÉê=kìíòÉê=áããÉê=~åâäáÅâÉå=ã~ÖI=ÄÉá= àÉÇÉã= häáÅâ= ëçää= áããÉê= EçÄ= ÇÉê= kìíòÉê= ïáää= çÇÉê= åáÅÜíF= ÇáÉ= j~êâáÉêìåÖ= òìê= _ìåÇÉëÜ~ìéíëí~Çí=ëéêáåÖÉå=E_áäÇ=QKNTFK==
== _áäÇ=QKNTW=pí~êí=ìåÇ=páíì~íáçå=å~ÅÜ=áêÖÉåÇÉáåÉê=t~Üä= aÉê= o~ÜãÉå= ÑΩê= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= áëí= ëÅÜåÉää= ÄÉëÅÜ~ÑÑíI= Ç~= Éë= ëáÅÜ= ìã= Ç~ë= pí~åÇ~êÇJbêÉáÖåáë= ÇÉê= o~ÇáçÖêìééÉ= Ü~åÇÉäíK= açÅÜ= ïÉäÅÜÉå= wìïÉáëìåÖëÄÉÑÉÜä= ãìëë=ã~å=Éáåíê~ÖÉå\=táÉ=ÜÉá≈í=ÇáÉ=é~ëëÉåÇÉ=báÖÉåëÅÜ~Ñí=EéêçéÉêíóF\== pìÅÜÉå= ïáê= áã= lÄàÉâíáåëéÉâíçê= ÇÉê= o~ÇáçÖêìééÉ= å~ÅÜ= ÇÉêàÉåáÖÉå= báÖÉåëÅÜ~ÑíI= ÇáÉ=ÇáÉ=j~êâáÉêìåÖ=~ìÑ=ÉáåÉ=ÄÉëíáããíÉ=wÉáäÉ=ëÉíòíK=_áäÇ=QKNU=òÉáÖí=Éë=Ó=Éë=áëí=ÇáÉ= báÖÉåëÅÜ~Ñí=ItemIndexK=
= _áäÇ=QKNUW=^ìëòìÖ=~ìë=ÇÉå=báÖÉåëÅÜ~ÑíÉå=ÉáåÉê=o~ÇáçÖêìééÉ==== táê=äÉëÉå=~ÄW=oÉÅÜíë=åÉÄÉå= ItemIndex=ëíÉÜí=ÉáåÉ=Ö~åòÉ=w~ÜäK=cçäÖäáÅÜ=ãìëë=ÇáÉJ ëÉê= báÖÉåëÅÜ~ÑíI= ïÉåå= ëáÉ= ~äë= éêçéÉêíó= áå= ÉáåÉê= bêÉáÖåáëéêçòÉÇìê= îÉêïÉåÇÉí= ïáêÇI=ëíÉíë=ÉáåÉ=w~Üä=òìÖÉïáÉëÉå=ïÉêÇÉåK=eáÉê=áëí=Éë=ÇáÉ=kìääK== SR =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= t~êìã=ÖÉê~ÇÉ=ÇáÉ=kìää\=kìåI=ïÉáä= Berlin=ÇÉê=ÉêëíÉ=báåíê~Ö=áëíI=ìåÇ=ãáí=kìää=ÇáÉ= w®ÜäìåÖ=ÄÉÖáååíK==== procedure TForm1.RadioGroup1Click(Sender: TObject); begin RadioGroup1.ItemIndex:=0 end;
c~ëëÉå=ïáê=òìë~ããÉåW== • sÉêä~åÖí=ÉáåÉ=éêçéÉêíó=ÉáåÉå=qÉñí=EÉáåÉ=wÉáÅÜÉåÑçäÖÉFI=ãìëë=~ìÑ=ÇÉê=êÉÅÜíÉå= EnìÉääJF= pÉáíÉ= ÇÉê= wìïÉáëìåÖ= Éáå= ëí~íáëÅÜÉê= qÉñí= ëíÉÜÉåI= âÉååíäáÅÜ= ~å= ÇÉå= ÄÉáÇÉå=eçÅÜâçãã~ë=‘=ìåÇ=‘=K= • sÉêä~åÖí= ÉáåÉ= éêçéÉêíó= ÉáåÉ= Ö~åòÉ= w~ÜäI= ãìëë= ~ìÑ= ÇÉê= êÉÅÜíÉå= pÉáíÉ= ÇÉê= wìïÉáëìåÖ=ÉáåÉ=Ö~åòÉ=w~Üä=ëíÉÜÉåK= • sÉêä~åÖí= ÉáåÉ= éêçéÉêíó= ÉáåÉå= t~ÜêÜÉáíëïÉêíI= ãìëë= ~ìÑ= ÇÉê= êÉÅÜíÉå= pÉáíÉ= ÇÉê= wìïÉáëìåÖ=ÉåíïÉÇÉê=True=çÇÉê=False=ëíÉÜÉåK== kìå= òìã= äÉíòíÉå= _ÉáëéáÉäK= ^ìÑ= ìåëÉêÉã= cçêãìä~ê= ïÉêÇÉå= ïÉáíÉêÉ= îáÉê= _ìííçåë= ãáí=ÇÉå=_ÉëÅÜêáÑíìåÖÉå= FlensburgI=GarmischI=Görlitz=ìåÇ=Aachen=éä~íòáÉêíX=ëáÉ=ÉêJ Ü~äíÉå=ÇáÉ=k~ãÉå= Button4=Äáë= Button8K=få=ÇÉê=jáííÉ=ÄÉÑáåÇÉí=ëáÅÜ=Ç~òì=Éáå=ïÉáJ íÉêÉë=i~ÄÉäI=Ç~ë=ëçää=~åÑ~åÖë=äÉÉê=ëÉáåK=bë=ÄÉâçããí=îçå=aÉäéÜá=ÇÉå=k~ãÉå= Label3K== kìå=ÇáÉ=^ìÑÖ~ÄÉW=táêÇ=ÇÉê=j~ìëòÉáÖÉê=ΩÄÉê=ÉáåÉã=ÇÉê=_ìííçåë=ÄÉïÉÖíI=ëçää=áã= i~ÄÉä= ÇÉê= k~ãÉ= ÇÉë= ÖÉê~ÇÉ= łΩÄÉêÑäçÖÉåÉå= lêíÉë= ÉêëÅÜÉáåÉåX= ïáêÇ= ÇÉê= j~ìëJ òÉáÖÉê= Ç~ÖÉÖÉå= ΩÄÉê= ÇÉã= wïáëÅÜÉåê~ìã= ÄÉïÉÖíI= ëçää= łaÉìíëÅÜä~åÇ= áã= i~ÄÉä= ÉêëÅÜÉáåÉåK= báåÉ=®ÜåäáÅÜÉ=^ìÑÖ~ÄÉ=ïìêÇÉ=ëÅÜçå=áå=^ÄëÅÜåáíí=OKPKN=ÖÉä∏ëíI=Ççêí=àÉÇçÅÜ=ÖáåÖ= Éë=åìê=ìã=ÉáåÉ=ÉáåÑ~ÅÜÉ=jáííÉáäìåÖK=táê=ÉêáååÉêå=ìåë=àÉÇçÅÜI=Ç~ëë=ÇáÉ=j~ìëòÉáJ ÖÉêJ_ÉïÉÖìåÖ=âÉáå=pí~åÇ~êÇJbêÉáÖåáë=áëíK= cçäÖäáÅÜ= ÄÉëÅÜ~ÑÑÉå= ïáê= ìåë= ãáí= eáäÑÉ= ÇÉë= oÉÖáëíÉêÄä~ííÉë= bobfdkfppb= ÇÉê= lÄJ àÉâíáåëéÉâíçêÉå=ÇáÉ=ÑΩåÑ=o~ÜãÉå=ÑΩê=ÇáÉ=ÑΩåÑ=bêÉáÖåáëéêçòÉÇìêÉåK== a~åå=ÉêáååÉêå=ïáê=ìåë=Ç~ê~åI=Ç~ëë=ÇáÉ= _ÉëÅÜêáÑíìåÖ=ÉáåÉë= i~ÄÉäë=ãáí= eáäÑÉ= ÇÉê= éêçéÉêíó= CaptionI=ÇÉêÉå=k~ãÉ=ïáê=~ìë=ÇÉã=oÉÖáëíÉêÄä~íí=bfdbkp`e^cqbk=ÇÉë=i~J ÄÉäJlÄàÉâíáåëéÉâíçêë=âÉååÉåI=îÉê®åÇÉêí=ïÉêÇÉå=â~ååK== a~ë=áëí=ëÅÜçå=~ääÉëI=ìåÇ=åìå=â∏ååÉå=ïáê=ìåë=ÇáÉ=ÑΩåÑ=ÑÉêíáÖÉå=bêÉáÖåáëéêçòÉÇìêÉå= ~åëÉÜÉåW== procedure TForm1.Button4MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer); begin Label3.caption:='Flensburg' end;
SS= =
QKQ== ^âíáîÉê=ìåÇ=é~ëëáîÉê=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉ= procedure TForm1.Button5MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer); begin Label3.caption:='Görlitz' end; procedure TForm1.Button6MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer); begin Label3.caption:='Garmisch' end; procedure TForm1.Button7MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer); begin Label3.caption:='Aachen' end; procedure TForm1.FormMouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer); begin Label3.Caption:='Deutschland' end;
fëí=Éë=åáÅÜí=ÉáåÉ=ëÅÜ∏åÉ=dÉëíÉ=îçå=aÉäéÜáI=Ç~ëë=ìåë=ÇáÉ=o~ÜãÉå=ÇÉê=bêÉáÖåáëJ éêçòÉÇìêÉå= áããÉê= ÖÉëÅÜÉåâí= ïÉêÇÉå\= d~åòÉ= ÑΩåÑ= wìïÉáëìåÖëÄÉÑÉÜäÉ= ãìëëíÉå= ïáê= àÉïÉáäë= òïáëÅÜÉå= begin= ìåÇ= end;= ëÅÜêÉáÄÉåI= ìåÇ= ëÅÜçå= Ü~í= ÇáÉ= _ÉåìíòÉêJ çÄÉêÑä®ÅÜÉ=ÖÉå~ì=ÇáÉ=cìåâíáçå~äáí®íI=ÇáÉ=ÇìêÅÜ=ÇáÉ=^ìÑÖ~ÄÉ=îçêÖÉÖÉÄÉå=ï~êK== §ÄêáÖÉåë=Ó=ï~ë=ïáêÇ=ÇÉåå=áã=i~ÄÉä=~åÖÉòÉáÖíI=ïÉåå=ÇÉê=kìíòÉê=ÇÉå=j~ìëòÉáJ ÖÉê=ΩÄÉê=ÉÄÉå=ÇáÉëÉã=i~ÄÉä=ÄÉïÉÖÉå=ïáêÇ\=k~íΩêäáÅÜW=łaÉìíëÅÜä~åÇK==
4.4
Aktiver und passiver Zugriff auf Datenkerne táê= Ü~ÄÉå= ÖÉäÉêåíI= ïáÉ= ã~å= báÖÉåëÅÜ~ÑíÉå= EéêçéÉêíáÉëF= ÄÉåìíòíI= ìã= ~ìë= ÇÉå= a~íÉåâÉêåÉå= ÇÉë= ÉáÖÉåÉå= çÇÉê= ÑêÉãÇÉê= lÄàÉâíÉ= Éíï~ë= łÜÉê~ìëòìÜçäÉåI= ïáê= Ü~ÄÉå=ÖÉäÉêåíI=ïáÉ=ã~å=éêçéÉêíáÉë=ÄÉåìíòíI=ìã=áå=ÇáÉ=a~íÉåâÉêåÉ=ÇÉë=ÉáÖÉåÉå= çÇÉê= ÑêÉãÇÉê= lÄàÉâíÉ= Éíï~ë= łÜáåÉáåòìÄêáåÖÉå= Ó= ï~ë= ëçää= ìåë= Ç~ê~å= ÜáåÇÉêåI= ÄÉáÇÉë=òì=íìå\== _ä®ííÉêå=ïáê= åçÅÜ=Éáåã~ä=òìêΩÅâ=òì=_áäÇ=QKT=áã=^ÄëÅÜåáíí=QKOKOK=báÖÉåíäáÅÜ=ÄÉJ ëÅÜêÉáÄí=ÇáÉëÉë=_áäÇ=ÖÉå~ì=ÇáÉ=páíì~íáçåI=ìã=ÇáÉ=Éë=åìå=ÖÉÜíK= • få=ÉáåÉê=bêÉáÖåáëéêçòÉÇìê=â~åå=Éë=~âíáîÉ=ìåÇ=é~ëëáîÉ=wìÖêáÑÑÉ=~ìÑ=ÇáÉ=a~íÉåJ âÉêåÉ=ÇÉë=ÉáÖÉåÉå=lÄàÉâíë=ìåÇ=ÑêÉãÇÉê=lÄàÉâíÉ=ÖÉÄÉå>== c~åÖÉå=ïáê=Ö~åò=ÉáåÑ~ÅÜ=~åK=báå=cçêãìä~ê=ÄÉëáíòÉ=òïÉá=ΩÄÉêÉáå~åÇÉê=äáÉÖÉåÇÉ= pÅêçääÄ~êëK== == = ST =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= == = ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 4= ÇáÉ= zipJa~íÉá= DKap04.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap04= ÇáÉ= mêçàÉâíJa~íÉá= proj_44.dpr= ~ìëòìï®ÜäÉåK= táêÇ= ãáí= aÉäéÜá= ULOMMR= ÖÉ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap04=ÇáÉ=a~íÉá=proj_44.bdsproj=~ìëòìï®ÜäÉåK== == tÉåå=ÇÉê=kìíòÉê=áå=ÇÉê=çÄÉêÉå=pÅêçääÄ~ê=ÇáÉ=mçëáíáçå=ÇÉë=oÉÖäÉêë=®åÇÉêí=Epí~åJ Ç~êÇJbêÉáÖåáëFI= ëçää= ëáÅÜ= ÇáÉ= mçëáíáçå= ÇÉë= oÉÖäÉêë= áå= ÇÉê= ìåíÉêÉå= pÅêçääÄ~ê= ~ìíçJ ã~íáëÅÜ=~åé~ëëÉåK== ûåÇÉêí=ÇÉê=kìíòÉê=áå=ÇÉê=ìåíÉêÉå=pÅêçääÄ~êI=ëç=ëçää=ëáÅÜ=ÇáÉ=çÄÉêÉ=~ìíçã~íáëÅÜ= ~åé~ëëÉåK== pÉÜÉå=ïáê=ìåë=ÖäÉáÅÜ=ÇáÉ=ÄÉáÇÉå=bêÉáÖåáëéêçòÉÇìêÉå=~åK=wìÉêëí=ÇáÉ=bêÉáÖåáëéêçJ òÉÇìê=ÑΩê=ÇáÉ=sÉêëÅÜáÉÄìåÖ=ÇÉë=oÉÖäÉêë=áå=ÇÉê=çÄÉêÉå=pÅêçääÄ~êI=ÇK=ÜK=ÇÉê=ûåÇÉJ êìåÖ=~ã=lÄàÉâí=ãáí=ÇÉã=k~ãÉå=ScrollBar1W== procedure TForm1.ScrollBar1Change(Sender: TObject); begin Scrollbar2.Position:=Scrollbar1.Position end;
a~åå= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= ÑΩê= ÇáÉ= ûåÇÉêìåÖ= áã= ìåíÉêÉå= lÄàÉâí= ãáí= ÇÉã= îçå= aÉäéÜá=îÉêÖÉÄÉåÉå=k~ãÉå=ScrollBar2W== procedure TForm1.ScrollBar2Change(Sender: TObject); begin Scrollbar1.Position:=Scrollbar2.Position end;
_áäÇ=QKNV=ÄÉëÅÜêÉáÄí=àÉïÉáäë=ÇáÉ=páíì~íáçåW=dÉÜçäí=ïáêÇ=áå=ÄÉáÇÉå=c®ääÉå=~ìë=ÇÉã= ÉáÖÉåÉå=a~íÉåâÉêåI=íê~åëéçêíáÉêí=ïáêÇ=áå=ÇÉå=ÑêÉãÇÉå=a~íÉåâÉêåK= _Éíê~ÅÜíÉå= ïáê= Éáå= å®ÅÜëíÉë= _ÉáëéáÉäW= ^ìÑ= ÇÉê= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= ÄÉÑáåÇÉ= ëáÅÜ= òìë®íòäáÅÜ= Éáå= qÉñíÑÉåëíÉê= ãáí= ÇÉã= k~ãÉå= Edit1I= Ç~êìåíÉê= ëÉá= Éáå= i~ÄÉä= ~åJ ÖÉçêÇåÉíI= Ç~ë= îçå= aÉäéÜá= ÇÉå= k~ãÉå= Label1= ÄÉâçããíK= _Éá= àÉÇÉê= ûåÇÉêìåÖI= ÇáÉ= ÇÉê= kìíòÉê= áã= qÉñíÑÉåëíÉê= îçêåáããí= Epí~åÇ~êÇJbêÉáÖåáëFI= ëçää= ~ìíçã~íáëÅÜ= ÇÉê= ~âíìÉääÉ= fåÜ~äí= ÇÉë= qÉñíÑÉåëíÉêë= ~äë= _ÉëÅÜêáÑíìåÖ= ÇÉë= i~ÄÉäë= ~åÖÉòÉáÖí= ïÉêJ ÇÉåK== §ÄÉêäÉÖÉå=ïáê=ìåë=ÇÉå=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=òìã=bêÉáÖåáë=ûåÇÉêìåÖ=áã= qÉñíÑÉåëíÉêW==aáÉ=nìÉääÉ=áëí=ÜáÉê=ÇÉê=a~íÉåâÉêå=ÇÉë=qÉñíÑÉåëíÉêë= Edit1I=EÇÉê=ÉáJ ÖÉåÉ=a~íÉåâÉêåFI=Ç~ë=wáÉä=áëí=ÇÉê=a~íÉåâÉêå=îçå=Label1K== SU= =
QKQ== ^âíáîÉê=ìåÇ=é~ëëáîÉê=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉ=
= _áäÇ=QKNVW=^ìë=ÇÉã=ÉáÖÉåÉå=áå=ÇÉå=ÑêÉãÇÉå=a~íÉåâÉêå= kìå=Äê~ìÅÜÉå=ïáê=åìê=åçÅÜ=ÇáÉ=êáÅÜíáÖÉå=báÖÉåëÅÜ~ÑíÉå=EéêçéÉêíáÉëF=~ìëòìï®ÜJ äÉåW= procedure TForm1.Edit1Change(Sender: TObject); begin Label1.Caption:=Edit1.Text end;
aáÉ= áã= _áäÇ= QKNV= ÖÉëÅÜáäÇÉêíÉ= páíì~íáçå= ł~ìë= ÇÉã= ÉáÖÉåÉå= áå= ÇÉå= ÑêÉãÇÉå= a~J íÉåâÉêå=äáÉÖí=~ìÅÜ=ÄÉá=ÇÉã=å®ÅÜëíÉå=_ÉáëéáÉä=îçêI=Ççêí=ëçÖ~ê=òïÉáã~äW== bêïÉáíÉêå= ïáê= ìåëÉêÉ= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= Éáå= ÇêáííÉë= j~äK= kÉÄÉåÉáå~åÇÉê= ïÉêJ ÇÉå=òïÉá=`ÜÉÅâÄçñÉå=éä~íòáÉêíW=iáåâë=ÄÉÑáåÇÉ=ëáÅÜ=ÉáåÉ=`ÜÉÅâÄçñ=ãáí=ÇÉã=k~J ãÉå= CheckBox1I=êÉÅÜíë=Ç~åÉÄÉå=ÉáåÉ=~åÇÉêÉ=`ÜÉÅâÄçñ=ãáí=ÇÉã=k~ãÉå= CheckBox2K== táêÇ=îçã=kìíòÉê=áå=ÇÉê=äáåâÉå=`ÜÉÅâÄçñ=ÖÉâäáÅâí=EÉáå=çÇÉê=~ìëFI=ëçää=~ìíçã~J íáëÅÜ=ÇáÉ=êÉÅÜíÉ=`ÜÉÅâÄçñ=ÇáÉëÉäÄÉ=_ÉäÉÖìåÖ=~ååÉÜãÉåK== táêÇ=îçã=kìíòÉê=áå=ÇÉê=êÉÅÜíÉå=`ÜÉÅâÄçñ=ÖÉâäáÅâí=EÉáå=çÇÉê=~ìëFI=ëçää=~ìíçã~J íáëÅÜ=ÇáÉ=äáåâÉ=`ÜÉÅâÄçñ=ÇáÉëÉäÄÉ=_ÉäÉÖìåÖ=~ååÉÜãÉåK== _ÉáÇÉ=bêÉáÖåáëéêçòÉÇìêÉå=â∏ååÉå=ïáê=ëçÑçêí=ëÅÜêÉáÄÉåI=Ç~=ïáê=ÇÉå=k~ãÉå=ÇÉê= é~ëëÉåÇÉå=éêçéÉêíó= Checked=~ìë=ÇÉã=oÉÖáëíÉêÄä~íí=bfdbkp`e^cqbk=ÇÉê=`ÜÉÅâÄçJ ñÉå=âÉååÉåW== SV =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= procedure TForm1.CheckBox1Click(Sender: TObject); begin Checkbox2.Checked:=Checkbox1.Checked end; procedure TForm1.CheckBox2Click(Sender: TObject); begin Checkbox1.Checked:=Checkbox2.Checked end;
kìå=åçÅÜ=Éáå=äÉíòíÉë=_ÉáëéáÉäI=ÇÉåå=Éë=áëí=ïáêâäáÅÜ=åáÅÜí=ëÅÜïÉêW=aáÉ=_ÉåìíòÉêJ çÄÉêÑä®ÅÜÉ= ïáêÇ= ÉêÖ®åòí= ÇìêÅÜ= ÉáåÉå= _ìííçå= ãáí= ÇÉê= _ÉëÅÜêáÑíìåÖ= WeiterI= Ç~êJ ìåíÉê= ïáêÇ= ÉáåÉ= ïÉáíÉêÉ= pÅêçääÄ~ê= ãáí= pí~åÇ~êÇJpí~êíÉáåëíÉääìåÖ= éä~íòáÉêíW= jáåáJ ãìã= NullI=j~ñáãìã= 100I= mçëáíáçå= NullK= aáÉëÉ= pÅêçääÄ~ê= ÄÉâçããí= îçå= aÉäéÜá= ÑçäÖäáÅÜ=ÇÉå=k~ãÉå=Scrollbar3K= _Éá=àÉÇÉã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ëçää=ëáÅÜ=ÇáÉ=mçëáíáçå=ÇÉë=oÉÖäÉêë=ìã=NM=báåÜÉáJ íÉå=å~ÅÜ=êÉÅÜíë=îÉêëÅÜáÉÄÉåK== procedure TForm1.Button1Click(Sender: TObject); begin ScrollBar3.Position:=ScrollBar3.Position+10 end;
a~ë=pÅÜÉã~=áå=_áäÇ=QKOM=îÉêÇÉìíäáÅÜí=ÇáÉëã~ä=Ç~ë=Éíï~ë=~åÇÉêÉ=sçêÖÉÜÉåW== • aáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=Üçäí=ãáííÉäë=ÇÉê=éêçéÉêíó= Position= òìÉêëí= ÇáÉ= ÖÉïΩåëÅÜíÉ= ^åÖ~ÄÉ= ~ìë= ÇÉã= a~íÉåâÉêå= ÇÉê= pÅêçääÄ~ê= EÑêÉãÇÉë=lÄàÉâíFK== • a~åå=îÉê~êÄÉáíÉí=ëáÉ=ÇáÉëÉ=^åÖ~ÄÉI=áåÇÉã=ëáÉ=ÇáÉ=w~Üä=NM=Üáåòì=~ÇÇáÉêíK= • pÅÜäáÉ≈äáÅÜ= íê~åëéçêíáÉêí= ëáÉ= ÇÉå= åÉìÉå= tÉêí= ïáÉÇÉê= ãáí= ÉáåÉê= éêçéÉêíó= ÇÉëJ ëÉäÄÉå=k~ãÉåë=òìêΩÅâ=áå=ÇÉå=a~íÉåâÉêå=ÇÉê=pÅêçääÄ~ê=EÑêÉãÇÉë=lÄàÉâíFI=ïçJ ãáí=ëçÑçêí=ÇáÉ=åÉìÉ=mçëáíáçå=ÇÉë=oÉÖäÉêë=ëáÅÜíÄ~ê=ïáêÇK==
4.5
Aktivierung und Deaktivierung von Steuerelementen táê= ~ääÉ= âÉååÉå= Éë= îçå= táåÇçïëW= hÉáåÉëÑ~ääë= áããÉê= áëí= Éë= ëáååîçääI= Ç~ëë= ÇÉê= kìíòÉê=àÉÇÉë=píÉìÉêÉäÉãÉåíI=Ç~ë=ëáÅÜ=~ìÑ=ÉáåÉã=cçêãìä~ê=ÄÉÑáåÇÉíI=~ìÅÜ=àÉÇÉêJ òÉáí=ÄÉÇáÉåÉå=â∏ååÉå=ëçääíÉK== báå=åÉìÉë=_ÉáëéáÉä=Ç~òìW=^ìÑ=ÉáåÉã=cçêãìä~ê=ÄÉÑáåÇÉå=ëáÅÜ=Éáå=~åÑ~åÖë=äÉÉêÉë= qÉñíÑÉåëíÉêI=Éáå=_ìííçå=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ= Übernehmen=ìåÇ=Éáå=~åÑ~åÖë=ÉÄÉåJ Ñ~ääë=ìåÄÉëÅÜêáÑíÉíÉë=i~ÄÉäK== _Éáã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ëçää=ÇÉê=~âíìÉääÉ=fåÜ~äí=ÇÉë=qÉñíÑÉåëíÉêë=~äë=_ÉëÅÜêáÑJ íìåÖ=ÇÉë=i~ÄÉäë=ÉêëÅÜÉáåÉåK==
TM= =
QKR== ^âíáîáÉêìåÖ=ìåÇ=aÉ~âíáîáÉêìåÖ=îçå=píÉìÉêÉäÉãÉåíÉå=
= _áäÇ=QKOMW=^âíáîÉê=ìåÇ=é~ëëáîÉê=wìÖêáÑÑ=~ìÑ=ÑêÉãÇÉå=a~íÉåâÉêå= gÉíòí=ëçää=ìåë=~ÄÉê=åáÅÜí=îçêÇÉêÖêΩåÇáÖ=ÇÉê=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ÑΩê=Ç~ë= pí~åÇ~êÇJbêÉáÖåáë=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ÄÉëÅÜ®ÑíáÖÉå=Ó=ÇáÉëÉê=áëí=áåòïáëÅÜÉå=ÄÉJ â~ååí=EëáÉÜÉ=^ÄëÅÜåáíí=QKQFK=kÉáåI=îáÉäãÉÜê=ïçääÉå=ïáê=âÉååÉå=äÉêåÉåI=ïáÉ=ã~å= Ç~ÑΩê=ëçêÖíI=Ç~ëë=ÇÉê=kìíòÉê=ÄÉá=äÉÉêÉã=qÉñíÑÉåëíÉê=ÇÉå=_ìííçå=ΩÄÉêÜ~ìéí=åáÅÜí= ÄÉÇáÉåÉå=â~ååK== a~òì= ÖáÄí= Éë= òïÉá= j∏ÖäáÅÜâÉáíÉåW= aÉê= _ìííçå= ïáêÇ= î∏ääáÖ= ìåëáÅÜíÄ~ê= ÖÉã~ÅÜíI= ëçä~åÖÉ= Ç~ë= qÉñíÑÉåëíÉê= äÉÉê= áëí= Ó= çÇÉê= Éê= ïáêÇ= áå~âíáî= ÖÉëÅÜ~äíÉíK= a~ë= äÉíòíÉêÉ= ÄÉÇÉìíÉíI=Ç~ëë=Éê=òï~ê=ëáÅÜíÄ~ê=ÄäÉáÄíI=~ÄÉê=âÉáåÉå=häáÅâ=ÉåíÖÉÖÉååáããíK=a~ãáí= ïçääÉå=ïáê=ìåë=òìÉêëí=ÄÉëÅÜ®ÑíáÖÉåK=
4.5.1
property Enabled
a~òì=ÖáÄí=Éë=áã=lÄàÉâíáåëéÉâíçê=ÇáÉ=wÉáäÉ=ãáí=ÇÉê=báÖÉåëÅÜ~Ñí=EnabledK==
= _áäÇ=QKONW=báÖÉåëÅÜ~Ñí=Enabled= TN =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= táÉ= áå= _áäÇ= QKON= òì= ÉêâÉååÉå= áëíI= ãìëë= ÇáÉëÉê= éêçéÉêíó= ÉáåÉê= ÇÉê= ÄÉáÇÉå= äçÖáJ ëÅÜÉå= tÉêíÉ= False= çÇÉê= True= òìÖÉïáÉëÉå= ïÉêÇÉåK= pÉÜÉå= ïáê= ìåë= ÇÉå= råíÉêJ ëÅÜáÉÇ=áå=_áäÇ=QKOO=~åW=
== _áäÇ=QKOOW=få~âíáîÉê=ìåÇ=~âíáîÉê=_ìííçå= tÉåå=òì=_ÉÖáåå=ÇÉê=i~ìÑòÉáí=Ç~ë=qÉñíÑÉåëíÉê=äÉÉê=áëíI=ëçääíÉ=òì=_ÉÖáåå=ÇÉê=i~ìÑJ òÉáí=ÇÉê=_ìííçå=áå~âíáî=ëÉáåW=báåÉ=_ÉÇáÉåìåÖ=ÇìêÅÜ=ÇÉå=kìíòÉê=ï®êÉ=òì=ÇáÉëÉã= wÉáíéìåâí= ëáååäçëK= fã= lÄàÉâíáåëéÉâíçê= ïáêÇ= ÑçäÖäáÅÜ= ÇáÉ= wÉáäÉ= Enabled= ÑΩê= ÇÉå= pí~êí=ÇÉê=i~ìÑòÉáí=~ìÑ=False=ÖÉëÉíòíK==
4.5.2 ==
Aktivierung des Steuerelements
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 4= ÇáÉ= zipJa~íÉá= DKap04.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap04= ÇáÉ= mêçàÉâíJa~íÉá= proj_452.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap04=ÇáÉ=a~íÉá=proj_452.bdsproj=~ìëòìï®ÜäÉåK== == t~åå=~ÄÉê=ïáêÇ=ÇáÉ=_ÉÇáÉåìåÖ=ÇÉë=_ìííçå=ëáååîçää\=^åíïçêíW=tÉåå=ÇÉê=kìíòÉê= áå=Ç~ë=qÉñíÑÉåëíÉê=Éíï~ë=ÉáåÖáÄíK== a~ë=ÜÉá≈íI=ïáê=ÄÉëÅÜ~ÑÑÉå=ìåë=ÇÉå=o~ÜãÉå=ÑΩê=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=ûåÇÉêìåÖ= áã= qÉñíÑÉåëíÉê= Epí~åÇ~êÇJbêÉáÖåáëF= ìåÇ= íê~ÖÉå= Ççêí= ÇÉå= wìïÉáëìåÖëÄÉÑÉÜä= òìê= ^âíáîáÉêìåÖ=ÇÉë=_ìííçåë=ÉáåK== aÉå=k~ãÉå=ÇÉê=é~ëëÉåÇÉå=éêçéÉêíó=âÉååÉå=ïáê=~ìë=ÇÉê=báÖÉåëÅÜ~ÑíI=ãáí=ÇÉêÉå= eáäÑÉ=ïáê=ÇáÉ=sçêÉáåëíÉääìåÖ=îçêå~ÜãÉåK=páÉ=ÜÉáëí=EnabledK===== procedure TForm1.Edit1Change(Sender: TObject); begin Button1.Enabled:=True end;
_áäÇ=QKOP=òÉáÖí=ìåë=ÇáÉ=táêâìåÖW=pçÄ~äÇ=ÇìêÅÜ=ÇÉå=kìíòÉê=ÇáÉ=ÉêëíÉ=báåÖ~ÄÉ=áå= Ç~ë=qÉñíÑÉåëíÉê=ÉêÑçäÖíI=ïáêÇ=ÇÉê=_ìííçå=~ìíçã~íáëÅÜ=~âíáî=ìåÇ=Ç~ãáí=ÄÉÇáÉåÄ~êK= TO= =
QKS== sÉêëíÉÅâÉå=îçå=píÉìÉêÉäÉãÉåíÉå= k~íΩêäáÅÜ=ãΩëëíÉå=ïáê=åçÅÜ=Ç~ÑΩê=ëçêÖÉåI=Ç~ëë=ÇÉê=_ìííçå=ïáÉÇÉê=áå~âíáî=ïáêÇI= ïÉåå=ÇÉê=kìíòÉê=ÇÉå=fåÜ~äí=ÇÉë=qÉñíÑÉåëíÉêë=ä∏ëÅÜíK==
= _áäÇ=QKOPW=^âíáîáÉêìåÖ=ÇÉë=_ìííçåë=ÄÉá=báåÖ~ÄÉ=áå=Ç~ë=qÉñíÑÉåëíÉê= bíï~ë=dÉÇìäÇ=ÄáííÉ=Ó=Ç~òì=âçããÉå=ïáê=áã=h~éáíÉä=RKNKOK=
4.5.3
Inaktive Menü-Einträge
fã=_áäÇ=QKOQ=áëí=òì=ëÉÜÉåI=Ç~ëë=ã~å=Ó=ïáÉ=áå=~ääÉå=táåÇçïëJ^åïÉåÇìåÖÉå=çÑí= éê~âíáòáÉêí=Ó=~ìÅÜ=báåíê®ÖÉ=áå=jÉåΩë=~âíáî=ìåÇ=áå~âíáî=ÉáåëíÉääÉå=â~ååK== eáÉê= ëçää= ÇÉê= kìíòÉê= Finnland= ìåÇ= Ungarn= òï~ê= ëÉÜÉåI= ~ÄÉê= åáÅÜí= ~ìëï®ÜäÉå= ÇΩêÑÉåK=
== _áäÇ=QKOQW=få~âíáîÉ=báåíê®ÖÉ=áå=ÉáåÉã=jÉåΩ=
4.6
Verstecken von Steuerelementen
4.6.1
property Visible
jáí=ÇÉê=báÖÉåëÅÜ~Ñí=Visible=E_áäÇ=QKORFI=ÇáÉ=ëáÅÜ=~äë=ÖäÉáÅÜå~ãáÖÉ=éêçéÉêíó=áå=bêJ ÉáÖåáëéêçòÉÇìêÉå=îÉêïÉåÇÉå=ä®ëëíI=â∏ååÉå=îáëìÉääÉ=lÄàÉâíÉ=ëçÖ~ê=ëáÅÜíÄ~ê=ìåÇ= ìåëáÅÜíÄ~ê=ÖÉã~ÅÜí=ïÉêÇÉåK==
== _áäÇ=QKORW=báÖÉåëÅÜ~Ñí=Visible= TP =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= tÉåå=ïáê=ÇÉã=kìíòÉê=ÇÉå=_ìííçå=ΩÄÉêÜ~ìéí=Éêëí=Ç~åå=òÉáÖÉå=ïçääÉåI=ïÉåå=Éê= áã= qÉñíÑÉåëíÉê= Éíï~ë= ÉáåÖÉíê~ÖÉå= Ü~íI= ãΩëëÉå= ïáê= ÇáÉ= báÖÉåëÅÜ~Ñí= Visible= áã= lÄàÉâíáåëéÉâíçê=ÇÉë=_ìííçåë=ÑΩê=ÇÉå=pí~êí=ÇÉê=i~ìÑòÉáí=~ìÑ=False=ëÉíòÉåK==
4.6.2 ==
Steuerelement sichtbar machen
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 4= ÇáÉ= zipJa~íÉá= DKap04.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap04= ÇáÉ= mêçàÉâíJa~íÉá= proj_462.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap04=ÇáÉ=a~íÉá=proj_462.bdsproj=~ìëòìï®ÜäÉåK== == bêëí=ÄÉáã=báåíêÉíÉå=ÇÉë= bêÉáÖåáëëÉë= ûåÇÉêìåÖ=áå= ÇÉê=qÉñíÄçñ= ëçêÖÉå=ïáê=Ç~åå= ãáííÉäë=ÇÉê=éêçéÉêíó=Visible=Ç~ÑΩêI=Ç~ëë=ÇÉê=_ìííçå=ëáÅÜíÄ~ê=ïáêÇK=_áäÇ=QKOS=òÉáÖí= ÇáÉ=páíì~íáçå=ÄÉá=_ÉÖáåå=ÇÉê=i~ìÑòÉáí=ìåÇ=å~ÅÜ=ÇÉê=ÉêëíÉå=báåÖ~ÄÉ=áå=Ç~ë=qÉñíJ ÑÉåëíÉêK== procedure TForm1.Edit1Change(Sender: TObject); begin Button1.Visible:=True end;
== _áäÇ=QKOSW=råëáÅÜíÄ~êÉê=ìåÇ=ëáÅÜíÄ~êÉê=_ìííçå= a~ë= ïÉÅÜëÉäëÉáíáÖÉ= sÉêëíÉÅâÉå= ìåÇ= ^åòÉáÖÉå= îçå= _ÉÇáÉåÉäÉãÉåíÉå= ãáí= eáäÑÉ= ÇÉê=éêçéÉêíó=Visible=ïáêÇ=áåëÖÉë~ãí=îáÉä=ëÉäíÉåÉê=îÉêïÉåÇÉí=~äë=ÇáÉ=^âíáîáÉêìåÖ= ÄòïK=aÉ~âíáîáÉêìåÖ=îçå=_ÉÇáÉåìåÖëÉäÉãÉåíÉåK== a~ë=áëí=~ìÅÜ=Ñ~áê=ÖÉÖÉåΩÄÉê=ÇÉã=kìíòÉêW=bê=ëçää=ëÅÜäáÉ≈äáÅÜ=ïáëëÉåI=ï~ë=ÇáÉ=_ÉJ åìíòÉêçÄÉêÑä®ÅÜÉ=ÑΩê=áÜå=ÄÉêÉáíÜ®äíI=~ìÅÜ=ïÉåå=Éê=Ç~ë=áå~âíáîÉ=píÉìÉêÉäÉãÉåí=áã= jçãÉåí=åáÅÜí=ÄÉÇáÉåÉå=Ç~êÑ=ìåÇ=â~ååK==
4.7
Namensbeschaffung für passende property _Éíê~ÅÜíÉå=ïáê=Ç~ë=_áäÇ=QKOTI=Ç~ë=ìåë=ÇÉå=ÄáëÜÉêáÖÉå=jÉÅÜ~åáëãìë=åçÅÜ=Éáåã~ä= Éêâä®êíI= ïáÉ= ÉáåÉ= bêÉáÖåáëéêçòÉÇìê= é~ëëáî= ìåÇLçÇÉê= ~âíáî= ãáííÉäë= ÉáåÉê= é~ëëÉåJ ÇÉå= éêçéÉêíó= ~ìÑ= ÇÉå= ÉáÖÉåÉå= çÇÉê= ÉáåÉå= ÑêÉãÇÉå= a~íÉåâÉêå= òìÖêÉáÑÉå= â~ååI= ìã= Ç~ãáí= îçã= píÉìÉêÉäÉãÉåí= Éíï~ë= òì= ÉêÑ~ÜêÉå= ÄòïK= ~ã= çÇÉê= áã= píÉìÉêÉäÉJ ãÉåí=Éíï~ë=òì=îÉê®åÇÉêåK==
TQ= =
QKT== k~ãÉåëÄÉëÅÜ~ÑÑìåÖ=ÑΩê=é~ëëÉåÇÉ=éêçéÉêíó=
== _áäÇ=QKOTW=nìÉääÉ=ìåÇ=wáÉä=ÉáåÉê=bêÉáÖåáëéêçòÉÇìê= aáÉëÉê=jÉÅÜ~åáëãìë=ÑìåâíáçåáÉêí=~ÄÉê=åìêI=ïÉåå=ã~å=ÖÉå~ì=ïÉá≈I=ïáÉ=ÇáÉ=ÉåíJ ëéêÉÅÜÉåÇÉ=báÖÉåëÅÜ~Ñí=EéêçéÉêíóF=ÜÉá≈íI=ãáí=ÇÉê=~ìÑ=ÇÉå=a~íÉåâÉêå=òìÖÉÖêáÑÑÉå= ïáêÇK==
4.7.1 ==
property-Namen im Objektinspektor finden
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 4= ÇáÉ= zipJa~íÉá= DKap04.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap04= ÇáÉ= mêçàÉâíJa~íÉá= proj_471.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap04=ÇáÉ=a~íÉá=proj_471.bdsproj=~ìëòìï®ÜäÉåK== = pÉÜÉå=ïáê=ìåë=Ç~ë=sçêÖÉÜÉå=åçÅÜ=Éáåã~ä=~å=ÉáåÉã=_ÉáëéáÉä=~åK=få=òïÉá=o~ÇáçJ ÖêìééÉå= EëK= ^ÄëÅÜåáíí= PKPF= ãáí= ÇÉå= k~ãÉå= RadioGroup1= ìåÇ= RadioGroup2= ÄÉÑáåJ ÇÉå= ëáÅÜ= åÉÄÉåÉáå~åÇÉê= ÇáÉ= k~ãÉå= ÇÉê= ÇÉìíëÅÜÉå= _ìåÇÉëä®åÇÉê= ìåÇ= ÇÉêÉå= e~ìéíëí®ÇíÉ=E_áäÇ=QKOUFK== aáÉ= ^ìÑÖ~ÄÉ= áëí= ÉáåÑ~ÅÜW= táêÇ= äáåâë= Éáå= _ìåÇÉëä~åÇ= ~ìëÖÉï®ÜäíI= ëç= ëçää= ~ìíçJ ã~íáëÅÜ=êÉÅÜíë=ÇáÉ=òìÖÉÜ∏êáÖÉ=e~ìéíëí~Çí=ÇáÉ=j~êâáÉêìåÖ=ÉêÜ~äíÉåK=táêÇ=Ç~ÖÉJ ÖÉå=êÉÅÜíë=ÉáåÉ=i~åÇÉëÜ~ìéíëí~Çí=ÇìêÅÜ=ÇÉå=kìíòÉê=~ìëÖÉï®ÜäíI=ëç=ëçää=Ç~ë=òìJ ÖÉÜ∏êáÖÉ=_ìåÇÉëä~åÇ=ÇáÉ=j~êâáÉêìåÖ=ÄÉâçããÉåK== TR =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= aáÉ=o~ÜãÉå=ÇÉê=ÄÉáÇÉå=bêÉáÖåáëéêçòÉÇìêÉå=ëáåÇ=ÇìêÅÜ=açééÉäâäáÅâ=ëÅÜåÉää=ÄÉJ ëÅÜ~ÑÑíI=ïÉáä=Éë=ëáÅÜ=áå=ÄÉáÇÉå=c®ääÉå=ìã=Ç~ë=àÉïÉáäáÖÉ= pí~åÇ~êÇJbêÉáÖåáë=Ü~åJ ÇÉäíK=cΩê=ÇÉå=fåÜ~äí=áëí=Ç~ë=tÉëÉåíäáÅÜÉ=~ìÅÜ=âä~êW==
= _áäÇ=QKOUW=_ÉÖáåå=ÇÉê=i~ìÑòÉáí=ìåÇ=å~ÅÜ=ÉáåÉê=^ìëï~Üä== táêÇ= áå= ÇÉê= i®åÇÉêÖêìééÉ= ÖÉï®ÜäíI= ãìëë= çÑÑÉåÄ~ê= cçäÖÉåÇÉë= éêçÖê~ããáÉêí= ïÉêÇÉåW== Städte-Gruppe.Positionsproperty := Länder-Gruppe.Positionsproperty
táêÇ=áå=ÇÉê=pí®ÇíÉÖêìééÉ=ÖÉï®ÜäíI=áëí=Ç~ÖÉÖÉå=ÑçäÖÉåÇÉê=wìïÉáëìåÖëÄÉÑÉÜä=~ìÑJ òìëÅÜêÉáÄÉåW== Länder-Gruppe.Positionsproperty:= Städte-Gruppe.Positionsproperty
aáÉ=i®åÇÉêJdêìééÉ=ÜÉá≈í= RadioGroup1I=ÇáÉ=pí®ÇíÉJdêìééÉ=ÜÉá≈í= RadioGroup2I=Ç~ë= ë~Öí=ìåë=ÇÉê=lÄàÉâíáåëéÉâíçêK=açÅÜ=ïáÉ=ÜÉá≈í=ÇáÉ=éêçéÉêíóI=ÇáÉ=ÇáÉ=mçëáíáçå=Üçäí= ìåÇ=ÄêáåÖí\=
=== _áäÇ=QKOVW=ItemIndex=~ìÑ=ÓN=îçêÉáåÖÉëíÉääíW=hÉáåÉ=pí~êí~ìëï~Üä= bêáååÉêå=ïáê=ìåë=~å=ÇÉå=^ÄëÅÜåáíí=PKPW=aáÉ=ÖÉëìÅÜíÉ=éêçéÉêíó=ÜÉá≈í=ItemIndexK= TS= =
QKT== k~ãÉåëÄÉëÅÜ~ÑÑìåÖ=ÑΩê=é~ëëÉåÇÉ=éêçéÉêíó= páÉ=Ü~í=Ó=ïáÉ=~ääÉ=éêçéÉêíáÉëI=ãáí=ÇÉåÉå=ïáê=ÄáëÜÉê=~êÄÉáíÉíÉå=Ó=Ç~ë=mêáîáäÉÖI=Ç~ëë= ëáÉ=ëçÖ~ê=áã=oÉÖáëíÉêÄä~íí=bfdbkp`e^cqbk=ÇÉë=lÄàÉâíáåëéÉâíçêë=E_áäÇ=QKOVF=òì=ÑáåJ ÇÉå= áëíK= táêÇ= áå= ÇÉê= wÉáäÉ= ItemIndex= ÇÉê= tÉêí= ãáåìë= báåë= ÉáåÖÉíê~ÖÉå= ÖáÄí= Éë= ~åÑ~åÖë=âÉáåÉ=j~êâáÉêìåÖ=áå=ÇÉê=o~ÇáçÖêìééÉK== ^åëçåëíÉå= ÄÉÖáååí= ÇáÉ= w®ÜäìåÖ= ÇÉê= mçëáíáçå= áããÉê= ãáí= kìääK= EcΩê= ÇáÉ= j~êâáÉJ êìåÖ=îçå=Sachsen-Anhalt=ÄòïK=Magdeburg=ãΩëëíÉ=ÇÉãå~ÅÜ=ÇáÉ=kÉìå=ÉáåÖÉíê~ÖÉå= ïÉêÇÉåFK= kìå=ëáåÇ=~ääÉ=fåÑçêã~íáçåÉå=îÉêÑΩÖÄ~êI=ÇÉê=k~ãÉ=ÇÉê=é~ëëÉåÇÉå=éêçéÉêíó=áëí=ÄÉJ â~ååíI= ìåÇ= ÇáÉ= fåÜ~äíÉ= ÇÉê= ÄÉáÇÉå= bêÉáÖåáëéêçòÉÇìêÉå= â∏ååÉå= éêçÖê~ããáÉêí= ïÉêÇÉåW== procedure TForm1.RadioGroup1Click(Sender: TObject); begin RadioGroup2.ItemIndex:=RadioGroup1.ItemIndex end; procedure TForm1.RadioGroup2Click(Sender: TObject); begin RadioGroup1.ItemIndex:=RadioGroup2.ItemIndex end;
4.7.2 ==
Eigenschaft fehlt im Objektinspektor
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 4= ÇáÉ= zipJa~íÉá= DKap04.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap04= ÇáÉ= mêçàÉâíJa~íÉá= proj_472.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap04=ÇáÉ=a~íÉá=proj_472.bdsproj=~ìëòìï®ÜäÉåK== == _Éíê~ÅÜíÉå= ïáê= Éáå= ëÅÜÉáåÄ~ê= ÖäÉáÅÜïÉêíáÖÉë= mêçÄäÉãW= aáÉ= i®åÇÉê= ìåÇ= i~åÇÉëJ Ü~ìéíëí®ÇíÉ= ÄÉÑáåÇÉå= ëáÅÜ= òïÉá= iáëíÉåI= ÇK= ÜK= áå= òïÉá= píÉìÉêÉäÉãÉåíÉå= ãáí= ÇÉå= îçå=aÉäéÜá=îÉêÖÉÄÉåÉå=k~ãÉå=ListBox1=ìåÇ=ListBox2=E_áäÇ=QKPMFK== táÉÇÉêìã=ëçää=òì=_ÉÖáåå=ÇÉê=i~ìÑòÉáí=âÉáåÉ=j~êâáÉêìåÖ=ÖÉëÉíòí=ëÉáåI=ìåÇ=ïáÉJ ÇÉêìã=ëçää=ëáÅÜ=ÄÉá=t~Üä=áå=ÇÉê=äáåâÉå=iáëíÉ=ÇáÉ=j~êâáÉêìåÖ=êÉÅÜíë=~ìíçã~íáëÅÜ= ~åé~ëëÉå=ìåÇ=ìãÖÉâÉÜêíK== aáÉ=o~ÜãÉå=ÇÉê=bêÉáÖåáëéêçòÉÇìêÉå=ÄÉâçããÉå=ïáê=ëçÑçêí=ÇìêÅÜ=ÇÉå=açééÉäJ âäáÅâI=ëÅÜäáÉ≈äáÅÜ=ïçääÉå=ïáê=~ìÅÜ=ÜáÉê=oÉ~âíáçåÉå=~ìÑ=ÇáÉ= pí~åÇ~êÇJbêÉáÖåáëëÉ= EëáÉÜÉ=^ÄëÅÜåáíí=PKNF=éêçÖê~ããáÉêÉåK= cΩê=ÇÉå=fåÜ~äí=áëí=~ìÅÜ=îçã=mêáåòáé=ÜÉê=ïáÉÇÉê=~ääÉë=âä~êK=táêÇ=áå=ÇÉê=i®åÇÉêJ äáëíÉ=ÖÉï®ÜäíI=ãìëë=ÑçäÖÉåÇÉë=éêçÖê~ããáÉêí=ïÉêÇÉåW== TT =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= Städte-Liste.Positionsproperty:=Länder-Liste.Positionsproperty
táêÇ=áå=ÇÉê=pí®ÇíÉäáëíÉ=ÖÉï®ÜäíI=áëí=ÑçäÖÉåÇÉê=wìïÉáëìåÖëÄÉÑÉÜä=~ìÑòìëÅÜêÉáÄÉåW== Länder-Liste.Positionsproperty:=Städte-Liste.Positionsproperty
açÅÜ=åìå=âçããí=Éáå=mêçÄäÉãI=Ç~ë=ïáê=ÄáëÜÉê=åáÅÜí=â~ååíÉåW== táê= â∏ååÉå= Ç~ë= oÉÖáëíÉêÄä~íí= bfdbkp`e^cqbk= áã= lÄàÉâíáåëéÉâíçê= òìã= lÄàÉâí= ãáí=ÇÉã=k~ãÉå= ListBox1=áããÉê=ìåÇ=áããÉê=ïáÉÇÉê=ëíìÇáÉêÉåK=táê=â∏ååÉå=Ç~J ÄÉá=~ìÅÜ=~ääÉ=ÉåÖäáëÅÜÉå=sçâ~ÄÉäå=ÑäÉá≈áÖ=áåë=aÉìíëÅÜÉ=ΩÄÉêëÉíòÉåI=e~åÇÄΩÅÜÉê= òì=eáäÑÉ=åÉÜãÉåW== bë=ïáêÇ=ìåë=åáÅÜí=ÖÉäáåÖÉåI=Ççêí=ÉáåÉ=wÉáäÉ=òì=ÑáåÇÉåI=ãáí=ÇÉêÉå=eáäÑÉ=ÇáÉ=mçëáJ íáçå=ÇÉê=j~êâáÉêìåÖ=áå=ÉáåÉê=iáëíÄçñ=îçêÉáåÖÉëíÉääí=ïÉêÇÉå=â~ååK=báåÉ=ÇÉê~êíáÖÉ= éêçéÉêíó=ëÅÜÉáåí=òì=ÑÉÜäÉåK== lÇÉê=ïìêÇÉ=ëáÉ=åìê=åáÅÜí=áå=Ç~ë=oÉÖáëíÉêÄä~íí=bfdbkp`e^cqbk=ÇÉë=lÄàÉâíáåëéÉâJ íçêë=~ìÑÖÉåçããÉå\==
== _áäÇ=QKPMW=wïÉá=iáëíÉå=ÄÉáã=pí~êí=ìåÇ=å~ÅÜ=ÉáåÉê=^ìëï~Üä== a~ãáí= ëíÉÜÉå= ïáê= îçê= ÇÉã= mêçÄäÉã= ÇÉê= pìÅÜÉ= å~ÅÜ= ÇÉã= k~ãÉå= ÇÉêàÉåáÖÉå= éêçéÉêíóI= ÇáÉ= ÇáÉ= mçëáíáçå= ÇÉê= j~êâáÉêìåÖ= ~ìë= ÉáåÉã= iáëíÉåJa~íÉåâÉêå= ÜÉê~ìëJ Üçäí=ìåÇLçÇÉê=áå=ÉáåÉå=iáëíÉåJa~íÉåâÉêå=ÜáåÉáåÄêáåÖíK=dáÄí=Éë=ëáÉ=ΩÄÉêÜ~ìéí\== aáÉ=i∏ëìåÖ=ä~ìíÉíW=aáÉ=ÖÉëìÅÜíÉ=éêçéÉêíó=ÖáÄí=ÉëI=~ÄÉê=ëáÉ=ãìëë=~å=~åÇÉêÉê=píÉääÉ= ÖÉëìÅÜí=ìåÇ=ÖÉÑìåÇÉå=ïÉêÇÉåK==
4.7.3
Information durch die Punktliste
_áäÇ=QKPN=òÉáÖí=ÉëW=tÉåå=ã~å=ÄÉáã=pÅÜêÉáÄÉå=îçã=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìêI= å~ÅÜ=ÇÉã=k~ãÉå=ÇÉë=lÄàÉâíëI=ÄÉáã=báåíáééÉå=ÇÉë=mìåâíÉëI=âå~éé=ÉáåÉ=pÉâìåJ ÇÉ=ï~êíÉíI=ÉêäÉÄí=ã~å=Ç~ë=^ìÑâä~ééÉå=ÉáåÉë=ÄÉëçåÇÉêÉå=jÉåΩëK= bë=ÉêëÅÜÉáåí=ÉáåÉ=^åòÉáÖÉI=ÇáÉ=ïáê=ïÉÖÉå=ÇÉë=sçêÖÉÜÉåë=òì=áÜêÉê=_ÉëÅÜ~ÑÑìåÖ= ~Ä=àÉíòí=ÇáÉ=mìåâíäáëíÉ=åÉååÉå=ïçääÉåK=
TU= =
QKT== k~ãÉåëÄÉëÅÜ~ÑÑìåÖ=ÑΩê=é~ëëÉåÇÉ=éêçéÉêíó= få=ÇÉê=mìåâíäáëíÉ=ÄÉÑáåÇÉå=ëáÅÜ=ëçïçÜä=ÇáÉàÉåáÖÉå=éêçéÉêíáÉëI=ÇáÉ=ÄÉêÉáíë=~äë=báJ ÖÉåëÅÜ~ÑíÉå= ~ìë= ÇÉã= lÄàÉâíáåëéÉâíçê= ÇÉê= iáëíÉ= ÄÉâ~ååí= ëáåÇI= ~äë= ~ìÅÜ= îáÉäÉ= ïÉáíÉêÉI=ÄáëÜÉê=ìåÄÉâ~ååíÉI=òìë®íòäáÅÜÉ=éêçéÉêíáÉëK==
= _áäÇ=QKPNW=mìåâíäáëíÉ= j~å=ÉêâÉååí=ëáÉ=~ääÉ=~å=ÇÉã=pÅÜäΩëëÉäïçêí= propertyK=^ääÉêÇáåÖëW=fÜê=k~ãÉ=Ç~êÑ= åáÅÜí=ãáí=On=ÄÉÖáååÉåK== • ^ääÉ= éêçéÉêíáÉëI= ÇK= ÜK= ~ääÉ= jÉÅÜ~åáëãÉå= òìã= ~âíáîÉå= ìåÇLçÇÉê= é~ëëáîÉå= wìJ ÖêáÑÑ= ~ìÑ= a~íÉåâÉêåÉ= îçå= îáëìÉääÉå= lÄàÉâíÉåI= ÉêâÉååí= ã~å= áå= ÇÉê= mìåâíäáëíÉ= Ç~ê~åI= Ç~ëë= ëáÉ= ãáí= ÇÉê= qóéJbêâä®êìåÖ= property= îÉêëÉÜÉå= ëáåÇ= ìåÇ= Ç~ëë= áÜê= k~ãÉ=åáÅÜí=ãáí=ÇÉå=ÄÉáÇÉå=_ìÅÜëí~ÄÉå=On=ÄÉÖáååíK=
4.7.4
Information über die Art der Zuweisung
bêáååÉêå=ïáê=ìåë=~å=Ç~ë=_áäÇ=QKOUW=fëí=ÉáåÉ=éêçéÉêíó=áã=oÉÖáëíÉêÄä~íí=bfdbkp`e^cJ qbk= ÇÉë= lÄàÉâíáåëéÉâíçêë= ~ìÑÖÉäáëíÉí= ÉêâÉååí= ã~å= êÉÅÜíë= Ç~åÉÄÉåI= ï~ë= ÇáÉëÉ= éêçéÉêíó=äáÉÑÉêí=ìåÇ=Äê~ìÅÜíK== açÅÜ=ïáÉ=ÉêÑ®Üêí=ã~åI=ï~ë=ÉáåÉ=éêçéÉêíó=äáÉÑÉêí=ìåÇ=Äê~ìÅÜíI=ïÉåå=ëáÉ=åáÅÜí=ëç= éêáîáäÉÖáÉêí=áëíI=Ç~ëë=ëáÉ=áã=lÄàÉâíáåëéÉâíçê=~ìÑÖÉäáëíÉí=áëí\==== pÉÜÉå=ïáê=ìåë=~äë=^åíïçêí=~ìÑ=ÇáÉëÉ=cê~ÖÉ=áå=_áäÇ=QKPN=ÇáÉ=ÜÉêîçêÖÉÜçÄÉåÉ=wÉáJ äÉ=~ìë=ÇÉê=mìåâíäáëíÉ=~åW= property ItemIndex: Integer
oÉÅÜíë=îçã=açééÉäéìåâí=â∏ååÉå=ïáê=ÇáÉ=ÖäÉáÅÜïÉêíáÖÉ=fåÑçêã~íáçå=~ÄäÉëÉåK= • aáÉ=éêçéÉêíó=ItemIndexI=ãáí=ÇÉê=ÇáÉ=mçëáíáçå=ÇÉê=j~êâáÉêìåÖ=áå=ÉáåÉê=iáëíÉ=~ìë= ÇÉã=a~íÉåâÉêå=ÖÉÜçäí=ÄòïK=áå=ÇÉå=a~íÉåâÉêå=ÖÉÄê~ÅÜí=ïÉêÇÉå=â~ååI=äáÉÑÉêí= ÄòïK=ÄÉå∏íáÖí=ÉáåÉ=Ö~åòÉ=w~Üä=EIntegerFK== gÉíòí=ëáåÇ=~ääÉ=fåÑçêã~íáçåÉå=îçêÜ~åÇÉåI=ÇáÉ=ïáê=òìê=i∏ëìåÖ=ÇÉê=^ìÑÖ~ÄÉ=ÄÉå∏J íáÖÉåW== aáÉ=ÄÉáÇÉå=îáëìÉääÉå=lÄàÉâíÉ=ÜÉá≈Éå=ListBox1=ìåÇ=ListBox2I=ÇáÉ=éêçéÉêíó=ÑΩê=ÇáÉ= mçëáíáçå=ÇÉê=j~êâáÉêìåÖ=ÜÉá≈í=ItemIndexK== pçãáí=â∏ååÉå=ïáê=ÇáÉ=o~ÜãÉå=ÇÉê=ÄÉáÇÉå=bêÉáÖåáëéêçòÉÇìêÉå=ÜÉêëíÉääÉå=ä~ëëÉå= ìåÇ=ÇáÉ=fåÜ~äíÉ=ëÅÜêÉáÄÉåW==
TV =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= procedure TForm1.ListBox1Click(Sender: TObject); begin Listbox2.ItemIndex:=Listbox1.ItemIndex end; procedure TForm1.ListBox2Click(Sender: TObject); begin Listbox1.ItemIndex:=Listbox2.ItemIndex end;
4.7.5
Start-Markierung in Listen setzen
fã= lÄàÉâíáåëéÉâíçê= îçå= iáëíÉå= ÖáÄí= ÉëI= Ç~ë= ÉêÑìÜêÉå= ïáê= ÉÄÉåI= âÉáåÉ= éêçéÉêíó= òìê=sçêÉáåëíÉääìåÖ=ÇÉê=pí~êíJj~êâáÉêìåÖ=áå=ÉáåÉê=iáëíÉK=fëí=Ç~ãáí=ëçäÅÜ=ÉáåÉ=sçêJ ÉáåëíÉääìåÖ=ÖÉåÉêÉää=ìåã∏ÖäáÅÜ\= kÉáåK= jáí= eáäÑÉ= ÇÉê= ÖÉÑìåÇÉåÉå= éêçéÉêíó= ItemIndex= ä®ëëí= ëáÅÜ= ÇìêÅÜ= ÉáåÉ= ÄÉJ ëíáããíÉ=bêÉáÖåáëéêçòÉÇìê=Ç~ÑΩê=ëçêÖÉåI=Ç~ëë=ÄÉá= _ÉÖáåå=ÇÉê=i~ìÑòÉáí=ÇáÉ=wÉáäÉ= Sachsen-Anhalt= ãáí= ÇÉê= e~ìéíëí~Çí= Magdeburg= ÄÉêÉáíë= ÇáÉ= j~êâáÉêìåÖ= íê®Öí= E_áäÇ= QKPOFK= báå=açééÉäâäáÅâ=~ìÑ=Ç~ë=cçêãìä~ê=EëáÉÜÉ=^ÄëÅÜåáíí=OKOKTF=äáÉÑÉêí=ìåë=ÄÉâ~ååíäáÅÜ= ÇÉå=o~ÜãÉå=ÑΩê=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=bêÉáÖåáë= CreateW=a~ë=cçêãìä~ê=ïáêÇ= ÉêòÉìÖíK= cçäÖäáÅÜ= Äê~ìÅÜÉå= ïáê= ~äë= fåÜ~äí= ÇáÉëÉê= bêÉáÖåáëéêçòÉÇìê= åìê= ÇáÉ= pí~êíJj~êâáÉJ êìåÖ= òì= éêçÖê~ããáÉêÉåI= ïçÄÉá= ïÉÖÉå= ÇÉê= òïÉá= wìïÉáëìåÖÉå= Ç~ë= pÉãáâçäçå= ~äë=qêÉååòÉáÅÜÉå=òì=ÄÉ~ÅÜíÉå=áëíW== procedure TForm1.FormCreate(Sender: TObject); begin Listbox1.ItemIndex:=9; Listbox2.ItemIndex:=9 end;
== _áäÇ=QKPOW=pí~êíJ_ÉäÉÖìåÖ=áå=ÇÉå=ÄÉáÇÉå=iáëíÄçñÉå==
4.7.6
Passiver und aktiver Zugriff auf Zeilen in einer Listbox
_Éíê~ÅÜíÉå=ïáê=Éáå=ïÉáíÉêÉë=_ÉáëéáÉäI=Ç~ë=ìåë=~ìÅÜ=ïáÉÇÉê=òïáåÖÉå=ïáêÇI=áå=ÇÉê= mìåâíäáëíÉ=å~ÅÜ=ÉáåÉê=é~ëëÉåÇÉå=éêçéÉêíó=òì=ëìÅÜÉåK== ^ìÑ=ÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=ëçääÉå=ëáÅÜ=ïáÉÇÉê=ÇáÉ=iáëíÉ=ÇÉê=_ìåÇÉëä®åÇÉê=ìåÇ= ÇáÉëã~ä= êÉÅÜíë= Ç~åÉÄÉå= Éáå= qÉñíÑÉåëíÉê= ÄÉÑáåÇÉåK= aáÉ= ÖÉÑçêÇÉêíÉ= pí~êíÄÉäÉÖìåÖ= òÉáÖí=_áäÇ=QKPPK= UM= =
QKT== k~ãÉåëÄÉëÅÜ~ÑÑìåÖ=ÑΩê=é~ëëÉåÇÉ=éêçéÉêíó= == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 4= ÇáÉ= zipJa~íÉá= DKap04.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap04= ÇáÉ= mêçàÉâíJa~íÉá= proj_476.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap04=ÇáÉ=a~íÉá=proj_476.bdsproj=~ìëòìï®ÜäÉåK== ==
= _áäÇ=QKPP=pí~êíJ_ÉäÉÖìåÖ=áå=iáëíÉ=ìåÇ=qÉñíÑÉåëíÉê= cΩê=ÇáÉ=pí~êíÄÉäÉÖìåÖ=êÉáÅÜÉå=òïÉá=wìïÉáëìåÖëÄÉÑÉÜäÉ=áå=ÇÉê=bêÉáÖåáëéêçòÉÇìê= òìã=pí~åÇ~êÇJbêÉáÖåáë=Create=Ó=eÉêëíÉääìåÖ=ÇÉë=cçêãìä~êë=~ìëW= procedure TForm1.FormCreate(Sender: TObject); begin Listbox1.ItemIndex:=9; Edit1.Text:='Sachsen-Anhalt' end;
_Éíê~ÅÜíÉå=ïáê=òìÉêëí=ÇáÉ=ÑçäÖÉåÇÉ=^ìÑÖ~ÄÉW=tÉåå=ÇÉê=kìíòÉê=áå=ÇÉê= iáëíÉ=ãáí= ÇÉå= i®åÇÉêå~ãÉå= ÉáåÉ= ^ìëï~Üä= íêáÑÑíI= ëçää= ~ìíçã~íáëÅÜ= ÇáÉëÉê= i®åÇÉêå~ãÉ= áå= ÇÉã=qÉñíÑÉåëíÉê=ÉêëÅÜÉáåÉåK== aÉå= o~ÜãÉå= ÑΩê= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= ÄÉâçããÉå= ïáê= ëçÑçêíI= ÇÉåå= òì= ÄÉÜ~åJ ÇÉäå=áëí=Ç~ë=iáëíÉåJpí~åÇ~êÇJbêÉáÖåáë=EëK=^ÄëÅÜåáíí=PKNFW== procedure TForm1.ListBox1Click(Sender: TObject); begin Edit1.Text:=...???........ end;
aáÉ=äáåâÉ=pÉáíÉI=ÇK=ÜK=ÇáÉ=wáÉäJpÉáíÉ=ÇÉë=_ÉÑÉÜäëI=áëí=î∏ääáÖ=âä~êW=aÉå=k~ãÉå= Text= ÇÉê= é~ëëÉåÇÉå= éêçéÉêíó= òìã= qê~åëéçêí= áå= ÇáÉ= fåÜ~äíëJhçãéçåÉåíÉ= ÇÉë= a~íÉåJ âÉêåë=ÉáåÉë=qÉñíÑÉåëíÉêJlÄàÉâíë=âÉååÉå=ïáê=~ìë=ÇÉã=lÄàÉâíáåëéÉâíçêK== UN =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= ^ÄÉê=ÇáÉ=êÉÅÜíÉ=pÉáíÉ\=açêí=ãìëë=ÇáÉ=_ÉëÅÜêáÑíìåÖ=ÇÉêàÉåáÖÉå=wÉáäÉ=ëíÉÜÉåI=~ìÑ= ÇáÉ=ÇÉê=kìíòÉê=ÖÉê~ÇÉ=ÇáÉ=j~êâáÉêìåÖ=ÖÉëÉíòí=Ü~íK== aáÉ=mçëáíáçå=ÇÉê=~âíìÉääÉå=j~êâáÉêìåÖ=ÑáåÇÉí=ã~å=ãáí=ÇÉê=éêçéÉêíó=ItemIndexK== ^ÄÉê=ïáÉ=ÑáåÇÉí=ã~å=ÇáÉ=_ÉëÅÜêáÑíìåÖ=~å=ÉáåÉê=ÄÉëíáããÉå=mçëáíáçå=ÇÉê=iáëíÉ\== báåÉë= ÇΩêÑíÉ= ãáííäÉêïÉáäÉ= ÄÉâ~ååí= ëÉáåW= báåÉ= wÉáäÉ= áå= ÉáåÉê= iáëíÉ= ÜÉá≈í= Item= ~ìÑ= båÖäáëÅÜK= cçäÖäáÅÜ= íáééÉå= ïáê= å~ÅÜ= Listbox1= ÇÉå= mìåâí= ÉáåI= ï~êíÉå= ÉáåÉ= pÉJ âìåÇÉ=ìåÇ=ëìÅÜÉå=Ç~åå=áå=ÇÉê=mìåâíäáëíÉ=E_áäÇ=QKPQFK=
== _áäÇ=QKPQW=pìÅÜÉ=å~ÅÜ=é~ëëÉåÇÉê=éêçéÉêíó= sÉêëìÅÜÉå= ïáê= ÉëW= qáééÉå= ïáê= Edit1.Text:=Listbox1.Items= ÉáåK=dÉÜí= åáÅÜí= Ó= Éë= ÖáÄí=ÉáåÉ=cÉÜäÉêãÉäÇìåÖK=== cçäÖäáÅÜ= îÉêëìÅÜÉå= ïáê= Éë= ïÉáíÉê= áå= ÇÉê= mìåâíäáëíÉI= íê~ÖÉå= ÜáåíÉê= Items= ÉáåÉå= ïÉáíÉêÉå= mìåâí= ÉáåI= ï~êíÉå= ~ÄÉêã~äëI= ìåÇ= ëìÅÜÉå= Ç~åå= òáÉäÖÉêáÅÜíÉí= áå= ÇÉê= å®ÅÜëíÉå=mìåâíäáëíÉ=E_áäÇ=QKPRFK=
== _áäÇ=QKPRW=pìÅÜÉ=áå=ÇÉê=å®ÅÜëíÉå=mìåâíäáëíÉ= kìå=ëáåÇ=ïáê=~ã=wáÉäW=aáÉ=ÖÉÑìåÇÉåÉ=éêçéÉêíó= Items.Strings=äáÉÑÉêí=ÄòïK=ÄÉå∏J íáÖí=ÉáåÉ=wÉáÅÜÉåÑçäÖÉI=ëçÑÉêå=ëáÉ=áå=ÇÉå=ÉÅâáÖÉå=hä~ããÉêå=ÇáÉ=ÄÉíêÉÑÑÉåÇÉ=mçJ ëáíáçå=ÉêÑ®ÜêíK=pÉÜÉå=ïáê=ìåë=ÇáÉ=ÑÉêíáÖÉ=bêÉáÖåáëéêçòÉÇìê=~åW= procedure TForm1.ListBox1Click(Sender: TObject); begin Edit1.Text:=Listbox1.Items.Strings[Listbox1.ItemIndex] end;
aÉê=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ëçääíÉ=îçå=êÉÅÜíë=å~ÅÜ=äáåâë=ìåÇ=îçå=áååÉå=å~ÅÜ= ~ì≈Éå=ÖÉäÉëÉå=ïÉêÇÉåX=Ç~ë=pÅÜÉã~=áå=_áäÇ=QKPS=Éêâä®êí=Ç~òì=Ç~ë=sçêÖÉÜÉåW==
UO= =
QKT== k~ãÉåëÄÉëÅÜ~ÑÑìåÖ=ÑΩê=é~ëëÉåÇÉ=éêçéÉêíó=
= _áäÇ=QKPSW=pÅÜÉã~=ÇÉê=^êÄÉáí=ÇÉê=bêÉáÖåáëéêçòÉÇìê= • _Éá=kìíòÉêÉáåïáêâìåÖ=~ìÑ=ÇáÉ=iáëíÉ=Üçäí=ëáÅÜ=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìÉêëí=~ìë= ÇÉã= ÉáÖÉåÉå= iáëíÉåJa~íÉåâÉêå= ÇáÉ= mçëáíáçå= ÇÉê= j~êâáÉêìåÖ= ãáí= eáäÑÉ= ÇÉê= éêçéÉêíó=ItemIndexK== • a~å~ÅÜ= Üçäí= ëáÉ= ïÉáíÉê= ~ìë= ÇÉã= ÉáÖÉåÉå= iáëíÉåJa~íÉåâÉêå= ãáí= eáäÑÉ= ÇÉê= áå= ÇÉê= mìåâíäáëíÉ= ÖÉÑìåÇÉåÉå= éêçéÉêíó= Items.String[..]= ÇÉå= fåÜ~äí= EÇáÉ= _ÉJ ëÅÜêáÑíìåÖF=ÇÉê=wÉáäÉ=ÑΩê=ÇáÉëÉ=mçëáíáçåK== • ^åëÅÜäáÉ≈ÉåÇ= ïáêÇ= ãáí= ÇÉê= éêçéÉêíó= Text= áå= ÇÉå= a~íÉåâÉêå= ÇÉë= qÉñíÑÉåëíÉêë= EÑêÉãÇÉë=lÄàÉâíF=íê~åëéçêíáÉêíK== wìê=ïÉáíÉêÉå=§ÄìåÖ=ïçääÉå=ïáê=ìåë=îçêëíÉääÉåI=Ç~ëë=ÇÉê=kìíòÉê=ÇáÉ=dÉäÉÖÉåÜÉáí= ÄÉâçããÉå=ëçääI=áã=qÉñíÑÉåëíÉê=~å=ÇÉã=i®åÇÉêå~ãÉå=Éíï~ë=®åÇÉêå=òì=ÇΩêÑÉåW= jáí=eáäÑÉ=ÉáåÉë=_ìííçåë=ãáí=ÇÉê=^ìÑëÅÜêáÑí=Änderung eintragen=ëçää=Éê=ÇáÉëÉ=ûåÇÉJ êìåÖ=Ç~åå=~ìÅÜ=áå=ÇáÉ=iáëíÉ=ΩÄÉêíê~ÖÉå=â∏ååÉå=E_áäÇ=QKPTFK== aÉê= o~ÜãÉå= ÇÉê= bêÉáÖåáëéêçòÉÇìê= òìã= häáÅâ= ~ìÑ= ÇÉå= _ìííçå= áëí= ëçÑçêí= ÄÉJ ëÅÜ~ÑÑíI=Éë=Ü~åÇÉäí=ëáÅÜ=ìã=Ç~ë=pí~åÇ~êÇJbêÉáÖåáëK=cΩê=ÇÉå= fåÜ~äí=ÇÉê=bêÉáÖåáëJ éêçòÉÇìê=áëí=äÉÇáÖäáÅÜ=Éáå=ÉáåòáÖÉê=wìïÉáëìåÖëÄÉÑÉÜä=òì=éêçÖê~ããáÉêÉåK== oÉÅÜíëI= ~ìÑ= ÇÉê= nìÉääëÉáíÉI= ëíÉÜí= ÄÉá= ÇáÉëÉê= ^ìÑÖ~ÄÉåëíÉääìåÖ= ÇÉê= fåÜ~äí= ÇÉë= qÉñíÑÉåëíÉêëI=ãáí=ÇÉê=éêçéÉêíó=Text=~ìë=ÇÉã=ÉáÖÉåÉå=a~íÉåâÉêå=ÖÉÜçäíK= iáåâë= ~ìÑ= ÇÉê= wáÉäëÉáíÉ= ëíÉÜí= ÇáÉ= éêçéÉêíó= Items.Strings[...]= òìê= sÉê®åÇÉêìåÖ= ÇÉê=_ÉëÅÜêáÑíìåÖX=ëáÉ=îÉêïÉåÇÉí=ÇáÉ=ÇìêÅÜ=ÇáÉ=éêçéÉêíó= ItemIndex=ÖÉäáÉÑÉêíÉ=mçJ ëáíáçå=ÇÉê=j~êâáÉêìåÖK= UP =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= procedure TForm1.Button1Click(Sender: TObject); begin Listbox1.Items.Strings[Listbox1.ItemIndex]:=Edit1.Text end;
_áäÇ= QKPT= òÉáÖí= ÉáåÉ= ã∏ÖäáÅÜÉ= táêâìåÖW= báå= kìíòÉê= ï~ê= ÇÉê= jÉáåìåÖI= Ç~ëë= áã= âäÉáåëíÉå= _ìåÇÉëä~åÇ= ìåÄÉÇáåÖí= ÇáÉ= òïÉáíÉ= pí~Çí= Éêï®Üåí= ïÉêÇÉå= ëçääíÉK= ^äëç= ëÉíòíÉ= Éê= áå= ÇÉê= iáëíÉ= ÇáÉ= j~êâáÉêìåÖ= ~ìÑ= BremenI= ÉêÖ®åòíÉ= áã= qÉñíÑÉåëíÉêI= ìåÇ= ëÅÜáÅâíÉ=ÇÉå=âçêêáÖáÉêíÉå=báåíê~Ö=éÉê=häáÅâ=~ìÑ=ÇÉå=_ìííçå=áå=ÇáÉ=iáëíÉ=òìêΩÅâK==
== _áäÇ=QKPTW=ûåÇÉêìåÖÉå=áå=ÇáÉ=iáëíÉ=ëÅÜêÉáÄÉå=
Vereinfachungen durch verkürzte property Items[...]
4.7.7
aÉäéÜá=Ü~í=ëáÅÜ=áã=i~ìÑÉ=ÇÉê=wÉáí=ÉåíïáÅâÉäíI=Ç~ÄÉá=ïìêÇÉå=ÑΩê=ÇáÉ=_ÉèìÉãäáÅÜJ âÉáí= ÇÉê= mêçÖê~ããáÉêÉê= îÉêëÅÜáÉÇÉåÉ= sÉêÉáåÑ~ÅÜìåÖÉå= òìÖÉä~ëëÉåK= báåÉ= ÉêëíÉ= sÉêÉáåÑ~ÅÜìåÖ=ïçääÉå=ïáê=âÉååÉå=äÉêåÉåK== bë=áëí=Éêä~ìÄíI=~åëíÉääÉ=ÇÉê=~ìëÑΩÜêäáÅÜÉå=wìïÉáëìåÖëÄÉÑÉÜäÉ= Listbox1.Items.Strings[Listbox1.ItemIndex]:=Edit1.Text
ìåÇ== Edit1.Text:=Listbox1.Items.Strings[Listbox1.ItemIndex];
ÇáÉ= ÄÉáÇÉå= sÉêâΩêòìåÖÉå= òì= îÉêïÉåÇÉåI= ÇáÉ= ÇìêÅÜ= tÉÖä~ëëÉå= ÇÉê= råíÉêJéêçJ éÉêíó=Strings=ÉåíëíÉÜÉåW= Listbox1.Items[Listbox1.ItemIndex]:=Edit1.Text
ìåÇ== Edit1.Text:=Listbox1.Items[Listbox1.ItemIndex];
tÉåÇÉå=ïáê=ÇáÉëÉ=îÉêâΩêòíÉ=pÅÜêÉáÄïÉáëÉ=~ìÑ=Éáå=äÉíòíÉë=_ÉáëéáÉä=áå=ÇáÉëÉã=h~J éáíÉä= ~åI= ãáí= ÇÉã= ïáê= ÖäÉáÅÜòÉáíáÖ= ÉáåëíáããÉå= ïçääÉå= ~ìÑ= ÇáÉ= sÉêï~äíìåÖ= îçå= a~íÉåÄÉëí®åÇÉåI=ÇáÉ=áå=iáëíÉå=ÉêÑ~ëëí=ëáåÇK=== = UQ= =
QKT== k~ãÉåëÄÉëÅÜ~ÑÑìåÖ=ÑΩê=é~ëëÉåÇÉ=éêçéÉêíó= == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 4= ÇáÉ= zipJa~íÉá= DKap04.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap04= ÇáÉ= mêçàÉâíJa~íÉá= proj_477.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap04=ÇáÉ=a~íÉá=proj_477.bdsproj=~ìëòìï®ÜäÉåK== == råíÉê= ÇÉå= ÇêÉá= iáëíÉå= ãáí= _ìåÇÉëä®åÇÉêåI= áÜêÉå= e~ìéíëí®ÇíÉå= ìåÇ= ÇÉå= ^ìíçJ âÉååòÉáÅÜÉå=ÇÉê=e~ìéíëí®ÇíÉ=ëçääÉå=ëáÅÜ=òïÉá=_ìííçåë=ãáí=ÇÉå=^ìÑëÅÜêáÑíÉå= Voriger=ìåÇ=Nächster=ÄÉÑáåÇÉåK== wì=_ÉÖáåå=ÇÉê=i~ìÑòÉáí=ëçää=ÇáÉ=wÉáäÉ=îçå= Sachsen-Anhalt=~ìëÖÉï®Üäí=ëÉáåW=a~òì= ëÅÜêÉáÄÉå= ïáê= ïáÉÇÉê= ÇÉå= áåòïáëÅÜÉå= ÄÉâ~ååíÉå= fåÜ~äí= ÇÉê= bêÉáÖåáëéêçòÉÇìê= òìã=pí~åÇ~êÇJbêÉáÖåáë=Create=ÇÉë=cçêãìä~êëK== _Éá= häáÅâ= ~ìÑ= ÉáåÉå= _ìííçå= ëçää= ÇáÉ= j~êâáÉêìåÖ= å~ÅÜ= çÄÉå= ÄòïK= ìåíÉå= áå= ÇÉê= êáÅÜíáÖÉå= tÉáëÉ= ï~åÇÉêåK= aáÉ= _ÉëÅÜêáÑíìåÖÉå= ëçääÉå= òìë®íòäáÅÜ= áå= ÇêÉá= i~ÄÉäë= E_áäÇ=QKPUF=~åÖÉòÉáÖí=ïÉêÇÉåK==
== _áäÇ=QKPUW=sÉêï~äíìåÖ=ÉáåÉë=a~íÉåÄÉëí~åÇÉë= cΩê=ÇêÉá=bêÉáÖåáëéêçòÉÇìêÉå=ãΩëëÉå=ÇáÉ=o~ÜãÉå=ÄÉëÅÜ~ÑÑí=ìåÇ=ÇáÉ=fåÜ~äíÉ=éêçJ Öê~ããáÉêí=ïÉêÇÉåW=cΩê=Ç~ë=bêÉáÖåáë=bêòÉìÖìåÖ=ÇÉë=cçêãìä~êë=ëçïáÉ=ïáÉ=ÑΩê=ÇáÉ= ÄÉáÇÉå=häáÅâJbêÉáÖåáëëÉ=ÇÉê=_ìííçåëK== UR =
Q= bêÉáÖåáëéêçòÉÇìêÉåW=sÉêïÉåÇìåÖ=îçå=éêçéÉêíáÉë= aáÉ= bêÉáÖåáëéêçòÉÇìêÉå= òì= ÇÉå= bêÉáÖåáëëÉå= häáÅâ= ~ìÑ= ÇÉå= _ìííçå= ãáí= ÇÉê= _ÉJ ëÅÜêáÑíìåÖ= Voriger= ëçïáÉ= häáÅâ= ~ìÑ= ÇÉå= _ìííçå= ãáí= ÇÉê= _ÉëÅÜêáÑíìåÖ= Nächster= ìåíÉêëÅÜÉáÇÉå=ëáÅÜ=åìê=áå=ÇÉå=ÇêÉá=ÉêëíÉå=wìïÉáëìåÖëÄÉÑÉÜäÉåK== _Éáã=äáåâÉå=_ìííçå=ïáêÇ=ÇáÉ=mçëáíáçåI=å~ÅÜÇÉã=ëáÉ=ãáííÉäë=ÇÉê=éêçéÉêíó= ItemIndex=~ìë=ÇÉã=a~íÉåâÉêå=ÖÉÜçäí=ïìêÇÉI=ìã=Éáåë=êÉÇìòáÉêí=ìåÇ=òìêΩÅâÖÉëÅÜáÅâíK= a~ÇìêÅÜ=ï~åÇÉêí=ÇáÉ=j~êâáÉêìåÖ=å~ÅÜ=çÄÉåK=== procedure TForm1.Button1Click(Sender: TObject); begin Listbox1.ItemIndex:=Listbox1.ItemIndex-1; Listbox2.ItemIndex:=Listbox2.ItemIndex-1; Listbox3.ItemIndex:=Listbox3.ItemIndex-1; Label1.Caption:=Listbox1.Items[Listbox1.ItemIndex]; Label2.Caption:=Listbox2.Items[Listbox2.ItemIndex]; Label3.Caption:=Listbox3.Items[Listbox3.ItemIndex] end;
_Éáã=êÉÅÜíÉå=_ìííçå=ïáêÇ=ÇáÉ=mçëáíáçåI=å~ÅÜÇÉã=ëáÉ=ãáí=eáäÑÉ=ÇÉê=éêçéÉêíó= ItemIndex= ~ìë= ÇÉã= a~íÉåâÉêå= ÖÉÜçäí= ïìêÇÉI= ìã= Éáåë= ÉêÜ∏Üí= ìåÇ= òìêΩÅâÖÉëÅÜáÅâíK= a~ÇìêÅÜ=ï~åÇÉêí=ÇáÉ=j~êâáÉêìåÖ=å~ÅÜ=ìåíÉåK= procedure TForm1.Button2Click(Sender: TObject); begin Listbox1.ItemIndex:=Listbox1.ItemIndex+1; Listbox2.ItemIndex:=Listbox2.ItemIndex+1; Listbox3.ItemIndex:=Listbox3.ItemIndex+1; Label1.Caption:=Listbox1.Items[Listbox1.ItemIndex]; Label2.Caption:=Listbox2.Items[Listbox2.ItemIndex]; Label3.Caption:=Listbox3.Items[Listbox3.ItemIndex] end;
= =
US= =
==
5
Einfache Tests und Alternativen a~ë= îçêáÖÉ= h~éáíÉä= Äê~ÅÜíÉ= ÇÉå= aìêÅÜÄêìÅÜK= táê= äÉêåíÉå= áå= áÜã= ~ìëÑΩÜêäáÅÜ= âÉååÉåI= ïáÉ= ïáê= áå= fåÜ~äíÉå= îçå= bêÉáÖåáëéêçòÉÇìêÉå= ãáí= eáäÑÉ= îçå= éêçéÉêíáÉë= EbáÖÉåëÅÜ~ÑíÉåF=~ìÑ=ÇÉå=a~íÉåâÉêå=ÇÉë=ÉáÖÉåÉå=îáëìÉääÉå=lÄàÉâíë=çÇÉê=ÑêÉãÇÉê= îáëìÉääÉê=lÄàÉâíÉ=òìÖêÉáÑÉå=ä~ëëÉå=â∏ååÉåK== a~=~ääÉ=jÉêâã~äÉ=ÇÉë=ëáÅÜíÄ~êÉå=qÉáäë=àÉÇÉë=îáëìÉääÉå=lÄàÉâíë=áå=ëÉáåÉã=a~íÉåJ âÉêå=ÖÉëéÉáÅÜÉêí=ëáåÇI=â∏ååÉå=ïáê=~ìÑ=ÇáÉëÉ=tÉáëÉ=ìåãáííÉäÄ~ê=~ìÑ=ÇáÉ=_ÉëÅÜêáÑJ íìåÖ= ÉáåÉë= i~ÄÉäë= çÇÉê= ÇÉå= fåÜ~äí= ÉáåÉë= qÉñíÑÉåëíÉêë= òìÖêÉáÑÉå= ä~ëëÉåI= ~ìÑ= ÇáÉ= _ÉëÅÜêáÑíìåÖ= ÉáåÉë= _ìííçåëI= ~ìÑ= ÇáÉ= mçëáíáçå= ÇÉë= oÉÖäÉêë= áå= ÉáåÉê= pÅêçääÄ~êI= ~ìÑ= _ÉëÅÜêáÑíìåÖÉå= ìåÇ= _ÉäÉÖìåÖëÉáÖÉåëÅÜ~ÑíÉå= îçå= `ÜÉÅâÄçñÉå= ìåÇ= o~ÇáçÄìíJ íçåëI=~ìÑ=ÇáÉ=mçëáíáçå=ÇÉê=j~êâáÉêìåÖ=áå=ÉáåÉê=o~ÇáçÖêìééÉ=ìåÇ=iáëíÉK=pÅÜäáÉ≈J äáÅÜ=áëí=~ìÅÜ=ÇÉê=wìÖêáÑÑ=~ìÑ=ÉáåÉ=wÉáäÉ=áå=ÉáåÉê=iáëíÉ=ã∏ÖäáÅÜK== a~ÄÉá=áëí=ÇáÉ=sçâ~ÄÉä=òìÖêÉáÑÉå=àÉïÉáäë=é~ëëáî=çÇÉê=~âíáî=çÇÉê=~ìÅÜ=áå=ÄÉáÇÉêäÉá= eáåëáÅÜí= ã∏ÖäáÅÜW= táê= â∏ååÉå= éêçÖê~ããáÉêÉåI= Ç~ëë= ÉáåÉ= bêÉáÖåáëéêçòÉÇìê= ãáí= eáäÑÉ= ÉáåÉê= éêçéÉêíó= åìê= Éíï~ë= ÉêÑ®Üêí= ìåÇ= ÖÉÉáÖåÉí= îÉê~êÄÉáíÉíI= ïáê= â∏ååÉå= ~ÄÉê=~ìÅÜ=éêçÖê~ããáÉêÉåI=Ç~ëë=ÉáåÉ=bêÉáÖåáëéêçòÉÇìê=Éíï~ë=ÄÉïáêâí=ìåÇ=Ç~ãáí= ~ã=ÉáÖÉåÉå=çÇÉê=ÑêÉãÇÉå=lÄàÉâí=sÉê®åÇÉêìåÖÉå=îçêåáããíK== táê=â∏ååÉå=ëçÖ~ê=ãáí=ÇÉã=áåíÉêÉëë~åíÉå=wìïÉáëìåÖëÄÉÑÉÜä=~ìë=^ÄëÅÜåáíí=QKQ= ScrollBar1.Position:=ScrollBar1.Position+10
Ç~ÑΩê= ëçêÖÉåI= Ç~ëë= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìÉêëí= ãáí= eáäÑÉ= ÇÉê= éêçéÉêíó= Position= ÇáÉ=píÉääìåÖ=ÇÉë=oÉÖäÉêë=~ìë=ÇÉã=a~íÉåâÉêå=Üçäí=ìåÇ=~åëÅÜäáÉ≈ÉåÇI=îÉêÖê∏≈Éêí= ìã=òÉÜå=báåÜÉáíÉåI=ïáÉÇÉê=éÉê=éêçéÉêíó= Position=ÇáÉ=píÉääìåÖ=ÇÉë=oÉÖäÉêë=åÉì= ÑÉëíäÉÖíK=bêÖÉÄåáëW=aÉê=oÉÖäÉê=ëéêáåÖí=ìã=NM=báåÜÉáíÉå=å~ÅÜ=êÉÅÜíëK= g~I= Ç~ë= ï~ê= ëÅÜçå= mêçÖê~ããáÉêÉåI= ï~ë= Ç~= áã= h~éáíÉä= Q= áå= îáÉäÉå= _ÉáëéáÉäÉå= îçêÖÉÑΩÜêí=ïìêÇÉK=råÇI=ï~ê=Éë=ëç=ëÅÜäáãã\== aêÉá=sçê~ìëëÉíòìåÖÉå=ãΩëëÉå=ÉêÑΩääí=ëÉáåI=Ç~ãáí=ïáê=ìåëÉê=aÉåâîÉêã∏ÖÉå=~åJ ïÉêÑÉå=ìåÇ=fåÜ~äíÉ=îçå=bêÉáÖåáëéêçòÉÇìêÉå=ëÅÜêÉáÄÉå=â∏ååÉåW= • lÜåÉ= ÇáÉ= k~ãÉå= ÇÉê= îáëìÉääÉå= lÄàÉâíÉ= ÖÉÜí= åáÅÜíëK= aÉê= ^ìíçê= ëÅÜä®Öí= Ç~òì= àÉÇÉã=^åÑ®åÖÉê=îçêI=ëíÉíë=ÇáÉ=îçå=aÉäéÜá=~ìíçã~íáëÅÜ=îÉêÖÉÄÉåÉå=k~ãÉå=òì= îÉêïÉåÇÉåK= báåëÅÜäáÉ≈äáÅÜ= ÇÉê= dêç≈J= ìåÇ= häÉáåëÅÜêÉáÄìåÖI= Ç~ë= ã~ÅÜí= Ç~ë= d~åòÉ=òáÉãäáÅÜ=ΩÄÉêëáÅÜíäáÅÜK= • tÉáíÉê=Äê~ìÅÜÉå=ïáê=ÇáÉ=ÖÉå~ìÉå=k~ãÉå=ÇÉê=ÄÉå∏íáÖíÉå=éêçéÉêíáÉëI=ìã=éêçJ Öê~ããáÉêÉå=òì=â∏ååÉåI=ïÉåå=~ìÑ=a~íÉåâÉêåÉ=òìÖÉÖêáÑÑÉå=ïÉêÇÉå=ëçääK==
UT =
R= báåÑ~ÅÜÉ=qÉëíë=ìåÇ=^äíÉêå~íáîÉå= • cΩê= ÇáÉ= ïáÅÜíáÖëíÉå= éêçéÉêíáÉë= ÑáåÇÉå= ïáê= ÇáÉ= k~ãÉå= ΩÄÉê= ÇáÉ= oÉÖáëíÉêâ~êíÉ= bfdbkp`e^cqbk=ÇÉë=lÄàÉâíáåëéÉâíçêëK== • tÉåå= ìåë= ÇÉê= lÄàÉâíáåëéÉâíçê= ~ÄÉê= áã= píáÅÜ= ä®ëëíI= ïÉáä= Éê= áå= ëÉáåÉå= wÉáäÉå= åìê= ïÉåáÖÉI= ~ìëÖÉï®ÜäíÉ= báÖÉåëÅÜ~ÑíÉå= EéêçéÉêíáÉëF= éê®ëÉåíáÉêí= ãΩëëÉå= ïáê= å~ÅÜ=ÇÉã=báåíáééÉå=ÇÉë=mìåâíÉë=ÜáåíÉê=ÇÉã=lÄàÉâíå~ãÉå=~ìÑ=ÇáÉ=mìåâíäáëíÉ= ï~êíÉå= ìåÇ= ìåíÉê= ÇÉå= Ç~åå= ÉêëÅÜÉáåÉåÇÉå= báåíê®ÖÉå= ãáí= ÇÉê= _ÉòÉáÅÜåìåÖ= property=ÖÉòáÉäí=ëìÅÜÉåK== • cΩê= ÇÉå= c~ääI= Ç~ëë= ãáííÉäë= ÉáåÉê= éêçéÉêíó= Éáå= ÄÉëíáããíÉê= tÉêí= çÇÉê= ÉáåÉ= ÑÉëíÉ= _ÉäÉÖìåÖ= áå= ÉáåÉå= a~íÉåâÉêå= ÖÉÄê~ÅÜí= ïÉêÇÉå= ëçääI= ãΩëëÉå= ïáê= ëÅÜäáÉ≈äáÅÜ= åçÅÜ= ïáëëÉåI= ï~ë= ÇáÉ= éêçéÉêíó= îÉê~êÄÉáíÉí= Ó= ÉáåÉ= w~ÜäI= ÉáåÉå= ÇÉê= ÄÉáÇÉå= t~ÜêÜÉáíëïÉêíÉ=True=çÇÉê=FalseI=ÉáåÉå=qÉñíK=táê=ÉêÑ~ÜêÉå=Éë=ÉåíïÉÇÉê=~ìë=ÇÉã= lÄàÉâíáåëéÉâíçê=çÇÉê=äÉëÉå=Éë=ÜáåíÉê=ÇÉã=açééÉäéìåâí=áå=ÇÉê=mìåâíäáëíÉK= t~ë=âçããí=åìå\=kìå=ïçääÉå=ïáê=ìåë=ïÉáíÉê=ãáí=ÇÉê=mêçÖê~ããáÉêìåÖ=îçå=fåJ Ü~äíÉå=îçå=bêÉáÖåáëéêçòÉÇìêÉå=ÄÉëÅÜ®ÑíáÖÉåK== táê=ïÉêÇÉå=ÇÉå=c~ää=ÄÉÜ~åÇÉäåI=Ç~ëë=Éáå=_ÉÑÉÜä=çÇÉê=ÉáåÉ=jÉåÖÉ=îçå=_ÉÑÉÜäÉå= åáÅÜí=áããÉêI=ëçåÇÉêå=åìê=ã~åÅÜã~ä=~ìëÖÉÑΩÜêí=ïÉêÇÉå=ëçääK=táÉ=ÄáëÜÉêI=ïÉêJ ÇÉå=ïáê=ìåë=ÇÉê=p~ÅÜÉ=ãáí=îáÉäÉå=_ÉáëéáÉäÉå=å®ÜÉêåK==
5.1
Einfacher Test
5.1.1
Bedingtes Aktivieren/Deaktivieren von Buttons
táê=ïçääÉå=ÖäÉáÅÜ=Ç~ë=äÉíòíÉ=_ÉáëéáÉä=ÇÉë=îçêáÖÉå=h~éáíÉäë=ÑçêíëÉíòÉå=E_áäÇ=RKNFW= få=ÉáåÉã=îáëìÉääÉå=lÄàÉâí=iáëíÉ=ãáí=ÇÉã=k~ãÉå= ListBox1=áëí=Éáå=a~íÉåÄÉëí~åÇ= ÖÉëéÉáÅÜÉêí=Ó=ÄÉá=ìåë=ëáåÇ=Éë=ïáÉÇÉê=ÇáÉ=k~ãÉå=ÇÉê=_ìåÇÉëä®åÇÉêK== aáÉ= Listbox1= ïáêÇ= ëé®íÉê= ìåëáÅÜíÄ~ê= ÖÉã~ÅÜí= E~ÄÉê= ÉêëíI= ïÉåå= ~ääÉë= ÑìåâíáçJ åáÉêíFK= bë= áëí= å®ãäáÅÜ= ÖêìåÇë®íòäáÅÜ= åáÅÜí= ΩÄäáÅÜI= a~íÉåÄÉëí®åÇÉ= ∏ÑÑÉåíäáÅÜ= òì= éê®ëÉåíáÉêÉåK= == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 5= ÇáÉ= zipJa~íÉá= DKap05.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap05= ÇáÉ= mêçàÉâíJa~íÉá= proj_511.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap05=ÇáÉ=a~íÉá=proj_511.bdsproj=~ìëòìï®ÜäÉåK== == aáÉ= pí~êíÉáåëíÉääìåÖ= Sachsen-AnhaltI= ïáêÇ= ΩÄÉê= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= pí~åJ Ç~êÇJbêÉáÖåáë= Create Ó= eÉêëíÉääìåÖ= ÇÉë= cçêãìä~êë= îÉê~åä~ëëíK= wìê= sÉêï~äíìåÖ= ÇÉë= a~íÉåÄÉëí~åÇÉë= ëçää= Éë= îáÉê= _ìííçåë= ÖÉÄÉåI= ÇÉêÉå= _ÉÇÉìíìåÖ= ~ìë= ÇÉå= _ÉJ ëÅÜêáÑíìåÖÉå=ÜÉêîçêÖÉÜíK=pÉÜÉå=ïáê=ìåë=~åI=ï~ë=ÑΩê=ÇáÉ=fåÜ~äíÉ=ÇÉê=îáÉê=bêÉáÖJ åáëéêçòÉÇìêÉå=òìã=_ìííçåJhäáÅâ=àÉïÉáäë=òì=éêçÖê~ããáÉêÉå=áëíW= UU= =
RKN== báåÑ~ÅÜÉê=qÉëí= häáÅâ=~ìÑ=ÇÉå=_ìííçå=łbêëíÉêW= Listbox1.ItemIndex:=0;Label1.Caption:=Listbox1.Items[0]
häáÅâ=~ìÑ=ÇÉå=_ìííçå=łsçêáÖÉêW= Listbox1.ItemIndex:=Listbox1.ItemIndex-1; Label1.Caption:=Listbox1.Items[Listbox1.ItemIndex]
häáÅâ=~ìÑ=ÇÉå=_ìííçå=łk®ÅÜëíÉêW= Listbox1.ItemIndex:=Listbox1.ItemIndex+1; Label1.Caption:=Listbox1.Items[Listbox1.ItemIndex]
häáÅâ=~ìÑ=ÇÉå=_ìííçå=łiÉíòíÉêW= Listbox1.ItemIndex:=15;Label1.Caption:=Listbox1.Items[15]
== _áäÇ=RKNW=sÉêï~äíìåÖ=ÉáåÉë=a~íÉåÄÉëí~åÇÉë= tç=äáÉÖí=Ç~ë=mêçÄäÉã\=t®Üäí=ÇÉê=kìíòÉê=ÇìêÅÜ=häáÅâ=~ìÑ= Erster=ÇÉå=ÉêëíÉå=báåJ íê~Ö= áã= a~íÉåÄÉëí~åÇ= ~ìë= ìåÇ= âäáÅâí= Ç~å~ÅÜI= ìåâçåòÉåíêáÉêíI= ~ìÑ= ÇÉå= _ìííçå= Voriger=ÖáÄí=Éë=ÉáåÉ=ÖÉÜ~êåáëÅÜíÉ=cÉÜäÉêãÉäÇìåÖK=hä~êK=
== _áäÇ=RKOW=aÉ~âíáîáÉêÉå=ÇÉê=äáåâÉå=_ìííçåë= UV =
R= báåÑ~ÅÜÉ=qÉëíë=ìåÇ=^äíÉêå~íáîÉå= cçäÖäáÅÜ= ãΩëëÉå= ïáê= îÉêÜáåÇÉêåI= Ç~ëë= Éáå= kìíòÉêI= ïÉåå= ÇÉê= ÉêëíÉ= báåíê~Ö= ÇÉë= a~íÉåÄÉëí~åÇë= ÉêêÉáÅÜí= ïáêÇI= ÇáÉ= ÄÉáÇÉå= äáåâÉå= _ìííçåë= åçÅÜ= Éáåã~ä= ÇêΩÅâÉå= Ç~êÑK= táÉ= Ç~ë= ÖÉÜí\= kìåI= ïáê= ëÉíòÉå= ÉáåÑ~ÅÜ= ÇáÉ= éêçéÉêíó= Enabled= ÇÉê= ÄÉáÇÉå= äáåâÉå= _ìííçåë=~ìÑ=False=ìåÇ=ëÅÜ~äíÉå=Ç~ãáí=ÇáÉ=ÄÉáÇÉå=_ìííçåë=~ìëK== açÅÜ= ÑΩê= ÇÉå= c~ääI= Ç~ëë= îçêÜÉê= ÇÉê= äÉíòíÉ= báåíê~Ö= ÇÉë= a~íÉåÄÉëí~åÇÉë= ~ìëÖÉJ ï®Üäí= ïçêÇÉå= ï~ê= ìåÇ= Ç~ãáí= ÇáÉ= êÉÅÜíÉå= ÄÉáÇÉå= _ìííçåë= áå~âíáî= ï~êÉåI= ãΩëJ ëÉå=ïáê=ëáÉ=ïáÉÇÉê=~âíáîáÉêÉåI=ÇÉåå=ëáÉ=ëáåÇ=ëáååîçääK== dÉå~ìëç= áëí= îçêòìÖÉÜÉåI= ïÉåå= ÇÉê= äÉíòíÉ= báåíê~Ö= áã= a~íÉåÄÉëí~åÇ= ÉêêÉáÅÜí= ïáêÇK=a~åå=ãΩëëÉå=ÇáÉ=ÄÉáÇÉå=êÉÅÜíÉå=_ìííçåë=ÇÉ~âíáîáÉêí=ïÉêÇÉåW= procedure TForm1.Button1Click(Sender: TObject); begin Listbox1.ItemIndex:=0;Label1.Caption:=Listbox1.Items[0]; Button1.Enabled:=False; Button2.Enabled:=False; Button3.Enabled:=True; Button4.Enabled:=True end; procedure TForm1.Button4Click(Sender: TObject); begin Listbox1.ItemIndex:=15;Label1.Caption:=Listbox1.Items[15]; Button1.Enabled:=True; Button2.Enabled:=True; Button3.Enabled:=False; Button4.Enabled:=False end;
kìå=òìã=_ìííçå=ãáí=ÇÉê=^ìÑëÅÜêáÑí= VorigerK=tÉåå=ÇÉê=kìíòÉê=áÜå=ÇêΩÅâí=áëí=ÉáJ åÉë= âä~êW= aáÉ= ÄÉáÇÉå= êÉÅÜíÉå= _ìííçåë= ëáåÇ= áããÉê= ëáååîçääI= ãΩëëÉå= ~âíáî= ëÉáåK= ^ÄÉê=ÇáÉ=ÄÉáÇÉå=äáåâÉå=_ìííçåë\= kìå=ãΩëëÉå=ïáê=Éíï~ë=kÉìÉë=éêçÖê~ããáÉêÉåI=ÉáåÉå=ÉáåÑ~ÅÜÉå=qÉëíW=kìê=Ç~ååI= ïÉåå=ÇáÉ=çÄÉêëíÉ=wÉáäÉ=ÇáÉ=j~êâáÉêìåÖ=ÄÉâçããÉå=Ü~í=EïÉåå=ÇáÉ=éêçéÉêíó= ItemIndex=ÇáÉ=kìää=äáÉÑÉêíFI=ëáåÇ=ÇáÉ=ÄÉáÇÉå=äáåâÉå=_ìííçåë=òì=ÇÉ~âíáîáÉêÉåK== táÉ=ëÅÜêÉáÄí=ã~å=Ç~ë=ÖÉã®≈=ÇÉå=m~ëÅ~äJoÉÖÉäå\== if Listbox1.ItemIndex=0 then begin Button1.Enabled:=False; Button2.Enabled:=False end
få= ÖäÉáÅÜÉê= tÉáëÉ= ãΩëëÉå= ïáê= îçêÖÉÜÉåI= ïÉåå= ïáê= Ç~ë= bêÉáÖåáë= häáÅâ= ~ìÑ= ÇÉå= _ìííçå=ãáí=ÇÉê=^ìÑëÅÜêáÑí=Nächster=ÄÉÜ~åÇÉäåW== VM= =
RKN== báåÑ~ÅÜÉê=qÉëí= if Listbox1.ItemIndex=15 then begin Button3.Enabled:=False; Button4.Enabled:=False end
pÉÜÉå=ïáê=ìåë=òìã=pÅÜäìëë=ÇáÉ=ÄÉáÇÉå=bêÉáÖåáëéêçòÉÇìêÉå=âçãéäÉíí=~åI=ïçÄÉá= àÉíòí=ä~åÖë~ã=âä~ê=ïáêÇI=ïáÉ=ïáÅÜíáÖ=ÉáåÉ=ÖìíÉ=ìåÇ=ëíêìâíìêáÉêíÉ=pÅÜêÉáÄïÉáëÉ=ÑΩê= Ç~ë=sÉêëí®åÇåáë=îçå=bêÉáÖåáëéêçòÉÇìêÉå=áëíK= procedure TForm1.Button2Click(Sender: TObject); //Button „Voriger“ begin Button3.Enabled:=True; Button4.Enabled:=True; Listbox1.ItemIndex:=Listbox1.ItemIndex-1; Label1.Caption:=Listbox1.Items[Listbox1.ItemIndex]; if Listbox1.ItemIndex=0 then begin Button1.Enabled:=False; Button2.Enabled:=False end end; procedure TForm1.Button3Click(Sender: TObject); //Button „Nächster“ begin Button1.Enabled:=True; Button2.Enabled:=True; Listbox1.ItemIndex:=Listbox1.ItemIndex+1; Label1.Caption:=Listbox1.Items[Listbox1.ItemIndex]; if Listbox1.ItemIndex=15 then begin Button3.Enabled:=False; Button4.Enabled:=False end end;
wìë~íòÑê~ÖÉW=_Éá=ëÉÅÜòÉÜå=_ìåÇÉëä®åÇÉêå=Ü~í=ÇáÉ=äÉíòíÉ=wÉáäÉ=ÇÉê=iáëíÉ=ÇáÉ= mçJ ëáíáçå=NRK=a~ë=áëí=ëáÅÜÉêI=Ç~ë=áëí=ÄÉâ~ååíK=^ÄÉê=ï~ë=ã~ÅÜÉå=ïáêI=ïÉåå=ïáê=åáÅÜí= ÖÉå~ì= ïáëëÉåI= ïáÉ= îáÉäÉ= báåíê®ÖÉ= ëáÅÜ= ΩÄÉêÜ~ìéí= áã= a~íÉåÄÉëí~åÇ= ÄÉÑáåÇÉå\= h~åå=ìåë=ÇáÉ=iáëíÄçñ=åáÅÜí=ëÉäÄÉê=ãáííÉäë=ÉáåÉê=é~ëëÉåÇÉå= éêçéÉêíó=ë~ÖÉåI=ïáÉ= îáÉäÉ=wÉáäÉå=ëáÉ=ÄÉëáíòí\== _ÉêÉáíë= ÇáÉ= pìÅÜÉ= áã= ÉêëíÉå= mìåâíJjÉåΩ= ÑΩÜêí= òìã= bêÑçäÖK= açêí= ïÉêÇÉå= ïáê= ÑΩåÇáÖ=E_áäÇ=RKPFK=
= _áäÇ=RKPW=éêçéÉêíó=Count= VN =
R= báåÑ~ÅÜÉ=qÉëíë=ìåÇ=^äíÉêå~íáîÉå= fã=qÉñí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=òìã=häáÅâ=~ìÑ=ÇÉå=_ìííçå= Letzter=â~åå=ÇáÉ=îçêJ Üáå=ÑÉëí=ÉáåéêçÖê~ããáÉêíÉ=w~Üä=NR=ÉêëÉíòí=ïÉêÇÉå=ÇìêÅÜ= ^åò~Üä=~ääÉê=báåíê®ÖÉ= ãáåìë=NW= procedure TForm1.Button4Click(Sender: TObject);
//Button „Letzter“
begin Listbox1.ItemIndex:=Listbox1.Count-1; Label1.Caption:=Listbox1.Items[Listbox1.Count-1]; Button3.Enabled:=False; Button4.Enabled:=False; Button1.Enabled:=True; Button2.Enabled:=True end;
få= ÇÉê= bêÉáÖåáëéêçòÉÇìê= òìã= häáÅâ= ~ìÑ= ÇÉå= _ìííçå= Nächster= Äê~ìÅÜí= ~åëÅÜäáÉJ ≈ÉåÇ=åìê=Éáåã~ä=ÇáÉ=w~Üä=15=ÇìêÅÜ=Listbox1.Count-1=ÉêëÉíòí=òì=ïÉêÇÉåK== a~ãáí=â∏ååÉå=ïáê=bêÉáÖåáëéêçòÉÇìêÉå=éêçÖê~ããáÉêÉåI=ÇáÉ=~ìÅÜ=ÄÉá= 13=çÇÉê= 17= çÇÉê=100=çÇÉê=10000=báåíê®ÖÉå=ÇÉå=a~íÉåÄÉëí~åÇ=ëíÉíë=âçêêÉâí=îÉêï~äíÉåK==
5.1.2 ==
Einklick oder Ausklick?
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 5= ÇáÉ= zipJa~íÉá= DKap05.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap05= ÇáÉ= mêçàÉâíJa~íÉá= proj_512.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap05=ÇáÉ=a~íÉá=proj_512.bdsproj=~ìëòìï®ÜäÉåK== == tÉåå=Éáå=kìíòÉê=ÉáåÉ=`ÜÉÅâÄçñ=~åâäáÅâíI=â~åå=ÇáÉëÉê=häáÅâ=ÉåíïÉÇÉê=Éáå=báåJ âäáÅâ= çÇÉê= Éáå= ^ìëâäáÅâ= ëÉáå= E_áäÇ= RKQFI= àÉ= å~ÅÜÇÉãI= çÄ= ÇÉê= e~âÉå= ÇìêÅÜ= ÇáÉ= kìíòÉêÉáåïáêâìåÖ=ÖÉëÉíòí=çÇÉê=ÄÉëÉáíáÖí=ïìêÇÉK== táÉ= ëáÉÜí= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= bêÉáÖåáë= häáÅâ= ~ìÑ= ÇáÉ= `ÜÉÅâÄçñ= ~ìëI= ÇáÉ= ìåë=ÇáÉëÉ=ÇáÑÑÉêÉåòáÉêíÉ=fåÑçêã~íáçå=äáÉÑÉêí\==
= _áäÇ=RKQW=báåâäáÅâ=çÇÉê=^ìëâäáÅâ== VO= =
RKN== báåÑ~ÅÜÉê=qÉëí= aÉå= o~ÜãÉå= ÉêÜ~äíÉå= ïáê= Ö~åò= ÉáåÑ~ÅÜI= ëÅÜäáÉ≈äáÅÜ= ÄÉÜ~åÇÉäå= ïáê= Ç~ë= pí~åJ Ç~êÇJbêÉáÖåáë=EëK=^ÄëÅÜåáíí=OKOKPFK=cΩê=ÇÉå=fåÜ~äí=åìíòÉå=ïáê=ìåëÉêÉ=ÖÉê~ÇÉ=ÉêJ ïçêÄÉåÉå=hÉååíåáëëÉI=áåÇÉã=ïáê=òïÉá=ÉáåÑ~ÅÜÉ=qÉëíë=éêçÖê~ããáÉêÉåK= procedure TForm1.CheckBox1Click(Sender: TObject); begin if Checkbox1.Checked=True then begin ShowMessage('Einklick') end; // Semikolon nötig, es folgt noch ein Test if Checkbox1.Checked=False then begin ShowMessage('Ausklick') end; end;
fã= hçããÉåí~ê= áëí= ëÅÜçå= ~ìÑ= ÇáÉ= kçíïÉåÇáÖâÉáí= ÇÉë= pÉãáâçäçåë= ÜáåÖÉïáÉëÉå= ïçêÇÉåX=~å=ÇáÉëÉê=píÉääÉ=ïáêÇ=Éë=~äë=qêÉååòÉáÅÜÉå=ìåÄÉÇáåÖí=ÖÉÄê~ìÅÜí>== iÉêåÉå=ïáê=åçÅÜ=ÉáåÉ=m~ëÅ~äJ^ìëå~ÜãÉêÉÖÉä=âÉååÉåW== • fëí=ÄÉá=ÉêÑΩääíÉã=qÉëí=åìê=Éáå=ÉáåòáÖÉê=_ÉÑÉÜä=~ìëòìÑΩÜêÉå=â∏ååÉå=ÇáÉ=^åïÉáJ ëìåÖëâä~ããÉêå=begin=ìåÇ=end=ÉåíÑ~ääÉåK= aáÉëÉ= ^ìëå~ÜãÉêÉÖÉä= áëí= ÄÉá= ìåë= ~åïÉåÇÄ~ê= ìåÇ= êÉÇìòáÉêí= ìåëÉêÉå= pÅÜêÉáÄJ ~ìÑï~åÇ=ÉêÜÉÄäáÅÜW= procedure TForm1.CheckBox1Click(Sender: TObject); begin if Checkbox1.Checked=True then ShowMessage('Einklick'); if Checkbox1.Checked=False then ShowMessage('Ausklick') end;
aáÉëÉ=^ìëå~ÜãÉêÉÖÉä=áëí=~ÄÉê=ëÉÜêI=ëÉÜê=ÖÉÑ®ÜêäáÅÜK=táêÇ=òìã=_ÉáëéáÉä=áå== if Listbox1.ItemIndex=0 then begin Button1.Enabled:=False; Button2.Enabled:=False end
Ç~ë= m~~ê= ÇÉê= ^åïÉáëìåÖëâä~ããÉêå= beginKKKend= ïÉÖÖÉä~ëëÉå= ÖÉÜ∏êí= åìê= åçÅÜ= ÇÉê= ÉêëíÉ= _ÉÑÉÜä= Button1.Enabled:=False= òìã= qÉëíI= Éê= ïáêÇ= åáÅÜí= áããÉêI= ëçåJ ÇÉêå=åìê=ã~åÅÜã~ä=~ìëÖÉÑΩÜêíK=aÉê=_ÉÑÉÜä= Button2.Enabled:=False=ïΩêÇÉ=Ç~J ÖÉÖÉå=~åëÅÜäáÉ≈ÉåÇ=áããÉê=~ìëÖÉÑΩÜêíK=aáÉ=í~íë®ÅÜäáÅÜÉ=táêâìåÖ=ë®ÜÉ=Ç~åå=ëç= ~ìëW= if Listbox1.ItemIndex=0 then Button1.Enabled:=False; Button2.Enabled:=False
VP =
R= báåÑ~ÅÜÉ=qÉëíë=ìåÇ=^äíÉêå~íáîÉå=
5.1.3 ==
Links-Rechts-Steuerung
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 5= ÇáÉ= zipJa~íÉá= DKap05.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap05= ÇáÉ= mêçàÉâíJa~íÉá= proj_513.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap05=ÇáÉ=a~íÉá=proj_513.bdsproj=~ìëòìï®ÜäÉåK== == báå= píÉìÉêÉäÉãÉåí= dêìééÉ= EGroupBoxFI= Ç~ê~ìÑ= äáåâë= Éáå= o~ÇáçÄìííçå= ãáí= ÇÉê= _ÉJ ëÅÜêáÑíìåÖ= nach linksI= áå= ÇÉê= jáííÉ= ÉáåÉ= pÅêçääÄ~ê= ìåÇ= êÉÅÜíë= Éáå= òïÉáíÉê= o~ÇáçJ Äìííçå=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ= nach rechts=E_áäÇ=RKRFK=pí~êíÉáåëíÉääìåÖ=ÇÉë=oÉÖäÉêë=áå= ÇÉê=jáííÉI=jáåáãìã=kìääI=j~ñáãìã=NMMK=^åÑ~åÖë=ëçää=ÇÉê=äáåâÉ=o~ÇáçÄìííçå=~ìëJ ÖÉï®Üäí=ëÉáåK=^ää=ÇáÉë=ä®ëëí=ëáÅÜ=ãáí=ÇÉã=lÄàÉâíáåëéÉâíçê=îçêÄÉêÉáíÉåK=
= _áäÇ=RKRW=dêìééÉ=ãáí=o~ÇáçÄìííçåëI=pÅêçääÄ~ê=ìåÇ=_ìííçå= wìë®íòäáÅÜ=ëçää=ÇÉê=_ìííçå=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ= Bewegung!=ÉñáëíáÉêÉåX=ïáêÇ=Éê=ÖÉJ âäáÅâíI=ëçää=ëáÅÜ=ÇÉê=oÉÖäÉê=òÉÜå=báåÜÉáíÉå=å~ÅÜ=äáåâë=çÇÉê=å~ÅÜ=êÉÅÜíë=ÄÉïÉÖÉå= Ó=àÉ=å~ÅÜ=t~ÜäK=wìÉêëí=ÇáÉ=i~åÖÑçêã=ÇÉê=bêÉáÖåáëéêçòÉÇìêW= procedure TForm1.Button1Click(Sender: TObject); begin if RadioButton1.Checked=True then begin Scrollbar1.Position:=ScrollBar1.Position-10 end; if RadioButton2.Checked=True then begin Scrollbar1.Position:=ScrollBar1.Position+10 end end;
dÉÑ®ÜêäáÅÜI=~ÄÉê=ÜáÉê=~ìÅÜ=ã∏ÖäáÅÜI=áëí=Ç~ë=tÉÖä~ëëÉå=ÇÉê=^åïÉáëìåÖëâä~ããÉêåW= procedure TForm1.Button1Click(Sender: TObject); begin if RadioButton1.Checked=True then Scrollbar1.Position:=ScrollBar1.Position-10; if RadioButton2.Checked=True then Scrollbar1.Position:=ScrollBar1.Position+10 end;
VQ= =
RKN== báåÑ~ÅÜÉê=qÉëí= ^ääÉë= ÑìåâíáçåáÉêíI= Éë= ÖáÄí= ~ìÅÜ= ΩÄÉêê~ëÅÜÉåÇ= âÉáåÉ= cÉÜäÉêãÉäÇìåÖI= ïÉåå= ÇÉê= oÉÖäÉê=êÉÅÜíë=çÇÉê=äáåâë=ł~åëí∏≈íK== açÅÜ= ï~êìã= ëçêÖÉå= ïáê= åáÅÜí= ëÉäÄëí= Ç~ÑΩêI= Ç~ëë= ÇáÉ= _ÉïÉÖìåÖëêáÅÜíìåÖ= ëáÅÜ= Ç~åå= ëÉäÄëí= ìãâÉÜêí\= a~ë= áëí= å®ãäáÅÜ= òáÉãäáÅÜ= ÉáåÑ~ÅÜI= ïáê= Äê~ìÅÜÉå= åìê= ÇÉå= fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=~ã=^åÑ~åÖ=ÇìêÅÜ=ÇáÉ=ÄÉáÇÉå=wÉáäÉå== if Scrollbar1.Position=100 then RadioButton1.Checked:=True; if Scrollbar1.Position=0
then RadioButton2.Checked:=True;
òì=ÉêÖ®åòÉåK=kìå=ã~ÅÜí=Éë=ëÅÜçå=êáÅÜíáÖ=pé~≈I=ãáí=ÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=òì= ëéáÉäÉåK=táê=ïÉêÇÉå=Ä~äÇ=ëé®íÉê=E^ÄëÅÜåáíí=SKSF=ëçÖ~ê=ÇáÉ=hçäÄÉåÄÉïÉÖìåÖ=áå= ÉáåÉã=sáÉêòóäáåÇÉêJjçíçê=ëáãìäáÉêÉå=â∏ååÉåK==
5.1.4 ==
Tasten wegfangen
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 5= ÇáÉ= zipJa~íÉá= DKap05.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap05= ÇáÉ= mêçàÉâíJa~íÉá= proj_514.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap05=ÇáÉ=a~íÉá=proj_514.bdsproj=~ìëòìï®ÜäÉåK== == bë= áëí= ïáÅÜíáÖK= pÉÜê= ïáÅÜíáÖK= få= ÇáÉëÉë= qÉñíÑÉåëíÉê= Ç~êÑ= ÇÉê= kìíòÉê= åìê= wáÑÑÉêå= ÉáåíáééÉåK= pçåëí= ÄêáÅÜí= Éáå= mêçÖê~ãã= òìë~ããÉåI= çÇÉê= ÇáÉ= tÉäí= ÉêëíáêÄí= çÇÉê= Ç~ë=råáîÉêëìã=áãéäçÇáÉêíK== = _áäÇ=RKSW=sÉêÖÉÄäáÅÜÉ=^ìÑÑçêÇÉêìåÖ= kìå=ÖìíI=ëç=ëÅÜäáãã=ïáêÇÛë=ëÅÜçå=åáÅÜí=ïÉêÇÉåI=çÄïçÜä=Éë=ëÅÜçå=mêçÖê~ããJ ÑÉÜäÉê=ÖÉÖÉÄÉå=Ü~íI=ÇáÉ=jáääá~êÇÉå=âçëíÉíÉåK== t~ë=ãÉáåÉå=páÉ=~ÄÉêI=äáÉÄÉ=iÉëÉêáåI=äáÉÄÉê=iÉëÉêW=táêÇ=ìåë=ÇáÉëÉ=åÉíí=ÖÉëÅÜêáÉJ ÄÉåÉ=^ìÑÑçêÇÉêìåÖ=Ç~îçê=ÄÉï~ÜêÉåI=Ç~ëë=Éáå=ìåâçåòÉåíêáÉêíÉê=kìíòÉê=ëáÅÜ=îÉêJ íáééí= çÇÉê= Éáå= ~åÇÉêÉê= kìíòÉê= îÉêëìÅÜíI= ÇçÅÜ= Éáå= u= çÇÉê= Éáå= jáåìë= çÇÉê= Éáå= mêçòÉåíòÉáÅÜÉå=ÉáåòìÖÉÄÉå\== páÉ=Ü~ÄÉå=oÉÅÜíW=kìíòÉê=ëáåÇ=ìåÄÉêÉÅÜÉåÄ~êK=táê=ãΩëëÉå=~ÄëáÅÜÉêåI=Ç~ëë=ìåÉêJ ä~ìÄíÉ=kìíòÉêÉáåÖ~ÄÉå=îÉêãáÉÇÉå=ïÉêÇÉåK=táêI=ÇáÉ=mêçÖê~ããáÉêÉêK=a~ÑΩê=ÖáÄí= Éë=ÖêìåÇë®íòäáÅÜ=òïÉá=jÉíÜçÇÉåW== • táê= ä~ëëÉå= ÇÉå= kìíòÉê= ÉáåÖÉÄÉåI= ï~ë= Éê= ïáää= ìåÇ= ~å~äóëáÉêÉå= ~åëÅÜäáÉ≈ÉåÇ= ëÉáåÉ=báåÖ~ÄÉK=tÉåå=ëáÉ=ìåâçêêÉâí=áëí=ïáêÇ=Éê=Ç~êΩÄÉê=áåÑçêãáÉêí=ìåÇ=~ìÑÖÉJ ÑçêÇÉêíI=ëÉáåÉ=báåÖ~ÄÉ=òì=ïáÉÇÉêÜçäÉåK==
VR =
R= báåÑ~ÅÜÉ=qÉëíë=ìåÇ=^äíÉêå~íáîÉå= • tÉåå= Éê= Ç~åå= ïáÉÇÉê= ìåâçåòÉåíêáÉêí= ~êÄÉáíÉíI= ÑáåÇÉí= Ç~ëëÉäÄÉ= åçÅÜ= Éáåã~ä= ëí~íí=ìåÇ=ëç=ïÉáíÉê==Ó=ëçä~åÖÉI=Äáë=Éê=ÉåÇäáÅÜ=ï~ÅÜ=ïáêÇK=lÇÉêI=ã~å=âÉååí=Ç~ë= îçå=ÇÉå=dÉäÇ~ìíçã~íÉåI=ã~å=ä®ëëí=åìê=ïáÉÇÉêÜçäÉåI=Äáë=ÉáåÉ=Éêä~ìÄíÉ=^åò~Üä= îçå=sÉêëìÅÜÉå=ÉêëÅÜ∏éÑí=áëíK=aêÉáã~ä=ÇáÉ=Ñ~äëÅÜÉ=mfkI=ìåÇ=ÇáÉ=h~êíÉ=áëí=ïÉÖK== a~ë= áëí= s~êá~åíÉ= Éáåë= ÇÉê= mêçÄäÉãä∏ëìåÖX= ïáê= ïÉêÇÉå= ëáÉ= áã= ^ÄëÅÜåáíí= NOKQKQ= âÉååÉå=äÉêåÉåK== açÅÜ=åìå=ÇáÉ=òïÉáíÉ=jÉíÜçÇÉW= • tÉåå= ÇÉê= kìíòÉê= ÉáåÉ= q~ëíÉ= ÇêΩÅâíI= ~å~äóëáÉêÉå= ïáê= áå= ÉáåÉê= é~ëëÉåÇÉå= bêJ ÉáÖåáëéêçòÉÇìêI= çÄ= ÇáÉëÉê= q~ëíÉåÇêìÅâ= ΩÄÉêÜ~ìéí= Éêä~ìÄí= áëíK= tÉåå= åáÅÜíI= ~ååìääáÉêÉå=ïáê=ÇÉå=q~ëíÉåÇêìÅâK== aáÉëÉ= òïÉáíÉ= jÉíÜçÇÉ= ïÉêÇÉå= ïáê= àÉíòí= ìãëÉíòÉåK= a~ÑΩê= Äê~ìÅÜÉå= ïáê= òìÉêëí= ÇÉå= o~ÜãÉå= ÇÉê= bêÉáÖåáëéêçòÉÇìê= ÑΩê= Ç~ë= bêÉáÖåáë= q~ëíÉåÇêìÅâ= ~ã= îáëìÉääÉå= lÄàÉâí=qÉñíÑÉåëíÉê=Edit1K= bë= Ü~åÇÉäí= ëáÅÜ= åáÅÜí= ìã= Ç~ë= pí~åÇ~êÇJbêÉáÖåáëI= ÑçäÖäáÅÜ= ÄÉëÅÜ~ÑÑÉå= ïáê= ìåë= ÇÉå= o~ÜãÉå= ÇÉê= bêÉáÖåáëéêçòÉÇìê= EëK= ^ÄëÅÜåáíí= OKPKOF= ãáí= eáäÑÉ= ÇÉë= oÉÖáëíÉêJ Ää~ííÉë=bobfdkfppb=ÇÉë=lÄàÉâíáåëéÉâíçêë=ÇÉë=qÉñíÑÉåëíÉêë=E_áäÇ= RKTF=ÇìêÅÜ=açéJ éÉäâäáÅâ=áå=Ç~ë=cÉäÇ=êÉÅÜíë=åÉÄÉå=OnKeyPressK==
== _áäÇ=RKTW=_ÉëÅÜ~ÑÑìåÖ=ÇÉë=o~ÜãÉåë=ÇÉê=bêÉáÖåáëéêçòÉÇìê= kìå= áëí= ~ääÉë= êÉÅÜí= ÉáåÑ~ÅÜW= aÉê= o~ÜãÉå= ÇáÉëÉê= bêÉáÖåáëéêçòÉÇìê= ëçêÖí= ÄÉêÉáíë= Ç~ÑΩêI=Ç~ëë=ìåë=ìåíÉê=ÇÉê=_ÉòÉáÅÜåìåÖ= Key=Ç~ëàÉåáÖÉ=wÉáÅÜÉå=ΩÄÉêÖÉÄÉå=ïáêÇI= Ç~ë=ÇÉê=kìíòÉê=ÖÉê~ÇÉ=~ìÑ=ÇÉê=q~ëí~íìê=ÖÉÇêΩÅâí=Ü~íK== i~ëëÉå=ïáê=íÉëíÉåI=çÄ=ÇáÉ=ÖÉÇêΩÅâíÉ=q~ëíÉ=Ñ~äëÅÜ=áëíK=páÉ=áëí=Ñ~äëÅÜI=ïÉåå=Ç~ë=wÉáJ ÅÜÉå=~ìÑ=ÇÉê=q~ëíÉ=äáåâë=îçã=łwÉáÅÜÉå=kìää=çÇÉê=êÉÅÜíë=îçã=łwÉáÅÜÉå=kÉìå= ëíÉÜí=EÑΩê=báåòÉäÜÉáíÉå=ëáÉÜÉ=^ÄëÅÜåáíí=NMKOFW== if (Key < '0') or (Key > '9') then ShowMessage(‘Taste falsch!‘)
qÉëíÉå=ïáê=ìåÇ=ÖÉåáÉ≈Éå=ÇÉå=qÉáäÉêÑçäÖW=bë=ïÉêÇÉå=í~íë®ÅÜäáÅÜ=~ääÉ=ìåÉêä~ìÄíÉå= wÉáÅÜÉå=Éêâ~ååíK=^ÄÉê=ëÅÜäÉÅÜí=Ó=ëáÉ=ïÉêÇÉå=íêçíòÇÉã=ÉáåÖÉíê~ÖÉå>= sÉêëìÅÜÉå=ïáêI=Ç~ë=òì=îÉêÜáåÇÉêåI=áåÇÉã=ïáê=ÄÉá=ÉêÑΩääíÉã=qÉëí=ÇáÉëÉë=Key=Ç~åå= ÉÄÉå=ãáí=ÉáåÉã=é~ëëÉåÇÉå=~åÇÉêÉå=wÉáÅÜÉå=ÄÉäÉÖÉåW= if (Key < '0') or (Key > '9') then Key:=' '
mêáã~I=~ÄÉê=ïáêÇ=ÑΩê=àÉÇÉë=Ñ~äëÅÜ=ÖÉíáééíÉ=wÉáÅÜÉå=Éáå=iÉÉêòÉáÅÜÉå=ÉáåÖÉÖÉÄÉå= E_áäÇ=RKUFK== == VS= =
RKN== báåÑ~ÅÜÉê=qÉëí= få=ÇÉã=qÉñíÑÉåëíÉê=ëáÉÜí=Éë=~ìë=ïáÉ=áã=âáåÇäáÅÜÉå=dÉÄáëë=ÉáåÉë=pÅÜìä~åÑ®åÖÉêëK= fëí=Ç~ë=ÇáÉ=i∏ëìåÖ\==
= _áäÇ=RKUW=iÉÉêòÉáÅÜÉå=~åëíÉääÉ=Ñ~äëÅÜÉê=q~ëíÉå= j~ÅÜÉå=ïáêÛë=âìêò=ìåÇ=îÉêïÉáëÉå=ÖäÉáÅÜòÉáíáÖ=~ìÑ=ÇÉå=^ÄëÅÜåáíí=NMKOW=t~ë=~ìÅÜ= áããÉê=òïáëÅÜÉå=ÇáÉ=ÄÉáÇÉå=eçÅÜâçãã~ë=ÖÉëÅÜêáÉÄÉå=ïáêÇ=Ó=Éë=ÉêëÉíòí=ÇáÉ=Ñ~äJ ëÅÜÉ= q~ëíÉ= ìåÇ= ïáêÇ= ëí~ííÇÉëëÉå= ÉáåÖÉíê~ÖÉåK= açÅÜ= Key:=''= áëí= îÉêÄçíÉåI= Ç~= âçããí=ÉáåÉ=ÖÉÜ~êåáëÅÜíÉ=cÉÜäÉêãÉäÇìåÖK=t~ë=íìå\= aáÉ= i∏ëìåÖ= âçããíI= áåÇÉã= ïáê= Éáå= mëÉìÇçJwÉáÅÜÉå= òìïÉáëÉåI= ÉáåÉ= q~ëíÉI= ÇáÉ= âÉáåÉ=báåíê~ÖÉJtáêâìåÖ=Ü~íK=_ÉáëéáÉäëïÉáëÉ=ÇáÉ=bëÅ~éÉJq~ëíÉ= Esc K=a~òì=ãìëë= ã~å=ÇáÉ=Eëé®íÉê=Éêâä®êíÉF=ChrJcìåâíáçå=îÉêïÉåÇÉåW= procedure TForm1.Edit1KeyPress(Sender: TObject; var Key: Char); begin if (Key < '0') or (Key > '9') then Key:=Chr(27) end;
a~ë= áëí= ÇáÉ= i∏ëìåÖI= åìå= ïÉêÇÉå= Ñ~äëÅÜÉ= q~ëíÉå= ÉáåÑ~ÅÜ= áÖåçêáÉêíX= ïáê= â∏ååÉå= ~Äëçäìí=ëáÅÜÉê=ëÉáåI=Ç~ëë=Ç~ë=qÉñíÑÉåëíÉêI=ëçÑÉêå=Éë=åáÅÜí=ΩÄÉêÜ~ìéí=äÉÉê=áëíI=åìê= wáÑÑÉêå=ÉåíÜ®äíK=_Éá=ïÉáíÉêÉê=mêçÖê~ããáÉêìåÖ=â∏ååÉå=ïáê=ìåë=Ç~ê~ìÑ=îÉêä~ëëÉåK= eìåÇÉêíéêçòÉåíáÖK=råÄÉÇáåÖíK== wìã=pÅÜäìëë=ïçääÉå=ïáê=åçÅÜ=Ç~ë=åÉì=dÉäÉêåíÉ=òìë~ããÉåÑ~ëëÉåW== • báåÑ~ÅÜÉ=qÉëíë=ÇΩêÑÉå=áå=m~ëÅ~ä=ãáí=ÇÉå=pÅÜäΩëëÉäï∏êíÉêå= or=EÑΩê=łçÇÉêF=ìåÇ= and= EÑΩê= łìåÇF= îÉêâåΩéÑí= ïÉêÇÉåK= a~ÄÉá= ëáåÇ= ÇáÉ= ÉáåòÉäåÉå= qÉëíë= áå= êìåÇÉ= hä~ããÉêå=òì=ëÉíòÉå=ìåÇ=ëíÉíë=îçääëí®åÇáÖ=òì=ÑçêãìäáÉêÉåK=píêÉåÖ=îÉêÄçíÉå=áëí= òìã=_ÉáëéáÉä=ëçäÅÜ=Éáå=råëáååW== if (Key < '0' or > '9') then...
• sÉêâåΩéÑìåÖ=òïÉáÉê=qÉëíë=ãáí=łìåÇW= if (...test1...) and (...test2...) then begin ... end
• sÉêâåΩéÑìåÖ=òïÉáÉê=qÉëíë=ãáí=łçÇÉêW= áf (...test1...) or (...test2...) then begin ... end
VT =
R= báåÑ~ÅÜÉ=qÉëíë=ìåÇ=^äíÉêå~íáîÉå= • fëí= ~ìëå~ÜãëïÉáëÉ= ÄÉá= ÉêÑΩääíÉã= qÉëí= åìê= Éáå= ÉáåòáÖÉê= _ÉÑÉÜä= ~ìëòìÑΩÜêÉåI= â~åå=ÇáÉ=^ìëå~ÜãÉêÉÖÉä=ÄÉåìíòí=ïÉêÇÉåW== if (...test1...) and (...test2...) then ...genau ein Befehl... if (...test1...) or (...test2...) then ...genau ein Befehl...
5.2
Alternative báåÑ~ÅÜÉ=qÉëíë=ÄÉïáêâÉå=åìêI=Ç~ëë=ÄÉá=áÜêÉê=bêÑΩääìåÖ=Éíï~ë=é~ëëáÉêíK=fëí=ÇÉê=qÉëí= åáÅÜí= ÉêÑΩääíI= é~ëëáÉêí= ÉÄÉå= åáÅÜíëK= a~ãáí= â~åå= ã~å= ëÅÜçå= îáÉäÉ= mêçÖê~ããáÉêJ ~ìÑÖ~ÄÉå=ä∏ëÉåK=^ÄÉê=åáÅÜí=~ääÉ=Ó=ìåÇ=Ç~ë=ïçääÉå=ïáê=ìåë=~å=ÉáåÉã=íóéáëÅÜÉå= _ÉáëéáÉä=~åëÉÜÉåK=
5.2.1 ==
Ein Nachttischlampen-Schalter
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 5= ÇáÉ= zipJa~íÉá= DKap05.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap05= ÇáÉ= mêçàÉâíJa~íÉá= proj_521.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap05=ÇáÉ=a~íÉá=proj_521.bdsproj=~ìëòìï®ÜäÉåK== == a~ë=ëçää=Éë=áããÉê=åçÅÜ=ÖÉÄÉåW=báå=aêìÅâ=~ìÑ=ÇÉå=pÅÜ~äíÉêI=ÇáÉ=i~ãéÉ=ÖÉÜí=~åI= ïáÉÇÉê=ÇÉêëÉäÄÉ=aêìÅâ=~ìÑ=ÇÉå=pÅÜ~äíÉêI=ÇáÉ=i~ãéÉ=ÖÉÜí=~ìëK=råÇ=ëç=ïÉáíÉêK== _Éíê~ÅÜíÉå= ïáê= Ç~ÑΩê= ÉáåÉå= _ìííçå= ãáí= ÇÉê= pí~êíJ_ÉëÅÜêáÑíìåÖ= EinK= táêÇ= Éê= ÖÉJ âäáÅâí=ëçää=ÇáÉ=_ÉëÅÜêáÑíìåÖ=ïÉÅÜëÉäå=áå= AusK=táêÇ=Éê=ïáÉÇÉê=ÖÉâäáÅâíI=ëçää=ïáÉJ ÇÉê=Ein=~ìÑ=ÇÉã=_ìííçå=ëíÉÜÉå=ìëïK=E_áäÇ=RKVFK=
= _áäÇ=RKVW=pí~êíI=å~ÅÜ=ÉêëíÉã=häáÅâI=å~ÅÜ=òïÉáíÉã=häáÅâ=EtìåëÅÜF= hÉáå=mêçÄäÉãI=ÇÉåâí=ëáÅÜ=ÇÉê=ïáëëÉåÇÉ=mêçÖê~ããáÉêÉêI=ÄÉëçêÖí=ëáÅÜ=ÇÉå= o~ÜJ ãÉå= ÑΩê= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= ìåÇ= ëÅÜêÉáÄí= ÉáåÉå= ~ìÑ= ÇÉå= ÉêëíÉå= _äáÅâ= íçääÉå= ìåÇ=ëÅÜÉáåÄ~ê=êáÅÜíáÖÉå=fåÜ~äíW== procedure TForm1.Button1Click(Sender: TObject); begin if Button1.Caption='Ein' then begin Button1.Caption:='Aus' end; if Button1.Caption='Aus' then begin Button1.Caption:='Ein' end end;
VU= =
//erster Test //zweiter Test
RKO== ^äíÉêå~íáîÉ= mêçÄáÉêÉå=ïáê=Éë=~ìëW=táê=â∏ååÉå=âäáÅâÉåI=ïáÉ=ìåÇ=ëç=çÑí=ïáê=ïçääÉå=Ó=ïáê=ÄÉJ âçããÉå= åáÉã~äë= ÇáÉ= _ÉëÅÜêáÑíìåÖ= Aus= òì= ëÉÜÉåK= t~ë= Ü~ÄÉå= ïáê= Ñ~äëÅÜ= ÖÉJ ã~ÅÜí\= aÉåâÉå=ïáê= ÖÉãÉáåë~ã= å~ÅÜK=aáÉ=i~ìÑòÉáí=ÄÉÖáååíI=~ìÑ=ÇÉã=_ìííçå=ëíÉÜí= EinK= bêëíÉê=häáÅâI=ÉêëíÉê=qÉëíK=aÉê=áëí=ÉêÑΩääíI=_ÉëÅÜêáÑíìåÖ=ïÉÅÜëÉäí=òì= AusK=açÅÜ=ÇáÉ= bêÉáÖåáëéêçòÉÇìê=áëí=ÖÉê~ÇÉ=Éêëí=òìê=e®äÑíÉ=~ÄÖÉ~êÄÉáíÉíW=báåÉ=jáääáçåëíÉäJpÉâìåJ ÇÉ=ëé®íÉê=âçããí=å®ãäáÅÜ=ëçÑçêí=ÇÉê=òïÉáíÉI=ÇÉê=ÑçäÖÉåÇÉ=qÉëíK=açêí=~ÄÉê=ïáêÇ= ÖÉÑê~ÖíI= çÄ= åìå= Aus= ~ìÑ= ÇÉã= _ìííçå= ëíÉÜíK= a~ë= áëí= ÇÉê= c~ää= Ó= ÑçäÖäáÅÜ= ïáêÇ= ÇáÉ= _ÉëÅÜêáÑíìåÖ= ïáÉÇÉê= ~ìÑ= Ein= ÖÉëíÉääíK= báå= íçääÉê= aÉåâÑÉÜäÉê= ÑΩÜêí= ÜáÉê= òì= ÉáåÉã= ~Äëçäìí=Ñ~äëÅÜÉå=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìêK== eáÉê=Äê~ìÅÜÉå=ïáê=ÉáåÉ=~åÇÉêÉ=qÉëíâçåëíêìâíáçåK=páÉ=ãìëë=ëç=~ìëëÉÜÉåW== • tÉåå=~ìÑ=ÇÉã=_ìííçå=Ein=ëíÉÜíI=Ç~åå=ëÅÜêÉáÄÉ=AusK=^åÇÉêåÑ~ääë=ëÅÜêÉáÄÉ=EinK== pçäÅÜ= ÉáåÉ= tÉååÓÇ~ååÓ~åÇÉêåÑ~ääëÓhçåëíêìâíáçå= åÉååí= ã~å= ^äíÉêå~íáîÉK= aáÉ= m~ëÅ~äJoÉÖÉäå=ÑΩê=áÜêÉ=rãëÉíòìåÖ=ëÉÜÉå=ïáê=áå=ÇÉê=êáÅÜíáÖÉå=bêÉáÖåáëéêçòÉÇìêK= procedure TForm1.Button1Click(Sender: TObject); begin if Button1.Caption='Ein' then begin // Befehle des JA-Zweiges Button1.Caption:='Aus' end else // andernfalls begin // Befehle des NEIN-Zweiges Button1.Caption:='Ein' end end;
aáÉ= ÉåÖäáëÅÜÉ= sçâ~ÄÉä= else= ÖÉÜ∏êí= òì= ÇÉå= ÇáîÉêëÉå= Ñ~äëÉ= ÑêáÉåÇë= EÑ~äëÅÜÉå= cêÉìåÇÉåFI=ÇáÉ=ÇáÉëÉ=péê~ÅÜÉ=ÑΩê=ìåë=aÉìíëÅÜÉ=ÄÉêÉáí=Ü®äíW=else=ÜÉá≈í=åáÅÜí=~äëçI= ëçåÇÉêå=~åÇÉêåÑ~ääëK=tÉê=ëáÅÜ=Ç~ë=ãÉêâíI=éêçÖê~ããáÉêí=êáÅÜíáÖK== ^äíÉêå~íáîÉå=ÄÉëáíòÉå=ÉáåÉå=g~J=ìåÇ=ÉáåÉå=kÉáåJwïÉáÖK== • _Éá=ÉêÑΩääíÉã=qÉëí=ïáêÇ=ÇÉê=g~JwïÉáÖ= ~ìëÖÉÑΩÜêíI=ÄÉá= åáÅÜí=ÉêÑΩääíÉã=qÉëí=ÇÉê= kÉáåJwïÉáÖK== båíÜ®äí= ÉáåÉê= ÇÉê= wïÉáÖÉ= ëéÉòáÉää= åìê= ÉáåÉå= ÉáåòáÖÉå= _ÉÑÉÜäI= ëç= â~åå= Eãìëë= ~ÄÉê= åáÅÜí>F= Ççêí= ïáÉÇÉêìã= Ç~ë= beginJendJm~~ê= ÇÉê= ^åïÉáëìåÖëâä~ããÉêå= ïÉÖJ ÖÉä~ëëÉå=ïÉêÇÉåW== procedure TForm1.Button1Click(Sender: TObject); begin if Button1.Caption='Ein' then Button1.Caption:='Aus' else Button1.Caption:='Ein' end;
VV =
R= báåÑ~ÅÜÉ=qÉëíë=ìåÇ=^äíÉêå~íáîÉå=
5.2.2 ==
Zu- und Abschalten von Buttons
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 5= ÇáÉ= zipJa~íÉá= DKap05.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap05= ÇáÉ= mêçàÉâíJa~íÉá= proj_522.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap05=ÇáÉ=a~íÉá=proj_522.bdsproj=~ìëòìï®ÜäÉåK== == táê= ïçääÉå= åçÅÜ= Éáåã~ä= òì= ÉáåÉê= ^ìÑÖ~ÄÉ= ®ÜåäáÅÜ= ïáÉ= áã= ^ÄëÅÜåáíí= QKRKO= òìJ êΩÅââÉÜêÉåI=ïç=Éë=ìã=ÇáÉ=^âíáîáÉêìåÖ=ìåÇ=aÉ~âíáîáÉêìåÖ=ÉáåÉë=_ìííçåë=ÖáåÖK= wïÉá=äÉÉêÉ=qÉñíÑÉåëíÉê=ëáåÇ=~ìÑ=ÇÉã=cçêãìä~ê=~åòìçêÇåÉåI=Ç~êìåíÉê=Éáå=_ìííçå= ãáí=ÇÉê=^ìÑëÅÜêáÑí= Füge zusammenI=Ç~êìåíÉê=Éáå=äÉÉêÉë=i~ÄÉäK=aáÉ=^ìÑÖ~ÄÉ=ä~ìíÉíW= tÉåå=ÇÉê=kìíòÉê=áå=ÇáÉ=ÄÉáÇÉå=qÉñíÑÉåëíÉê=Éíï~ë=ÉáåÖÉíê~ÖÉå=Ü~íI=ëçääÉå=ÄÉáã= häáÅâ=~ìÑ=ÇÉå=_ìííçå=ÇáÉ=ÄÉáÇÉå=fåÜ~äíÉ=ãáí=ÉáåÉã=_áåÇÉëíêáÅÜ=òìë~ããÉåÖÉÑΩÖí= ìåÇ=áã=i~ÄÉä=~åÖÉòÉáÖí=ïÉêÇÉåK=
= _áäÇ=RKNMW=sÉêâÉííìåÖ=ãáí=_áåÇÉëíêáÅÜ= §ÄÉê= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= häáÅâ= ~ìÑ= ÇÉå= _ìííçå= Äê~ìÅÜÉå= ïáê= Ö~ê= åáÅÜí= ãÉÜê=òì=êÉÇÉåI=ëç=ÉáåÑ~ÅÜ=áëí=ëáÉW= procedure TForm1.Button1Click(Sender: TObject); begin Label1.Caption:=Edit1.Text + '-' + Edit2.Text end;
açÅÜ=ïÉäÅÜÉ=páíì~íáçå=äáÉÖí=ÉáÖÉåíäáÅÜ=îçêI=ïÉåå=ÉáåÉë=ÇÉê=ÄÉáÇÉå=qÉñíÑÉåëíÉê= çÇÉê= ëçÖ~ê= ~ääÉ= ÄÉáÇÉ= äÉÉê= ëáåÇ\= a~åå= ï®êÉ= ÇçÅÜ= ÉáåÉ= _ÉÇáÉåìåÖ= ÇÉë= _ìííçåë= ëáååäçëK== cçäÖäáÅÜ=ãìëë=ÇáÉ=éêçéÉêíó= Enabled=ÇÉë=_ìííçåë=~ìÑ=àÉÇÉå=c~ää=ÑΩê=ÇÉå=pí~êí=ÇÉê= i~ìÑòÉáí=~ìÑ=False=ÖÉëÉíòí=ïÉêÇÉå=E_áäÇ=RKNNFK=
= _áäÇ=RKNNW=_Éáã=pí~êíW=iÉÉêÉ=qÉñíÑÉåëíÉêI=áå~âíáîÉê=_ìííçå= kìå=âçããí=ÇÉê=áåíÉêÉëë~åíÉ=qÉáä=ÇÉê=^ìÑÖ~ÄÉW=_Éá=àÉÇÉê=ûåÇÉêìåÖ=áå=ÉáåÉã=ÇÉê= qÉñíÑÉåëíÉê=ãìëë=ÖÉéêΩÑí=ïÉêÇÉåI=çÄ=ÄÉáÇÉ=qÉñíÑÉåëíÉê=åáÅÜí=äÉÉê=ëáåÇK==
NMM= =
RKO== ^äíÉêå~íáîÉ= tÉåå= à~I= ïáêÇ= ÇÉê= _ìííçå= òìÖÉëÅÜ~äíÉíK= ^åÇÉêåÑ~ääë= ãìëë= ÇÉê= _ìííçå= ïáÉÇÉê= ÇÉ~âíáîáÉêí=ïÉêÇÉåW== procedure TForm1.Edit1Change(Sender: TObject); begin if (Edit1.Text'') and (Edit2.Text'') then Button1.Enabled:=True else Button1.Enabled:=False end; procedure TForm1.Edit2Change(Sender: TObject); begin if (Edit1.Text'') and (Edit2.Text'') then Button1.Enabled:=True else Button1.Enabled:=False end;
aÉê=qÉëí=òÉáÖí=ÉëW=bêëí=ïÉåå=ÄÉáÇÉ=qÉñíÑÉåëíÉê=ÉáåÉå=fåÜ~äí=Ü~ÄÉåI=ïáêÇ=ÇÉê=_ìíJ íçå=~âíáîK=táêÇ=~ìÅÜ=åìê=Éáå=fåÜ~äí=ÖÉä∏ëÅÜíI=ïáêÇ=ÇÉê=_ìííçå=ëçÑçêí=~ìíçã~íáëÅÜ= ïáÉÇÉê=áå~âíáîK=pçãáí=áëí=ÉáåÉ=ÖÉäìåÖÉåÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=Éåíëí~åÇÉåI=ÇÉêÉå= _ÉÇáÉåìåÖëÉäÉãÉåíÉ=åìê=Ç~åå=~âíáî=EÑçäÖäáÅÜ=ÄÉÇáÉåÄ~êF=ëáåÇI=ïÉåå=ÉáåÉ=kìíJ òÉêÉáåïáêâìåÖ=~ìÑ=ëáÉ=ΩÄÉêÜ~ìéí=ëáååîçää=áëíK= t~ë=Ü~ÄÉå=ïáê=~ì≈ÉêÇÉã=ÖÉäÉêåí\== • få=m~ëÅ~ä=ÄÉëáíòí=ÇáÉ=wÉáÅÜÉåâçãÄáå~íáçå==ÇáÉ=_ÉÇÉìíìåÖ=ìåÖäÉáÅÜK=== • báå=qÉëí=~ìÑ=ÉáåÉå=îçêÜ~åÇÉåÉå=fåÜ~äí=ïáêÇ=ëç=ÑçêãìäáÉêíI=Ç~ëë=ÖÉÑê~Öí=ïáêÇI= çÄ=ÇÉê=fåÜ~äí=åáÅÜí=äÉÉê=áëíW=få=m~ëÅ~ä=ïáêÇ=ÇáÉëÉë=äÉÉê=ãáí=òïÉá=åÉÄÉåÉáå~åJ ÇÉê=ëíÉÜÉåÇÉå=eçÅÜâçãã~ë=''=ÄÉëÅÜêáÉÄÉåK= t®êÉ= Éë= ÜáÉê= ÉáÖÉåíäáÅÜ= Ñ~äëÅÜI= ïÉåå= ã~å= ÇÉå= fåÜ~äí= ÇÉê= bêÉáÖåáëéêçòÉÇìêÉå= ãáí=òïÉá=ÉáåÑ~ÅÜÉå=qÉëíë=éêçÖê~ããáÉêíÉ\=pÉÜÉå=ïáê=Éë=ìåë=~åW== procedure TForm1.Edit1Change(Sender: TObject); begin if (Edit1.Text'') and (Edit2.Text'') then Button1.Enabled:=True;
//Semikolon nötig, ein Test folgt
if (Edit1.Text='') or (Edit2.Text='') then Button1.Enabled:=False end;
NMN =
R= báåÑ~ÅÜÉ=qÉëíë=ìåÇ=^äíÉêå~íáîÉå= procedure TForm1.Edit2Change(Sender: TObject); begin if (Edit1.Text'') and (Edit2.Text'') then Button1.Enabled:=True;
//Semikolon nötig, ein Test folgt
if (Edit1.Text='') or (Edit2.Text='') then Button1.Enabled:=False end;
pçÑÉêå= ÇáÉ= içÖáâ= ÄÉáÇÉê= ÉáåÑ~ÅÜÉê= qÉëíë= EÉáåã~ä= ìåÇI= Éáåã~ä= çÇÉêF= êáÅÜíáÖ= ÄÉJ Ç~ÅÜí=áëíI=â~åå=ã~å=~ìÅÜ=ëç=éêçÖê~ããáÉêÉåK== wïÉá=ÉáåÑ~ÅÜÉ=qÉëíë=~åëíÉääÉ=ÇÉê= if ... then ... else-hçãÄáå~íáçå=ëáåÇ=ÇáÉëJ ã~ä=ÜáÉê=åáÅÜí=Ñ~äëÅÜK= =
NMO= =
==
6
Timer und Timer-Ereignisse bë=ÖÉÜí=îçê~åK=fã=îçêáÖÉå=h~éáíÉä=äÉêåíÉå=ïáê=ãáí=ÇÉå= if...thenJ=ìåÇ=ëé®íÉê=ãáí= ÇÉå= if...then...elseJhçåëíêìâíáçåÉå= ïáÅÜíáÖÉ= j∏ÖäáÅÜâÉáíÉå= âÉååÉåI= ãáí= ÇÉJ åÉå=ïáê=ÉêêÉáÅÜÉå=â∏ååÉåI=Ç~ëë=ã~åÅÜÉ=_ÉÑÉÜäÉ=áã=fååÉêÉå=îçå=bêÉáÖåáëéêçòÉJ ÇìêÉå= åáÅÜí= áããÉêI= ëçåÇÉêå= åìê= ã~åÅÜã~ä= ~ÄÖÉ~êÄÉáíÉí= ïÉêÇÉåK= lÇÉê= áã= tÉÅÜëÉä=ãáí=~åÇÉêÉå=_ÉÑÉÜäÉå=ÄòïK=_ÉÑÉÜäëÖêìééÉåK== båíïÉÇÉê= KKK= çÇÉêI= Ç~ë= áëí= ÇáÉ= ^äíÉêå~íáîÉK= aáÉ= ä~íÉáåáëÅÜÉ= sçâ~ÄÉä= alter= ÜÉá≈í= ~ìÅÜ= åáÅÜíë= ~åÇÉêÉë= ~äë= Ç~ë= ~åÇÉêÉK= mçäáíáâÉê= çÇÉê= cì≈Ä~ääêÉéçêíÉêI= ÇáÉ= å~ÅÜ= ÇêáííÉå=ìåÇ=îáÉêíÉå=^äíÉêå~íáîÉå=ëìÅÜÉåI=Ü~ÄÉå=ÇÉãå~ÅÜ=áã=i~íÉáåìåíÉêêáÅÜí=ÖÉJ ëÅÜä~ÑÉå=çÇÉê=ÄÉá=ÇáÉëÉê=sçâ~ÄÉä=ÖÉê~ÇÉ=ÖÉÑÉÜäíK= aáÉ=^äíÉêå~íáîÉ=~äë=péê~ÅÜÉäÉãÉåí=Äê~ìÅÜí=ã~å=ìåÄÉÇáåÖí=ÄÉá=ÇÉã=ÖÉëÅÜáäÇÉêJ íÉå=k~ÅÜííáëÅÜä~ãéÉåJ_ÉáëéáÉäX=~åÇÉêÉ=_ÉáëéáÉäÉI=ïáÉ=ÇáÉ=wìJ=ìåÇ=^ÄëÅÜ~äíìåÖ= îçå=_ìííçåëI=â∏ååÉå=ï~ÜäïÉáëÉ=ãáí=^äíÉêå~íáîÉ=çÇÉê=òïÉá=ÉáåÑ~ÅÜÉå=qÉëíë=éêçJ Öê~ããáÉêí=ïÉêÇÉåK== ^ìÅÜ=ÇáÉ=áå=^ÄëÅÜåáíí=RKNKO=ÖÉëíÉääíÉ=^ìÑÖ~ÄÉI=Ç~ëë=ÄÉáã=häáÅâ=~ìÑ=ÉáåÉ=`ÜÉÅâJ Äçñ=ãáíÖÉíÉáäí=ïÉêÇÉå=ëçääI=çÄ=Éë=Éáå=báåâäáÅâ=çÇÉê=Éáå=^ìëâäáÅâ=ï~êI=Ü®ííÉ=ëáÅÜI= Ç~ë= ïáëëÉå= ïáê= åìåI= ãáí= ÇÉê= ^äíÉêå~íáîÉ= ÉäÉÖ~åíÉê= éêçÖê~ããáÉêÉå= ä~ëëÉåK= dÉJ å~ìëç= äáÉ≈É= ëáÅÜ= ÇáÉ= ^äíÉêå~íáîÉ= ~ìÅÜ= ~åïÉåÇÉå= ÄÉá= ÇÉê= _ÉïÉÖìåÖëëíÉìÉêìåÖ= ÇÉê=pÅêçääÄ~ê=E^ÄëÅÜåáíí=RKNKPFK== kìå=Ö∏ååÉå=ïáê=ìåë=ïáÉÇÉê=ÉáåÉ=sÉêëÅÜå~ìÑé~ìëÉI=ÄÉîçê=Éêëí=áã=h~éáíÉä=V=ãáí= ÇÉê= w®ÜäëÅÜäÉáÑÉ= Ç~ë= å®ÅÜëíÉ= äÉáëíìåÖëÑ®ÜáÖÉI= ~ÄÉê= ~ìÅÜ= ÖÉáëíáÖ= ~åëéêìÅÜëîçääÉ= péê~ÅÜÉäÉãÉåí=ÉáåÖÉÑΩÜêí=ïÉêÇÉå=ïáêÇK==
6.1
Timer: Begriff und Bedeutung
6.1.1
Bisherige Möglichkeiten und Grenzen
t~ë= â∏ååÉå= ïáê= ÄáëÜÉê\= sáÉäK= táê= â∏ååÉå= Éáå= cçêãìä~ê= ÜÉêëíÉääÉåI= ~ìÑ= ÇÉã= píÉìÉêÉäÉãÉåíÉ=~åÖÉçêÇåÉí=ëáåÇK=táê=â∏ååÉå=ëçïçÜä=ÑΩê=Ç~ë=cçêãìä~ê=~äë=~ìÅÜ= ÑΩê= ÇáÉ= píÉìÉêÉäÉãÉåíÉ= ÇáÉ= dÉëí~äíìåÖ= ÑΩê= ÉáåÉ= sáÉäò~Üä= îçå= jÉêâã~äÉå= ãáí= eáäÑÉ=ÇÉë=oÉÖáëíÉêÄä~ííÉë=bfdbkp`e^cqbk=ÇÉë=lÄàÉâíáåëéÉâíçêë=îçêÉáåëíÉääÉåK== _Éáã= _ÉÖáåå= ÇÉê= i~ìÑòÉáí= ïÉêÇÉå= ÇáÉëÉ= sçêÉáåëíÉääìåÖÉå= Ç~åå= ãáííÉäë= ÇÉê= éêçJ éÉêíáÉë=áå=ÇáÉ=a~íÉåâÉêåÉ=ÇÉê=ÉåíëíÉÜÉåÇÉå=îáëìÉääÉå=lÄàÉâíÉ=íê~åëéçêíáÉêíK=a~=ÇáÉ= a~íÉåâÉêåÉ= îáëìÉääÉê= lÄàÉâíÉ= ìåãáííÉäÄ~ê= ãáí= ÇÉå= ëáÅÜíÄ~êÉå= qÉáäÉå= îÉêÄìåÇÉå= ëáåÇI=ëÉÜÉå=ïáê=òìã=_ÉÖáåå=ÇÉê=i~ìÑòÉáí=Ç~ëI=ï~ë=ïáê=îçêÜÉê=ÉáåÖÉëíÉääí=Ü~ÄÉåK== NMP =
S= qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ= pçääíÉ=Éáå=jÉêâã~ä=ëáÅÜ=~ìëå~ÜãëïÉáëÉ=åáÅÜí=ΩÄÉê=ÇÉå=lÄàÉâíáåëéÉâíçê=îçêÉáåJ ëíÉääÉå= ä~ëëÉåI= Ç~= ÇáÉ= ÉåíëéêÉÅÜÉåÇÉ= éêçéÉêíó= Ççêí= ÑÉÜäí= EòK= _K= ÇáÉ= pí~êíã~êâáÉJ êìåÖ= áå= ÉáåÉê= iáëíÉFI= ä®ëëí= ëáÅÜ= ÇÉã= ~ÄÜÉäÑÉå= ãáí= eáäÑÉ= ÇÉê= ëéÉòáÉääÉå= bêÉáÖåáëJ éêçòÉÇìê=òìã=bêÉáÖåáë=bêòÉìÖìåÖ=ÇÉë=cçêãìä~êë=ìåÇ=ìåíÉê=sÉêïÉåÇìåÖ=ÖÉÉáÖJ åÉíÉê= ïÉáíÉêÉê= éêçéÉêíáÉëI= ÇáÉ= Ç~åå= áå= ÇÉê= mìåâíäáëíÉ= òì= ëìÅÜÉå= ëáåÇ= EëK= ^ÄJ ëÅÜåáíí=QKTKPFK=== tÉáíÉêÉ=bêÉáÖåáëéêçòÉÇìêÉå=ïÉêÇÉå=~ì≈ÉêÇÉã=îçêÄÉêÉáíÉíI=Ç~ãáí=ÄÉá= ÄÉëíáããJ íÉå=kìíòÉêÜ~åÇäìåÖÉå=~å=ÇÉå=ëáÅÜíÄ~êÉå=qÉáäÉå=ÖÉïáëëÉê=îáëìÉääÉê=lÄàÉâíÉ=ÇáÉ= ÖÉïΩåëÅÜíÉå=oÉ~âíáçåÉå=ÉáåíêÉíÉåK=t~ë=ïç=ìåÇ=ïçÄÉá=é~ëëáÉêÉå=ëçääI=Ç~ë=ãìëë= ã~å=~ìë=ÇÉê=^ìÑÖ~ÄÉåëíÉääìåÖ=ÉåíåÉÜãÉåK=a~ë=Ü~ÄÉå=ïáê=~å=îáÉäÉå=_ÉáëéáÉäÉå= ëÅÜçå=íê~áåáÉêí=ìåÇ=ïÉêÇÉå=Éë=ïÉáíÉê=íê~áåáÉêÉåK=
== _áäÇ=SKNW=_áëÜÉêáÖÉ=páíì~íáçåW=lÜåÉ=kìíòÉê=é~ëëáÉêí=åáÅÜíë== aáÉ= oÉ~âíáçåÉå= â∏ååÉå= áã= ÉáåÑ~ÅÜëíÉå= c~ää= åìê= jáííÉáäìåÖÉå= ëÉáåI= ëáÉ= â∏ååÉå= ~ÄÉê=~ìÅÜ=áå=ûåÇÉêìåÖÉå=~å=jÉêâã~äÉå=ÇÉë=ëáÅÜíÄ~êÉå=qÉáäë=ÇÉë=ÉáÖÉåÉå=çÇÉê= ~åÇÉêÉê=îáëìÉääÉê=lÄàÉâíÉ=ÄÉëíÉÜÉåK== j∏ÖäáÅÜ= ïáêÇ= Ç~ë= ~ääÉë= ÇìêÅÜ= ÇáÉ= sÉêïÉåÇìåÖ= îçå= éêçéÉêíáÉëI= ãáí= ÇÉêÉå= eáäÑÉ= ïáê=ÇÉå=wìÖêáÑÑ=~ìÑ=a~íÉåâÉêåÉ=îáëìÉääÉê=lÄàÉâíÉ=é~ëëáî=ìåÇ=~âíáî=éêçÖê~ããáÉJ êÉå=â∏ååÉåK= ^ääÉë= éêáã~K= açÅÜ= Éáå= qÉáä= ÉáåÉë= p~íòÉë= ëçää= ÜáÉê= åçÅÜ= Éáåã~ä= ÜÉêîçêÖÉÜçÄÉå= ïÉêÇÉåW= NMQ= =
SKN== qáãÉêW=_ÉÖêáÑÑ=ìåÇ=_ÉÇÉìíìåÖ= • KKK=Ç~ãáí=ÄÉá=ÄÉëíáããíÉå=kìíòÉêÜ~åÇäìåÖÉå=~å=ÇÉå=ëáÅÜíÄ~êÉå=qÉáäÉå=ÖÉïáëJ ëÉê=îáëìÉääÉê=lÄàÉâíÉ=ÇáÉ=ÖÉïΩåëÅÜíÉå=oÉ~âíáçåÉå=ÉáåíêÉíÉå= a~ë= ÜÉá≈í= ÇçÅÜ= áã= hä~êíÉñí= ÖÉå~ì= Ç~ëI= ï~ë= áå= ÇÉê= råíÉêëÅÜêáÑí= îçå= _áäÇ= SKN= ëíÉÜíW=lÜåÉ=kìíòÉê=é~ëëáÉêí=åáÅÜíëK== açÅÜ= ~ìÅÜ= Ç~ååI= ïÉåå= Éáå= kìíòÉê= îçêÜ~åÇÉå= áëí= ìåÇ= ëáÅÜ= ÄÉÖÉáëíÉêí= ÇÉå= ÜΩÄëÅÜ=ÖÉëí~äíÉíÉå=_áäÇëÅÜáêã=~åëáÉÜíI=é~ëëáÉêí=åáÅÜíëK=táê=ãΩëëÉå=ÖÉå~ìÉê=ÑçêJ ãìäáÉêÉåW== • lÜåÉ=ÉáåÉ=_ÉÇáÉåÜ~åÇäìåÖ=ÉáåÉë=kìíòÉêë=ïáêÇ=ÄáëÜÉê=åáÅÜí=ÉáåÉ=ÉáåòáÖÉ=bêJ ÉáÖåáëéêçòÉÇìê=ÖÉëí~êíÉí=ìåÇ=~ÄÖÉ~êÄÉáíÉíK== k~=ìåÇI=â∏ååíÉ=ã~å=Ç~=ÉáåïÉåÇÉå\=pÅÜäáÉ≈äáÅÜ=ïáêÇ=ÇçÅÜ=ÉáåÉ=_ÉåìíòÉêçÄÉêJ Ñä®ÅÜÉ=ÖÉê~ÇÉ=Ç~ÑΩê=ÖÉã~ÅÜíI=Ç~ëë=Éáå=kìíòÉê=ãáí=áÜê=ìãÖÉÜíK= açÅÜ= Éë= ÖáÄí= ~ìÅÜ= åçÅÜ= ~åÇÉêÉ= ^êíÉå= îçå= ^ìÑÖ~ÄÉåëíÉääìåÖÉåK= pç= Ü~ÄÉå= ïáê= ÇáÉ=îáÉäÉå=péáÉäÉI=ÇáÉ=ÖÉê~ÇÉòì=Ç~îçå=äÉÄÉåI=Ç~ëë=òìå®ÅÜëí=çÜåÉ=kìíòÉêÉáåïáêJ âìåÖ= ~ìÑ= ÇÉê= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= Éíï~ë= é~ëëáÉêíI= ïçê~ìÑ= ÇÉê= kìíòÉê= êÉ~ÖáÉêÉå= ëçääK== ^ìÅÜ=ÇÉê=_ÉÖêáÑÑ=ÇÉê=páãìä~íáçå=ïáêÇ=ìåë=åçÅÜ=ÄÉëÅÜ®ÑíáÖÉåW=lÜåÉ=báåïáêâìåÖ= îçå=~ì≈Éå= ëçääÉå=mêçòÉëëÉ=áã=wÉáíêÜóíÜãìë= ~Ää~ìÑÉåI=ÇáÉ=ã~å= Ç~åå=ÄÉçÄ~ÅÜJ íÉå=â~åå=Ó=ÄÉáëéáÉäëïÉáëÉ=ÇáÉ=píÉìÉêìåÖ=ÉáåÉê=^ãéÉä=~å=ÉáåÉê=hêÉìòìåÖK== lÇÉê=ÇÉåâÉå=ïáê=~å=mê®ëÉåí~íáçåëJ=ìåÇ=fåÑçêã~íáçåëéêçÖê~ããÉK=tÉåå=ÇÉê=fåJ Ü~ÄÉê= ÉáåÉë= oÉáëÉÄΩêçë= ~ã= p~ãëí~Öãáíí~Ö= ÉáåÉå= m`J_áäÇëÅÜáêã= áå= ëÉáå= pÅÜ~ìJ ÑÉåëíÉê=ëíÉääí=ìåÇ=ãáí=ÇÉã=_ÉÖáåå=ÇÉê=i~ìÑòÉáí=ÉáåÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=ÜÉêëíÉääíI= ëçää=å~íΩêäáÅÜ=çÜåÉ=wìíìå=ÇÉê=_Éíê~ÅÜíÉê=ÉáåÉ=mê®ëÉåí~íáçå=~Ää~ìÑÉåK== pÅÜäáÉ≈äáÅÜ=ëçääíÉå=ïáê=~ìÅÜ=~å=ÉáåÉå=_áäÇëÅÜáêãëÅÜçåÉê=ÇÉåâÉåI=ÇÉê=çÜåÉ=àÉÖJ äáÅÜÉå=^åëíç≈=ÇìêÅÜ=ÉáåÉ=kìíòÉêÉáåïáêâìåÖ=éä∏íòäáÅÜ=ëí~êíÉí=ìåÇ=é~ìëÉåäçë=îÉêJ ëÅÜáÉÇÉå~êíáÖëíÉ=_áäÇÉê=éêçÇìòáÉêíK===
6.1.2
Timer
báå=qáãÉê=áëí=Éáå=wÉáíÖÉÄÉêI=ÇÉê=Ó=ëçÑÉêå=Éê=~âíáî=áëí=Ó=áå=ÄÉëíáããíÉå=^Äëí®åÇÉå= Éáå=bêÉáÖåáë=~ìëä∏ëíI=Ç~ë=qáãÉêJbêÉáÖåáëK== wìã=qáãÉêJbêÉáÖåáë=â∏ååÉå=áå=ÇÉê=òìÖÉÜ∏êáÖÉå=bêÉáÖåáëéêçòÉÇìê=îáÉäÑ®äíáÖÉ=oÉJ ~âíáçåÉå=éêçÖê~ããáÉêí=ïÉêÇÉå=EëáÉÜÉ=_áäÇ=SKOFK==== báå= qáãÉê= áëí= Éáå= lÄàÉâíI= Ç~ë= áå= ëÉáåÉã= ÖÉâ~éëÉäíÉå= a~íÉåâÉêå= ÇáÉ= jÉêâã~äÉ= îÉêï~äíÉíK=fã=lÄàÉâíáåëéÉâíçê=ëáåÇ=ÇáÉ=báÖÉåëÅÜ~ÑíÉå=~ìÑÖÉäáëíÉíI=ãáí=ÇÉêÉå=eáäÑÉ= ÇáÉ=páíì~íáçå=ÇÉë=qáãÉêë=ÄÉáã=pí~êí=ÇÉê=i~ìÑòÉáí=îçêÉáåÖÉëíÉääí=ïÉêÇÉå=â~ååK== jáí=eáäÑÉ=ÉáåáÖÉê=éêçéÉêíáÉë=â~åå=áå=bêÉáÖåáëéêçòÉÇìêÉå=~ääÉê=^êí=~ìÑ=ÇÉå=a~íÉåJ âÉêå=ÉáåÉë=qáãÉêë=òìÖÉÖêáÑÑÉå=ïÉêÇÉåK== j∏ÖäáÅÜâÉáíÉå= ÇÉê= ìåãáííÉäÄ~êÉå= kìíòÉêÉáåïáêâìåÖ= ~ìÑ= ÉáåÉå= qáãÉê= ÖáÄí= Éë= åáÅÜíK=cçäÖäáÅÜ=ò®Üäí=Éáå=qáãÉê=ïçÜä=åáÅÜí=òì=ÇÉå=îáëìÉääÉå=lÄàÉâíÉåK= NMR =
S= qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ=
= _áäÇ=SKOW=qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáë== aÉäéÜá=ÄáÉíÉí=ÇáÉ=j∏ÖäáÅÜâÉáíI=ãÉÜêÉêÉ=qáãÉê=òì=îÉêïÉåÇÉå=E_áäÇ=SKPFK=cΩê=àÉJ ÇÉå=ÉáåòÉäåÉå=qáãÉê=â~åå=Éáå=ÄÉëíáããíÉë=fåíÉêî~ää=ÉáåÖÉëíÉääí=ïÉêÇÉåK== aáÉ=jÉåÖÉ=ÇÉê=bêÉáÖåáëéêçòÉÇìêÉåI=áå=ÇÉåÉå=~ìÑ=kìíòÉêÉáåïáêâìåÖÉå=êÉ~ÖáÉêí= ïáêÇI=â~åå=ÉêÖ®åòí=ïÉêÇÉå=ÇìêÅÜ=îáÉäÑ®äíáÖÉ=bêÉáÖåáëéêçòÉÇìêÉå=òì=ÇÉå=qáãÉêJ bêÉáÖåáëëÉåK==
6.2
Einrichtung und Starteinstellung lÄïçÜä=Éáå=qáãÉê=âÉáå=îáëìÉääÉë=lÄàÉâí=áëíI=â~åå=Éê=ÇçÅÜ=ÉÄÉåëç=ïáÉ=ÇáÉ=ÄáëJ ÜÉê=ÄÉâ~ååíÉå=îáëìÉääÉå=lÄàÉâíÉ=ÉáåÖÉêáÅÜíÉí=ïÉêÇÉåK==
6.2.1
Platzieren des Timer-Symbols
a~ë=qáãÉêJpóãÄçä=ErÜêF=ÑáåÇÉå=ïáê=áå=aÉäéÜá=~ìÑ=ÇÉê=oÉÖáëíÉêâ~êíÉ=pvpqbj=ÇÉê= hçãéçåÉåíÉåäÉáëíÉK= få= aÉäéÜá= ULOMMR= ãìëë= áå= ÇÉê= qççäJm~äÉííÉ= ~ìÑ= pvpqbj= ìãJ ÖÉëíÉääí=ïÉêÇÉå=EëK=_áäÇ=SKQFK=a~ë=qáãÉêJpóãÄçä=â~åå=áêÖÉåÇïçÜáå=~ìÑ=Ç~ë=cçêJ ãìä~ê=ÖÉòçÖÉå=ïÉêÇÉåK=bë=áëí=òìê=i~ìÑòÉáí=åáÅÜí=òì=ëÉÜÉåX=Éë=áëí=ìåïáÅÜíáÖI=ïç= Éë=~ìÑ=ÇÉã=cçêãìä~ê=éä~íòáÉêí=ïáêÇK=aÉäéÜá=îÉêÖáÄí=~ìíçã~íáëÅÜ=ÇáÉ=k~ãÉå= Timer1I=Timer2=ìëïK=ÑΩê=ÇáÉ=éä~íòáÉêíÉå=qáãÉêK= aÉê= lÄàÉâíáåëéÉâíçê= ÖáÄí= Ó= ïáÉ= áããÉê= Ó= ÇáÉ= j∏ÖäáÅÜâÉáí= îçêÉáåòìëíÉääÉåI= ïáÉ= ÇÉê=àÉïÉáäáÖÉ=qáãÉê=òì=_ÉÖáåå=ÇÉê=i~ìÑòÉáí=ÉáåÖÉêáÅÜíÉí=ëÉáå=ëçääK== aìêÅÜ= ÇÉå= qáãÉêJlÄàÉâíáåëéÉâíçê= ëáåÇ= ÖäÉáÅÜòÉáíáÖ= ~ìÅÜ= ÇáÉ= k~ãÉå= ïáÅÜíáÖÉê= éêçéÉêíáÉë= ÄÉâ~ååíI= ãáí= ÇÉåÉå= áååÉêÜ~äÄ= îçå= ~åÇÉêÉå= bêÉáÖåáëéêçòÉÇìêÉå= ~ìÑ= ÇÉå=a~íÉåâÉêå=ÉáåÉë=qáãÉêë=~âíáî=ìåÇ=é~ëëáî=òìÖÉÖêáÑÑÉå=ïÉêÇÉå=â~ååK== NMS= =
SKO== báåêáÅÜíìåÖ=ìåÇ=pí~êíÉáåëíÉääìåÖ=
= _áäÇ=SKPW=jÉÜêÉêÉ=qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ=
= _áäÇ=SKQW=qáãÉêJpóãÄçä=áå=aÉäéÜá=ìåÇ=aÉäéÜá=ULOMMR= aáÉ=ïáÅÜíáÖëíÉå=éêçéÉêíáÉëI=~äë=qáãÉêJbáÖÉåëÅÜ~ÑíÉå=ÉåíÜ~äíÉå=áå=ÇÉëëÉå=lÄàÉâíJ áåëéÉâíçêI=Ü~ÄÉå=ÇáÉ=k~ãÉå=Enabled=ìåÇ=IntervalK==
== _áäÇ=SKRW=sçêÉáåëíÉääìåÖ=ÇÉê=pí~êíJbáÖÉåëÅÜ~ÑíÉå= fëí=ÇáÉ=éêçéÉêíó= Enabled=~ìÑ= True=ÖÉëÉíòíI=ëç=ä®ìÑí=ÇÉê=qáãÉêI=ÇK=ÜK=Ç~ë=qáãÉêJbêJ ÉáÖåáë= íêáíí= ãáí= ÇÉã= ÉáåÖÉëíÉääíÉå= fåíÉêî~ää= ~ìÑK= jáí= Enabled:=False= ïáêÇ= ÇÉê= qáJ ãÉê=~åÖÉÜ~äíÉåI=çÜåÉ=Ç~ëë=Ç~ë=fåíÉêî~ää=îÉê®åÇÉêí=ïáêÇK=bêåÉìíÉ=rãëíÉääìåÖ=~ìÑ= Enabled:=True=ëí~êíÉí=ÇÉå=qáãÉê=ïáÉÇÉêK= jáí= ÇÉê= éêçéÉêíó= Interval= E^ÅÜíìåÖ= Ó= = åìê= Éáå= łlF= ïáêÇ= ÇáÉ= m~ìëÉ= òïáëÅÜÉå= òïÉá=qáãÉêJbêÉáÖåáëëÉå=áå=jáääáëÉâìåÇÉå=ÑÉëíÖÉäÉÖíK== NMT =
S= qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ= få= _áäÇ= SKR= áëí= ÇÉê= ÉêëíÉ= qáãÉêI= ÇÉê= îçå= aÉäéÜá= ÇÉå= k~ãÉå= Timer1= ÄÉâçããÉå= Ü~íI= ëç= ÉáåÖÉëíÉääíI= Ç~ëë= ëÉáå= qáãÉêJbêÉáÖåáë= Éáåã~ä= éêç= pÉâìåÇÉ= = Éáåíêáíí= ENMMM= jáääáëÉâìåÇÉå=Z=N=pÉâìåÇÉFK= • aáÉ=cêÉèìÉåò=îçå=qáãÉêå=áëí=áã=^ääÖÉãÉáåÉå=ÄÉÖêÉåòíW=bë=áëí=ëáååäçëI=ÉáåÉå= qáãÉê=~ìÑ=Éáå=ÉñíêÉã=âäÉáåÉë=fåíÉêî~ää=òì=ëÉíòÉåX=áã=báåòÉäåÉå=Ü®åÖí=ÇáÉ=ÇáÉJ ëÉë=jáåáã~äáåíÉêî~ää=îçå=îÉêëÅÜáÉÇÉåÉå=c~âíçêÉåI=òK=_K=ÇÉã=_ÉíêáÉÄëëóëíÉãI= ~ÄK=_Éá=aÉäéÜá=T=ÄÉíê®Öí=ÇÉê=âäÉáåëíã∏ÖäáÅÜÉ=tÉêí=RR=ãëK==
6.2.2 ==
Einfache Ereignisprozeduren
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 6= ÇáÉ= zipJa~íÉá= DKap06.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap06= ÇáÉ= mêçàÉâíJa~íÉá= proj_622.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap06=ÇáÉ=a~íÉá=proj_622.bdsproj=~ìëòìï®ÜäÉåK== = wìê= aÉãçåëíê~íáçå= ïçääÉå= ïáê= ÇêÉá= qáãÉê= ìåíÉêÉáå~åÇÉê= ~ìÑ= ÇÉã= cçêãìä~ê= éä~íòáÉêÉå=ìåÇ=Ç~åÉÄÉå=àÉïÉáäë=ÉáåÉ= pÅêçääÄ~ê=ëÉíòÉå=E_áäÇ=SKSFK=gÉÇÉ=pÅêçääÄ~ê= ÄÉëáíòí=ÇáÉëÉäÄÉ=pí~åÇ~êÇJpí~êíÉáåëíÉääìåÖW=jáåáãìã=0I=j~ñáãìã=100I=mçëáíáçå=0K==
== _áäÇ=SKSW=aêÉá=qáãÉêI=ÇêÉá=lÄàÉâíÉ=pÅêçääÄ~ê== ^ääÉ= ÇêÉá= qáãÉê= ïÉêÇÉå= ~âíáî= îçêÉáåÖÉëíÉääíI= ~ÄÉê= ãáí= îÉêëÅÜáÉÇÉåÉå= fåíÉêî~ääÉå= E_áäÇ=SKSFW=Timer1=âçããí=àÉÇÉ=pÉâìåÇÉI=Timer2=~ääÉê=O=pÉâìåÇÉåI=ìåÇ=Timer3=ä®ëëí= ëáÅÜ=~ã=ãÉáëíÉå=wÉáíW=bê=ä∏ëí=åìê=~ääÉê=îáÉê=pÉâìåÇÉå=ëÉáå=qáãÉêJbêÉáÖåáë=~ìëK==
= _áäÇ=SKTW=pí~êíÉáåëíÉääìåÖÉå=ÇÉê=ÇêÉá=qáãÉê= _Éá=ÇÉå=ÄáëÜÉê=ÄÉÜ~åÇÉäíÉå=îáëìÉääÉå=lÄàÉâíÉå=Ö~Ä=Éë=ÇìêÅÜïÉÖ=Ç~ë=pí~åÇ~êÇJ bêÉáÖåáë=ìåÇ=îáÉäÉ=~åÇÉêÉ=káÅÜíJpí~åÇ~êÇJbêÉáÖåáëëÉK==
NMU= =
SKO== báåêáÅÜíìåÖ=ìåÇ=pí~êíÉáåëíÉääìåÖ= táê=ãìëëíÉå=àÉïÉáäë=ÖÉå~ì=ΩÄÉêäÉÖÉåI=ÑΩê=ïÉäÅÜÉ=bêÉáÖåáëJ^êí=ÇÉê=o~ÜãÉå=ÇÉê= bêÉáÖåáëéêçòÉÇìê=ÄÉëÅÜ~ÑÑí=ïÉêÇÉå=ëçääíÉK== _Éáã= qáãÉê= ÖáÄí= Éë= åìê= Éáå= ÉáåòáÖÉë= bêÉáÖåáëI= ÑΩê= Ç~ë= ÉáåÉ= oÉ~âíáçå= éêçÖê~ãJ ãáÉêí= ïÉêÇÉå= â~åå= Ó= ÇáÉ= ÇáÉëÄÉòΩÖäáÅÜÉ= iáëíÉ= áã= lÄàÉâíáåëéÉâíçê= E_áäÇ= SKUF= ëÅÜêìãéÑí=ÑçäÖäáÅÜ=~ìÑ=ÉáåÉå=ÉáåòáÖÉå=báåíê~Ö=òìë~ããÉåK==
== _áäÇ=SKUW=iáëíÉ=ÇÉê=ã∏ÖäáÅÜÉå=bêÉáÖåáëëÉ=ÄÉáã=qáãÉê== báå=açééÉäâäáÅâ=áå=Ç~ë=äÉÉêÉ=cÉäÇ=åÉÄÉå= OnTimer=çÇÉê=Éáå=açééÉäâäáÅâ=~ìÑ=Ç~ë= qáãÉêJpóãÄçä=~ìÑ=ÇÉã=cçêãìä~ê=äáÉÑÉêí=ìåë=Ç~åå=ëçÑçêí=ÇÉå=o~ÜãÉå=ÑΩê=ÇáÉ=bêJ ÉáÖåáëéêçòÉÇìê=òìã=bêÉáÖåáë=qáãÉê=âçããí=EqáãÉêJbêÉáÖåáëFW== procedure TForm1.Timer1Timer(Sender: TObject); begin .............
//Inhalt der Ereignisprozedur
end;
hÉÜêÉå= ïáê= òì= ìåëÉêÉã= _ÉáëéáÉä= òìêΩÅâW= tÉåå= Ç~ë= àÉïÉáäáÖÉ= qáãÉêJbêÉáÖåáë= ÉáåíêáííI=ëçää=ëáÅÜ=ÇáÉ=mçëáíáçå=ÇÉë=oÉÖäÉêë=áå=ÇÉê=òìÖÉÜ∏êáÖÉå=pÅêçääÄ~ê=ìã=òÉÜå= báåÜÉáíÉå=å~ÅÜ=êÉÅÜíë=îÉêëÅÜáÉÄÉåW== procedure TForm1.Timer1Timer(Sender: TObject); begin ScrollBar1.Position:=ScrollBar1.Position+10 end; procedure TForm1.Timer2Timer(Sender: TObject); begin ScrollBar2.Position:=ScrollBar2.Position+10 end; procedure TForm1.Timer3Timer(Sender: TObject); begin ScrollBar3.Position:=ScrollBar3.Position+10 end;
få= ÇÉå= _áäÇÉêå= SKV= Äáë= SKNO= â∏ååÉå= ïáê= ïìåÇÉêÄ~ê= îÉêÑçäÖÉåI= ï~åå= ëáÅÜ= ïÉäJ ÅÜÉê=qáãÉê=ãÉäÇÉíW=t®ÜêÉåÇ=ÇÉê=oÉÖäÉê=ÇÉê=çÄÉêëíÉå= ScrollBar1=å~ÅÜ=àÉÇÉê=pÉJ âìåÇÉ= ïÉáíÉêêΩÅâí= ìåÇ= áå= ÇÉå= ÄÉíê~ÅÜíÉíÉå= ëáÉÄÉå= pÉâìåÇÉå= ëáÉÄÉåã~ä= å~ÅÜ= êÉÅÜíë=ÖÉï~åÇÉêí=áëíI=Ü~í=Éë=ÇÉê=oÉÖäÉê=ÇÉê=ìåíÉêëíÉå= ScrollBar3=~ìÑ=ÖÉê~ÇÉ=ÉáåÉ= sÉê®åÇÉêìåÖ= ÖÉÄê~ÅÜíX= Éê= ïΩêÇÉ= ëáÅÜ= Éêëí= ÄÉá= pÉâìåÇÉ= ~ÅÜí= òìã= òïÉáíÉå= j~ä= ÄÉïÉÖÉåK= = NMV =
S= qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ= =
= _áäÇ=SKVW=pí~êí=ìåÇ=páíì~íáçå=å~ÅÜ=ÉáåÉê=pÉâìåÇÉ=
= _áäÇ=SKNMW=k~ÅÜ=òïÉá=ìåÇ=ÇêÉá=pÉâìåÇÉå=
=== _áäÇ=SKNNW=k~ÅÜ=îáÉê=ìåÇ=ÑΩåÑ=pÉâìåÇÉå=
== _áäÇ=SKNOW=k~ÅÜ=ëÉÅÜë=ìåÇ=ëáÉÄÉå=pÉâìåÇÉå=
6.3
Arbeit mit Timern
6.3.1 ==
Start und Selbst-Stopp
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 6= ÇáÉ= zipJa~íÉá= DKap06.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap06= ÇáÉ= mêçàÉâíJa~íÉá= proj_631.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap06=ÇáÉ=a~íÉá=proj_631.bdsproj=~ìëòìï®ÜäÉåK== == jáí=_ÉÖáåå=ÇÉê=i~ìÑòÉáí=ëçää=Éêëí=Éáåã~ä=ÑΩåÑ=pÉâìåÇÉå=ä~åÖ=ΩÄÉêÜ~ìéí=åáÅÜíë=é~ëJ ëáÉêÉåK=a~åå=ëçää=ÖÉå~ì=Éáåã~ä=Ç~ë=qáãÉêJbêÉáÖåáë=ëí~ííÑáåÇÉåI=ÄÉá=ÇÉã=Éáå=oÉÖJ äÉê=ÉáåÉê=pÅêçääÄ~ê=òÉÜå=báåÜÉáíÉå=å~ÅÜ=êÉÅÜíë=ëéêáåÖíI=~åëÅÜäáÉ≈ÉåÇ=åáÉ=ïáÉÇÉêK== NNM= =
SKP== ^êÄÉáí=ãáí=qáãÉêå= i∏ëìåÖW= táê= ÄÉíê~ÅÜíÉå= òìê= aÉãçåëíê~íáçå= ÇáÉëã~ä= åìê= ÉáåÉå= qáãÉê= ìåÇ= ÉáåÉ= pÅêçääÄ~êK=fã=lÄàÉâíáåëéÉâíçê=ïáêÇ=ÇÉê=qáãÉê=~ìÑ=~âíáî=ìåÇ=~ìÑ=Éáå=fåíÉêî~ää=îçå= RMMM=ãë=îçêÄÉêÉáíÉí=E_áäÇ=SKNPFK=
= _áäÇ=SKNPW=cÉëíäÉÖìåÖÉå=ÑΩê=ÇÉå=_ÉÖáåå=ÇÉê=i~ìÑòÉáí== aáÉ=bêÉáÖåáëéêçòÉÇìê=ÄÉëÅÜêÉáÄí=Ç~åå=ÇÉå=oÉëí=ÇÉê=i∏ëìåÖ=ÇÉê=^ìÑÖ~ÄÉW= procedure TForm1.Timer1Timer(Sender: TObject); begin ScrollBar1.Position:=ScrollBar1.Position+10;
//Semikolon nötig
Timer1.Enabled:=False end;
jáí= ÇÉê= éêçéÉêíó= Enabled= â~åå= ~ìë= àÉÇÉê= bêÉáÖåáëéêçòÉÇìê= ~ìÑ= ÇÉå= a~íÉåâÉêå= ÇÉë= lÄàÉâíë= Timer1= òìÖÉÖêáÑÑÉå= ïÉêÇÉåK= a~ë= ïìêÇÉ= ÜáÉê= ÖÉåìíòíX= ÇÉê= qáãÉê= ëÅÜ~äíÉí=ëáÅÜ=ëÉäÄÉê=~ìëK=pç=ÉáåÑ~ÅÜ=áëí=Ç~ëK=
6.3.2 ==
Halt und Weitermachen
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 6= ÇáÉ= zipJa~íÉá= DKap06.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap06= ÇáÉ= mêçàÉâíJa~íÉá= proj_632.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap06=ÇáÉ=a~íÉá=proj_632.bdsproj=~ìëòìï®ÜäÉåK== == ^ìÑÖ~ÄÉW= wìë®íòäáÅÜ= òì= qáãÉê= ìåÇ= pÅêçääÄ~ê= ëçää= ëáÅÜ= åçÅÜ= Éáå= _ìííçå= ãáí= ÇÉê= ^åÑ~åÖëÄÉëÅÜêáÑíìåÖ= Halt= ~ìÑ= ÇÉã= cçêãìä~ê= ÄÉÑáåÇÉå= E_áäÇ= SKNQFK= aÉê= qáãÉêI= ÜáÉê=~ìÑ=ÉáåÉ=Ü~äÄÉ=pÉâìåÇÉ=ÉáåÖÉëíÉääíI=ëçää=ïáÉ=çÄÉå=äÉÇáÖäáÅÜ=ÇáÉ=mçëáíáçå=îÉêJ ëÅÜáÉÄÉåI=ïÉáíÉê=åáÅÜíëK==
== _áäÇ=SKNQW=e~äÄëÉâìåÇÉåJqáãÉêI=pÅêçääÄ~ê=ìåÇ=_ìííçå== _Éáã=ÉêëíÉå=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ëçää=ÇÉê=qáãÉê=~ìëÖÉëÅÜ~äíÉí=ïÉêÇÉå=ìåÇ=ÇáÉ= _ÉëÅÜêáÑíìåÖ=ÇÉë=_ìííçåë=ëçää=ïÉÅÜëÉäå=áå= WeiterK=_Éáã=å®ÅÜëíÉå=häáÅâ=~ìÑ=ÇÉå= _ìííçå= ëçää= ÇÉê= qáãÉê= ïáÉÇÉê= ÉáåÖÉëÅÜ~äíÉí= ïÉêÇÉåI= ÇáÉ= _ÉëÅÜêáÑíìåÖ= ïÉÅÜëÉäí= òì=Halt=ìåÇ=ëç=ïÉáíÉê=E_áäÇ=SKNRFK== NNN =
S= qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ= táê=ïçääÉå=ÇÉã=kìíòÉê=Ç~ãáí=ÇáÉ=j∏ÖäáÅÜâÉáí=ÖÉÄÉåI=Ç~ëë=Éê=ÇÉå=qáãÉê=ÄÉäáÉJ ÄáÖ=~åÜ~äíÉå=ìåÇ=ëé®íÉê=ïáÉÇÉê=ïÉáíÉêä~ìÑÉå=ä~ëëÉå=â~ååK==
== _áäÇ=SKNRW=pí~êíI=píçéé=ãáí=ÉêëíÉã=häáÅâI=ïÉáíÉê=ãáí=òïÉáíÉã=häáÅâ== pÉÜÉå=ïáê=ìåë=òìÉêëí=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=qáãÉêJbêÉáÖåáë=~åW= procedure TForm1.Timer1Timer(Sender: TObject); begin ScrollBar1.Position:=ScrollBar1.Position+10 end;
sáÉä=áåíÉêÉëë~åíÉê=Ç~ÖÉÖÉå=áëí=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=bêÉáÖåáë=häáÅâ=~ìÑ=ÇÉå= _ìííçå=Ó=áå=áÜê=ïáêÇ=ÇáÉ=^äíÉêå~íáîÉ=~ìë=ÇÉã=łk~ÅÜííáëÅÜä~ãéÉåJmêçÖê~ãã=~ìë= ^ÄëÅÜåáíí=RKOKN=ïáÉÇÉêÜçäí=ìåÇ=~ìëÖÉÄ~ìíK= §ÄÉê= ÇáÉ= ^ÄÑê~ÖÉ= ÇÉê= _ÉëÅÜêáÑíìåÖ= ÇÉë= _ìííçåë= ëíÉääí= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= ÑÉëíI= ïÉäÅÜÉ=páíì~íáçå=ÖÉê~ÇÉ=îçêäáÉÖíK=píÉÜí=ÇáÉ=_ÉëÅÜêáÑíìåÖ=~ìÑ= Halt=EÇ~åå=ä®ìÑí=ÇÉê= qáãÉêFI= ïÉêÇÉå= ÇáÉ= _ÉÑÉÜäÉ= ÇÉë= g~JwïÉáÖÉë= ~ìëÖÉÑΩÜêíW= aáÉ= _ÉëÅÜêáÑíìåÖ= ïÉÅÜJ ëÉäíI=ÇÉê=qáãÉê=ïáêÇ=~ìëÖÉëÅÜ~äíÉíK== procedure TForm1.Button1Click(Sender: TObject); begin if Button1.Caption='Halt' then begin
// JA-Zweig
Button1.Caption:='Weiter'; Timer1.Enabled:=False end else begin
// NEIN-Zweig
Button1.Caption:='Halt'; Timer1.Enabled:=True end end;
^åÇÉêåÑ~ääë= ïÉêÇÉå= ÇáÉ= ÄÉáÇÉå= _ÉÑÉÜäÉ= ÇÉë= kÉáåJwïÉáÖÉë= ~ìëÖÉÑΩÜêíW= aáÉ= _ÉJ ëÅÜêáÑíìåÖ=ïÉÅÜëÉäí=ÉêåÉìíI=ÇÉê=qáãÉê=ïáêÇ=ïáÉÇÉê=~åÖÉëÅÜ~äíÉíK== aáÉ= ^ìëå~ÜãÉêÉÖÉä= â~åå= ÜáÉê= åáÅÜí= áå= ^åëéêìÅÜ= ÖÉåçããÉå= ïÉêÇÉåI= Ç~= ëçJ ïçÜä=áã=g~JwïÉáÖ=~äë=~ìÅÜ=áã=kÉáåJwïÉáÖ=àÉ=òïÉá=_ÉÑÉÜäÉ=ëíÉÜÉåK== wì= ÄÉ~ÅÜíÉå= ëáåÇ= ÇÉëÜ~äÄ= ÇáÉ= ÄÉáÇÉå= íêÉååÉåÇÉå= pÉãáâçäçåë= òïáëÅÜÉå= ÇÉå= ÄÉáÇÉå=_ÉÑÉÜäÉå=áå=g~J=ìåÇ=kÉáåJwïÉáÖK= NNO= =
SKP== ^êÄÉáí=ãáí=qáãÉêå=
6.3.3 ==
Blinkende Schrift
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 6= ÇáÉ= zipJa~íÉá= DKap06.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap06= ÇáÉ= mêçàÉâíJa~íÉá= proj_633.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap06=ÇáÉ=a~íÉá=proj_633.bdsproj=~ìëòìï®ÜäÉåK== == ^ìÑÖ~ÄÉW= báå= i~ÄÉä= ãáí= ÇÉê= pí~êíÄÉëÅÜêáÑíìåÖ= ^ÅÜíìåÖ>= ïáêÇ= ~ìÑ= ÇÉã= cçêãìä~ê= éä~íòáÉêíK=aáÉ=pÅÜêáÑí=â~åå=ëÅÜ∏å=Öêç≈=ëÉáåI=òìã=_ÉáëéáÉä=OQéí=ìåÇ=ÑÉííK=k~ÅÜ=òïÉá= pÉâìåÇÉå=ëçää=ÇáÉ=pÅÜêáÑí=ÑΩê=ÉáåÉ=pÉâìåÇÉ=îÉêëÅÜïáåÇÉåI=Ç~åå=ïáÉÇÉê=òïÉá=pÉJ âìåÇÉå= òì= äÉëÉå= ëÉáåI= Ç~åå= ïáÉÇÉê= ÑΩê= ÉáåÉ= pÉâìåÇÉ= îÉêëÅÜïáåÇÉåI= ìåÇ= ëç= ïÉáíÉêK=táÉ=ÇáÉ=§ÄÉêëÅÜêáÑí=ëÅÜçå=ë~Öí=Ó=ÖÉëìÅÜí=áëí=ÉáåÉ=ÄäáåâÉåÇÉ=pÅÜêáÑíK==
== _áäÇ=SKNSW=i~ÄÉä=ìåÇ=òïÉá=qáãÉê= táÉ= â~åå= ã~å= ÇáÉëÉ= ^ìÑÖ~ÄÉ= ä∏ëÉå\= _áäÇ= SKNS= òÉáÖí= ÉáåÉå= i∏ëìåÖë~åë~íòW= táê= ~êÄÉáíÉå= ãáí= òïÉá=qáãÉêåI=ÇáÉ=ëáÅÜ= ÖÉÖÉåëÉáíáÖ=ÉáåJ= ìåÇ=~ìëëÅÜ~äíÉåK= aÉê=ÉêëíÉ= qáãÉê=áëí=~åÑ~åÖë=~âíáîI=âçããí=å~ÅÜ=OMMM=jáääáëÉâìåÇÉå=E_áäÇ=SKNTFK== aÉê=òïÉáíÉ=qáãÉê=áëí=~åÑ~åÖë=~ìëÖÉëÅÜ~äíÉíX=ïÉåå=Éê=ÉáåÖÉëÅÜ~äíÉí=áëíI=ãÉäÇÉí=Éê= ëáÅÜ=å~ÅÜ=àÉïÉáäë=NMMM=jáääáëÉâìåÇÉåK==
== _áäÇ=SKNTW=wïÉá=qáãÉê= aáÉ=ÄÉáÇÉå=bêÉáÖåáëéêçòÉÇìêÉå=ä~ëëÉå=Ç~ë=sçêÖÉÜÉå=ÉêâÉååÉåW== procedure TForm1.Timer1Timer(Sender: TObject); begin Label1.Caption:=''; Timer1.Enabled:=False; Timer2.Enabled:=True end; procedure TForm1.Timer2Timer(Sender: TObject); begin Label1.Caption:='Achtung!'; Timer1.Enabled:=True; Timer2.Enabled:=False end;
NNP =
S= qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ= k~ÅÜ=ÇÉã=pí~êí=ï~êíÉí= Timer1I=Éë=îÉêÖÉÜÉå=òïÉá=pÉâìåÇÉåK=a~åå=âçããí= ëÉáå= qáãÉêJbêÉáÖåáëI= Timer1= ä∏ëÅÜí= ÇÉå= fåÜ~äí= ÇÉë= i~ÄÉäI= ëÅÜ~äíÉí= ëáÅÜ= ëÉäÄÉê= ~ìëI= ëÅÜ~äíÉí=Ç~ÑΩê=Timer2=~åK== kìå= îÉêÖÉÜí= ÉáåÉ= pÉâìåÇÉI= áå= ÇÉê= áã= i~ÄÉä= åáÅÜíë= ëíÉÜíI= Ç~åå= âçããí= ÇÉê= Timer2K=bê=ëÅÜêÉáÄí=ÉêåÉìí=áåë=i~ÄÉäI=ëÅÜ~äíÉí=ëáÅÜ=Ç~åå=ëÉäÄÉê=~ìëI=ëÅÜ~äíÉí= Timer1= ÉáåK= Timer1=ï~êíÉí=ïáÉÇÉê=ëÉáåÉ=òïÉá=pÉâìåÇÉåI=Ç~åå=âçããí=ëÉáå=bêÉáÖåáë=ìåÇ= ëç=ïÉáíÉêK== §ÄêáÖÉåë=Ó=ëç=Éáå=i~ÄÉä=Ü~í=ÉáåÉ=ÄÉëçåÇÉêÉ=báÖÉåëÅÜ~ÑíW=bë=é~ëëí=ëáÅÜ=áå=ëÉáåÉê= dê∏≈É=ÇÉã=fåÜ~äí=~åK=a~ë=ÄÉÇÉìíÉí=áå=ìåëÉêÉã=c~ää=E_áäÇ=SKNUFI=Ç~ëë=Ç~ë=i~ÄÉä= ÉñíêÉã=âäÉáå=ïáêÇI=ïÉåå=åáÅÜíë=Çêáå=ëíÉÜíK=tçääÉå=ïáê=Ç~ë\=
== _áäÇ=SKNUW=táêâìåÖ=îçå=Autosize=True= tÉåå=åáÅÜí=ãΩëëÉå=ïáê=áã=lÄàÉâíáåëéÉâíçê=ÇÉë=i~ÄÉäë=ÇáÉ=báÖÉåëÅÜ~Ñí=EéêçéÉêíóF= AutoSize=~ìÑ= False=ëÉíòÉå=Ó=Ç~åå=ÄÉÜ®äí=Ç~ë=i~ÄÉä=ëÉáåÉ=cçêãI=~ìÅÜ=ïÉåå=ÇÉê= fåÜ~äí=ëáÅÜ=®åÇÉêíK==
6.4
Permanente Prüfung im Hintergrund tÉÅÜëÉäå= ïáê= ÇçÅÜ= ëÅÜåÉää= Éáåã~ä= òì= ìåëÉêÉã= ÖìíÉå= ~äíÉå= qÉñíîÉê~êÄÉáíìåÖëJ éêçÖê~ãã= tloa= ìåÇ= ë~ÖÉå= a^qbfaor`hbkK= pÅÜçå= ÉêëÅÜÉáåí= Ç~ë= ÉåíëéêÉJ ÅÜÉåÇÉ= aá~äçÖÑÉåëíÉêI= ìåÇ= äáåâë= ìåíÉå= ïÉêÇÉå= ïáê= ÖÉÑê~ÖíI= ï~ë= ïáê= ÇÉåå= ëç= ÇêìÅâÉå= ïçääÉå= E_áäÇ= SKNVFK= pí~åÇ~êÇã®≈áÖ= áëí= Alles= îçêÉáåÖÉëíÉääíK= qêáÑÑí= ~ìÅÜ= ãÉáëí=òìK==
== _áäÇ=SKNVW=tloaJaá~äçÖÑÉåëíÉê=òìã=pÉáíÉåÄÉêÉáÅÜ=ÄÉáã=aêìÅâÉå= j~åÅÜã~ä= ~ääÉêÇáåÖë= ã∏ÅÜíÉ= ã~å= åìê= ÉáåÉ= ÄÉëíáããíÉ= pÉáíÉ= ~ìë= ÇÉã= aêìÅâÉê= âçããÉå= ä~ëëÉåK= cçäÖäáÅÜ= ïÉÅÜëÉäí= ã~å= áå= Ç~ë= qÉñíÑÉåëíÉê= åÉÄÉå= ÇÉã= o~ÇáçJ Äìííçå=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ=Seiten=ìåÇ=íê®Öí=ÇáÉ=ÖÉïΩåëÅÜíÉå=pÉáíÉåò~ÜäÉå=ÉáåK== t~ë=é~ëëáÉêí=~ÄÉê=ÖäÉáÅÜòÉáíáÖI=ïáÉ=ÇìêÅÜ=Éáå=tìåÇÉê\=^ìÅÜ=ïÉåå=ïáê=~äë=kìíJ òÉê= ÇÉå= o~ÇáçÄìííçå= ãáí= ÇÉê= _ÉëÅÜêáÑíìåÖ= Seiten= ΩÄÉêÜ~ìéí= åáÅÜí= ÄÉÇáÉåí= Ü~J ÄÉå=Ó=Éê=ÉêÜ®äíI=î∏ääáÖ=çÜåÉ=ìåëÉê=wìíìåI=~ìíçã~íáëÅÜI=éä∏íòäáÅÜ=ÇáÉ=åìå=òìíêÉÑJ ÑÉåÇÉ=j~êâáÉêìåÖ=E_áäÇ=SKOMFK== NNQ= =
SKQ== mÉêã~åÉåíÉ=mêΩÑìåÖ=áã=eáåíÉêÖêìåÇ= =
= _áäÇ=SKOMW=báåÖÉíê~ÖÉåÉ=pÉáíÉåò~ÜäÉå= tÉê=~ÄÉê=í~í=Ç~ë\=gÉíòí=ïáëëÉå=ïáê=Éë=ìåÇ=â∏ååÉå=Éë=ëÉäÄëí=éêçÖê~ããáÉêÉåW=fã= eáåíÉêÖêìåÇ=ä®ìÑí=çÑÑÉåëáÅÜíäáÅÜ=Éáå=qáãÉêI=ÇÉê=ëç=çÑí=ïáÉ=ã∏ÖäáÅÜ=Ç~ë=qÉñíÑÉåJ ëíÉê= íÉëíÉíK= táêÇ= Ç~ÄÉá= éä∏íòäáÅÜ= Éáå= fåÜ~äí= ÑÉëíÖÉëíÉääí= ïáêÇ= ÉÄÉå= ÇÉê= é~ëëÉåÇÉ= o~ÇáçÄìííçå=òìÖÉëÅÜ~äíÉíK== mêΩÑÉå=ïáê=âçåëíêìâíáî=å~ÅÜI=çÄ=ìåëÉêÉ=sÉêãìíìåÖ=ëíáããíK=mä~íòáÉêÉå=ïáê=òìÉêëí= ~ìÑ=ÇÉã=cçêãìä~ê=ÉáåÉ=ÉåíëéêÉÅÜÉåÇÉ=o~ÇáçÖêìééÉ=ãáí=qÉñíÑÉåëíÉê=ìåÇ=qáãÉêK= == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 6= ÇáÉ= zipJa~íÉá= DKap06.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap06= ÇáÉ= mêçàÉâíJa~íÉá= proj_64.dpr= ~ìëòìï®ÜäÉåK= táêÇ= ãáí= aÉäéÜá= ULOMMR= ÖÉ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap06=ÇáÉ=a~íÉá=proj_64.bdsproj=~ìëòìï®ÜäÉåK== = få=áÜê=ëçêÖÉå=ïáê=ΩÄÉê=ÇáÉ=báÖÉåëÅÜ~Ñí= Items=ãáí=ÇÉã=píêáåÖäáëíÉåJbÇáíçê=ÑΩê=ÇÉå= ~åÑ®åÖäáÅÜÉå= fåÜ~äíK= a~ë= wÉáÅÜÉå= &= âÉååòÉáÅÜåÉí= Ç~ÄÉá= ÇÉå= pÅÜåÉääï~ÜäÄìÅÜJ ëí~ÄÉå=EëáÉÜÉ=^ÄëÅÜåáíí=PKQFK=
== _áäÇ=SKONW=o~ÇáçÖêçìé=ìåÇ=píêáåÖäáëíÉåJbÇáíçêI=pí~êíã~êâáÉêìåÖ= aÉê= ItemIndex=ÇÉê=o~ÇáçÖêìééÉ=ãáí=ÇÉã=k~ãÉå= RadioGroup1=ïáêÇ=~ìÑ=kìää=ÖÉJ ëÉíòí=Ó=ÇáÉ=j~êâáÉêìåÖ=ëçää=~åÑ~åÖë=å~íΩêäáÅÜ=~ìÑ=ÇÉê=ÉêëíÉå=wÉáäÉI=~ìÑ= Alles=ëíÉJ ÜÉåK== a~ë=qáãÉêJpóãÄçä=ïáêÇ=áêÖÉåÇïçÜáå=~ìÑ=Ç~ë=cçêãìä~ê=ÖÉòçÖÉåX=ÇÉê=qáãÉê=ïáêÇ= ~ìÑ=ÉáåÉ=ÜçÜÉ=cêÉèìÉåò=EòK_K=RR=ãëF=ÉáåÖÉëíÉääíI=ìåÇ=å~íΩêäáÅÜ=ëçää=Éê=îçã=pí~êí= ïÉÖ=~êÄÉáíÉå=E_áäÇ=SKOOFK= NNR =
S= qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ= kìå=Äê~ìÅÜÉå=ïáê=åìê=åçÅÜ=ÉáåÉ=ÉáåòáÖÉ=bêÉáÖåáëéêçòÉÇìê=ãáí=fåÜ~äí=òì=îÉêëÉJ ÜÉåI=å®ãäáÅÜ=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=qáãÉêJbêÉáÖåáëW== procedure TForm1.Timer1Timer(Sender: TObject); begin if Edit1.Text'' then RadioGroup1.ItemIndex:=2 end;
= _áäÇ=SKOOW=pí~êíÉáåëíÉääìåÖ=ÑΩê=ÇÉå=qáãÉê= pç=ÉáåÑ~ÅÜ=áëí=Ç~ëW=tÉåå=ÇÉê=qáãÉê=áå=ëÉáåÉê=~åÇ~ìÉêåÇÉå=mêΩÑí®íáÖâÉáíI=ìåÖÉJ Ñ®Üê= ~ÅÜíòÉÜå= j~ä= éêç= pÉâìåÇÉI= éä∏íòäáÅÜ= ÉáåÉ= åáÅÜíäÉÉêÉ= qÉñíÄçñ= ÄÉãÉêâíI= ëÅÜ~äíÉí=Éê=ÉÄÉå=áå=ÇÉê=o~ÇáçÖêìééÉ=~ìÑ=ÇÉå=ÇêáííÉå=o~ÇáçÄìííçå=ìãK== ^ääÉêÇáåÖë= Ü~ÄÉå= ïáê= åìê= ÇáÉ= e®äÑíÉ= éêçÖê~ããáÉêíK= t~ë= ïáêÇI= ïÉåå= ÇÉê= kìíòÉê= ëáÅÜ= éä∏íòäáÅÜ= ~åÇÉêë= ÄÉëáååí= ìåÇ= ÇáÉ= pÉáíÉåò~Üä= ïáÉÇÉê= ÜÉê~ìë= ëíêÉáÅÜí\= t~ë= ã~ÅÜí=tloa=Ç~åå\=tloa=ëÅÜ~äíÉí=Ç~åå=~ìÑ=Alles=òìêΩÅâK=a~ë=â∏ååÉå=ïáê=~ìÅÜW== procedure TForm1.Timer1Timer(Sender: TObject); begin if Edit1.Text'' then RadioGroup1.ItemIndex:=2 else RadioGroup1.ItemIndex:=0 end;
a~ë=dÉÜÉáãåáë=áëí=ÖÉäΩÑíÉíW== • pÅÜÉáåÄ~ê=~ìíçã~íáëÅÜÉë=wìJ=çÇÉê=^ÄëÅÜ~äíÉå=îçå=píÉìÉêÉäÉãÉåíÉå=áå=tçêÇ= çÇÉê= bñÅÉä= çÇÉê= mçïÉêmçáåí= çÇÉê= àÉÇÉê= ~åÇÉêÉå= táåÇçïëJ^åïÉåÇìåÖ= Ä~J ëáÉêí=~ìÑ=åáÅÜíë=~åÇÉêÉã=~äë=~ìÑ=ãáíä~ìÑÉåÇÉå=mêΩÑJqáãÉêåI=ÇáÉ=áå=pÉâìåÇÉåJ ÄêìÅÜíÉáäÉå=ÇáÉ=páíì~íáçå=~å=ÇÉå=ëáÅÜíÄ~êÉå=qÉáäÉå=~ääÉê=áåíÉêÉëëáÉêÉåÇÉå=îáëìJ ÉääÉå=lÄàÉâíÉ=ÄÉçÄ~ÅÜíÉå=ìåÇ=ëçÑçêí=é~ëëÉåÇ=êÉ~ÖáÉêÉåK=
6.5
Rot-Gelb-Grün: Die Ampel an der Kreuzung
6.5.1
Ganze Zahlen in wiederholter Folge
c~åÖÉå=ïáê=âäÉáå=~åW=báå=qáãÉê=ìåÇ=ÉáåÉ=pÅêçääÄ~ê=ïÉêÇÉå=~ìÑ=ÉáåÉã=cçêãìä~ê= éä~íòáÉêíK=aÉê=qáãÉê=ãáí=ÇÉã=k~ãÉå= Timer1=ëçää=ëçÑçêí=~âíáî=ëÉáåI=ÇáÉ=cêÉèìÉåò= ëçää= ÉáåÉ= pÉâìåÇÉ= ÄÉíê~ÖÉå= E_áäÇ= SKOPFK= aáÉ= pÅêçääÄ~ê= ãáí= ÇÉã= k~ãÉå= ScrollBar1=ïáêÇ=îçêÉáåÖÉëíÉääí=ãáí=jáåáãìã=1I=j~ñáãìã=4I=mçëáíáçå=1K== NNS= =
SKR== oçíJdÉäÄJdêΩåW=aáÉ=^ãéÉä=~å=ÇÉê=hêÉìòìåÖ= tÉåå=Ç~ë=qáãÉêJbêÉáÖåáë=Éáåíêáíí=ëçää=ëáÅÜ=ÇáÉ=mçëáíáçå=ÇÉë=oÉÖäÉêë=ìã=ÉáåÉ=báåJ ÜÉáí= å~ÅÜ= êÉÅÜíë= îÉêëÅÜáÉÄÉåK= pçääíÉ= ÇáÉ= mçëáíáçå= àÉÇçÅÜ= ~ìÑ= ÇÉå= tÉêí= 4= âçãJ ãÉå= áëí= ëáÉ= ïáÉÇÉê= ~ìÑ= 1= òì= ëÉíòÉåK= a~ë= ÜÉá≈íI= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= ëçää= Ç~ÑΩê= ëçêÖÉåI= Ç~ëë= ÇÉê= oÉÖäÉê= ÇÉê= pÅêçääÄ~ê= é~ìëÉåäçë= ÇáÉ= w~ÜäÉåÑçäÖÉ= 1234 123412...=ÇìêÅÜä®ìÑíK==
== _áäÇ=SKOPW=pí~êíÉáåëíÉääìåÖÉå= aÉê=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ãìëë=çÑÑÉåëáÅÜíäáÅÜ=ãáí=eáäÑÉ=îçå=qÉëíë=çÇÉê=ÉáJ åÉê=^äíÉêå~íáîÉ=Ç~ÑΩê=ëçêÖÉåI=Ç~ëë=ÇÉê=oÉÖäÉê=åáÅÜí=êÉÅÜíë=ÜÉê~ìëï~åÇÉêíW= procedure TForm1.Timer1Timer(Sender: TObject); begin if Scrollbar1.Position < 4 then Scrollbar1.Position:=Scrollbar1.Position+1 else Scrollbar1.Position:=1 end;
sÉêëìÅÜÉå=ïáêI=ÇáÉëÉäÄÉ=táêâìåÖ=ãáí=òïÉá=ÉáåÑ~ÅÜÉå=qÉëíë=òì=ÉêòáÉäÉåW= procedure TForm1.Timer1Timer(Sender: TObject); begin if Scrollbar1.Position== cçäÖäáÅÜ=ëÉíòí=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=å~ÅÜ=ÇÉê= 3=ëçÑçêí=~ìÑ=ÇáÉ= 1=òìêΩÅâK=aáÉ=4=ïáêÇ= åáÉ=ÉêêÉáÅÜíK=táÉÇÉê=Éáå=_ÉáëéáÉä=Ç~ÑΩêI=Ç~ëë=ÇáÉ=^äíÉêå~íáîÉ=ÖÉÄê~ìÅÜí=ïáêÇK=
NNT =
S= qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ=
6.5.2 ==
Die Verkehrsampel
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 6= ÇáÉ= zipJa~íÉá= DKap06.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap06= ÇáÉ= mêçàÉâíJa~íÉá= proj_652.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap06=ÇáÉ=a~íÉá=proj_652.bdsproj=~ìëòìï®ÜäÉåK== = wìÉêëí=òÉáÖí=ÇáÉ=^ãéÉä=ÖÉäÄ=Ó=cêΩÜ~ìÑëíÉÜÉê=ïáëëÉå=Ç~ëK=a~åå=âçããí=oçíI=Ç~åå= oçí=éäìë=dÉäÄI=Ç~åå=dêΩåI=Ç~å~ÅÜ=ïáÉÇÉê=dÉäÄK=a~ë=áëí=ÇÉê=wóâäìëI=ÇÉå=ïáê=~ìÑ= ÉáåÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=å~ÅÜÄáäÇÉå=ïçääÉåK== aÉê=wóâäìë=ÄÉëíÉÜí=~ìë=îáÉê=mÜ~ëÉåI=ÇáÉ=ëáÅÜ=ïáÉÇÉêÜçäÉåK=hìêòÉë=k~ÅÜÇÉåâÉå= Ó=Ç~ë=Ü~ííÉå=ïáê=ÇçÅÜ=ÉÄÉå=ëÅÜçå=Éáåã~äI=Ç~=ï~êÉå=Éë=ÇáÉ=îáÉê=píÉääìåÖÉå=ÇÉë= oÉÖäÉêëI=ÇáÉ=áããÉê=ïáÉÇÉêâÉÜêíÉåK== a~=Ü~ÄÉå=ïáê=ÇçÅÜ=ÇáÉ=êáÅÜíáÖÉ=fÇÉÉW=táê=îÉêâåΩéÑÉå=ÇáÉ=píÉääìåÖÉå=ÇÉë=oÉÖJ äÉêë=ãáí=ÉåíëéêÉÅÜÉåÇÉê=^ãéÉä~åòÉáÖÉW== píÉääìåÖ=NW=dÉäÄ= píÉääìåÖ=OW=oçí= píÉääìåÖ=PW=oçí=éäìë=dÉäÄ= píÉääìåÖ=QW=dêΩå= pÉíòÉå= ïáê= ÇáÉ= fÇÉÉ= ìãW= wìÉêëí= Äê~ìÅÜÉå= ïáê= ÉáåÉ= ^ãéÉäK= aáÉ= ÇêÉá= i~ãéÉå= ãΩëëÉå=~ìÑ=ÉáåÉê=dêìåÇéä~ííÉ=ÄÉÑÉëíáÖí=ïÉêÇÉåK=a~ÑΩê=ÄáÉíÉí=ëáÅÜ=Éáå=m~åÉä=~å= E_áäÇ= SKOQFI= Ç~ë= ëáÅÜ= áå= aÉäéÜá= T= ~ìÑ= ÇÉã= oÉÖáëíÉêÄä~íí= pq^ka^oa= ÇÉê= hçãéçJ åÉåíÉåé~äÉííÉ= ìåÇ= áå= aÉäéÜá= ULOMMR= áå= ÇÉê= ÖäÉáÅÜå~ãáÖÉå= h~íÉÖçêáÉ= ÇÉê= qççäJ m~äÉííÉ=ÄÉÑáåÇÉíK==
== _áäÇ=SKOQ=píÉìÉêÉäÉãÉåí=Panel=áå=aÉäéÜá=T=ìåÇ=aÉäéÜá=ULOMMR= fã=lÄàÉâíáåëéÉâíçê=ï®ÜäÉå=ïáê=~äë=pí~êíÑ~êÄÉ=ÑΩê=Ç~ë=m~åÉä=ÉáåÉ=åÉìíê~äÉ=c~êÄÉ= EbáÖÉåëÅÜ~Ñí= Color=ÉåíëéêÉÅÜÉåÇ=îçêï®ÜäÉåFI=ÇáÉ=_ÉëÅÜêáÑíìåÖ=EbáÖÉåëÅÜ~Ñí= CaptionF=ä∏ëÅÜÉå=ïáêK= a~åå=ïÉêÇÉå=ÇêÉá=i~ÄÉäë=ìåíÉêÉáå~åÇÉê=~ìÑ=Ç~ë=m~åÉä=ÖÉòçÖÉå=E_áäÇ=SKORFK=fÜêÉ= báÖÉåëÅÜ~Ñí=AutoSize=ïáêÇ=~ìÑ=False=ÖÉëÉíòíX=Ç~ãáí=îÉêÜáåÇÉêå=ïáê=Ç~ë=pÅÜêìãéJ ÑÉå= ÇÉê= i~ÄÉäë= ÄÉá= ÑÉÜäÉåÇÉê= _ÉëÅÜêáÑíìåÖK= aáÉ= c~êÄÉå= ÇÉê= i~ÄÉäë= ïÉêÇÉå= îçå= çÄÉå=å~ÅÜ=ìåíÉå=ãáí=êçíI=ÖÉäÄ=ìåÇ=ÖêΩå=ÉáåÖÉëíÉääíK= t~ë=ëçää=òìÉêëí=òì=ëÉÜÉå=ëÉáå=Ó=~ÅÜ=à~I=Ç~ë=dÉäÄ=áå=ÇÉê=jáííÉK=cçäÖäáÅÜ=ï®ÜäÉå= ïáê=ÑΩê=ÇáÉ=pí~êíÉáåëíÉääìåÖ=ÇÉë=çÄÉêÉå=i~ÄÉäë=áå=ÇÉê=báÖÉåëÅÜ~Ñí= Visible=ÇáÉ=_ÉJ äÉÖìåÖ=FalseI=ÉÄÉåëç=False=ÑΩê=ÇáÉ=páÅÜíÄ~êâÉáí=ÇÉë=ìåíÉêÉå=i~ÄÉäëK= _Éá=_ÉÖáåå=ÇÉê=i~ìÑòÉáíI=_áäÇ=SKOS=òÉáÖí=ÉëI=áëí=åìê=Ç~ë=ãáííäÉêÉ=i~ÄÉä=dÉäÄ=òì=ëÉJ ÜÉåI=ÇáÉ=pÅêçääÄ~ê=ëíÉÜí=~ìÑ=ÇÉã=Epí~êíJFtÉêí=báåëI=ÇÉê=qáãÉê=ÄÉÖáååí=ëÉáå=tÉêâK== == = NNU= =
SKR== oçíJdÉäÄJdêΩåW=aáÉ=^ãéÉä=~å=ÇÉê=hêÉìòìåÖ= =
= _áäÇ=SKORW=sçêÄÉêÉáíìåÖ=ÇÉê=^ãéÉäëáãìä~íáçå=
= _áäÇ=SKOSW=_ÉÖáåå=ÇÉê=i~ìÑòÉáí= t~ë= áëí= òì= íìå\= tÉåå= ÇÉê= qáãÉê= å~ÅÜ= ÉáåÉê= pÉâìåÇÉ= Ç~ë= ÉêëíÉ= j~ä= âçããíI= ïÉåå=ÇáÉ=mçëáíáçå=ÇÉë=oÉÖäÉêë=~ìÑ=ÇáÉ=2=ëéêáåÖí=áëí=oçí=ëáÅÜíÄ~ê=òì=ã~ÅÜÉåI=dÉäÄ= ïáêÇ=ìåëáÅÜíÄ~ê=ìåÇ=dêΩå=ÄäÉáÄí=ìåëáÅÜíÄ~êW== if Scrollbar1.Position=2 then begin Label1.Visible:=True;Label2.Visible:=False;Label3.Visible:=False end;
c~ääë= ÄÉáã= báåíêÉíÉå= ÇÉë= qáãÉêJbêÉáÖåáëëÉë= ÇáÉ= mçëáíáçå= ÇÉë= oÉÖäÉêë= ~ìÑ= ÇÉê= 3= ëÉáå=ëçääíÉ=ëçää=łoçí=ìåÇ=łdÉäÄ=ÖÉãÉáåë~ã=ÉêëÅÜÉáåÉåW= if Scrollbar1.Position=3 then begin Label1.Visible:=True;Label2.Visible:=True;Label3.Visible:=False end;
pç= ÖÉÜí= Éë= ïÉáíÉêX= ëÉÜÉå= ïáê= ìåë= ÇÉå= oÉëí= ÖäÉáÅÜ= áå= ÇÉê= âçãéäÉííÉå= bêÉáÖåáëJ éêçòÉÇìê=òìã=qáãÉêJbêÉáÖåáë=~åK=fã=_áäÇ=SKOT=â~åå=Ç~ë=tÉÅÜëÉäëéáÉä=òïáëÅÜÉå= ÇÉê=mçëáíáçå=ÇÉë=oÉÖäÉêëI=ÇáÉ=ÇìêÅÜ=ÇÉå=qáãÉê=ÖÉëíÉìÉêí=ïáêÇI=ìåÇ=ÇÉê=ÉåíëéêÉJ ÅÜÉåÇÉå= ^ãéÉäJ^åòÉáÖÉ= ÑΩê= ÇÉå= pí~êí= ÇÉê= i~ìÑòÉáí= ìåÇ= ÇáÉ= ÉêëíÉå= îáÉê= pÉâìåJ ÇÉå=Ç~å~ÅÜ=ÄÉçÄ~ÅÜíÉí=ïÉêÇÉåK= NNV =
S= qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ= procedure TForm1.Timer1Timer(Sender: TObject); begin if Scrollbar1.Position=aêÉáã~ä=Ñ~äëÅÜ>=k~íΩêäáÅÜ=ÄÉå∏íáÖÉå=ïáê=ëáÉ=åçÅÜ=Ó=~ÄÉê=ïáê=ãΩëëÉå=ëáÉ= åáÅÜí= ãÉÜê= ëÉÜÉåK= a~ë= áëí= Éáå= ÉåíëÅÜÉáÇÉåÇÉê= råíÉêëÅÜáÉÇK= pÉíòÉå= ïáê= ÑΩê= ÇáÉ= Scrollbar1=ÇáÉ=pí~êíÉáÖÉåëÅÜ~Ñí= Visible=~ìÑ= FalseI=â∏ååÉå=ïáê=àÉÇÉã=kìíòÉê=ïáÉ= áå=_áäÇ=SKOU=ÉáåÉ=éÉêÑÉâíÉ=^ãéÉä=îçêëéáÉäÉåI=ÇáÉ=áã=pÉâìåÇÉåí~âí=Äê~î=ÇáÉ=c~êJ ÄÉå=ïÉÅÜëÉäíK== = NOM= =
SK=S= aÉê=sáÉêòóäáåÇÉêJjçíçê= =
= _áäÇ=SKOUW=råëáÅÜíÄ~êÉI=~ÄÉê=ïáêâëÉåÇÉ=pÅêçääÄ~ê== tÉê=ïÉáíÉê= ÇÉå=tìåëÅÜ=îÉêëéΩêíI= ãáí=eáäÑÉ=îçå= òïÉá=^ãéÉäå= ÇáÉ=páíì~íáçå=~å= ÉáåÉê=êáÅÜíáÖÉå=hêÉìòìåÖ=òì=ëáãìäáÉêÉåI=ÇÉê=ãìëë=ëáÅÜ=òìÉêëí=âä~ê=ã~ÅÜÉåI=ïáÉ= îáÉäÉ=ìåÇ=ïÉäÅÜÉ=mÜ~ëÉå=ÇÉê=wóâäìë=Ç~åå=Ü~íK=== = mÜ~ëÉ= ^ãéÉä=N= ^ãéÉä=O= 1
Rot
Grün
2
Rot + Gelb
Gelb
3
Grün
Rot
4
Gelb
Rot + Gelb
5: wie 1
Rot
Grün
sáÉê=mÜ~ëÉå=ïΩêÇÉå=~ìÅÜ=ÜáÉê=êÉáÅÜÉå=Ó=ïÉê=~ÄÉê=ãÉáåíI=Ç~ëë=ÉáåÉ=oçíJ^ãéÉä= Éêëí=Ç~åå=~ìÑ=oçíJdÉäÄ=ìãëéêáåÖíI=ïÉåå=ÇáÉ=~åÇÉêÉ=pÉáíÉ=ëÅÜçå=êáÅÜíáÖ=oçí=Ü~íI= ÇÉê=ãΩëëíÉ=ïçÜä=ãáí=ÑΩåÑ=çÇÉê=ëÉÅÜë=mÜ~ëÉå=~êÄÉáíÉåK== oìåÇÉ= ^ãéÉä~ìÖÉåI= ÇáÉ= åáÅÜí= ìåëáÅÜíÄ~ê= ïÉêÇÉåI= ëçåÇÉêå= ÉåíïÉÇÉê= åÉìíê~äÉë= Öä~ëJÖê~ì= çÇÉê= áÜêÉ= c~êÄÉ= ~åòÉáÖÉåI= ï®êÉå= ÉÄÉåÑ~ääë= ïΩåëÅÜÉåëïÉêíK= a~ë= âçããí=~ääÉë=åçÅÜ=Ó=ïÉåå=ïáê=áå=^ÄëÅÜåáíí=NMKNKO=Ç~ë=píÉìÉêÉäÉãÉåí=pÜ~éÉ=ìåÇ= ëÉáåÉ=c®êÄìåÖ=ãáí=ÇÉê=RGBJcìåâíáçå=ÄÉÜ~åÇÉäå=ïÉêÇÉåK=bíï~ë=dÉÇìäÇI=ÄáííÉK====
6. 6
Der Vierzylinder-Motor
c~åÖÉå=ïáê=ïáÉÇÉê=Ö~åò=ÉáåÑ~ÅÜ=~åW=báåÉ=ëÉåâêÉÅÜíÉ=pÅêçääÄ~êI=Éáå=qáãÉêI=ÉáåÉ= `ÜÉÅâÄçñ= ãáí= ÇÉê= _ÉëÅÜêáÑíìåÖ= RunterK= pí~êíÉáåëíÉääìåÖ= ÇÉê= pÅêçääÄ~êW= jáåáãìã= 0I=j~ñáãìã= 1000I=mçëáíáçå= 0K=aÉê=~âíáîÉ=qáãÉê=ëçää=ëÅÜåÉää=ä~ìÑÉåI=òìã=_ÉáëéáÉä= ~ääÉê=RR=jáääáëÉâìåÇÉå=ëÉáå=bêÉáÖåáë=~ìëëÉåÇÉåK== aáÉ= `ÜÉÅâÄçñ= ëçää= òì= _ÉÖáåå= ÇÉê= i~ìÑòÉáí= ÉáåÉå= e~âÉå= ÄÉëáíòÉå= EbáÖÉåëÅÜ~Ñí= Checked=~ìÑ=True=îçêÉáåëíÉääÉåFK= táÉ=áå=_áäÇ=SKOV=òì=ëÉÜÉåI=ÉêÜ®äí=ã~å=ÉáåÉ=ëÉåâêÉÅÜíÉ=pÅêçääÄ~ê=ÇìêÅÜ=báåëíÉäJ äìåÖ=ÇÉê=báÖÉåëÅÜ~Ñí=Kind=~ìÑ=sbVerticalK= sáÉê=^ìÑÖ~ÄÉå=ÉêÖÉÄÉå=ëáÅÜ=ÑΩê=ÇÉå=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=òìã=qáãÉêJbêJ ÉáÖåáëW== NON =
S= qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ= • tÉåå= ÇáÉ= `ÜÉÅâÄçñ= ÇÉå= e~âÉå= Ü~í= EbáÖÉåëÅÜ~Ñí= Checked= áëí= TrueFI= ëçää= ëáÅÜ= ÇáÉ=mçëáíáçå=ÇÉë=oÉÖäÉêë=ìã=NMM=báåÜÉáíÉå=å~ÅÜ=ìåíÉå=îÉêëÅÜáÉÄÉåK== • e~í=ÇáÉ=`ÜÉÅâÄçñ=âÉáåÉå=e~âÉåI=ÖÉÜí=ÇáÉ=sÉêëÅÜáÉÄìåÖ=å~ÅÜ=çÄÉåK== • ^åëÅÜäáÉ≈ÉåÇ= áëíI= Ñ~ääë= ÇáÉ= mçëáíáçå= 1000= ÉêêÉáÅÜí= ïìêÇÉI= ÇÉê= e~âÉå= áå= ÇÉê= `ÜÉÅâÄçñ=òì=ÄÉëÉáíáÖÉåK== • tìêÇÉ=ÇáÉ=mçëáíáçå=0=ÉêêÉáÅÜíI=áëí=ÇÉê=e~âÉå=ïáÉÇÉê=òì=ëÉíòÉåK==
== _áäÇ=SKOVW=píÉìÉêÉäÉãÉåíÉ=ìåÇ=pí~êíÉáåëíÉääìåÖ=ÇÉê=pÅêçääÄ~ê= pÉÜÉå= ïáê= ìåë= ÖäÉáÅÜ= ÇáÉ= âçãéäÉííÉ= bêÉáÖåáëéêçòÉÇìê= ~åK= páÉ= áëí= ΩÄÉêê~ëÅÜÉåÇ= âìêòI=ä∏ëí=~ÄÉê=íêçíòÇÉã=~ääÉ=îáÉê=ÖÉëíÉääíÉå=^ìÑÖ~ÄÉåW= procedure TForm1.Timer1Timer(Sender: TObject); begin if CheckBox1.Checked=True then Scrollbar1.Position:=Scrollbar1.Position+100 else Scrollbar1.Position:=Scrollbar1.Position-100;
//Semikolon!
if Scrollbar1.Position=1000 then CheckBox1.Checked:=False; if Scrollbar1.Position=0 then CheckBox1.Checked:=True end;
a~ë=ÄÉëçåÇÉêë=ÜÉêîçêÖÉÜçÄÉåÉ=pÉãáâçäçå=íêÉååí=ÇáÉ=^äíÉêå~íáîÉ=îçå=ÇÉã=ÑçäJ ÖÉåÇÉå= ÉáåÑ~ÅÜÉå= qÉëíI= ~å= ÇÉëëÉå= båÇÉ= ïáÉÇÉêìã= Éáå= qêÉååòÉáÅÜÉå= ÄÉå∏íáÖí= ïáêÇI=ÇÉåå=Éë=âçããí=ÇÉê=å®ÅÜëíÉ=ÉáåÑ~ÅÜÉ=qÉëíK=pçïçÜä=áå=ÇÉê=^äíÉêå~íáîÉ=~äë= ~ìÅÜ=áå=ÇÉå=ÉáåÑ~ÅÜÉå=qÉëíë=ïìêÇÉ=îçå=ÇÉê=^ìëå~ÜãÉêÉÖÉäìåÖ=dÉÄê~ìÅÜ=ÖÉJ ã~ÅÜíK=== t~ê=áå=ÇÉê=§ÄÉêëÅÜêáÑí=åáÅÜí=îçå=ÉáåÉã=sáÉêòóäáåÇÉêJjçíçê=ÇáÉ=oÉÇÉ\== hÉáå=mêçÄäÉãI=ïáê=ëÉíòÉå=ëÅÜåÉää=ÇêÉá=ïÉáíÉêÉ=ëÉåâêÉÅÜíÉ=pÅêçääÄ~êë=ãáí=Ç~êΩÄÉê= ÄÉÑáåÇäáÅÜÉå=`ÜÉÅâÄçñÉå=~ìÑ=Ç~ë=cçêãìä~êK=aáÉ=pí~êíÉáåëíÉääìåÖÉå=â∏ååÉå=~ìë= _áäÇ=SKPM=~ÄÖÉäÉëÉå=ïÉêÇÉåK==
NOO= =
SK=T= pí®ÇíÉJo~íÉå= k~íΩêäáÅÜ= ÄäÉáÄí= Éë= ÄÉá= ÇÉê= ÉáåÉå= bêÉáÖåáëéêçòÉÇìêK= páÉ= ãìëë= áã= fåÜ~äí= åìê= ÉêJ ïÉáíÉêí=ïÉêÇÉå=ÇìêÅÜ=ÇáÉ=àÉïÉáäáÖÉå=i∏ëìåÖÉå=ÇÉê=îáÉê=^ìÑÖ~ÄÉå=ÑΩê=ÇáÉ=òïÉáJ íÉI=ÇêáííÉ=ÄòïK=îáÉêíÉ=pÅêçääÄ~êK=a~ë=ëÅÜ~ÑÑí=ã~å=ÇìêÅÜ=ÑäÉá≈áÖÉë=hçéáÉêÉåKKK=
==
= _áäÇ=SKPMW=páãìä~íáçå=ÉáåÉë=sáÉêòóäáåÇÉêJjçíçêëI=pí~êíëáíì~íáçå=
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 6= ÇáÉ= zipJa~íÉá= DKap06.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap06= ÇáÉ= mêçàÉâíJa~íÉá= proj_66.dpr= ~ìëòìï®ÜäÉåK= táêÇ= ãáí= aÉäéÜá= ULOMMR= ÖÉ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap06=ÇáÉ=a~íÉá=proj_66.bdsproj=~ìëòìï®ÜäÉåK== == aáÉ=`ÜÉÅâÄçñÉå=â∏ååíÉå=ëçÖ~ê=~äë=póãÄçäÉ=ÑΩê=ÇáÉ=wΩåÇâÉêòÉå=ÖÉÇÉìíÉí=ïÉêJ ÇÉå=Ó=ïÉåå=Éë=ëáÅÜ=ìã=ÉáåÉå=wïÉáí~âíÉê=Ü~åÇÉäíK=sáÉêí~âíÉê=ëáåÇ=ëÅÜïáÉêáÖK=
6. 7
Städte-Raten
báå=âäÉáåÉëI=ÉáåÑ~ÅÜÉë=o~íÉëéáÉä=ëçää=Éáå=ïÉáíÉêÉë=j~ä=òÉáÖÉåI=ïáÉ=ëáÅÜ=Ç~ë=píÉìJ ÉêÉäÉãÉåí=qáãÉê=~ííê~âíáî=~åïÉåÇÉå=ä®ëëíK== aÉê= ê~íÉåÇÉ= kìíòÉê= ëáÉÜí= ~ìÑ= ÉáåÉã= cçêãìä~ê= E_áäÇ= SKPNF= äáåâë= ÇáÉ= iáëíÉ= ~ääÉê= ëÉÅÜòÉÜå=_ìåÇÉëä®åÇÉêI=êÉÅÜíë=ÉáåÉ=pí®ÇíÉäáëíÉI=ÇáÉ=òìë®íòäáÅÜ=òì=~ääÉå=i~åÇÉëJ Ü~ìéíëí®ÇíÉå=ïÉáíÉêÉ=pí®ÇíÉ=ÉåíÜ®äíK== == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 6= ÇáÉ= zipJa~íÉá= DKap06.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap06= ÇáÉ= mêçàÉâíJa~íÉá= proj_67.dpr= ~ìëòìï®ÜäÉåK= táêÇ= ãáí= aÉäéÜá= ULOMMR= ÖÉ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap06=ÇáÉ=a~íÉá=proj_67.bdsproj=~ìëòìï®ÜäÉåK== == häáÅâí=ÇÉê=kìíòÉê=~ìÑ=ÇÉå=_ìííçå=StartI=ëçää=ÇÉëëÉå=_ÉëÅÜêáÑíìåÖ=áå=Stopp=ïÉÅÜJ ëÉäåK= däÉáÅÜòÉáíáÖ= ëçää= ÇáÉ= j~êâáÉêìåÖ= ëÅÜåÉää= ìåÇ= é~ìëÉåäçë= îçå= çÄÉå= å~ÅÜ= ìåíÉå=ìåÇ=ïáÉÇÉê=îçå=çÄÉå=å~ÅÜ=ìåíÉå=ìëïK=ΩÄÉê=ÇáÉ=i®åÇÉêäáëíÉ=ä~ìÑÉåK==
NOP =
S= qáãÉê=ìåÇ=qáãÉêJbêÉáÖåáëëÉ= píçééí= ÇÉê= kìíòÉê= ÇìêÅÜ= å~ÅÜÑçäÖÉåÇÉå= häáÅâ= ~ìÑ= ÇÉå= _ìííçåI= ÄäÉáÄí= ÇáÉ= j~êJ âáÉêìåÖ= ~ìÑ= áêÖÉåÇÉáåÉã= i~åÇ= ëíÉÜÉåI= ÇáÉ= _ÉëÅÜêáÑíìåÖ= ÇÉë= _ìííçåë= ïÉÅÜëÉäí= ïáÉÇÉê=áå=StartK= gÉíòí= ÄÉâçããí= ÇÉê= kìíòÉê= ÇáÉ= j∏ÖäáÅÜâÉáíI= ÇáÉ= ÇáÉ= êáÅÜíáÖÉ= e~ìéíëí~Çí= áå= ÇÉê= Öêç≈Éå=iáëíÉ=~ìëòìï®ÜäÉåK=pçä~åÖÉ=ëçää=ÇÉê=qáãÉê=ï~êíÉåK=
== _áäÇ=SKPNW=e~ìéíëí®ÇíÉ=ê~íÉå= häáÅâí= ÇÉê= kìíòÉê= áå= ÇÉê= pí®ÇíÉäáëíÉ= ÉáåÉ= pí~Çí= ~åI= ëçää= Éê= ÉáåÉ= fåÑçêã~íáçå= ÄÉJ âçããÉåI=çÄ=Éê=êáÅÜíáÖ=çÇÉê=Ñ~äëÅÜ=ÖÉï®Üäí=Ü~í=E_áäÇ=SKPNI=êÉÅÜíëFK== tÉåå=Éê=ÇáÉ=fåÑçêã~íáçåI=çÄ=ÇáÉ=îçå=áÜã=~ìëÖÉï®ÜäíÉ=i~åÇÉëÜ~ìéíëí~Çí=êáÅÜíáÖ= çÇÉê= Ñ~äëÅÜ= áëíI= ÄÉëí®íáÖí= Ü~íI= îÉêëÅÜïáåÇÉå= ÄÉáÇÉ= j~êâáÉêìåÖÉå= áå= ÇÉå= iáëíÉåI= ÇÉê=kìíòÉê=â~åå=ÉêåÉìí=ëí~êíÉå=ìåÇ=ëÉáå=táëëÉå=ïáÉÇÉê=ìåíÉê=_ÉïÉáë=ëíÉääÉåK= táÉ= ïáêÇ= ÇáÉëÉ= ^ìÑÖ~ÄÉ= éêçÖê~ããíÉÅÜåáëÅÜ= ÖÉä∏ëí\= táÉ= â~åå= ÇÉê= oÉÅÜåÉê= ΩÄÉêÜ~ìéí=ïáëëÉåI=ïÉäÅÜÉ=i~åÇÉëÜ~ìéíëí~Çí=ÇáÉ=êáÅÜíáÖÉ=áëí\== bê= â~åå= Éë= åáÅÜí= ïáëëÉåI= ïáê= ãΩëëÉå= Éë= áÜã= ãáííÉáäÉåK= aÉå= qêáÅâ= Ç~òì= îÉêê®í= _áäÇ= SKPOW= bë= ÖáÄí= å®ãäáÅÜ= ÉáåÉ= ÇêáííÉ= iáëíÉI= ÇáÉ= ÇáÉ= êáÅÜíáÖÉå= e~ìéíëí~Çíå~ãÉå= ~å=ÇÉå=êáÅÜíáÖÉå=mçëáíáçåÉå=ÉåíÜ®äíK=aáÉëÉ=iáëíÉ=ïáêÇ=ÇÉã=kìíòÉê=~ÄÉê=åáÅÜí=ÖÉJ òÉáÖíX=ïÉáä=ëáÉ=îçå=^åÑ~åÖ=~å=~ìÑ=ìåëáÅÜíÄ~ê=ÉáåÖÉëíÉääí=ïáêÇK== a~ãáí=â∏ååÉå=ïáê=ãáí=ÇÉê=mêçÖê~ããáÉêìåÖ=ÇÉê=ÇêÉá=bêÉáÖåáëéêçòÉÇìêÉå=ÄÉÖáåJ åÉåK== _Éá=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ëçää=ÇáÉ=_ÉëÅÜêáÑíìåÖ=ïÉÅÜëÉäå=ìåÇ=ÇÉê=qáãÉê=ëí~êíÉå= ÄòïK=~åÜ~äíÉåW= NOQ= =
SK=T= pí®ÇíÉJo~íÉå= procedure TForm1.Button1Click(Sender: TObject); begin if Button1.Caption='Start' then begin Button1.Caption:='Stopp';Timer1.Enabled:=True end else begin Button1.Caption:='Start';Timer1.Enabled:=False end end;
== _áäÇ=SKPOW=båíïìêÑ=ãáí=_ìííçåI=ÇêÉá=iáëíÉå=ìåÇ=qáãÉê= _Éá= àÉÇÉã= qáãÉêJbêÉáÖåáë= ëçää= áå= ÇÉê= ÉêëíÉå= ìåÇ= ÇêáííÉå= iáëíÉ= ÇáÉ= j~êâáÉêìåÖ= å~ÅÜ=ìåíÉå=ï~åÇÉêåK=tÉåå=ëáÉ=ÇáÉ=ìåíÉêëíÉ=mçëáíáçå= 15=ÉêêÉáÅÜí=Ü~íI=ëçää=çÄÉå= áå=ÇÉê=ÉêëíÉå=wÉáäÉ=ãáí=mçëáíáçå=0=ïáÉÇÉê=ÄÉÖçååÉå=ïÉêÇÉåW== procedure TForm1.Timer1Timer(Sender: TObject); begin if Listbox1.ItemIndex== tÉåå= áå= ÉáåÉê= bêÉáÖåáëéêçòÉÇìê= ÉáåÉê= çÇÉê= ãÉÜêÉêÉ= péÉáÅÜÉêéä®íòÉ= îÉêïÉåÇÉí= ïÉêÇÉå=ÄÉâçããí=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=ÇêÉá=_Éëí~åÇíÉáäÉW== • ÇáÉ=hçéÑòÉáäÉW=páÉ=ÄÉÖáååí=ãáí=ÇÉã=pÅÜäΩëëÉäïçêí=procedure= • ÇÉå=sÉêÉáåÄ~êìåÖëíÉáäW=bê=ÄÉÖáååí=ãáí=ÇÉã=pÅÜäΩëëÉäïçêí=var= • ÇÉå= ^ìëÑΩÜêìåÖëíÉáäW= bê= ÄÉÖáååí= ãáí= ÇÉã= ÉêëíÉå= begin= ìåÇ= ÉåÇÉí= ãáí= ÇÉã= äÉíòíÉå=end;= NQM= =
TKP== sÉêÉáåÄ~êìåÖÉå=îçå=Ö~åòò~ÜäáÖÉå=péÉáÅÜÉêéä®íòÉå= fã=sÉêÉáåÄ~êìåÖëíÉáä=ãΩëëÉå=ìåÄÉÇáåÖí=~ääÉ=péÉáÅÜÉêéä®íòÉ=~ìÑÖÉäáëíÉí=ïÉêÇÉåI= ÇáÉ= ëé®íÉê= áã= ^ìëÑΩÜêìåÖëíÉáä= îÉêïÉåÇÉí= ïÉêÇÉåK= táêÇ= Éáå= îÉêÉáåÄ~êíÉê= péÉáJ ÅÜÉêéä~íò=åáÅÜí=îÉêïÉåÇÉíI=ëç=ÖáÄí=Éë=âÉáåÉ=cÉÜäÉêãÉäÇìåÖI=ëçåÇÉêå=åìê=ÉáåÉå= eáåïÉáë=áå=ÇÉê=^êí=îçå=_áäÇ=TKNQW= [Hinweis] proj_72u.pas(35): Variable 'x' wurde deklariert, aber in 'TForm1.Button1Click' nicht verwendet
_áäÇ=TKNQW=péÉáÅÜÉêéä~íò=îÉêÉáåÄ~êíI=~ÄÉê=åáÅÜí=îÉêïÉåÇÉí= aáÉ=pÅÜ∏éÑÉê=îçå=aÉäéÜá=ëáåÇ=å®ãäáÅÜ=îçå=ÑçäÖÉåÇÉê=§ÄÉêäÉÖìåÖ=~ìëÖÉÖ~åÖÉåW= tÉåå= Éáå= mêçÖê~ããáÉêÉê= ÉáåÉå= îÉêÉáåÄ~êíÉå= péÉáÅÜÉêéä~íò= ëé®íÉê= åáÅÜí= îÉêJ ïÉåÇÉíI=Ü~í=Éê=ã∏ÖäáÅÜÉêïÉáëÉ=ÉáåÉå=_ÉÑÉÜä=îÉêÖÉëëÉå=çÇÉê=ëáÅÜ=îÉêíáééíK=tçäJ äÉå=ïáê=áÜå=Ç~ê~ìÑ=ÜáåïÉáëÉåI=Ç~ãáí=Éê=ëáÅÜ=ëÉáåÉå=^ìëÑΩÜêìåÖëíÉáä=åçÅÜ=Éáåã~ä= âêáíáëÅÜ=~åëÉÜÉK=== táêÇ=Éáå=péÉáÅÜÉêéä~íò=Ç~ÖÉÖÉå=îÉêïÉåÇÉíI=çÜåÉ=îçêÜÉê=îÉêÉáåÄ~êí=òì=ëÉáå=ÖáÄí= Éë=áããÉê=ÉáåÉ=cÉÜäÉêãÉäÇìåÖ=E_áäÇ=TKNRFW= [Fehler] proj_72u.pas(37): Undefinierter Bezeichner: 'sum'
_áäÇ=TKNRW=cÉÜäÉêW=sum=áëí=åáÅÜí=îÉêÉáåÄ~êí== pé®íÉê=ïÉêÇÉå=ïáê=åçÅÜ=~åÇÉêÉ=łaáåÖÉ=âÉååÉå=äÉêåÉåI=ÇáÉ=ÉÄÉåÑ~ääë=îÉêÉáåÄ~êí= ïÉêÇÉå= ãΩëëÉå= Ó= ÇÉëÜ~äÄ= ÇáÉ= åÉìíê~äÉ= sçâ~ÄÉä= _ÉòÉáÅÜåÉê= áå= ÇÉê= cÉÜäÉêãÉäJ ÇìåÖK=_ÉëçåÇÉêë=ïÉêíîçää=áëí=Ç~ÄÉáW=táêÇ=ãáí=ÇÉê=äáåâÉå=j~ìëí~ëíÉ=ÇçééÉäí=~ìÑ= ÇáÉ= cÉÜäÉêãÉäÇìåÖ= ÖÉâäáÅâíI= ïáêÇ= áã= qÉñí= ÇÉê= bêÉáÖåáëéêçòÉÇìê= ÇáÉ= wÉáäÉ= ÜÉêJ îçêÖÉÜçÄÉåI=áå=ÇÉê=ÇÉê=cÉÜäÉê=Éêâ~ååí=ïìêÇÉ=E_áäÇ=TKNSFK=
=== _áäÇ=TKNSW=eÉêîçêÜÉÄìåÖ=ÇÉê=wÉáäÉ=ãáí=cÉÜäÉêâçåëÉèìÉåò= aáÉëÉ= ÜÉêîçêÖÉÜçÄÉåÉ= wÉáäÉ= ÄÉÑáåÇÉí= ëáÅÜ= áããÉê= ìåíÉêÜ~äÄ= ÇÉë= cÉÜäÉêëI= ïÉáä= ÇÉê=qÉñí=ÉáåÉê=bêÉáÖåáëéêçòÉÇìê=ëíÉíë=îçå=çÄÉå=å~ÅÜ=ìåíÉå=~å~äóëáÉêí=ïáêÇK=
7.3
Vereinbarungen von ganzzahligen Speicherplätzen
7.3.1
Bit und Byte
hÉÜêÉå=ïáê=òì=ìåëÉêÉã=_ÉáëéáÉä=òìêΩÅâK=_áäÇ=TKNT=òÉáÖí=ìåëI=Ç~ëë=ïáê=ãáí= îáÉê= `ÜÉÅâÄçñÉå=~ääÉ=Ö~åòÉå=w~ÜäÉå=îçå=0=Äáë=15=Ç~êëíÉääÉå=â∏ååÉåK== bêïÉáíÉêå=ïáê=ìåëÉêÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=ìã=ïÉáíÉêÉ=îáÉê=`ÜÉÅâÄçñÉå=ìåÇ=ÇáÉ= bêÉáÖåáëéêçòÉÇìê=ÉåíëéêÉÅÜÉåÇI=ëç=ëÉÜÉå=ïáê=áå=_áäÇ=TKNUI=Ç~ëë=ãáí=~ÅÜí=`ÜÉÅâJ ÄçñÉå=~ääÉ=Ö~åòÉå=w~ÜäÉå=îçå=0=Äáë=255=Ç~êëíÉääÄ~ê=ëáåÇW= NQN =
T= d~åòÉ=w~ÜäÉå= báåÉ=âäÉáåÉ=cäÉá≈~ìÑÖ~ÄÉ=áëí=Éë=ëÅÜçå=Ó=~ÄÉê=åáÅÜí=ìåä∏ëÄ~êW=jáí=NS=`ÜÉÅâÄçñÉå= ìåÇ= ÇÉê= ïÉáíÉêÉå= _ÉëÅÜêáÑíìåÖ= 256, 512, 1024= ìëïK= â~åå= ã~å= áå= ÇÉê= q~í= ~ääÉ= Ö~åòÉå=w~ÜäÉå=îçå=0=Äáë=65535=Ç~êëíÉääÉåK==
= _áäÇ=TKNTW=j~ñáã~äÄÉäÉÖìåÖ=ÄÉá=îáÉê=`ÜÉÅâÄçñÉå====
= _áäÇ=TKNUW=j~ñáã~äÄÉäÉÖìåÖ=ÄÉá=~ÅÜí=`ÜÉÅâÄçñÉå= jáí=OQ=`ÜÉÅâÄçñÉå=ÖÉÜí=Éë=îçå= 0=Äáë= 16777215I=ìåÇ=ãáí=PO=`ÜÉÅâÄçñÉå=â∏ååÉå= ïáê=ÇÉå=êáÉëáÖÉå=w~ÜäÉåÄÉêÉáÅÜ=ÇÉê=Ö~åòÉå=w~ÜäÉå=îçå= 0=Äáë= 4294967295=ΩÄÉêJ ëíêÉáÅÜÉå>== pçI=ìåÇ=åìå=ÉêëÉíòÉå=ïáê=ÇáÉ=sçâ~ÄÉä=`ÜÉÅâÄçñ=ÇìêÅÜ=ÇáÉ=sçâ~ÄÉä=_áíK=a~åå= ëáåÇ= ïáê= å®ãäáÅÜ= áã= fååÉêÉå= àÉÇÉë= `çãéìíÉêëI= ïç= ÇáÉ= w~ÜäÉå= ÉÄÉå= áå= ÖÉå~ì= ÇÉê=^êí=ÖÉëéÉáÅÜÉêí=ïÉêÇÉåI=ïáÉ=Éë=ìåëÉêÉ=`ÜÉÅâÄçñÉå=îçêã~ÅÜÉåK=báå=_áí=áëí= ÇáÉ=âäÉáåëíÉ=péÉáÅÜÉêÉáåÜÉáí=áã=oÉÅÜåÉêI=ìåÇ=ëáÉ=â~åå=åìê=ÇáÉ=tÉêíÉ=0=EäÉÉêF=ìåÇ= 1=EÄÉäÉÖíF=~ååÉÜãÉåK= tÉåå= ïáê= ïáëëÉåI= Ç~ëë= áå= ÉáåÉã= péÉáÅÜÉêéä~íò= ãáí= páÅÜÉêÜÉáí= åìê= w~ÜäÉå= òïáJ ëÅÜÉå= 0= ìåÇ= 255= ~ÄòìëéÉáÅÜÉêå= ëáåÇ= êÉáÅÜí= Éë= ~ìëI= ÇáÉëÉå= péÉáÅÜÉêéä~íò= ~äë= UJ _áíJpéÉáÅÜÉêéä~íò= ~åòìÑçêÇÉêåK= táëëÉå= ïáêI= Ç~ëë= ÇáÉ= ~ÄòìëéÉáÅÜÉêåÇÉå= w~ÜäÉå= Öê∏≈Éê=ïÉêÇÉåI=òïáëÅÜÉå= 0=ìåÇ= 65535=äáÉÖÉå=ïÉêÇÉå=ãΩëëÉå=ïáê=ëÅÜçå=ÉáåÉå= NSJ_áíJpéÉáÅÜÉêéä~íò=~åÑçêÇÉêåK== tÉêÇÉå=ÇáÉ=w~ÜäÉå=åìê=òïáëÅÜÉå= 0=ìåÇ=15=äáÉÖÉåI=ïΩêÇÉå=ïáê=ãáí=ÉáåÉã=QJ_áíJ péÉáÅÜÉêéä~íò=~ìëâçããÉåK=aÉå=ÖáÄí=Éë=~ÄÉê=áå=aÉäéÜá=åáÅÜí>== • cΩê= Ö~åòÉ= w~ÜäÉå= ÖáÄí= Éë= áå= aÉäéÜáJm~ëÅ~ä= åìê= UJ_áíJI= NSJ_áíJ= ìåÇ= POJ_áíJ péÉáÅÜÉêéä®íòÉK=a~ë=ïìêÇÉ=ëç=ÑÉëíÖÉäÉÖíK= råÇ=ïÉáä=U=_áí=ÖäÉáÅÜ=N=_óíÉ=áëíI=ÖáÄí=Éë=ÑçäÖäáÅÜ=áå== • aÉäéÜáJm~ëÅ~ä=ÑΩê=Ö~åòÉ=w~ÜäÉå=NJ_óíÉI=OJ_óíÉ=ìåÇ=QJ_óíÉJpéÉáÅÜÉêéä®íòÉK= _Éîçê= ïáê= ìåë= áå= ÉáåÉê= §ÄÉêëáÅÜí= åçÅÜ= Éáåã~ä= ÇáÉ= w~ÜäÉåÄÉêÉáÅÜÉ= ~åëÉÜÉåI= ïçääÉå= ïáê= ìåë= òìë®íòäáÅÜ= âä~êã~ÅÜÉåI= Ç~ëë= Éáå= NSJ_áíJpéÉáÅÜÉêéä~íò= EO= _óíÉF= ÉáåÉêëÉáíë= ~ääÉ= Ö~åòÉå= w~ÜäÉå= îçå= 0= Äáë= 65535= ìåÇ= ~åÇÉêÉêëÉáíë= ~ääÉ= Ö~åòÉå= w~ÜäÉå=îçå=-32768=Äáë=32767=~ìÑåÉÜãÉå=â~ååK== fã=òïÉáíÉå=c~ää=ïáêÇ=Ç~ë=ÉêëíÉ=_áí=~äë=ëç=ÖÉå~ååíÉë=sçêòÉáÅÜÉåJ_áí=ÄÉíê~ÅÜíÉíK= NQO= =
TKQ== ^åïÉåÇìåÖÉå=îçå=Ö~åòò~ÜäáÖÉå=péÉáÅÜÉêéä®íòÉå=
7.3.2
Integer-Datentypen
• tÉåå=ïáê=áå=ÉáåÉê=bêÉáÖåáëéêçòÉÇìê=ÉáåÉå=péÉáÅÜÉêéä~íò=òìê=^ìÑå~ÜãÉ=Ö~åJ òÉê= w~ÜäÉå= îÉêïÉåÇÉå= ïçääÉåI= ãΩëëÉå= ïáê= áÜå= îÉêÉáåÄ~êÉåK= aáÉ= sÉêÉáåÄ~J êìåÖ=ÄÉëíÉÜí=Ç~êáåI=Ç~ëë=ã~å=ÇìêÅÜ=^åÖ~ÄÉ=ÇÉë=òìíêÉÑÑÉåÇÉå=aÉäéÜáJm~ëÅ~äJ pÅÜäΩëëÉäïçêíÉë=ãáííÉáäíI=ïÉäÅÜÉå=w~ÜäÉåÄÉêÉáÅÜ=ÇÉê=fåÜ~äí=ΩÄÉêëíêÉáÅÜÉå=ëçääW= var x: Byte
1 Byte
Der Speicherplatz kann ganze Zahlen zwischen 0 und 255 aufnehmen.
var x: ShortInt
1 Byte
Der Speicherplatz kann ganze Zahlen zwischen -128 und 127 aufneh¬men.
var x: Word
2 Byte
Der Speicherplatz kann ganze Zahlen zwischen 0 und 65.535 aufneh¬men.
var x: Cardinal
4 Byte
Der Speicherplatz kann ganze Zahlen zwischen 0 und 4.294.967.295 aufnehmen.
var x: Integer
4 Byte
Der Speicherplatz kann ganze Zahlen zwischen -2.147.483.648 und 2.147.483.647 aufnehmen.
var x: Long
4 Byte
Der Speicherplatz kann ganze Zahlen zwischen -2.147.483.648 und 2.147.483.647 aufnehmen.
tÉåå= ïáê= ìåë= âêáíáëÅÜ= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= ~ìë= ÇÉã= ^ÄëÅÜåáíí= TKOKO= ~åëÉÜÉåI= ãΩëëÉå=ïáê=ÑÉëíëíÉääÉåI=Ç~ëë=ïáê=Ççêí=ãáí=ÑìêÅÜíÄ~ê=Öêç≈Éå=h~åçåÉå=~ìÑ=âäÉáåÉ= pé~íòÉå=ÖÉëÅÜçëëÉå=Ü~ÄÉåK=jáí= var sum: Integer;=Ü~ÄÉå=ïáê=ÉáåÉå=QJ_óíÉJpéÉáJ ÅÜÉêéä~íò=~åÖÉÑçêÇÉêíX=ÇáÉ=Öê∏≈íÉ=w~ÜäI=ÇáÉ=Ççêí=àÉã~äë=ÜáåÉáå=âçããÉå=âçååíÉI= ï~ê= ~ÄÉê= ÇáÉ= 15K= bë= Ü®ííÉ= Ççêí= îçääâçããÉå= ~ìëÖÉêÉáÅÜíI= var sum: Byte;= òì= ëÅÜêÉáÄÉåK====
7.4
Anwendungen von ganzzahligen Speicherplätzen
7.4.1
Grundsätze, Namensgebung
tÉêÇÉå= áå= ÉáåÉê= bêÉáÖåáëéêçòÉÇìê= péÉáÅÜÉêéä®íòÉ= îÉêïÉåÇÉíI= â~åå= ëáÅÜ= ÇáÉ= §ÄÉêëáÅÜíäáÅÜâÉáí= ìåÇ= sÉêëí®åÇäáÅÜâÉáí= ÇÉê= bêÉáÖåáëéêçòÉÇìê= ìã= Éáå= sáÉäÑ~ÅÜÉë= ÉêÜ∏ÜÉåK=a~òì=íê®Öí=ÇáÉ=k~ãÉåëÖÉÄìåÖ=ÇÉê=péÉáÅÜÉêéä®íòÉ=îáÉä=ÄÉáW== • báå=péÉáÅÜÉêéä~íò=ëçääíÉ=ëíÉíë=ÉáåÉå=ëéêÉÅÜÉåÇÉå=k~ãÉå=Ü~ÄÉåK=a~ë=ÜÉá≈íI=ÇÉê= k~ãÉ=ÉáåÉë=péÉáÅÜÉêéä~íòÉë=ëçääíÉ=~ìÑ=ÇáÉ=_ÉÇÉìíìåÖ=ÇÉë=fåÜ~äíë=ÜáåïÉáëÉåK== cΩê=ÇáÉ=k~ãÉåëÖÉÄìåÖ=ÖáÄí=Éë=ëíêÉåÖÉ=sçêëÅÜêáÑíÉåW== • báå= k~ãÉ= ÉáåÉë= péÉáÅÜÉêéä~íòÉë= Ç~êÑ= åìê= ãáí= ÉáåÉã= _ìÅÜëí~ÄÉå= çÇÉê= ÇÉã= råíÉêëíêáÅÜ= |= ÄÉÖáååÉåK= ^åëÅÜäáÉ≈ÉåÇ= â∏ååÉå= _ìÅÜëí~ÄÉå= ìåÇLçÇÉê= wáÑÑÉêå= ÑçäÖÉåK= sÉêÄçíÉå= ëáåÇ= iÉÉêòÉáÅÜÉå= ìåÇ= pçåÇÉêòÉáÅÜÉåK= k~ãÉå= ëçääíÉå= åáÅÜí= òì=ä~åÖ=ëÉáåK= NQP =
T= d~åòÉ=w~ÜäÉå=
7.4.2 ==
Erhöhung der Übersichtlichkeit
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 7= ÇáÉ= zipJa~íÉá= DKap07.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap07= ÇáÉ= mêçàÉâíJa~íÉá= proj_742.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap07=ÇáÉ=a~íÉá=proj_742.bdsproj=~ìëòìï®ÜäÉåK== == hçããÉå=ïáê=ïáÉÇÉê=Éáåã~ä=òì=ÉáåÉã=a~íÉåÄÉëí~åÇI=ÇÉê=ëáÅÜ=áå=ÉáåÉê=iáëíÉ=ÄÉJ ÑáåÇÉí=E_áäÇ=TKNVFK=báÖÉåíäáÅÜ=ëçää=ÇáÉ=iáëíÉ=ìåëáÅÜíÄ~ê=ëÉáå=Ó=Äáë=ÇáÉ=^ìÑÖ~ÄÉ=ÖÉJ ä∏ëí=áëíI=ä~ëëÉå=ïáê=ëáÉ=~ÄÉê=ëáÅÜíÄ~êK== wìã= pí~êí= ÇÉê= i~ìÑòÉáí= ëçää= ÇÉê= çÄÉêëíÉ= báåíê~Ö= EbêëíÉ= wÉáäÉI= mçëáíáçå= 0F= áå= ÇÉê= iáëíÉ=ÇáÉ=j~êâáÉêìåÖ=ÄÉëáíòÉåI=ÖäÉáÅÜòÉáíáÖ=ëçää=Éê=áã=i~ÄÉä=òì=ëÉÜÉå=ëÉáåK=aáÉëÉ= ^ìÑÖ~ÄÉ=ä∏ëÉå=ïáê=ïáÉÇÉê=ãáí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=òìã=bêÉáÖåáë= Create=Ó=eÉêJ ëíÉääìåÖ=ÇÉë=cçêãìä~êë=EëK=^ÄëÅÜåáíí=QKTKRFK=páÉ=áëí=ëç=ÉáåÑ~ÅÜI=Ç~ëë=ïáê=ãáí=ÇÉå= éêçéÉêíáÉë=ItemIndex=ìåÇ=Items[..]=ÇÉê=iáëí_çñ=ìåÇ=ÇÉê=éêçéÉêíó=Caption=ÇÉë=i~J ÄÉäë=~ìëâçããÉåW== procedure TForm1.FormCreate(Sender: TObject); begin ListBox1.ItemIndex:=0; Label1.Caption:=ListBox1.Items[0] end;
aáÉ=å®ÅÜëíÉ=^ìÑÖ~ÄÉ=ÉêÖáÄí=ëáÅÜ=~ìë=ÇÉê=_ÉëÅÜêáÑíìåÖ=ÇÉë=k~îáÖ~íáçåëJ_ìííçåëK= táêÇ= Éê= ÖÉâäáÅâíI= ëçää= ÇáÉ= j~êâáÉêìåÖ= áå= ÇÉê= iáëíÉ= ìã= ÉáåÉ= wÉáäÉ= å~ÅÜ= ìåíÉå= ï~åÇÉêåI=ÄÉá=ÖäÉáÅÜòÉáíáÖÉê=^åòÉáÖÉ=áã=i~ÄÉäK=fëí=ÇáÉ=ìåíÉêëíÉ=wÉáäÉ=ÉêêÉáÅÜíI=ëç= ëçää=ãáí=ÇÉê=ÉêëíÉå=wÉáäÉ=ïáÉÇÉê=ÄÉÖçååÉå=ïÉêÇÉåI=Éë=áëí=Éáå=łoìåÇìãä~ìÑ=òì= éêçÖê~ããáÉêÉåK=
== _áäÇ=TKNVW=a~íÉåÄÉëí~åÇI=^åòÉáÖÉJi~ÄÉä=ìåÇ=k~îáÖ~íáçåëJ_ìííçå=== NQQ= =
TKQ== ^åïÉåÇìåÖÉå=îçå=Ö~åòò~ÜäáÖÉå=péÉáÅÜÉêéä®íòÉå= pÉÜÉå=ïáê=ìåë=~åI=ïáÉ=éêçÖê~ããáÉêí=ïÉêÇÉå=â~ååI=ïÉåå=òïÉá=péÉáÅÜÉêéä®íòÉ=pos= EÑΩê=PosáíáçåF=ìåÇ=lepos=EÑΩê=leíòíÉ=PosáíáçåF=îÉêïÉåÇÉí=ïÉêÇÉåW== procedure TForm1.Button1Click(Sender: TObject); var pos,lepos: Byte;
//Vereinbarungen
begin //Eingangsdaten werden in Speicherplätze geholt lepos:=ListBox1.Items.Count-1; pos:=ListBox1.ItemIndex; //nun wird "gerechnet" if pos=
== _áäÇ=TKOVW=páååäçëÉ=báåÖ~ÄÉ== t~ë=ï®êÉ=ÜáÉê=òì=íìå\=bë=ÖáÄí=ãÉÜêÉêÉ=j∏ÖäáÅÜâÉáíÉåK== aáÉ=ÉêëíÉ=j∏ÖäáÅÜâÉáí=ÄÉëíÉÜí=Ç~êáåI=Ç~≈=ã~å=~ääÉë=ëç=ä®ëëíI=ïáÉ=Éë=áëíK=fëí=åáÅÜí= ~Äëçäìí=Ñ~äëÅÜI=ÇáÉëÉ=^ìëâìåÑíK== aáÉ=òïÉáíÉ=j∏ÖäáÅÜâÉáíW=píÉÜí=çÄÉå=ïÉåáÖÉê=~äë=ìåíÉåI=ïáêÇ=ÇÉê=ÖÉë~ãíÉ=fåÜ~äí= ÇÉê=_ìííçåJhäáÅâJbêÉáÖåáëéêçòÉÇìê=ÉáåÑ~ÅÜ=åáÅÜí=~ìëÖÉÑΩÜêíW= procedure TForm1.Button1Click(Sender: TObject); var gross_zahl, klein_zahl: Integer;
//Vereinbarungen
begin
//Ausführungsteil
gross_zahl:=StrToInt(Edit1.Text);
//Transport in Speicherplätze
klein_zahl:=StrToInt(Edit2.Text); if gross_zahl>klein_zahl then
//Nur bei sinnvoller Belegung
begin if gross_zahl mod klein_zahl = 0 then ShowMessage('Die Zahl '+
//mod liefert den Rest //Ja-Zweig für die Teilbarkeit
IntToStr(gross_zahl)+ ' ist durch '+ IntToStr(klein_zahl)+ ' ohne Rest teilbar' )
NRP =
T= d~åòÉ=w~ÜäÉå= else //Nein-zweig, falls nicht teilbar ShowMessage('Die Zahl '+ IntToStr(gross_zahl)+ ' ist nicht durch '+ IntToStr(klein_zahl)+ ' teilbar' ) end end;
aáÉ= ÇêáííÉ= j∏ÖäáÅÜâÉáíW= j~å= ÉêÖ®åòí= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= qáãÉêJbêÉáÖåáë= ëçI=Ç~ëë=ÇÉê=_ìííçå=~ìÅÜ=åìê=Ç~åå=~âíáîáÉêí=ïáêÇI=ïÉåå=ÇáÉ=çÄÉêÉ=w~Üä=Öê∏≈Éê= çÇÉê=ÖäÉáÅÜ=ÇÉê=ìåíÉêÉå=w~Üä=áëíK=tÉäÅÜÉå=fåÜ~äí=ÄÉâçããí=Ç~åå=ÇáÉ=qáãÉêJbêJ ÉáÖåáëéêçòÉÇìê\== procedure TForm1.Timer1Timer(Sender: TObject); begin if (Edit1.Text'') and (Edit2.Text'') and (StrToInt(Edit1.Text)>StrToInt(Edit2.Text)) then Button1.Enabled:=True else Button1.Enabled:=False end;
sáÉêíÉåëW= j~å= â~åå= ~ìÅÜ= ÖìíïáääáÖ= ëÉáåI= ìåÇ= áå= ÇÉê= _ìííçåJhäáÅâJ bêÉáÖåáëéêçòÉÇìê=òìÉêëí=Ñê~ÖÉå=ä~ëëÉåI=ïç=ÇáÉ=Öê∏≈ÉêÉ=w~Üä=ëíÉÜíK=aáÉëÉ=âçããí= áå= ÇÉå= péÉáÅÜÉêéä~íò= gross_zahlK= aáÉ= ~åÇÉêÉ= áå= ÇÉå= péÉáÅÜÉêéä~íò= klein_zahlK= a~åå=ïáêÇ=ìåíÉêëìÅÜíK=^ìÅÜ=Ç~ë=áëí=ã∏ÖäáÅÜK== tÉåå= ÇáÉ= ^ìÑÖ~ÄÉåëíÉääìåÖ= åáÅÜí= Ö~åò= âä~ê= ìåÇ= ÉáåÇÉìíáÖ= ÑçêãìäáÉêí= áëí= ëáåÇ= ΩÄêáÖÉåë=~ääÉ=îçêÖÉëÅÜä~ÖÉåÉå=i∏ëìåÖÉå=êáÅÜíáÖK==== =
NRQ= =
==
8 8.1
Grafikprogrammierung Grundbegriffe ^ìëÖ~åÖëéìåâí= ÑΩê= ìåëÉêÉ= àÉíòáÖÉå= §ÄÉêäÉÖìåÖÉå= áëí= ÉáåÉ= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= ãáí= ÉáåÉã= ÉáåòáÖÉå= Öêç≈Éå= _áäÇÉêê~ÜãÉåK= få= ^ÄëÅÜåáíí= TKQKQ= Ü~ííÉå= ïáê= Ó= Ç~J ã~äë= òìê= eÉêëíÉääìåÖ= ÇÉê= päçíJj~ëÅÜáåÉ= ÑΩê= häÉáåâáåÇÉê= Ó= ÄÉêÉáíë= âÉååÉå= ÖÉJ äÉêåíI=ïáÉ=Éáå=_áäÇÉêJo~ÜãÉå=~åÖÉÑçêÇÉêí=ïáêÇK==
= _áäÇ=UKNW=sáëìÉääÉë=lÄàÉâí=Image=áå=aÉäéÜá=T=ÄòïK=aÉäéÜá=ULOMMR== a~ë=òìÖÉÜ∏êáÖÉ=póãÄçä=E_áäÇ=UKNF=ÑáåÇÉå=ïáê=áã=oÉÖáëíÉêÄä~íí=çÇÉê=ÇÉê=h~íÉÖçJ êáÉ=wrpûqwif`e=îçå=hçãéçåÉåíÉåJ=çÇÉê=qççäJm~äÉííÉK== tÉåå= ÇÉê= _áäÇÉêê~ÜãÉå= ~ìÑ= ÇÉê= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= éä~íòáÉêí= áëíI= ÄÉâçããí= Éê= îçå= aÉäéÜá= ÇÉå= k~ãÉå= Image1K= a~ë= _áäÇÉêê~ÜãÉåJlÄàÉâí= áëí= ~åÑ~åÖë= åìê= áã= båíïìêÑ=ÇìêÅÜ=ÇáÉ=ÖÉëíêáÅÜÉäíÉ=o~åÇäáåáÉ=òì=ÉêâÉååÉåX=ïáêÇ=ÇáÉ=_ÉåìíòÉêçÄÉêJ Ñä®ÅÜÉ=ÜÉêÖÉëíÉääíI=áëí=Ç~åå=EëÅÜÉáåÄ~êF=ΩÄÉêÜ~ìéí=åáÅÜíë=òì=ëÉÜÉå=E_áäÇ=UKOFK==
= _áäÇ=UKOW=_áäÇÉêê~ÜãÉå=áã=båíïìêÑ=ìåÇ=å~ÅÜ=pí~êí=== táê=ïçääÉå=~ÄÉê=åáÅÜíI=ïáÉ=áã=ÖÉå~ååíÉå=^ÄëÅÜåáííI=ÑΩê=ÉáåÉå=ÄÉëíáããíÉå=_áäÇJ fåÜ~äí= ÇáÉëÉë= o~ÜãÉåë= ëçêÖÉåI= ëçåÇÉêå= Ç~ë= _áäÇJfååÉêÉ= ~äë= ìåëÉêÉ= j~äÑä®ÅÜÉ= ÄÉíê~ÅÜíÉåK== • aÉäéÜá=ÖáÄí=ìåë=ÇáÉ=j∏ÖäáÅÜâÉáíI=àÉÇÉå=ÉáåòÉäåÉå=_áäÇéìåâí=EmáñÉäF=ÉáåÉë=ImageJlÄàÉâíë= ïáÉ= ~ìÑ= ÉáåÉê= j~äÑä®ÅÜÉ= ÇáÑÑÉêÉåòáÉêí= ÄÉ~êÄÉáíÉå= òì= â∏ååÉåK= a~ë= ÄÉÇÉìíÉíI=ïáê=â∏ååÉå=ãáí=aÉäéÜá=ã~äÉåK=== tÉåå=Éáå=j~äÉê=ëÉáåÉ=sçêÄÉêÉáíìåÖÉå=ÑΩê=Éáå=åÉìÉë=_áäÇ=ÄÉÖáååí=ëé~ååí=Éê=òìÉêëí= ~äë= j~äÑä®ÅÜÉ= ÉáåÉ= iÉáåï~åÇ= ~ìÑK= a~ë= ÉåÖäáëÅÜÉ= tçêí= ÑΩê= iÉáåï~åÇ= áëí= canvasK= aáÉëÉë=tçêí=canvas=ïáêÇ=ÇáÉ=ïáÅÜíáÖëíÉ=sçâ~ÄÉä=ÇáÉëÉë=^ÄëÅÜåáííë=ïÉêÇÉåK=== NRR =
U= dê~ÑáâéêçÖê~ããáÉêìåÖ= a~ë=pÅÜÉã~=îçå=_áäÇ=UKP=Éêâä®êí=ÇáÉ=åÉìÉ=páíì~íáçåW=táê=ëçääíÉå=ìåë===îçêëíÉääÉåI= Ç~ëë=ëáÅÜ=áã=a~íÉåâÉêå=ÇÉë=_áäÇÉêê~ÜãÉåJlÄàÉâíÉë=ãáí=ÇÉã=k~ãÉå= Image1=Éáå= ïáÉÇÉêìã=~ÄÖÉëÉíòíÉê=_ÉêÉáÅÜ=ãáí=ÇÉã=k~ãÉå=Canvas=ÄÉÑáåÇÉíK== aáÉëÉê=áååÉêÉ=_ÉêÉáÅÜ= Canvas=ÉåíÜ®äí=~ääÉ=^åÖ~ÄÉå=òì=ÇÉå=ÉáåòÉäåÉå=_áäÇéìåâíÉå= ÇÉë= _áäÇÉêê~ÜãÉåJlÄàÉâíëI= ìåÇ= ãáí= eáäÑÉ= îçå= îáÉäÉå= ÄÉêÉáíÖÉëíÉääíÉå= báÖÉåëÅÜ~ÑJ íÉå= ìåÇ= jÉíÜçÇÉå= â~åå= ÉåíïÉÇÉê= àÉÇÉê= ÉáåòÉäåÉ= _áäÇéìåâí= ÉáåÖÉÑ®êÄí= ïÉêÇÉå= çÇÉê=Éë=â∏ååÉå=ãáí=áÜåÉå=~ìÅÜ=ÖäÉáÅÜòÉáíáÖ=ãÉÜêÉêÉ=_áäÇéìåâíÉ=ÖÉÑ®êÄí=ïÉêÇÉåK==
= _áäÇ=UKPW=lÄàÉâí=Image1=ìåÇ=_ÉêÉáÅÜ=Canvas=ëÉáåÉë=a~íÉåâÉêåë== fã= _áäÇ= UKP= ëáåÇ= ÇáÉ= k~ãÉå= îçå= ÉáåáÖÉå= ÇÉê= ïáÅÜíáÖëíÉå= c®êÄÉJjÉÅÜ~åáëãÉå= ÑΩê=_áäÇéìåâíÉ=ÉáåÖÉíê~ÖÉåX=ëáÉ=ïÉêÇÉå=ÄÉêÉáíë=áã=å®ÅÜëíÉå=^ÄëÅÜåáíí=ÄÉå∏íáÖíK== • §ÄÉê~ìë= ïáÅÜíáÖ= áëí= ÇáÉ= sçêëíÉääìåÖI= Ç~ëë= ãáí= ÇÉå= ~åÖÉÖÉÄÉåÉå= wìÖêáÑÑëJjÉJ ÅÜ~åáëãÉå=~ìÑ= Canvas=åáÅÜí=ÖÉã~äíI= ëçåÇÉêå=ÉáåÖÉÑ®êÄí= ïáêÇK=bë=áëí=Ç~åå= ïáÉ= ÄÉá= ÉáåÉã= j~äÉêW= tÉåå= ÇáÉ=c~êÄÉ=íêçÅâÉå=áëí= â~åå= Ç~ë= dÉã~äíÉ= åìê=Ç~ÇìêÅÜ= ïáÉÇÉê=ÄÉëÉáíáÖí=ïÉêÇÉåI=Ç~ëë=ã~å=Éë=ãáí=ÇÉê=eáåíÉêÖêìåÇÑ~êÄÉ=ΩÄÉêã~äíK== bë= ïáêÇ= ÇÉëÜ~äÄ= áå= ÇÉå= ÑçäÖÉåÇÉå= ^ÄëÅÜåáííÉå= ÇáÉ= sçâ~ÄÉä= i∏ëÅÜÉå= åìê= ëÉäíÉå== ÖÉÄÉåK=pçåÇÉêå=ãÉáëí=ÇáÉ=òìíêÉÑÑÉåÇÉêÉå=sçâ~ÄÉäå=Ñ®êÄÉå=ìåÇ=ΩÄÉêã~äÉåK==
8.2
Geometrische Gebilde erzeugen
8.2.1
Das Koordinatensystem
_áäÇ=UKQ=òÉáÖíI=Ç~ëë=áã=fååÉêÉå=àÉÇÉë=_áäÇÉêê~ÜãÉåë=äáåâë=çÄÉå=ãáí=ÇÉê=w®ÜäìåÖ= ÄÉÖçååÉå=ïáêÇK== • aáÉ=äáåâÉ=çÄÉêÉ=bÅâÉ=àÉÇÉë=canvasJlÄàÉâíë=ÄÉëáíòí=ëíÉíë=ÇÉå=Pixel[0,0].
NRS= =
UKO== dÉçãÉíêáëÅÜÉ=dÉÄáäÇÉ=ÉêòÉìÖÉå= == ========================tÉê= ÇáÉ= ÑçäÖÉåÇÉå= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 8= ÇáÉ= zipJa~íÉá= DKap08.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap08= ÇáÉ= mêçàÉâíJa~íÉá= proj_8?.dpr= ~ìëòìï®ÜäÉåK= táêÇ= ãáí= aÉäéÜá= ULOMMR= ÖÉ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbf= = molgbhq= £cckbk= áã= lêÇåÉê= D8Kap07= ÇáÉ= a~íÉá= proj_8?.bdsproj= ~ìëòìï®ÜäÉåK= a~ë= cê~ÖÉòÉáÅÜÉå=ëíÉÜí=Ç~ÄÉá=ÑΩê=ÇáÉ=kìããÉê=ÇÉë=råíÉê~ÄëÅÜåáííëK= = oÉÅÜíë= åÉÄÉå= ÇÉã= _áäÇéìåâí= áå= ÇÉê= äáåâÉå= çÄÉêÉå= bÅâÉ= ÇÉë= _áäÇÉêê~ÜãÉåJfåJ Ü~äíë= ÄÉÑáåÇÉí= ëáÅÜ= Ç~åå= ÇÉê= Pixel[1,0]= Äáë= Ó= ëéÉòáÉää= áå= _áäÇ= UKQ= Ó= ìåÖÉÑ®Üê= òìã= Pixel[750,0]K= aáÉ= òïÉáíÉ= máñÉäêÉáÜÉ= ÄÉÖáååí= äáåâë= ãáí= ÇÉã= Pixel[0,1]= âçããí=êÉÅÜíë=Ç~åÉÄÉå=ÇÉê=Pixel[1,1]=ìåÇ=ëç=ïÉáíÉêK== bêëíêÉÅâí= ëáÅÜ= ÇÉê= _áäÇÉêê~ÜãÉå= ~ÄÉê= ΩÄÉê= ÇÉå= Ö~åòÉå= _áäÇëÅÜáêã= â~åå= Éë= çÄÉå=å~ÅÜ=êÉÅÜíë=Äáë=òìã=Pixel[1150,0]=ÖÉÜÉå=Ó=àÉ=å~ÅÜ=^ìÑä∏ëìåÖK=^ã=äáåâÉå= _áäÇëÅÜáêãê~åÇ= â~åå= Éë= Ç~åå= å~ÅÜ= ìåíÉå= Äáë= òìã= Pixel[0,815]= ÖÉÜÉå= Ó= àÉ= å~ÅÜ= ^ìÑä∏ëìåÖK= _Éá= îçääÉã= _áäÇëÅÜáêã= Ü®ííÉ= Ç~åå= ÇÉê= äÉíòíÉ= _áäÇéìåâí= êÉÅÜíë= ìåíÉå= ÇáÉ= _ÉòÉáÅÜåìåÖ= Pixel[1150,815]= Eáå= ÇÉã= _áäÇÉêê~ÜãÉå= îçå= _áäÇ= UKQ= ëÅÜ~ÑÑÉå=ïáê=ÉëI=ïáÉ=òì=ëÉÜÉåI=~ÄÉê=åìê=Äáë=ìåÖÉÑ®Üê=òìã=Pixel[750,800]=FK===
= _áäÇ=UKQW=hççêÇáå~íÉåëóëíÉãI=w®ÜäìåÖ=ÄÉÖáååí=äáåâë=çÄÉå== NRT =
U= dê~ÑáâéêçÖê~ããáÉêìåÖ= táÉ=ÖÉÜÉå=ïáê=ïÉáíÉê=îçê\=fã=_áäÇ=UKR=ëáåÇ=~ÅÜí=ÖÉçãÉíêáëÅÜÉ=cáÖìêÉå=ëçïáÉ=Éáå= qÉñí= òì= ëÉÜÉåK= páÉ= ~ääÉ= ëáåÇ= àÉïÉáäë= ãáííÉäë= häáÅâ= ~ìÑ= ÉáåÉå= ÇÉê= _ìííçåë= ÇìêÅÜ= ÖÉÉáÖåÉíÉë=c®êÄÉå=îçå=máñÉäå=Éåíëí~åÇÉåK== fåÇÉã= ïáê= ìåë= ÇáÉ= fåÜ~äíÉ= ÇÉê= åÉìå= bêÉáÖåáëéêçòÉÇìêÉå= ~åëÉÜÉåI= äÉêåÉå= ïáê= ÇáÉ=àÉïÉáäáÖÉ=sçêÖÉÜÉåëïÉáëÉ=òìã=é~ëëÉåÇÉå=báåÑ®êÄÉå=âÉååÉåK===
= _áäÇ=UKRW=bêòÉìÖíÉ=EÉáåÖÉÑ®êÄíÉF=ÖÉçãÉíêáëÅÜÉ=cáÖìêÉå=
8.2.2
Einzelner Pixel
aáÉ=_ÉëÅÜêáÑíìåÖ=================================================================ÇÉë=ÉêëíÉå=_ìíJ= íçåë=ÑçêãìäáÉêí=ÇáÉ=^ìÑÖ~ÄÉK=páÉ=áëí=ÉáåÑ~ÅÜ=òì=ä∏ëÉåW== procedure TForm1.Button1Click(Sender: TObject); var x1,y1: Integer; begin x1:=100;y1:=100; image1.canvas.Pixels[x1,y1]:=RGB(0,0,0) end;
NRU= =
UKO== dÉçãÉíêáëÅÜÉ=dÉÄáäÇÉ=ÉêòÉìÖÉå= lÑÑÉåëáÅÜíäáÅÜ=ïáêÇ=Éáå=ÄÉëíáããíÉê=máñÉäI=Éáå=ÉáåòáÖÉêI=ãáí=ÇÉã=^ìÖÉ=â~ìã=ÉêJ âÉååÄ~êÉê= _áäÇéìåâíI= Ç~ÇìêÅÜ= ÉáåÖÉÑ®êÄíI= Ç~ëë= òìÉêëí= ~ìÑ= ÇÉê= äáåâÉå= pÉáíÉ= ÇÉê= nìÉääÉJwáÉäJ^åïÉáëìåÖ= áå= ÇáÉ= ÉÅâáÖÉå= hä~ããÉêå= ÇÉëëÉå= mçëáíáçåI= ÑçäÖäáÅÜ= ÇÉê= ^Äëí~åÇ=îçã=äáåâÉå=ìåÇ=îçã=çÄÉêÉå=_áäÇê~åÇI=ÉáåÖÉíê~ÖÉå=ïáêÇK== ^ìÑ=ÇÉê=êÉÅÜíÉå=pÉáíÉ=ÇÉê=nìÉääÉJwáÉäJ^åïÉáëìåÖ=ïÉêÇÉå=áå=ÇÉå=êìåÇÉå=hä~ãJ ãÉêå=ÇÉê=RGBJcìåâíáçå=Ç~òì=ÇáÉ=ÇêÉá=c~êÄ~åíÉáäëïÉêíÉ=EàÉïÉáäë=M=Äáë=ORRF=ÑΩê=êçíI= ÖêΩå=ìåÇ=Ää~ì=ÉáåÖÉíê~ÖÉåK=kìää=ÑΩê=oçíI=kìää=ÑΩê=dêΩåI=kìää=ÑΩê=_ä~ì=Ó=Ç~ë=äáÉJ ÑÉêí=Ç~ë=îÉêä~åÖíÉ=pÅÜï~êòK== få= _áäÇ= UKR= òÉáÖí= ÇÉê= j~ìëòÉáÖÉê= ~ìÑ= ÇÉå= ÄÉáã= häáÅâ= ÉêëÅÜÉáåÉåÇÉå= ÉáåòÉäåÉå= _áäÇéìåâíX=ÇÉåå=Éê=áëíI=ïáÉ=ÖÉë~ÖíI=ãáí=Ääç≈Éã=^ìÖÉ=åìê=ãáí=jΩÜÉ=òì=ÉêâÉååÉåK===
8.2.3
Gerade Linie
aáÉ=_ÉëÅÜêáÑíìåÖ=====================================================================ÇÉë=òïÉáíÉå== _ìííçåë=ÑçêãìäáÉêí=ÇáÉ=å®ÅÜëíÉ=^ìÑÖ~ÄÉK=páÉ=ïáêÇ=ãáí=ÇÉê=ÑçäÖÉåÇÉå=bêÉáÖåáëéêçJ òÉÇìê=ÖÉä∏ëíW== procedure TForm1.Button2Click(Sender: TObject); var x1,y1,x2,y2: Integer; begin x1:=300;y1:=250; image1.canvas.moveTo(x1,y1); x2:=600;y2:=300; image1.canvas.Pen.Color:=RGB(0,255,0); image1.canvas.Pen.Width:=10; image1.canvas.LineTo(x2,y2)
//Anfangspunkt festlegen //Sprung zum Anfangspunkt //Endpunkt festlegen //Linienfarbe //Linienstärke //Gerade zeichnen
end;
aáÉ= å~ÅÜ= ÇÉå= ÄÉáÇÉå= pÅÜê®ÖëíêáÅÜÉå= // ëíÉÜÉåÇÉå= hçããÉåí~êÉ= Éêâä®êÉå= Ç~ë= sçêÖÉÜÉåW= wìÉêëí= ãìëë= ÇÉê= ^åÑ~åÖëéìåâí= ÇÉê= dÉê~ÇÉå= ÑÉëíÖÉäÉÖí= ïÉêÇÉåI= ÇÉê= moveToJ_ÉÑÉÜä=îÉê~åä~ëëí=ÇÉå=péêìåÖ=ÇçêíÜáåK=k~ÅÜÇÉã=ÇÉê=båÇéìåâí=ÑÉëíÖÉäÉÖí= áëíI=ëçääíÉ=îçê=ÇÉã=báåÑ®êÄÉå=ÇÉê=dÉê~ÇÉå=EÜáÉê=ãáí=ÇÉã=tçêí= zeichnen=ÉáÖÉåíJ äáÅÜ=Ñ~äëÅÜ=ÄÉëÅÜêáÉÄÉåF=òìÉêëí=ÇáÉ= iáåáÉåÑ~êÄÉ=ìåÇ=Jëí®êâÉ=ãáí=ÇÉå= CanvasJjÉJ íÜçÇÉå=Pen.Color=ìåÇ=Pen.Width=ÑÉëíÖÉäÉÖí=ïÉêÇÉåK====
8.2.4
Offenes Rechteck
_Éáã=häáÅâ=~ìÑ=ÇÉå=ÇêáííÉå=_ìííçå== ëçää= ÇÉê= oÉÅÜíÉÅâìãêáëë= ÉáåÖÉÑ®êÄí= ïÉêÇÉåI= ÇÉëëÉå= äáåâÉ= çÄÉêÉ= bÅâÉ= ëáÅÜ= áã= mìåâí=(100,150)=ÄÉÑáåÇÉí=ìåÇ=ÇÉëëÉå=êÉÅÜíÉ=ìåíÉêÉ=bÅâÉ=ÄÉá=(250,350)=áëíK== ^ìÅÜ=ÜáÉê=â∏ååÉå=ïáê=~ìë=ÇÉå=hçããÉåí~êÉå=áå=ÇÉê=òìÖÉÜ∏êáÖÉå=bêÉáÖåáëéêçJ òÉÇìê=Ç~ë=sçêÖÉÜÉå=ÉåíåÉÜãÉåW== NRV =
U= dê~ÑáâéêçÖê~ããáÉêìåÖ= procedure TForm1.Button3Click(Sender: TObject); var x1,y1,x2,y2: Integer; begin x1:=100;y1:=150;
//Ecke links oben festlegen
x2:=250;y2:=350;
//Ecke rechts unten festlegen
image1.canvas.Pen.Color:=RGB(0,0,0); image1.canvas.Pen.Width:=3; image1.Canvas.Brush.Color:=RGB(255,255,255); image1.canvas.Rectangle(x1,y1,x2,y2)
//Umriss-Farbe //Umriss-Stärke //Füll-Farbe //Rechteck zeichnen
end;==
_ÉãÉêâÉåëïÉêí=áëí=ÜáÉêI=Ç~ëë=ìåÄÉÇáåÖí=ÉáåÉ=cΩääJc~êÄÉ=~åÖÉÖÉÄÉå=ïÉêÇÉå=ãìëëK== a~ãáí= ~ÄÉê= åìê= ÇÉê= oÉÅâíÉÅâJrãêáëë= òì= ëÉÜÉå= áëíI= ãìëë= ~äë= cΩääJc~êÄÉ= ~ìÑ= ÇÉê= êÉÅÜíÉå=pÉáíÉ=ÇÉê=báÖÉåëÅÜ~Ñí= Brush.Color=Éñ~âí=ÇáÉ=eáåíÉêÖêìåÇÑ~êÄÉ=ÇÉê=j~äJ Ñä®ÅÜÉ=EÜáÉê=áëí=Éë=ïÉá≈F=~åÖÉÖÉÄÉå=ïÉêÇÉåK== bë=ïáêÇ=áå=táêâäáÅÜâÉáí=Éáå=âçãéäÉííÉë=oÉÅÜíÉÅâI=ÄÉëíÉÜÉåÇ=~ìë=rãêáëë= Pen=ìåÇ= fåÜ~äí= BrushI=ÉáåÖÉÑ®êÄíK=a~=ÇÉê=fåÜ~äí=~ÄÉê=ÇáÉëÉäÄÉ=c~êÄÉ=ïáÉ=ÇÉê=eáåíÉêÖêìåÇ= Ü~íI=ãÉêâí=Éë=ÇÉê=_Éíê~ÅÜíÉê=åáÅÜí=ìåÇ=ëáÉÜí=åìê=ÇÉå=oÉÅÜíÉÅâJo~ÜãÉåK==
8.2.5
Rechteckfläche
kìå=ïçääÉå=ïáê=ÇÉå=îáÉêíÉå=_ìííçå== ìåÇ= ÇáÉ= òìÖÉÜ∏êáÖÉ= bêÉáÖåáëéêçòÉÇìê= ÄÉíê~ÅÜíÉåK= fÜê= fåÜ~äí= ìåíÉêëÅÜÉáÇÉí= ëáÅÜ= îçã=fåÜ~äí=ÇÉê=îçêáÖÉå=bêÉáÖåáëéêçòÉÇìê=åìê=Ç~ÇìêÅÜI=Ç~ëë=ëçïçÜä=ÑΩê=ÇÉå=rãJ êáëë= Pen= ~äë= ~ìÅÜ= ÑΩê= ÇÉå= fåÜ~äí= Brush= ÇÉë= oÉÅÜíÉÅâë= ÇáÉëÉäÄÉ= c~êÄÉ= ÉáåÖÉëíÉääí= ïáêÇI=ÇáÉ=ëáÅÜ=îçå=ÇÉê=efåíÉêÖêìåÇÑ~êÄÉ=ÇÉê=iÉáåï~åÇ=ìåíÉêëÅÜÉáÇÉí=EÜáÉêW=Ää~ìFW=== procedure TForm1.Button4Click(Sender: TObject); var x1,y1,x2,y2: Integer; begin x1:=300;y1:=150;
//Anfangspunkt festlegen
x2:=500;y2:=200;
//Endpunkt festlegen
image1.canvas.Pen.Color:=RGB(0,0,255); image1.canvas.Pen.Width:=1; image1.Canvas.Brush.Color:=RGB(0,0,255); image1.canvas.Rectangle(x1,y1,x2,y2) end;
NSM= =
//Umriss-Farbe blau //Umriss-Stärke //Füll-Farbe blau //Rechteck zeichnen
UKO== dÉçãÉíêáëÅÜÉ=dÉÄáäÇÉ=ÉêòÉìÖÉå=
8.2.6
Quadratfläche
aÉê=ÑΩåÑíÉ=_ìííçå===================================================================îÉêä~åÖí=ëçäÅÜÉ= _ÉÑÉÜäÉ=áååÉêÜ~äÄ=ÇÉê=bêÉáÖåáëéêçòÉÇìêI=ÇáÉ=òìê=báåÑ®êÄìåÖ=ÉáåÉë=nì~Çê~íë=ãáí= îçêÖÉÖÉÄÉåÉã=jáííÉäéìåâí=ìåÇ=îçêÖÉÖÉÄÉåÉê=pÉáíÉåä®åÖÉ=ÑΩÜêÉå=ëçääÉåW= procedure TForm1.Button5Click(Sender: TObject); var x,y,seite,x1,y1,x2,y2: Integer; begin x:=400;y:=400;seite:=100;
//vorgegebene Daten
x1:=x-seite div 2;y1:=y-seite div 2;
//Anfangspunkt festlegen
x2:=x+seite div 2;y2:=y+seite div 2;
//Endpunkt festlegen
image1.canvas.Pen.Color:=RGB(255,255,0); image1.canvas.Pen.Width:=1; image1.Canvas.Brush.Color:=RGB(255,255,0); image1.canvas.Rectangle(x1,y1,x2,y2)
//Umriss-Farbe gelb //Umriss-Stärke //Füll-Farbe gelb //Rechteck zeichnen
end;===
aÉê=äÉíòíÉ=hçããÉåí~ê=ä®ëëí=Éë=ÉêâÉååÉå=Ó=Éáå=nì~Çê~í=ïáêÇ=ÉêòÉìÖíI=áåÇÉã=Éë= ~äë=oÉÅÜíÉÅâ=ãáí=ÖäÉáÅÜÉå=pÉáíÉåä®åÖÉå=îçêÄÉêÉáíÉí=ïáêÇW== a~òì= ãΩëëÉåI= ~ìëÖÉÜÉåÇ= îçã= ÖÉÖÉÄÉåÉå= jáííÉäéìåâí= ìåÇ= ÖÉÖÉÄÉåÉê= pÉáíÉåJ ä®åÖÉI= òìÉêëí= ÇáÉ= mçëáíáçåÉå= ÇÉê= äáåâÉå= çÄÉêÉå= ìåÇ= êÉÅÜíÉå= ìåíÉêÉå= bÅâÉ= ÄÉJ êÉÅÜåÉí=ïÉêÇÉåK=^åëíÉääÉ=ÇÉë=ΩÄäáÅÜÉå=aáîáëáçåëòÉáÅÜÉå= /=ãìëë=ÜáÉêI=Ç~=Éë=ëáÅÜ= ìã= Ö~åòò~ÜäáÖÉ= aáîáëáçå= Ü~åÇÉäíI= Ç~ë= pÅÜäΩëëÉäïçêí= div= îÉêïÉåÇÉí= ïÉêÇÉåK= aÉê=oÉëí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ëéêáÅÜí=Ç~åå=ÑΩê=ëáÅÜK==
8.2.7
Ellipsen-Umriss
pçääÉå=ÇáÉ=_áäÇéìåâíÉ=ÉáåÉë=_áäÇÉêê~ÜãÉåJfåÜ~äíë= Canvas=ëç=ÉáåÖÉÑ®êÄí=ïÉêÇÉåI= Ç~ëë=ÉáåÉ=çÑÑÉåÉ=çÇÉê=ÖÉÑΩääíÉ=bääáéëÉ=ÉåíëíÉÜí=îÉêä~åÖí=aÉäéÜáI=Ç~ÑΩê=ÇÉå=äáåâÉå= çÄÉêÉå=ìåÇ=ÇÉå=êÉÅÜíÉå=ìåíÉêÉå=bÅâéìåâí=ÇÉëàÉåáÖÉå=oÉÅÜíÉÅâë=~åòìÖÉÄÉåI=áå= Ç~ë=ÇáÉ=bääáéëÉ=ÉáåÄÉëÅÜêáÉÄÉå=ïáêÇK=pç=áëí=~ìÅÜ=ÇáÉ=_ÉëÅÜêáÑíìåÖ=ÇÉë=ëÉÅÜëíÉå== _ìííçåë=============================================================òì=îÉêëíÉÜÉåK= aÉãòìÑçäÖÉ=ëíáããí=ÇÉê=fåÜ~äí=ÇÉê=òìÖÉÜ∏êáÖÉå=bêÉáÖåáëéêçòÉÇìê=Ó=ãáí=^ìëå~ÜJ ãÉ= ÇÉë= äÉíòíÉå= _ÉÑÉÜäë= image1.canvas.Ellipse(x1,y1,x2,y2)= Ó= ãáí= ÇÉê= bêÉáÖåáëJ éêçòÉÇìê=òìã=bêòÉìÖÉå=ÉáåÉë=oÉÅÜíÉÅâê~ÜãÉåë=î∏ääáÖ=ΩÄÉêÉáåW== procedure TForm1.Button6Click(Sender: TObject); var x1,y1,x2,y2: Integer; begin
NSN =
U= dê~ÑáâéêçÖê~ããáÉêìåÖ= x1:=550;y1:=550; x2:=600;y2:=700; image1.canvas.Pen.Color:=RGB(0,0,0); image1.canvas.Pen.Width:=3; image1.Canvas.Brush.Color:=RGB(255,255,255); image1.canvas.Ellipse(x1,y1,x2,y2)
//Anfangspunkt festlegen //Endpunkt festlegen //Umriss-Farbe schwarz //Umriss-Stärke //Füll-Farbe weiß //Ellipse zeichnen
end;
8.2.8
Ellipsen-Fläche
bÄÉåëç=Öáäí=ÑΩê=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ãáí=ÇÉê=^ìÑëÅÜêáÑí= = ÇáÉ= ÉåÖÉ= sÉêï~åÇíëÅÜ~Ñí= ãáí= ÇÉã= fåÜ~äí= ÇÉêàÉåáÖÉå= bêÉáÖåáëéêçòÉÇìêI= ãáí= ÇÉê= Éáå=ÖÉÑΩääíÉë=oÉÅÜíÉÅâ=ãáí=ÖäÉáÅÜÉê=rãêáëëJ=ìåÇ=fåÜ~äíëÑ~êÄÉ=ÉêòÉìÖí=ïáêÇW== procedure TForm1.Button7Click(Sender: TObject); var x1,y1,x2,y2: Integer; begin x1:=100;y1:=400;
//Anfangspunkt festlegen
x2:=300;y2:=500;
//Endpunkt festlegen
image1.canvas.Pen.Color:=RGB(255,0,0); image1.canvas.Pen.Width:=3; image1.Canvas.Brush.Color:=RGB(255,0,0); image1.canvas.Ellipse(x1,y1,x2,y2)
//Umriss-Farbe rot //Umriss-Stärke //Füll-Farbe rot //Ellipse zeichnen
end;==
8.2.9
Kreisfläche
fëí=ëéÉòáÉää=ÉáåÉ=jÉåÖÉ=îçå=_áäÇéìåâíÉå=ëç=ÉáåòìÑ®êÄÉåI=Ç~ëë=ÇáÉ=ãáí=ÇÉã=~ÅÜíÉå== _ìííçå============================================================ÖÉÖÉÄÉåÉ=^ìÑÖ~ÄÉ=ÖÉä∏ëí=ïáêÇI= Ç~åå= ãΩëëÉå= ~ìë= ÇÉå= ÖÉã~ÅÜíÉå= ^åÖ~ÄÉå= ÑΩê= jáííÉäéìåâí= ìåÇ= o~Çáìë= òìÉêëí= ÇáÉ= bÅâéìåâíÉ= Eäáåâë= çÄÉå= ìåÇ= êÉÅÜíë= ìåíÉåF= ÉáåÉë= é~ëëÉåÇÉå= nì~Çê~íë= ÄÉJ êÉÅÜåÉí=ïÉêÇÉåK== a~åå= ïáêÇ= ÇáÉ= áå= Ç~ë= nì~Çê~í= ÉáåÄÉëÅÜêáÉÄÉåÉ= bääáéëÉ= å®ãäáÅÜ= òì= ÇÉã= ÖÉJ ïΩåëÅÜíÉå=hêÉáëW== procedure TForm1.Button8Click(Sender: TObject); var x,y,radius,x1,y1,x2,y2: Integer;
NSO= =
UKO== dÉçãÉíêáëÅÜÉ=dÉÄáäÇÉ=ÉêòÉìÖÉå= begin x:=150;y:=600;radius:=100;
//Daten der Aufgabenstellung
x1:=x-radius div 2;y1:=y-radius div 2;
//Quadratecke links oben
x2:=x+radius div 2;y2:=y+radius div 2;
//Quadratecke rechts unten
image1.canvas.Pen.Color:=RGB(0,255,255); image1.canvas.Pen.Width:=1; image1.Canvas.Brush.Color:=RGB(0,255,255); image1.canvas.Ellipse(x1,y1,x2,y2)
//Umriss-Farbe lila //Umriss-Stärke //Füll-Farbe lila //Kreis zeichnen
end;
8.2.10
Text
aáÉ=_ÉëÅÜêáÑíìåÖ=====================================================================ÇÉë=îçêäÉíòíÉå= íÉå= _ìííçåë= îÉêä~åÖíI= ÉáåÉ= jÉåÖÉ= îçå= _áäÇéìåâíÉå= ëç= ÉáåòìÑ®êÄÉåI= Ç~ëë= Éáå= îçêÖÉÖÉÄÉåÉê= qÉñí= ãáí= îçêÖÉÖÉÄÉåÉê= pÅÜêáÑíÖê∏≈É= ìåÇ= ÓÑ~êÄÉ= êÉÅÜíë= ìåíÉê= ÇÉê= ÖÉå~ååíÉå=mçëáíáçå=ÉêëÅÜÉáåíK=aáÉ=òìÖÉÜ∏êáÖÉ=bêÉáÖåáëéêçòÉÇìê=Éêâä®êí=Ç~ë=sçêJ ÖÉÜÉåW=== procedure TForm1.Button9Click(Sender: TObject); var x1,y1: Integer;tx: String; begin x1:=300;y1:=600; image1.Canvas.Brush.Color:=RGB(255,255,255);
//Bezugspunkt festlegen //Füll-Farbe weiß
tx:='Vieweg';
//Vorgegebener Text
image1.canvas.Font.Color:=RGB(255,0,0);
//Schrift-Farbe rot
image1.canvas.Font.Size:=24; image1.canvas.TextOut(x1,y1,tx)
//Schrift-Stärke //Schrift einfärben
end;
8.2.11
Löschen
tÉåå=~ìÅÜ=~ìÑ=ÇÉã=_ìííçå== ëíÉÜíI=ëç=ïáÇÉêëéêáÅÜí=Ç~ë=åáÅÜí=ÇÉê=ÉáåÖ~åÖë=ÖÉã~ÅÜíÉå=^ìëë~ÖÉI=Ç~ëë=ÖêìåÇJ ë®íòäáÅÜ=åáÅÜí=ÖÉä∏ëÅÜí=ïÉêÇÉå=â∏ååÉK== bë= â~åå= åìê= åÉì= ÉáåÖÉÑ®êÄí= ïÉêÇÉåI= ìåÇ= ïÉåå= ~ääÉë= îÉêëÅÜïáåÇÉå= ëçääK= aáÉ= ÉáåÑ~ÅÜëíÉ= sçêÖÉÜÉåëïÉáëÉ= ÄÉëíÉÜí= Ç~êáåI= Éáå= oÉÅÜíÉÅâ= îçã= _áäÇéìåâí= Pixel[0,0]= EçÄÉå= äáåâëF= ΩÄÉê= ÇáÉ= ÖÉë~ãíÉ= j~äÑä®ÅÜÉ= òì= äÉÖÉå= ìåÇ= åÉì= ãáí= ÇÉê= eáåíÉêÖêìåÇÑ~êÄÉ=ÉáåòìÑ®êÄÉåK== dêç≈òΩÖáÖÉ=^åÖ~ÄÉå=ÑΩê=ÇáÉ=bÅâÉ=êÉÅÜíë=ìåíÉå=ëÅÜ~ÇÉå=Ç~ÄÉá=åáÅÜíW== NSP =
U= dê~ÑáâéêçÖê~ããáÉêìåÖ= procedure TForm1.Button10Click(Sender: TObject); begin image1.Canvas.Pen.Color:=RGB(255,255,255);
//Rand weiß
image1.Canvas.Brush.Color:=RGB(255,255,255);
//Inhalt weiß
image1.Canvas.Rectangle(0,0,2000,2000)
//Färbe neu
end;==
8.2.12
Achsenkreuz
táÉ=~ÄÉê=ÉåíëíÉÜí=Ç~ë=^ÅÜëÉåâêÉìòI=ãáí=ÇÉëëÉå=eáäÑÉ=ïáê=âçåíêçääáÉêÉå=â∏ååÉåI= çÄ=í~íë®ÅÜäáÅÜ=~å=ÇÉê=êáÅÜíáÖÉå=mçëáíáçå=áå=ÇÉê=êáÅÜíáÖÉ=dê∏≈É=Ç~ë=êáÅÜíáÖÉ=dê~J ÑáâÉäÉãÉåí=ÉêëÅÜÉáåí=E_áäÇ=UKSF\===
= _áäÇ=UKSW=pçÑçêí=ëáÅÜíÄ~êÉë=^ÅÜëÉåâêÉìò= a~= Éë= âÉáåÉå= _ìííçå= òìê= báåÑ®êÄìåÖ= ÇáÉëÉë= ^ÅÜëÉåâêÉìòÉë= ÖáÄíI= ãΩëëÉå= ÇáÉ= _ÉÑÉÜäÉ=òì=ÇÉëëÉå=báåÑ®êÄìåÖ=áå=ÉáåÉê=~åÇÉêÉå=bêÉáÖåáëéêçòÉÇìê=ÉåíÜ~äíÉå=ëÉáåK== oáÅÜíáÖW= bêáååÉêå= ïáê= ìåë= ~å= ÇáÉ= ^ÄëÅÜåáííÉ= OKOKT= ìåÇ= QKTKRK= açêí= äÉêåíÉå= ïáêI= Ç~ëë= ÄÉáã= häáÅâ= ÇÉë= kìíòÉêë= ~ìÑ= Ç~ë= å~ÅÜ= êÉÅÜíë= ÖÉêáÅÜíÉíÉ= ÖêΩåÉ= aêÉáÉÅâI= ïÉåå= ÇáÉ= i~ìÑòÉáí= ÄÉÖáååí= ìåÇ= ÇáÉ= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= í~íë®ÅÜäáÅÜ= ÜÉêÖÉëíÉääí= ïáêÇI=Ç~ë=cçêãìä~êJpí~åÇ~êÇÉêÉáÖåáë=Create=ëí~ííÑáåÇÉíK== NSQ= =
UKO== dÉçãÉíêáëÅÜÉ=dÉÄáäÇÉ=ÉêòÉìÖÉå= aÉå= o~ÜãÉå= ÑΩê= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= ÑΩê= ÇáÉëÉë= bêÉáÖåáë= ÉêÜ~äíÉå= ïáê= ÑçäÖäáÅÜ= ëçÑçêí=å~ÅÜ=açééÉäâäáÅâ=~ìÑ=Ç~ë=cçêãìä~ê=EÇáÉ=^êÄÉáíëÑä®ÅÜÉFW== procedure TForm1.FormCreate(Sender: TObject); begin end;
cΩê=ÇÉå=fåÜ~äí=ÇáÉëÉê=bêÉáÖåáëéêçòÉÇìê=ãΩëëÉå=ïáê=ìåë=~ääÉ=_ÉÑÉÜäÉ=ΩÄÉêäÉÖÉåI= ãáí=ÇÉêÉå=eáäÑÉ=å~ÅÜÉáå~åÇÉê== • • • •
ÇáÉ=^ÅÜëÉ=çÄÉå=îçå=äáåâë=å~ÅÜ=êÉÅÜíë=EñJ^ÅÜëÉF== ÇáÉ=mÑÉáäÉ=~ã=êÉÅÜíÉå=båÇÉ=ÇÉê=çÄÉêÉå=^ÅÜëÉ= ÇáÉ=ëÉåâêÉÅÜíÉå=qÉáäëíêáÅÜÉ=ÇÉê=çÄÉêÉå=^ÅÜëÉ= ÇáÉ=_ÉëÅÜêáÑíìåÖÉå=ÇÉê=çÄÉêÉå=^ÅÜëÉ=
• • • •
ÇáÉ=^ÅÜëÉ=äáåâë=îçå=çÄÉå=å~ÅÜ=ìåíÉå=EóJ^ÅÜëÉF= ÇáÉ=mÑÉáäÉ=~ã=ìåíÉêÉå=båÇÉ=ÇÉê=äáåâÉå=^ÅÜëÉ= ÇáÉ=ï~~ÖÉêÉÅÜíÉå=qÉáäëíêáÅÜÉ=ÇÉê=äáåâÉå=^ÅÜëÉ= ÇáÉ=_ÉëÅÜêáÑíìåÖÉå=ÇÉê=äáåâÉå=^ÅÜëÉ=
ëÅÜï~êò=ÉáåÖÉÑ®êÄí=ïÉêÇÉåK=bë=áëí=òì=ëÉÜÉå=Ó=ÜáÉê=ãìëë=îáÉä=^ìÑï~åÇ=ÖÉíêáÉÄÉå= ïÉêÇÉåI=ïáÉ=òìãÉáëí=ÄÉá=dê~ÑáâJmêçÖê~ããáÉêìåÖK== cΩê=ÇáÉ=qÉáäëíêáÅÜÉ=ìåÇ=ÇáÉ=_ÉëÅÜêáÑíìåÖÉå=ïáêÇ=ÄÉêÉáíë=ÇáÉ=w®ÜäëÅÜäÉáÑÉ=~äë=~ÄâΩêJ òÉåÇÉ= pÅÜêÉáÄïÉáëÉ= ãÉÜêÉêÉê= ÖäÉáÅÜ~êíáÖÉê= _ÉÑÉÜäÉ= îÉêïÉåÇÉíI= Éáå= sçêÖêáÑÑ= ~ìÑ= Ç~ë=âçããÉåÇÉ=h~éáíÉäI=áå=ÇÉã=ëáÉ=Ç~åå=~ìëÑΩÜêäáÅÜ=îçêÖÉëíÉääí=ìåÇ=Éêâä®êí=ïáêÇW== procedure TForm1.FormCreate(Sender: TObject); var i: Integer; tx: String; begin image1.Canvas.Pen.color:=RGB(0,0,0); image1.Canvas.Brush.color:=RGB(255,255,255);
//Linienfarbe schwarz //Hintergrundfarbe weiß
image1.canvas.moveTo(40,15);image1.canvas.LineTo(650,15); for i:=0 to 11 do
//x- Achse
//senkrechte Teil-Striche
begin image1.canvas.MoveTo(50+50*i,25); image1.canvas.LineTo(50+50*i,5); end; image1.canvas.moveTo(625,5);
//Pfeil rechts
image1.canvas.LineTo(650,15); image1.canvas.moveTo(625,25); image1.canvas.LineTo(650,15);
NSR =
U= dê~ÑáâéêçÖê~ããáÉêìåÖ= for i:=0 to 11 do
//Beschriftung x-Achse
begin Str(50+i*50,tx); image1.Canvas.TextOut(50+i*50-Canvas.TextWidth(tx) div 2,25,tx) end; image1.canvas.moveTo(15,40); image1.canvas.LineTo(15,750); for i:=0 to 13 do
//y-Achse
// waagerechte Teil-Striche
begin image1.canvas.MoveTo(25,50+50*i);image1.canvas.LineTo(5,50+50*i) end; image1.canvas.moveTo(5,725);
//Pfeil unten
image1.canvas.LineTo(15,750); image1.canvas.moveTo(25,725); image1.canvas.LineTo(15,750); for i:=0 to 13 do
//Beschriftung y-Achse
begin Str(50+i*50,tx); image1.Canvas.TextOut(25, 50+i*50-Canvas.TextHeight(tx) div 2,tx) end end;==
8.3
Text verändern _áäÇ= UKT= òÉáÖí= ÇáÉ= åÉìÉ= ^ìÑÖ~ÄÉW= _Éá= häáÅâ= ~ìÑ= ÇÉå= çÄÉêÉå= _ìííçå= ëçää= êÉÅÜíë= ìåíÉê= ÇÉê= ~åÖÉÖÉÄÉåÉå= mçëáíáçå= EÇçêí= ÇìêÅÜ= Éáå= âäÉáåÉë= ^ÅÜëÉåâêÉìò= ÇÉìíäáÅÜ= ÖÉã~ÅÜíF=ÇÉê=qÉñí=sáÉïÉÖ=ÉêëÅÜÉáåÉåK==
= _áäÇ=UKTW=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ= aáÉ=bêÉáÖåáëéêçòÉÇìê=ÑΩê=ÇÉå=çÄÉêÉå=_ìííçå=ïìêÇÉ=áã=îçêáÖÉå=^ÄëÅÜåáíí=ëÅÜçå= Éêâä®êíI=ëáÉ=â~åå=ÜáÉê=ëÅÜåÉää=ïáÉÇÉêÜçäí=ïÉêÇÉåW== NSS= =
UKP== qÉñí=îÉê®åÇÉêå= procedure TForm1.Button1Click(Sender: TObject); var x1,y1: Integer;tx: String; begin x1:=100;y1:=200; image1.canvas.Pen.color:=RGB(0,0,0);
//Bezugspunkt festlegen //Farbe f. Achsenkreuz schwarz //Kleines Achsenkreuz einfärben
image1.Canvas.moveto(x1-1,y1-1);image1.canvas.lineTo(x1+50,y1-1); image1.Canvas.moveto(x1-1,y1-1);image1.canvas.lineTo(x1-1,y1+50); image1.Canvas.Brush.Color:=RGB(255,255,255); //Hintergrundfarbe weiß tx:='Vieweg';
//Text festlegen
image1.canvas.Font.Color:=RGB(255,0,0);
//Schrift-Farbe rot
image1.canvas.Font.Size:=24;
//Schrift-Stärke
image1.canvas.TextOut(x1,y1,tx) //Schrift positionieren und ausgeben end;
t~ë=~ÄÉê=áëí=òì=íìåI=ïÉåå=ÇÉê=ãáííäÉêÉ=_ìííçå=ÑçêÇÉêí=Ändere den Text in “Teubner”=\=bêáååÉêå=ïáê=ìåë=~å=ìåëÉêÉå=j~äÉêW=tÉåå=ÇáÉ=c~êÄÉ=íêçÅâÉå=áëíI=â~åå=Éê= åáÅÜí=ãÉÜê=âçêêáÖáÉêÉåI=ëçåÇÉêå=åìê=ΩÄÉêã~äÉåK== cçäÖäáÅÜ=Ü~ÄÉå=ïáê=òïÉá=j∏ÖäáÅÜâÉáíÉåW== • aáÉ= ÖÉë~ãíÉ= iÉáåï~åÇ= ïáêÇ= åÉì= ÉáåÖÉÑ®êÄí= EëáÉÜÉ= ^ÄëÅÜåáíí= UKOKNNFK= a~åå= ïΩêÇÉå=~ÄÉê=~ìÅÜ=~ääÉ=~åÇÉêÉå=j~äÉêÖÉÄåáëëÉ=îÉêëÅÜïáåÇÉåK=tçääÉå=ïáê=Ç~ë\== • aáÉ=òïÉáíÉ=j∏ÖäáÅÜâÉáí=ÄÉëíÉÜí=Ç~êáåI=ÇÉå=qÉñí=Vieweg=ãáí=ÇÉê=c~êÄÉ=ÇÉë=eáåJ íÉêÖêìåÇÉë= åçÅÜ= Éáåã~ä= å~ÅÜòìòÉáÅÜåÉå= Ó= Ç~åå= áëí= ÇáÉëÉê= qÉñí= åáÅÜí= ãÉÜê= òì=ëÉÜÉåK== ^åëÅÜäáÉ≈ÉåÇ=â~åå=Ç~åå=îÉê~åä~ëëí=ïÉêÇÉåI=Ç~ëë=ÇáÉ=_áäÇéìåâíÉ=ëç=ÉáåÖÉÑ®êÄí= ïÉêÇÉåI=Ç~ëë=ÇÉê=åÉìÉ=qÉñí=~å=ÖÉïΩåëÅÜíÉê=píÉääÉ=ÉêâÉååÄ~ê=ïáêÇK== aáÉ=ïáÉÇÉêÖÉÖÉÄÉåÉ=bêÉáÖåáëéêçòÉÇìê=ÑçäÖí=ÇÉê=òïÉáíÉå=j∏ÖäáÅÜâÉáíW== procedure TForm1.Button2Click(Sender: TObject); var x1,y1: Integer;tx1,tx2: String; begin x1:=100;y1:=200;
//Bezugspunkt festlegen
image1.Canvas.Brush.Color:=RGB(255,255,255); //Hintergund-Farbe weiß tx1:='Vieweg';
//Alter Text wird wiederholt
image1.canvas.Font.Color:=RGB(255,255,255);
//Schrift-Farbe weiß
image1.canvas.Font.Size:=24;
//Schrift-Stärke wie vorher
image1.canvas.TextOut(x1,y1,tx1);
//Schrift weiß nachzeichnen
NST =
U= dê~ÑáâéêçÖê~ããáÉêìåÖ= tx2:='Teubner'; image1.canvas.Font.Color:=RGB(0,255,0); image1.canvas.Font.Size:=24; image1.canvas.TextOut(x1,y1,tx2)
//Neuer Text //Schrift-Farbe neu: grün //Schrift-Stärke neu //neue Schrift ausgeben
end;
§ÄêáÖÉåë= ÉåíÜ®äí= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= ÉêëíÉå= _ìííçå= åáÅÜí= ÉáåÉå= ëçäÅÜÉå= qÉáä= i∏ëÅÜÉå= ÇìêÅÜ= k~ÅÜòÉáÅÜåÉå= ãáí= ÇÉê= eáåíÉêÖêìåÇÑ~êÄÉI= ìåÇ= ÑçäÖÉêáÅÜíáÖ= ïáêÇ= ÇÉê= qÉñí= Teubner= ÄÉá= å~ÅÜÑçäÖÉåÇÉã= häáÅâ= ~ìÑ= ÇÉå= çÄÉêÉå= _ìííçå= åáÅÜí= ÄÉëÉáíáÖíI= ëçåÇÉêå= åìê= íÉáäïÉáëÉ= ΩÄÉêã~äí= îçå= ÇÉã= âΩêòÉêÉå= qÉñí= ViewegK= _áäÇ= UKU=òÉáÖí=ÉëK==
= _áäÇ=UKUW=kÉìÉ=qÉñí~ìëÖ~ÄÉ=~ìÑ=îçêÜ~åÇÉåÉå=qÉñí=çÜåÉ=ÇÉëëÉå=i∏ëÅÜìåÖ==
8.4
Bildschirmschoner gÉÇÉ=_ÉëÅÜêÉáÄìåÖ=ÉáåÉë=_áäÇëÅÜáêãëÅÜçåÉêë=ÖäÉáÅÜí=ÉáåÉê=fåÑä~íáçå=ÇÉë=tçêíÉë= òìÑ®ääáÖK=pç=ëçää=ÇÉê=îçêÖÉëíÉääíÉ=ÉáåÑ~ÅÜÉ=_áäÇëÅÜáêãëÅÜçåÉê=áå=ÑçäÖÉåÇÉê=tÉáëÉ= ~êÄÉáíÉåW== • k~ÅÜ=ÇÉã=pí~êí=ÇÉê=i~ìÑòÉáí=ëçääÉå=~ìÑ=ÇÉã=_áäÇëÅÜáêã=å~ÅÜÉáå~åÇÉê=áå=òìJ Ñ®ääáÖÉå= wÉáí~Äëí®åÇÉå= áå= òìÑ®ääáÖÉê= c~êÄÉ= ãáí= òìÑ®ääáÖÉê= pí®êâÉ= ~åÉáå~åÇÉê= Ü®åÖÉåÇÉ=dÉê~ÇÉå=îçå= òìÑ®ääáÖÉå=mìåâíÉå=òì=òìÑ®ääáÖÉå=mìåâíÉå=ÇÉë=Ö~åJ òÉå=_áäÇëÅÜáêãÉë=ÉåíëíÉÜÉåK==
= _áäÇ=UKVW=táêâìåÖ=ÇÉë=_áäÇëÅÜáêãëÅÜçåÉêë=å~ÅÜ=ÉáåáÖÉå=pÉâìåÇÉå=== NSU= =
UKQ== _áäÇëÅÜáêãëÅÜçåÉê= _áäÇ= UKV= òÉáÖí= ÉáåÉ= jçãÉåí~ìÑå~ÜãÉ= ÇÉë= _áäÇëÅÜáêãëI= å~ÅÜÇÉã= ÇÉê= pÅÜçåÉê= Éáå=é~~ê=pÉâìåÇÉå=ÖÉä~ìÑÉå=ï~êK== táÉ=ëçääíÉå=ïáê=~å=ÇáÉ=i∏ëìåÖ=ÇáÉëÉê=mêçÖê~ããáÉê~ìÑÖ~ÄÉ=ÜÉê~åÖÉÜÉå\=wìÉêëí= ãìëë= ÖÉëáÅÜÉêí= ïÉêÇÉåI= Ç~ëë= ~ìÅÜ= í~íë®ÅÜäáÅÜ= ÇÉê= Ö~åòÉ= _áäÇëÅÜáêã= ÉêÑ~ëëí= ïáêÇK=a~ë=ÉêÑçäÖí=Éáåã~ä=ÇìêÅÜ=Ç~ë=báåëíÉääÉå=ÇÉê=báÖÉåëÅÜ~Ñí=wsMaximized=áå=ÇÉê= wÉáäÉ= WindowState= ÇÉë= lÄàÉâíáåëéÉâíçêë= îçã= cçêãìä~ê= E_áäÇ= UKNMI= ëáÉÜÉ= ~ìÅÜ= ^ÄëÅÜåáíí=NKOKNFK====
= _áäÇ=UKNMW=cÉåëíÉê=ã~ñáã~ä=ã~ÅÜÉå= a~åå= ãìëë= òìë®íòäáÅÜ= ÖÉëáÅÜÉêí= ïÉêÇÉåI= Ç~ëë= Ç~ë= _áäÇçÄàÉâí= Image1= ÇÉå= âçãJ éäÉííÉå=fååÉåê~ìã=ÇÉë=cçêãìä~êë= Form1=ÑΩääíK=a~ë=â~åå=Ç~ÇìêÅÜ=ÉêÑçäÖÉåI=Ç~ëë= ÇÉê=cÉåëíÉêJo~ÜãÉå=Öêç≈=ÖÉåìÖ=~ìÑÖÉòçÖÉå=ïáêÇK== aìêÅÜ=é~ëëÉåÇÉ=_ÉÑÉÜäÉ=áã=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=òìã=bêÉáÖåáë=Create=bêJ òÉìÖìåÖ=ÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=ïáêÇ=ïÉáíÉê=Ç~ÑΩê=ÖÉëçêÖíI=Ç~ëë=ÄÉá=_ÉÖáåå=ÇÉê= i~ìÑòÉáíI=ÇK=ÜK=ÄÉá=eÉêëíÉääìåÖ=ÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉI=ÇÉê=_áäÇÉêê~ÜãÉå=Ö~ê~åJ íáÉêí=äáåâë=çÄÉå=éä~íòáÉêí=ïáêÇK=^ì≈ÉêÇÉã=ïáêÇ=ãáí=eáäÑÉ=ÉáåÉë=Öêç≈Éå=oÉÅÜíÉÅâë= ÇÉê=eáåíÉêÖêìåÇ=ëÅÜï~ÅÜ=Öê~ì=ÉáåÖÉÑ®êÄíW==== procedure TForm1.FormCreate(Sender: TObject); begin image1.Top:=0;image1.Left:=0;
//Rahmen beginnt links oben
image1.canvas.brush.color:=RGB(215,215,215); //Füllfarbe schwach grau image1.canvas.Pen.color:=RGB(215,215,215); //Umrissfarbe schwach grau image1.Canvas.Rectangle(0,0,2000,2000)
//Rechteck einfärben
end;
páÅÜÉê= áëí= ïÉáíÉê= ~ìÅÜI= Ç~ëë= ÇÉê= ^Ää~ìÑ= ÇÉë= báåÑ®êÄÉåë= ÇÉê= dÉê~ÇÉå= ~ìÑ= ÇÉê= iÉáåï~åÇ=ÇìêÅÜ=ÉáåÉå=qáãÉê=ÖÉëíÉìÉêí=ïÉêÇÉå=ãìëë=EëáÉÜÉ=^ÄëÅÜåáíí=SFK=^ÄÉê= ÉáåÉ=ïáÅÜíáÖÉ=cê~ÖÉ=áëí=åçÅÜ=òì=âä®êÉåW=tÉåå=ÄÉáã=báåíêÉíÉå=ÇÉë= qáãÉêJbêÉáÖJ åáëëÉë=ÇáÉ=åÉì=òì=ÉêòÉìÖÉåÇÉ=dÉê~ÇÉ=~å=ÇáÉ=äÉíòíÉ=ÉêòÉìÖíÉ=dÉê~ÇÉ=ìåãáííÉäÄ~ê= ~åëÅÜäáÉ≈Éå=ëçää=Ó=ïçÜÉê=ÉêÑ®Üêí=ã~å=Ç~åå=ÇÉêÉå=äÉíòíÉå=båÇéìåâí\== aáÉ=^åíïçêí=áëí=áå=_áäÇ=UKV=çÄÉå=~å=ÇÉê=_áäÇëÅÜáêãâ~åíÉ=òì=ëÉÜÉåW=wïÉá=i~ÄÉäë= ΩÄÉêåÉÜãÉå= îçå= qáãÉêJbêÉáÖåáë= òì= qáãÉêJbêÉáÖåáë= áå= ÑçäÖÉåÇÉê= tÉáëÉ= ÇáÉëÉ= a~íÉåW=qêáíí=Éáå=qáãÉêJbêÉáÖåáë=Éáå=ïáêÇ=ÇáÉ=mçëáíáçå=ÇÉë=äÉíòíÉå=båÇéìåâíÉë=Ççêí= ~ÄÖÉäÉëÉåI= Éáå= åÉìÉê= båÇéìåâí= ïáêÇ= ÉêòÉìÖíI= ÇáÉ= dÉê~ÇÉ= ïáêÇ= ÉáåÖÉÑ®êÄíI= ÇÉê= åÉìÉå= båÇéìåâí= ïáêÇ= ~åëÅÜäáÉ≈ÉåÇ= áå= ÇÉå= ÄÉáÇÉå= i~ÄÉäë= ~ÄÖÉäÉÖíK= _áë= òìã= å®ÅÜëíÉå=qáãÉêJbêÉáÖåáëK== NSV =
U= dê~ÑáâéêçÖê~ããáÉêìåÖ= a~ë= ÇêáííÉ= i~ÄÉäI= çÄÉå= áå= _áäÇ= UKVI= Ü~í= ÉáåÉ= ~åÇÉêÉ= _ÉÇÉìíìåÖW= lÑÑÉåëáÅÜíäáÅÜ= ëçää=ÇçÅÜ=ÇÉê=_áäÇëÅÜáêãëÅÜçåÉê=~ìíçã~íáëÅÜ=åÉì=ëí~êíÉåI=ïÉåå=ÇÉê=_áäÇëÅÜáêã= ÇìêÅÜ=ëÉÜê=îáÉäÉ=dÉê~ÇÉå=Ñ~ëí=ÖÉÑΩääí=áëíK=aÉëÜ~äÄ=ò®Üäí=ÇáÉëÉë=ÇêáííÉ=i~ÄÉä=ãáíI= ïáÉ=îáÉäÉ=dÉê~ÇÉå=Éë=ëÅÜçå=ÖáÄíI=ìåÇ=ÄÉá=PMM=ïáêÇ=åÉì=ÄÉÖçååÉåK== k~íΩêäáÅÜ=ïÉêÇÉå=ÇáÉëÉ=ÇêÉá=i~ÄÉäë=å~ÅÜ=cÉêíáÖëíÉääìåÖ=ÇÉë=_áäÇëÅÜáêãëÅÜçåÉêë= ëé®íÉê= îçå= ^åÑ~åÖ= ~å= ãáí= eáäÑÉ= ÇÉê= wÉáäÉ= Visible= áÜêÉê= lÄàÉâíáåëéÉâíçêÉå= ~ìÑ= ìåëáÅÜíÄ~ê=ÉáåÖÉëíÉääí=EëáÉÜÉ=^ÄëÅÜåáíí=QKSFK= a~ë= ï~ê= ëÅÜçå= ~ääÉëI= ï~ë= ÑΩê= Ç~ë= sÉêëí®åÇåáë= ÇÉê= ÑçäÖÉåÇÉå= bêÉáÖåáëéêçòÉÇìê= òìã=qáãÉêJbêÉáÖåáë=åçíïÉåÇáÖ=áëíW=== procedure TForm1.Timer1Timer(Sender: TObject); var x_alt, y_alt, x_neu, y_neu, anzahl: Integer; begin //Übernehmen aus den drei Labels x_alt:=StrToInt(Label1.Caption); y_alt:=StrToInt(Label2.Caption); anzahl:=StrToInt(Label3.Caption); Randomize; x_neu:=Random(1152); y_neu:=Random(801); //neuer Endpunkt if anzahl10) and (x10) and (yvergleich then anzahl:=anzahl+1;
//Untersuchung 1.Zeile
wert:=StrToInt(ListBox5.Items[1]); if wert> vergleich then anzahl:=anzahl+1;
//Untersuchung 2.Zeile
wert:=StrToInt(ListBox5.Items[2]); if wert> vergleich then anzahl:=anzahl+1;
//Untersuchung 3.Zeile
...
// und so weiter
wert:=StrToInt(ListBox5.Items[15]); if wert> vergleich then anzahl:=anzahl+1;
//Untersuchung 16. Zeile
ShowMessage('Es sind '+IntToStr(anzahl)+' Länder') end;
NUS= =
VKN== ^Äò®ÜäÉå=áå=iáëíÉå= ^äë=ÉêëíÉë=ïáêÇ=ÇÉê=w®ÜäïÉêâëëéÉáÅÜÉêéä~íò=anzahl=îÉêÉáåÄ~êíX=ãáí=ÉáåÉã=Öê∏≈íÉå= tÉêí=îçå=Ü∏ÅÜëíÉåë= 16=êÉáÅÜí=ÇÉê=qóé= Byte=î∏ääáÖ=~ìëK=a~åå=Äê~ìÅÜÉå=ïáê=~ÄÉê= åçÅÜ=ÉáåÉå=péÉáÅÜÉêéä~íòI=áå=ÇÉã=ïáê=ÇÉå=w~ÜäÉåïÉêí=~ìë=ÇÉê=àÉïÉáäáÖÉå=wÉáäÉ= ~ÄäÉÖÉå=ãΩëëÉåK=açêí=íêÉíÉå=jáääáçåÉå=~ìÑ=Ó=ÑçäÖäáÅÜ=qóé=IntegerK== a~ë= w®ÜäïÉêâ= ïáêÇ= ~ìÑ= kìää= ÖÉëÉíòíK= a~åå= ÄÉÖáååí= ÇáÉ= råíÉêëìÅÜìåÖK= aÉê= EqÉñíJFfåÜ~äí= ÇÉê= ÉêëíÉå= wÉáäÉ= ïáêÇ= ãáí= eáäÑÉ= ÇÉê= cìåâíáçå= StrToInt= òì= ÉáåÉã= w~ÜäÉåïÉêí=ÖÉã~ÅÜí=ìåÇ=áå=ÇÉå=péÉáÅÜÉêéä~íò= wert=ÖÉÄê~ÅÜíK=hçããí=Ççêí=ÉáåÉ= w~Üä= Öê∏≈Éê= ~äë= R= jáääáçåÉå= ~åI= ïáêÇ= ãáííÉäë= ÇÉë= _ÉÑÉÜäë= anzahl:=anzahl+1= Ç~ë= w®ÜäïÉêâ=ÖÉëÅÜ~äíÉíK=pç=ÖÉÜí=Éë=ïÉáíÉêK== cΩê=ÇÉå=ÇÉåâÉåÇÉå=jÉåëÅÜÉå=áëí=~ääÉë=âä~êI=ìåÇ=Éê=â~åå=ÇáÉ=ÇêÉá=mìåâíÉ=éêçÄJ äÉãäçë= áåíÉêéêÉíáÉêÉåW= ìåÇ= ëç= ïÉáíÉê= KKK= ÄáëK= aÉê= `çãéìíÉê= â~åå= Ç~ë= åáÅÜíK= bê= â~åå=åáÅÜí=ÇÉåâÉå>=pÅÜ~ÇÉK== pçI=ïáÉ=Éê=Äáë=àÉíòí=Ç~ëíÉÜíI=áëí=ÇÉê=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=åáÅÜí=îÉê~êÄÉáíÄ~êK= jΩëëÉå=ïáê=~ääÉ=ëÉÅÜòÉÜå=qÉëíë=ÉáåòÉäå=ÜáåëÅÜêÉáÄÉå\=a~ë=â~åå=åáÅÜí=ëÉáåI=ÇÉåå= ÄÉá=í~ìëÉåÇ=wÉáäÉå=Ü®ííÉå=ïáê=Ç~åå=í~ìëÉåÇ=qÉëíë=òì=éêçÖê~ããáÉêÉåK== aáÉ= i∏ëìåÖ= ÜÉá≈í= w®ÜäëÅÜäÉáÑÉK= iÉêåÉå= ïáê= ÇáÉ= ëÉÅÜë=pÅÜêáííÉ= ~ìÑ= ÇÉã= tÉÖ= òìê= w®ÜäëÅÜäÉáÑÉ=âÉååÉåK== • pÅÜêáíí=NW= aÉê=_ÉÑÉÜä=çÇÉê=ÇáÉ=_ÉÑÉÜäëÑçäÖÉI=ÇáÉ=ëáÅÜ=ïáÉÇÉêÜçäíI=áëí=áå= begin= ìåÇ=end=ÉáåòìëÅÜäáÉ≈ÉåW== begin wert:=StrToInt(ListBox5.Items[0]); if wert>vergleich then anzahl:=anzahl+1 end
• pÅÜêáíí= OW= aÉêàÉåáÖÉ= w~ÜäÉåïÉêíI= ÇÉê= ëáÅÜ= îçå= j~ä= òì= j~ä= ®åÇÉêíI= áëí= ÇìêÅÜ= ÇÉå=k~ãÉå=ÉáåÉë=péÉáÅÜÉêéä~íòÉë=òì=ÉêëÉíòÉåI=ΩÄäáÅÜ=áëí=ÜáÉê= iK= i=ÜÉá≈í=Ç~åå= i~ìÑî~êá~ÄäÉW== begin wert:=StrToInt(ListBox5.Items[i]); if wert>vergleich then anzahl:=anzahl+1 end
• pÅÜêáíí=PW=a~êΩÄÉê=ïáêÇ=ÉáåÉ=for...to...doJwÉáäÉ=ÖÉëÅÜêáÉÄÉåW== for i:=... to ... do begin wert:=StrToInt(ListBox5.Items[i]); if wert>vergleich then anzahl:=anzahl+1 end
NUT =
V= w®ÜäëÅÜäÉáÑÉå= • pÅÜêáíí=QW=aÉê=pí~êíïÉêí=ÑΩê=ÇáÉ=i~ìÑî~êá~ÄäÉ=i=ïáêÇ=ÉáåÖÉíê~ÖÉåW= for i:=0 to ... do begin wert:=StrToInt(ListBox5.Items[i]); if wert>vergleich then anzahl:=anzahl+1 end
• pÅÜêáíí=RW=aÉê=båÇïÉêí=ÑΩê=ÇáÉ=i~ìÑî~êá~ÄäÉ=i=ïáêÇ=ÉáåÖÉíê~ÖÉåW= for i:=0 to 15 do begin wert:=StrToInt(ListBox5.Items[i]); if wert>vergleich then anzahl:=anzahl+1 end
• pÅÜêáíí=SW=aáÉ=i~ìÑî~êá~ÄäÉ=ïáêÇ=é~ëëÉåÇ=îÉêÉáåÄ~êíK=_Éá=ìåë=êÉáÅÜí=ByteK= gÉíòí=áëí=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=ÑÉêíáÖI=ÄÉá=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ÉêÑ~ÜêÉå=ïáêI=Ç~ëë= ÖÉê~ÇÉ=ÑΩåÑ=ÇÉìíëÅÜÉ=_ìåÇÉëä®åÇÉê=ãÉÜê=~äë=R=jáääáçåÉå=báåïçÜåÉê=Ü~ÄÉåK= procedure TForm1.Button1Click(Sender: TObject); var anzahl,i
: Byte;
//Vereinbarungen
wert, vergleich : Integer; begin anzahl:=0; vergleich:=5000000;
//Ausführungsteil //Zählwerk auf Null setzen //Vergleichswert zuweisen
for i:=0 to 15 do //Zählschleife begin wert:=StrToInt(ListBox5.Items[i]); if wert>vergleich then anzahl:=anzahl+1 end; //Semikolon nötig, da noch ein Befehl kommt ShowMessage('Es sind '+IntToStr(anzahl)+' Länder') end;
wìê=§ÄìåÖ=ëçääíÉ=ÇáÉ=cê~ÖÉ=Wie viele Länder haben weniger als 1000 Quadratkilometer?=ãáí=ÉåíëéêÉÅÜÉåÇÉê=bêÉáÖåáëéêçòÉÇìê=ÄÉ~åíïçêíÉí=ïÉêÇÉåK= pé®íÉê=â~åå=Éáå=qÉñíÑÉåëíÉê=ÉêÖ®åòí=ïÉêÇÉåI=áå=Ç~ë=ÇÉê=kìíòÉê=ëÉáåÉå=tÉêí=ÉáåJ íê®Öí=EÑ~äëÅÜÉ=q~ëíÉå=Ç~ÄÉá=ïÉÖÑ~åÖÉåFX=Ç~åå=â~åå=ÇÉê=fåÜ~äí=ÇÉë=péÉáÅÜÉêéä~íòÉë= vergleich=ãáí=eáäÑÉ=ÇÉê=StrToIntJcìåâíáçå=~ìë=ÇÉã=qÉñíÑÉåëíÉê=ÖÉÜçäí=ïÉêÇÉåK=== kìíòÉå= ïáê= ÇçÅÜ= ÖäÉáÅÜ= Éáåã~ä= ÇáÉ= åÉì= ÖÉäÉêåíÉ= w®ÜäëÅÜäÉáÑÉI= ìã= ãáííÉäë= ÇÉê= bêÉáÖåáëéêçòÉÇìê= òìã= Epí~åÇ~êÇJFbêÉáÖåáë= bêòÉìÖìåÖ= ÇÉë= cçêãìä~êë= Ç~ÑΩê= òì= ëçêÖÉåI= Ç~ëë= ÇáÉ= qÉñíÉáåíê®ÖÉ= áå= ÇÉå= iáëíÉå= îáÉê= ìåÇ= ÑΩåÑI= ÇáÉ= ïáê= ~äë= w~ÜäÉå= ëÉÜÉå=ã∏ÅÜíÉåI=êÉÅÜíëÄΩåÇáÖ=~åÖÉçêÇåÉí=ïÉêÇÉåK== NUU= =
VKN== ^Äò®ÜäÉå=áå=iáëíÉå= táÉ= ÖÉÜÉå= ïáê= îçê\= táê= éêΩÑÉå= àÉïÉáäëI= áå= ïÉäÅÜÉã= _ÉêÉáÅÜ= ëáÅÜ= ÇÉê= w~ÜäÉåJ ïÉêí= ÇÉë= báåíê~Öë= ÄÉÑáåÇÉíK= båíëéêÉÅÜÉåÇ= ïÉêÇÉå= äáåâë= ~å= ÇáÉ= wÉáäÉ= Éáå= çÇÉê= òïÉá=iÉÉêòÉáÅÜÉå=~åÖÉâÉííÉíW== procedure TForm1.FormCreate(Sender: TObject); var i
: Byte;
//Vereinbarungen
wert: Integer; begin
//Ausführungsteil
for i:=0 to 15 do begin wert:=StrToInt(ListBox4.Items[i]);
//4. Liste
if wert=1000) and (wertmax then max:=wert
lÇÉê=áå=ÇÉê=äÉíòíÉå=wÉáäÉ\== wert:=StrToInt(ListBox5.Items[15]);if wert>max then max:=wert
wáÉÜÉå=ïáê=_áä~åò=ÉêâÉååÉå=ïáêI=Ç~ëë=ÇáÉ=ëçÉÄÉå=~ìÑÖÉëÅÜêáÉÄÉåÉå=wÉáäÉå=ëáÅÜ= áå=ÉáåÉê=w®ÜäëÅÜäÉáÑÉ=òìë~ããÉåÑ~ëëÉå=ä~ëëÉåK== wìë~ããÉåÖÉÑ~ëëí=ÉêÖáÄí=ëáÅÜ=ÑçäÖÉåÇÉ=bêÉáÖåáëéêçòÉÇìêW= NVM= =
VKO== jáåáã~ñJ^ìÑÖ~ÄÉå= procedure TForm1.Button1Click(Sender: TObject); var i
: Byte;
//Vereinbarungen
max, wert: Integer; begin
//Ausführungsteil wert:=StrToInt(ListBox5.Items[0]); max:=wert;
//Kandidat
for i:=1 to 15 do
//Zählschleife
begin wert:=StrToInt(ListBox5.Items[i]); if wert>max then max:=wert; end;
//Ende der Zählschleife
ShowMessage('Das Maximum lautet:'+ IntToStr(max)); end;
== _áäÇ=VKPW=j~ñáãìãJpìÅÜÉ== báåÉ=Ö~åò=âäÉáåÉ=ûåÇÉêìåÖ=Äê~ìÅÜí=ã~å=åìêI=ìã=ÇÉå=âäÉáåëíÉå=tÉêí=òì=ÑáåÇÉåW= if wert<max then max:=wert;
^ääÉêÇáåÖë=ï®êÉ=Éë=ÄÉá=jáåáãìãJ^ìÑÖ~ÄÉå=òïÉÅâã®≈áÖI=ÇÉå=h~åÇáÇ~íÉåJpéÉáJ ÅÜÉêéä~íò=min=òì=åÉååÉåK=pçåëí=îÉêïáêêí=ã~å=ëáÅÜ=ëÉäÄëíK==
9.2.2
Position des größten und kleinsten Wertes bestimmen
_Éáã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ëçää===ãáíÖÉíÉáäí=ïÉêÇÉåI=ïÉäÅÜÉë=i~åÇ=ÇáÉ=ÖÉêáåÖëíÉ= báåïçÜåÉêò~Üä=Ü~íK== rã=ÇáÉëÉ=cê~ÖÉ=òì=ÄÉ~åíïçêíÉåI=ãΩëëÉå=ïáê=ÇêÉá=^ìÑÖ~ÄÉå=ä∏ëÉåK== • táê=ãΩëëÉå=òìë®íòäáÅÜ=òìã=jáåáãìã=~ìÅÜ=åçÅÜ== • ÇáÉ=mçëáíáçå=ÇÉë=jáåáãìãë=ÑáåÇÉåK== • jáí=ÇáÉëÉê=mçëáíáçå=â∏ååÉå=ïáê=Ç~åå=~ìë=iáëíÉ=N=ÇÉå=i®åÇÉêå~ãÉå=ÜçäÉåK== NVN =
V= w®ÜäëÅÜäÉáÑÉå= aÉãå~ÅÜ= Äê~ìÅÜÉå= ïáê= òïÉá= h~åÇáÇ~íÉåJpéÉáÅÜÉêéä®íòÉI= ÉáåÉå= ÑΩê= Ç~ë= jáåáJ ãìã=ëÉäÄëí=ìåÇ=ÉáåÉå=ÑΩê=ÇáÉ=jáåáãìãJmçëáíáçåK=_ÉáÇÉ=ïÉêÇÉå=îÉêÉáåÄ~êí=ìåÇ= òì=_ÉÖáåå=ÇÉë=^ìëÑΩÜêìåÖëíÉáäë=òìÉêëí=~ìÑ=ÇÉå=ÉêëíÉå=iáëíÉåÉáåíê~Ö=ìåÇ=ÇáÉ=ÉêëíÉ= mçëáíáçå=ÑÉëíÖÉäÉÖíW== wert:=StrToInt(ListBox5.Items[0]); min:=wert; minpos:=0
kìå=ïáêÇ=wert=ãáí=ÇÉê=òïÉáíÉå=wÉáäÉ=îÉêÖäáÅÜÉåI=ÖÉÖÉÄÉåÉåÑ~ääë=~âíì~äáëáÉêíW== wert:=StrToInt(ListBox5.Items[1]); if wert<min then begin min:=wert; minpos:=1 end
aáÉ=ïÉáíÉêÉ=§ÄÉêäÉÖìåÖ=ÉêÖáÄíW=eáÉê=®åÇÉêí=ëáÅÜ=~å=òïÉá=píÉääÉå=ÇÉê=w~ÜäÉåïÉêíK= a~ë=ÜÉá≈íI=Ç~ë=i=ãìëë=òïÉáã~ä=ÉáåÖÉíê~ÖÉå=ïÉêÇÉåK= kìå= â∏ååÉå= ìåë= ÇáÉ= bêïÉáíÉêìåÖ= ÇÉê= bêÉáÖåáëéêçòÉÇìêI= ëç= Ç~ëë= ~ìÅÜ= Ç~ë= ÄÉJ î∏äâÉêìåÖë®êãëíÉ=i~åÇ=~ìëÖÉÖÉÄÉå=ïáêÇI=áã=d~åòÉå=~åëÉÜÉåW= min:=wert;
//Kandidat
minpos:=0;
//Kandidatenposition
for i:=1 to 15 do
//Zählschleife
begin wert:=StrToInt(ListBox5.Items[i]); if wert<min then begin min:=wert; minpos:=i end end;
//Ende der Zählschleife
ShowMessage('Das Land mit den wenigsten Bewohnern heißt:' + ListBox1.Items[minpos])
wìã=pÅÜäìëë=ÄÉÑáåÇÉí=ëáÅÜ=áã=péÉáÅÜÉêéä~íò= min=ÇáÉ=âäÉáåëíÉ=báåïçÜåÉêò~Üä=ìåÇ= áã=péÉáÅÜÉêéä~íò=minpos=ÇáÉ=òìÖÉÜ∏êáÖÉ=mçëáíáçåK== a~ãáí=â~åå=ÇÉê=k~ãÉ=ÇÉë=i~åÇÉë=~ìë=ÇÉê=ÉêëíÉå=iáëíÉ=~ìëÖÉÖÉÄÉå=ïÉêÇÉåW= NVO= =
VKP== pìããÉå=ΩÄÉê=iáëíÉå=
9.3
Summen über Listen aáÉ=báåíê®ÖÉ=ÇÉê=äÉíòíÉå=ÄÉáÇÉå=iáëíÉåI=çÄïçÜä=ëáÉ=òïÉáÑÉäëÑêÉá=qÉñíÉ=ëáåÇI=ëÉÜÉå= ~ìë=ïáÉ=w~ÜäÉå=ìåÇ=ä~ëëÉå=ëáÅÜ=ÇÉãòìÑçäÖÉ=áå=w~ÜäÉå=ìãï~åÇÉäåK== aÉãå~ÅÜ= áëí= ~ìÅÜ= ÉáåÉ= ÉêÖ®åòÉåÇÉ= ïÉáíÉêÉ= ^ìÑÖ~ÄÉåëíÉääìåÖ= ëáååîçääK= aÉåå= ÄÉáã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ëçää=òìë®íòäáÅÜ=ÇáÉ=dÉë~ãíÑä®ÅÜÉ=aÉìíëÅÜä~åÇë=ÉêãáíJ íÉäí=ìåÇ=~ìëÖÉÖÉÄÉå=ïÉêÇÉåW=bë=áëí=ÇáÉ=pìããÉ=~ääÉê=báåíê®ÖÉ=áå=ÇÉê=îáÉêíÉå=iáëíÉ= òì=ÉêãáííÉäå=ìåÇ=~ìëòìÖÉÄÉåK== pÉÜÉå=ïáê=ìåë=ÇáÉëã~ä=ÖäÉáÅÜ=ÇáÉ=_ÉÑÉÜäÉ=~åI=ÇáÉ=áã=^ìëÑΩÜêìåÖëíÉáä=ÇÉê=bêÉáÖJ åáëéêçòÉÇìê=òìã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=òì=ÉêÖ®åòÉå=ëáåÇW= sum:=0;
//Summenspeicher auf Null setzen
for i:=0 to 15 do
//Zählschleife
begin zuwachs:=StrToInt(ListBox4.Items[i]); sum:=sum+zuwachs end;
//Semikolon nötig, da noch ein Befehl kommt
ShowMessage('Die Gesamtfläche Deutschlands beträgt '+ IntToStr(sum) + ' Quadratkilometer')
táÉ=áããÉêI=ïÉåå=ÉáåÉ=pìããÉ=òì=ÉêãáííÉäå=áëíI=îÉêïÉåÇÉå=ïáê=ÉáåÉå=pìããÉåJ péÉáÅÜÉêéä~íòI=ÇÉå=ïáê=å~íΩêäáÅÜ= sum=åÉååÉåK=bê=ïáêÇ=~åÑ~åÖë=áåáíá~äáëáÉêíI=ÇK=ÜK=== ~ìÑ=kìää=ÖÉëÉíòíK= ^åëÅÜäáÉ≈ÉåÇ=ïáêÇ=å~ÅÜÉáå~åÇÉê=~ìë=àÉÇÉê=wÉáäÉ=ÇÉê=îáÉêíÉå=iáëíÉ=ÇáÉ=_ÉëÅÜêáÑJ íìåÖ=E~äëç=ÇÉê=qÉñíF=ÜÉê~ìëÖÉÜçäí=ìåÇ=ãáííÉäë=ÇÉê=cìåâíáçå=StrToInt=òìê=Ö~åòÉå= w~Üä=âçåîÉêíáÉêíI=ÇáÉëÉ=ïáêÇ=Ç~åå=áå=ÇÉå=eáäÑëJpéÉáÅÜÉêéä~íò=zuwachs=ÖÉÄê~ÅÜíK== aáÉëÉê= wìï~ÅÜë= ÉêÜ∏Üí= Ç~åå= ÇÉå= fåÜ~äí= ÇÉë= pìããÉåëéÉáÅÜÉêëK= _áäÇ= VKQ= äáÉÑÉêí= ìåë=Ç~ë=bêÖÉÄåáëK== jáí=ÉáåÉê=ÉáåòáÖÉå=ûåÇÉêìåÖ=áå=ÇÉê=bêÉáÖåáëéêçòÉÇìê=â~åå=ÇáÉ=báåïçÜåÉêò~Üä= aÉìíëÅÜä~åÇë=~ìë=~ääÉå=báåíê®ÖÉå=áå=ÇÉê=äÉíòíÉå=iáëíÉ=ÉêãáííÉäí=ïÉêÇÉåK= i∏ëìåÖW= aÉìíëÅÜä~åÇ= Ü~í= áåëÖÉë~ãí= 82.439.000= báåïçÜåÉê= Epí~åÇ= îçã= g~Üê= OMMOFK= báåÉ=cê~ÖÉ=áëí=åçÅÜ=ìåÄÉ~åíïçêíÉíW== táÉ= ÑáåÇÉå= ïáê= ÄÉá= ÉáåÉê= ä~åÖÉåI= ëÉÜê= ä~åÖÉå= iáëíÉ= ÇÉå= äÉíòíÉå= tÉêí= ÑΩê= ÇáÉ= i~ìÑî~êá~ÄäÉ\=jìëë=ã~å=ãΩÜÉîçää=~Äò®ÜäÉå\== k~íΩêäáÅÜ=åáÅÜíK=jáí=ÇÉê= éêçéÉêíó= Count=â∏ååÉå=ïáê=ìåë=ÇáÉ= i®åÖÉ=ÇÉê= iáëíÉ= ë~J ÖÉå=ä~ëëÉåK=aáÉ=äÉíòíÉ=mçëáíáçåI=ÑΩê=ÇáÉ=ïáê=ÉáåÉå=péÉáÅÜÉêéä~íò=ãáí=ÇÉã=k~ãÉå= lepos=îÉêïÉåÇÉå=ëçääíÉåI=ÉêÖáÄí=ëáÅÜ=Ç~åå=~ìë=iáëíÉåä®åÖÉ=ãáåìë=ÉáåëW= =
lepos:=ListBox4.Count-1;
//letzte Position in der Liste
NVP =
V= w®ÜäëÅÜäÉáÑÉå= =
= _áäÇ=VKQW=dÉë~ãíÑä®ÅÜÉ=aÉìíëÅÜä~åÇë= ==
NVQ= =
==
10 10.1
Nichtnumerische Speicherplätze Speicherplätze für Wahrheitswerte (Typ Boolean)
tÉåå=áã=sÉêÉáåÄ~êìåÖëíÉáä=áå=ÉáåÉê=bêÉáÖåáëéêçòÉÇìê== var p: Boolean;
ëíÉÜíI= ïáêÇ= ãáí= p= Éáå= péÉáÅÜÉêéä~íò= òìê= ^ìÑå~ÜãÉ= ÉáåÉë= ÇÉê= ÄÉáÇÉå= t~ÜêÜÉáíëJ ïÉêíÉ=True=çÇÉê=False=~åÖÉÑçêÇÉêíK==
10.1.1
Suchen und Finden in Listen
hÉÜêÉå=ïáê=åçÅÜ=Éáåã~ä=òì=ìåëÉêÉã=a~íÉåÄÉëí~åÇ=~ìë=ÇÉã=îçêáÖÉå=^ÄëÅÜåáíí= E_áäÇ= NMKNF= òìêΩÅâI= ÇÉê= ~ìÑ= ÉáåÉê= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= ãáí= eáäÑÉ= îçå= ÑΩåÑ= iáëíÉå= îÉêï~äíÉí=ïáêÇK==
== _áäÇ=NMKNW=a~íÉåÄÉëí~åÇ=ãáí=hcwJhÉååòÉáÅÜÉå=ÇÉê=i~åÇÉëÜ~ìéíëí~Çí= dÉëìÅÜí= áëí= ÇáÉ= _ÉÑÉÜäëÑçäÖÉI= ãáí= ÇÉê= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= häáÅâ= ~ìÑ= ÇÉå= _ìTííçå= ëç= òì= ÉêïÉáíÉêå= áëíI= ëç= Ç~ëë= òìë®íòäáÅÜ= ~ìÅÜ= ÇáÉ= cê~ÖÉ= Gibt es eine Landes-Hauptstadt mit dem Autokennzeichen KS?=ÄÉ~åíïçêíÉí=ïáêÇK== báåÉ= j∏ÖäáÅÜâÉáí= âÉååÉå= ïáê= ëÅÜçåW= táê= éêçÖê~ããáÉêÉå= Ç~ë= ^Äò®ÜäÉåI= ïáÉ= çÑí= ÇáÉ= wÉáÅÜÉåÑçäÖÉ= KS= áå= ÇÉê= ÇêáííÉå= iáëíÉ= ~ìÑíêáííI= ëç= ïáÉ= ïáê= Éë= áå= ^ÄëÅÜåáíí= VKN= âÉååÉå=ÖÉäÉêåí=Ü~ÄÉåK=hçããí=kìää=ÜÉê~ìëI=áëí=ÇáÉ=^åíïçêí=åÉÖ~íáîI=âçããí=ÉáåÉ= w~Üä=Öê∏≈Éê=~äë=kìää=ÜÉê~ìë=ÖáÄí=Éë=ãáåÇÉëíÉåë=Éáåã~ä=ÇáÉëÉë=hÉååòÉáÅÜÉåK== NVR =
NM=káÅÜíåìãÉêáëÅÜÉ=péÉáÅÜÉêéä®íòÉ= açÅÜ=Ç~ãáí=ëÅÜáÉ≈Éå=ïáê=ãáí=h~åçåÉå=~ìÑ=pé~íòÉåW=t~êìã=~ìÑï®åÇáÖ=Ç~ë=^ÄJ ò®ÜäÉå=éêçÖê~ããáÉêÉåI=ïÉåå=Éë=åáÅÜí=å∏íáÖ=áëíI=ïÉåå=Éë=ÇáÉ=ÖÉëíÉääíÉ=^ìÑÖ~ÄÉ= ΩÄÉêÜ~ìéí=åáÅÜí=ÉêÑçêÇÉêí\== • aÉê~êíáÖÉ=^ìÑÖ~ÄÉå=ãáí=g~JkÉáåJ^åíïçêíÉå=ä∏ëí=ã~å=òïÉÅâã®≈áÖ=ìåíÉê=sÉêJ ïÉåÇìåÖ=ÉáåÉë=BooleanJpéÉáÅÜÉêéä~íòÉëK== bë=áëí=ΩÄäáÅÜI=ÇÉê~êíáÖÉ=péÉáÅÜÉêéä®íòÉ=áå=áÜêÉê=k~ãÉåëÖÉÄìåÖ=ëÉÜê=ÇÉìíäáÅÜ=ÇÉê= _ÉÇÉìíìåÖ=ÇÉë=fåÜ~äíë=~åòìé~ëëÉåK=aÉëÜ~äÄ=îÉêïÉåÇÉå=ïáê=ÄÉáëéáÉäëïÉáëÉ=ÇÉå= ëéêÉÅÜÉåÇÉå=k~ãÉå=ist_da=ìåÇ=îÉêÉáåÄ~êÉå=áÜå=òìÉêëí=áã=sÉêÉáåÄ~êìåÖëíÉáäW== var ist_da : Boolean;
a~å~ÅÜ=ëáåÇ=áã=^ìëÑΩÜêìåÖëíÉáä=ÇáÉ=ÑçäÖÉåÇÉå=_ÉÑÉÜäÉ=òìê=i∏ëìåÖ=ÇÉê=^ìÑÖ~ÄÉ= Éáåòìíê~ÖÉåW== lepos:=ListBox3.Count-1; ist_da:=False;
//letzte Position //Anfangs-Festlegung
for i:=0 to lepos do
//Zählschleife
begin if ListBox3.Items[i]='KS' then ist_da:=True end; if ist_da=True then
//Auswertung
ShowMessage('Mindestens einmal tritt KS auf') else ShowMessage('KS fehlt')
^åÑ~åÖë= ÑçêãìäáÉêÉå= ïáê= ÉáåÉ= råëÅÜìäÇëîÉêãìíìåÖW= aÉê= péÉáÅÜÉêéä~íò= ist_da= ïáêÇ=ãáí=ÇÉã=wìïÉáëìåÖëÄÉÑÉÜä=ist_da:=False=åÉÖ~íáî=îçêÄÉäÉÖíK= pçääíÉ=ëáÅÜ=ÄÉá=ÇÉê=råíÉêëìÅÜìåÖ=âÉáå=táÇÉêëéêìÅÜ=ÉáåëíÉääÉå=áëí=ÇáÉëÉ=kÉÖ~íáîJ sçêÄÉäÉÖìåÖ=ÖäÉáÅÜ=ÇÉã=båÇÉêÖÉÄåáëK== ^åëÅÜäáÉ≈ÉåÇ=ïáêÇ=wÉáäÉ=ÑΩê=wÉáäÉ=áå=ÇÉê=ÇêáííÉå=iáëíÉ=ìåíÉêëìÅÜíK=tÉêÇÉå=ïáê=áêJ ÖÉåÇïç=ÑΩåÇáÖI=ëÅÜ~äíÉå=ïáê=ÇÉå=fåÜ~äí=îçå= ist_da=~ìÑ=TrueK=tÉêÇÉå=ïáê=ëé®íÉê= åçÅÜ=Éáåã~ä=ÑΩåÇáÖI=ïáêÇ=True=ÇìêÅÜ=True=ΩÄÉêëéÉáÅÜÉêíK=báåJ=çÇÉê=ãÉÜêã~äáÖÉë= ^ìÑíêÉíÉå= ïáêÇ= ëçãáí= åáÅÜí= ìåíÉêëÅÜáÉÇÉåI= ~ÄÉê= Ç~ë= îÉêä~åÖí= ÇáÉ= ^ìÑÖ~ÄÉåëíÉäJ äìåÖ=~ìÅÜ=åáÅÜíK=wìã=pÅÜäìëë=ÉêÑçäÖí=ÇáÉ=_áä~åòX=Éë=ÉêÑçäÖí=ÉáåÉ=jáííÉáäìåÖ=ÉåíJ ëéêÉÅÜÉåÇ=ÇÉê=_ÉäÉÖìåÖ=ÇÉë=äçÖáëÅÜÉå=péÉáÅÜÉêéä~íòÉë=ist_daK== ^ìÅÜ=ÜáÉê=â~åå=ã~å=îçå=ÉáåÉê=^ìëå~ÜãÉêÉÖÉäìåÖ=dÉÄê~ìÅÜ=ã~ÅÜÉåI=ãìëë=Éë= ~ÄÉê=åáÅÜíW== • ^åëíÉääÉ= ÇÉë= qÉëíë= if ist_da=True then...= Ç~êÑ= âìêò= if ist_da then...= ÖÉJ ëÅÜêáÉÄÉå=ïÉêÇÉåK= aÉê= fåÜ~äí= ÉáåÉë= BooleanJpéÉáÅÜÉêéä~íòÉë= ïáêÇ= ~ìíçã~íáëÅÜ= ~ìÑ= True= ÖÉíÉëíÉíI= ÇÉëÜ~äÄ=Äê~ìÅÜí=ã~å=Éë=~äë=_ÉÇáåÖìåÖ=åáÅÜí=ÖÉëçåÇÉêí=ÜáåòìëÅÜêÉáÄÉåK= NVS= =
NMKN== péÉáÅÜÉêéä®íòÉ=ÑΩê=t~ÜêÜÉáíëïÉêíÉ=Eqóé=_ççäÉ~åF=
10.1.2 ==
Verhalten einer Schaltung
========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 10= ÇáÉ= zipJa~íÉá= DKap10.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap10= ÇáÉ= mêçàÉâíJa~íÉá= proj_10.dpr= ~ìëòìï®ÜäÉåK= táêÇ= ãáí= aÉäéÜá= ULOMMR= ÖÉ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap10=ÇáÉ=a~íÉá=proj_10.bdsproj=~ìëòìï®ÜäÉåK== == få=_áäÇ=NMKO=ëÉÜÉå=ïáê=ÉáåÉ=ÉáåÑ~ÅÜÉ=pÅÜ~äíìåÖ=ãáí=ëáÉÄÉå=pÅÜ~äíÉêåI=îçå=ÇÉåÉå= àÉÇÉê=åìê=ÇáÉ=ÄÉáÇÉå=píÉääìåÖÉå=ein=çÇÉê=aus=âÉååíK===
== _áäÇ=NMKOW=pÅÜ~äíìåÖ=ãáí=ëáÉÄÉå=pÅÜ~äíÉêå= ^åëíÉääÉ=ÉáåÉê=i~ãéÉ=ïáêÇ=Éáå=i~ÄÉä=~å=Ç~ë=båÇÉ=ÇÉê=pÅÜ~äíìåÖ=ÖÉëÉíòíI=Ç~ë=~ìÑ= ÖêΩåÉã= eáåíÉêÖêìåÇ= ÇáÉ= _ÉëÅÜêáÑíìåÖ= Ein= íê~ÖÉå= ëçääI= ïÉåå= ÇìêÅÜ= ÇáÉ= pÅÜ~äJ íìåÖ= píêçã= ÑäáÉ≈Éå= â~ååI= ~åÇÉêåÑ~ääë= ÇáÉ= _ÉëÅÜêáÑíìåÖ= Aus= ~ìÑ= êçíÉã= eáåíÉêJ ÖêìåÇ=òÉáÖíK== wì=_ÉÖáåå=ÇÉê=i~ìÑòÉáí=ÄÉÑáåÇÉå=ëáÅÜ=~ääÉ=pÅÜ~äíÉê=áå=ÇÉê=píÉääìåÖ= ausI=Éë=â~åå= âÉáå=píêçã=ÑäáÉ≈ÉåI=ÇáÉ=łi~ãéÉ=äÉìÅÜíÉí=åáÅÜíK=a~å~ÅÜ=â~åå=ÇÉê=kìíòÉê=ëÉáåÉ= pÅÜ~äíÉêëíÉääìåÖÉå=Éáåíê~ÖÉå=ìåÇ=å~ÅÜ=häáÅâ=~ìÑ=ÇÉå=_ìííçå=éêΩÑÉåI=çÄ=Éê=ÉáåÉ= pÅÜ~äíÉêâçãÄáå~íáçå=ÖÉÑìåÇÉå=Ü~íI=ÄÉá=ÇÉê=píêçã=ÇìêÅÜ=ÇáÉ=pÅÜ~äíìåÖ=ÑäáÉ≈íK== _Éîçê= ïáê= ìåë= ãáí= ÇÉå= bêÉáÖåáëéêçòÉÇìêÉå= ÄÉëÅÜ®ÑíáÖÉåI= Éêëí= Éáå= tçêí= òìê= ëÅÜåÉääÉå=ìåÇ=ÉÑÑÉâíáîÉå=eÉêëíÉääìåÖ=ÇÉë=_áäÇÉë=ÇÉê=pÅÜ~äíìåÖK== táê=ÄÉÖáååÉå=ãáí=ÉáåÉê=o~ÇáçÖêìééÉI=ëáÉ=ÉêÜ®äí=îçå=aÉäéÜá=ïáÉ=ΩÄäáÅÜ=ÇÉå=k~J ãÉå= RadioGroup1I= ãáí= eáäÑÉ= ÇÉë= píêáåÖäáëíÉåJbÇáíçêë= ëçêÖÉå= ïáê= ÑΩê= ÇáÉ= ÄÉáÇÉå= _ÉëÅÜêáÑíìåÖÉå=ein=ìåÇ=aus=E_áäÇ=NMKPFK= NVT =
NM=káÅÜíåìãÉêáëÅÜÉ=péÉáÅÜÉêéä®íòÉ= aáÉ=pí~êíÄÉäÉÖìåÖ=ëçää=ëáÅÜ=ëíÉíë=ÄÉá= aus=ÄÉÑáåÇÉå=Ó=Ç~=ÇáÉ=w®ÜäìåÖ=ÇÉê=mçëáíáçJ åÉå=ïáÉ=áããÉê=ãáí=kìää=ÄÉÖáååíI=ãìëë=ÑçäÖäáÅÜ=áå=_áäÇ=NMKP=ÇáÉ=éêçéÉêíó=ItemIndex=~ìÑ=1=îçêÉáåÖÉëíÉääí=ïÉêÇÉåK=
= _áäÇ=NMKPW=fåÜ~äí=ÇÉê=o~ÇáçÖêìééÉ=ìåÇ=pí~êíÄÉäÉÖìåÖ=ÑÉëíäÉÖÉå= aáÉ=bêòÉìÖìåÖ=ÉáåÉê=ÉáåòáÖÉå=o~ÇáçÖêìééÉ=êÉáÅÜí=ëÅÜçå=~ìëK=jáí=_b^o_bfqbk= = hlmfbobk=ìåÇ=ëÉÅÜëã~äáÖÉã=_b^o_bfqbkbfkc§dbk=Ü~ÄÉå=ïáê=ëçÑçêí=ÇáÉ=êÉëíäáJ ÅÜÉå=łpÅÜ~äíÉê=ÉêòÉìÖíX=aÉäéÜá=ÄÉåÉååí=ÇáÉëÉ=~ìíçã~íáëÅÜ=ãáí= RadioGroup2=Äáë= RadioGroup7K=táê=ãΩëëÉå=ÇáÉ=pÅÜ~äíÉê=Ç~å~ÅÜ=äÉÇáÖäáÅÜ=êáÅÜíáÖ=~ìÑ=ÇÉã=cçêãìä~ê= éä~íòáÉêÉå=ìåÇ=ÇáÉ=_ÉëÅÜêáÑíìåÖÉå=EbáÖÉåëÅÜ~Ñí=CaptionF=~ìÑ=S2=Äáë=S7=®åÇÉêåK== ^äë= sÉêÄáåÇìåÖëäáåáÉå= â∏ååÉå= ïáê= òïÉÅâã®≈áÖ= îáëìÉääÉ= lÄàÉâíÉ= Shape= ÄÉåìíJ òÉåK=táê=ÑáåÇÉå=å~ÅÜ=_áäÇ=NMKQ=áå=aÉäéÜá=Ç~ë=píÉìÉêÉäÉãÉåí= Shape=áã=oÉÖáëíÉêJ Ää~íí=wrpûqwif`e=ÇÉê=hçãéçåÉåíÉåäÉáëíÉ=ÄòïK=áå=aÉäéÜá=ULOMMR=áå=ÇÉê=h~íÉÖçêáÉ= wrpûqwif`e=ÇÉê=qççäJm~äÉííÉK=
== _áäÇ=NMKQW=píÉìÉêÉäÉãÉåí=Shape=== jáí= eáäÑÉ= îçå= Shape= â∏ååÉå= ïáê= ÉáåÉå= hêÉáëI= ÉáåÉ= bääáéëÉI= Éáå= oÉÅÜíÉÅâI= Éáå= oÉÅÜíÉÅâ= ãáí= ~ÄÖÉêìåÇÉíÉå= bÅâÉåI= Éáå= nì~Çê~í= ãáí= ~ÄÖÉêìåÇÉíÉå= bÅâÉå= çÇÉê= Éáå=nì~Çê~í=~ìÑ=ÇÉã=cçêãìä~ê=éä~íòáÉêÉå=Ó=àÉ=å~ÅÜÇÉãI=ï~ë=áã=lÄàÉâíáåëéÉâJ íçê=åÉÄÉå=ÇÉê=báÖÉåëÅÜ~Ñí=Shape=îçêÉáåÖÉëíÉääí=ïáêÇ=E_áäÇ=NMKRFK==
== _áäÇ=NMKRW=bêëÅÜÉáåìåÖëÑçêãÉå=îçå=Shape= cΩê=ìåëÉêÉ=łsÉêÄáåÇìåÖëäáåáÉå=Ü~ÄÉå=ïáê=å~íΩêäáÅÜ=oÉÅÜíÉÅâÉ=~ìëÖÉï®ÜäíK= ^ìÅÜ= ÜáÉê= êÉáÅÜí= ÉëI= Éáå= ÉáåòáÖÉë= oÉÅÜíÉÅâ= îçêòìÄÉêÉáíÉå= ìåÇ= òì= ÉáåÉê= ï~~ÖÉJ êÉÅÜíÉå=łiáåáÉ=òì=ÇÉÑçêãáÉêÉåI=Ç~òì=Éáå=ÉáåòáÖÉë=oÉÅÜíÉÅâ=ÑΩê=ÉáåÉ=ëÉåâêÉÅÜíÉ= łiáåáÉI=ÇÉê=oÉëí=ÉêäÉÇáÖí=ëáÅÜ=ÉäÉÖ~åí=ãáííÉäë=_b^o_bfqbk= = hlmfbobk=ìåÇ=_b^oJ _bfqbkbfkc§dbk== NVU= =
NMKN== péÉáÅÜÉêéä®íòÉ=ÑΩê=t~ÜêÜÉáíëïÉêíÉ=Eqóé=_ççäÉ~åF= tÉê= Éáå= ShapeJlÄàÉâí= ~ìÑ= ÇÉã= cçêãìä~ê= EÄÉá= ìåë= ëáåÇ= Éë= ÇáÉëÉ= łiáåáÉåF= åáÅÜí= ëç=ïáÉ=ÄÉá=ìåë=áå=_áäÇ=NMKO=ïÉá≈=ä~ëëÉå=ïáääI=ëçåÇÉêå=ãáí=ÉáåÉê=~åÇÉêÉå=c~êÄÉ= ÑΩääÉå= ã∏ÅÜíÉI= ÇÉê= ÉêäÉÄí= ÄÉá= ÇÉê= pìÅÜÉ= å~ÅÜ= ÇÉê= c~êÄJsçêÉáåëíÉääìåÖ= áã= lÄJ àÉâíáåëéÉâíçê=ÉáåÉ=ìå~åÖÉåÉÜãÉ=§ÄÉêê~ëÅÜìåÖ=E_áäÇ=NMKSFW=aáÉ=báÖÉåëÅÜ~Ñí= Color=ÑÉÜäíK=
=== _áäÇ=NMKSW=báÖÉåëÅÜ~Ñí=Color=ÑÉÜäí= açÅÜ= ÉêáååÉêå= ïáê= ìåë= ~å= ÇÉå= ^ÄëÅÜåáíí= QKTKP= ìåÇ= ÇáÉ= iáëíÉI= ÄÉá= ÇÉê= ~ìÅÜ= áã= lÄàÉâíáåëéÉâíçê= ÉáåÉ= ïáÅÜíáÖÉ= báÖÉåëÅÜ~Ñí= ÑÉÜäíÉ= Ó= Ççêí= âçååíÉå= ïáê= ÇáÉ= pí~êíJ ã~êâáÉêìåÖ=åáÅÜí=ÑÉëíäÉÖÉåK== táÉ= ï~ê= ÇÉê= ^ìëïÉÖ\= táê= ëÉíòÉå= ÉáåÑ~ÅÜ= áå= Ç~ë= fååÉêÉ= ÇÉê= bêÉáÖåáëéêçòÉÇìê= òìã= bêÉáÖåáë= Create= Ó= cçêãìä~ê= ÜÉêëíÉääÉå= ÉáåÉå= ÉåíëéêÉÅÜÉåÇÉå= wìïÉáëìåÖëJ ÄÉÑÉÜäK= pç=ÖÉÜí=Éë=~ìÅÜ=ÜáÉêK=wìê=báåëíÉääìåÖ=ÇÉê=^åÑ~åÖëJcΩääÑ~êÄÉ=ÉáåÉë=ShapeJlÄàÉâíë= ïáêÇ= ãáí= eáäÑÉ= ÇÉê= éêçéÉêíó= Brush.Color= ìåÇ= ÇÉê= RGBJcìåâíáçå= ÇáÉ= ÖÉïΩåëÅÜíÉ= c~êÄÉ=~ìë=ÇÉå=ÇêÉá=c~êÄ~åíÉáäÉå=oçíI=dêΩå=ìåÇ=_ä~ì=òìë~ããÉåÖÉãáëÅÜíW= procedure TForm1.FormCreate(Sender: TObject); begin Shape1.Brush.Color:=RGB(255,0,0) end;
få= ÇáÉëÉã= _ÉáëéáÉä= ïΩêÇÉ= Ç~ë= lÄàÉâí= ãáí= ÇÉã= k~ãÉå= Shape1= ÄÉá= _ÉÖáåå= ÇÉê= i~ìÑòÉáí= êçí= ÖÉÑΩääí= ëÉáåK= RGB(0,0,0)= äáÉÑÉêí= ëÅÜï~êòI= RGB(255,255,255)= ÑΩääí= êÉáå= ïÉá≈K=iÉíòíÉêÉë=áëí=~ìÅÜ=ÇáÉ=pí~åÇ~êÇJbáåëíÉääìåÖI=ÇáÉ=ïáê=ÄÉåìíòíÉåK== kìå=áëí=ÇáÉ=wÉáí=ÖÉâçããÉåI=Ç~ëë=ïáê=ìåë=ãáí=ÇÉã=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê= òìã= bêÉáÖåáë= häáÅâ= ~ìÑ= ÇÉå= _ìííçå= ÄÉëÅÜ®ÑíáÖÉåK= a~åå= ëçää= å®ãäáÅÜ= ÉåíëéêÉJ ÅÜÉåÇ=ÇÉê=pÅÜ~äíÉêëíÉääìåÖ=Ç~ë=iáÅÜí=~åJ=çÇÉê=~ìëÖÉëÅÜ~äíÉí=ïÉêÇÉåK== cΩê= ÇáÉ= ëáÉÄÉå= pÅÜ~äíÉê= îÉêïÉåÇÉå= ïáê= òïÉÅâã®≈áÖ= ëáÉÄÉå= BooleanJpéÉáÅÜÉêJ éä®íòÉ=ãáí=âìêòÉå=k~ãÉåI=òK=_K=p1=Äáë=p7:= var p1,p2,p3,p4,p5,p6,p7: Boolean;
wì= _ÉÖáåå= ÇÉë= ^ìëÑΩÜêìåÖëíÉáäë= ÑçäÖÉå= ïáê= ïáÉÇÉê= ÇÉã= mêáåòáéI= ~åÑ~åÖë= ÇáÉ= áåíÉêÉëëáÉêÉåÇÉå= báÖÉåëÅÜ~ÑíÉå= ~ìë= ÇÉå= a~íÉåâÉêåÉå= ÇÉê= îáëìÉääÉå= lÄàÉâíÉ= ÜÉê~ìëòìÜçäÉå=ìåÇ=áå=é~ëëÉåÇÉ=péÉáÅÜÉêéä®íòÉ=òì=ÄêáåÖÉåK== NVV =
NM=káÅÜíåìãÉêáëÅÜÉ=péÉáÅÜÉêéä®íòÉ= a~ë=Éêëé~êí=ìåë=ëé®íÉê=ëÉÜê=îáÉä=pÅÜêÉáÄ~êÄÉáí=ìåÇ=ã~ÅÜí=ÇÉå=fåÜ~äí=ÇÉê=bêÉáÖJ åáëéêçòÉÇìê=ΩÄÉêëáÅÜíäáÅÜ=ìåÇ=äÉëÄ~êK== pÉÜÉå=ïáê=ìåë=ÇáÉ=_ÉÑÉÜäÉ=òìê=_ÉäÉÖìåÖ=îçå=p1=Äáë=p7=~åW= if RadioGroup1.ItemIndex=0 then p1:=True else p1:=False; p2:=RadioGroup2.ItemIndex=0; p3:=RadioGroup3.ItemIndex=0; p4:=RadioGroup4.ItemIndex=0; p5:=RadioGroup5.ItemIndex=0; p6:=RadioGroup6.ItemIndex=0; p7:=RadioGroup7.ItemIndex=0;
aáÉ=_ÉäÉÖìåÖ=ÇÉë=äçÖáëÅÜÉå=péÉáÅÜÉêéä~íòÉë= p1=áëí=ãáí=ÉáåÉê=^äíÉêå~íáîÉ=òáÉãäáÅÜ= ìãëí®åÇäáÅÜ=éêçÖê~ããáÉêí=ïçêÇÉåK== cΩê=ÇáÉ=~åÇÉêÉå=_ÉäÉÖìåÖÉå=ïìêÇÉ=ÇáÉ=ÖäÉáÅÜïÉêíáÖÉI=~ÄÉê=îáÉä=ÉäÉÖ~åíÉêÉ=ìåÇ= âìêòÉ=cçêã== p2:=RadioGroup2.ItemIndex=0
ÖÉï®ÜäíK== bêâä®êÉå= ïáê= ëáÉW= oÉÅÜíë= îçã= wÉáÅÜÉå= ÉêÖáÄí= ëáÅÜ= ~ìë= :== ëíÉÜí= ïáÉ= áããÉê= ÇáÉ= nìÉääÉK=aáÉëÉ=nìÉääÉ=áëí= ÜáÉê= Ç~ë=bêÖÉÄåáë=ÇÉë=sÉêÖäÉáÅÜÉë= òïáëÅÜÉå= ÇÉê=báÖÉåJ ëÅÜ~Ñí=ItemIndex=ÇÉë=lÄàÉâíë=RadioGroup2=ìåÇ=ÇÉê=w~Üä=kìääK== fëí=ÇÉê=sÉêÖäÉáÅÜ=ÉêÑΩääíI=ÄÉâçããí=ÇáÉ=êÉÅÜíÉ=pÉáíÉ=ÇÉå=äçÖáëÅÜÉå=tÉêí= TrueK=fëí= Éê=åáÅÜí=ÉêÑΩääíI=ÖáÄí=Éë=ÉÄÉå=ÇÉå=äçÖáëÅÜÉå=tÉêí=FalseK== ^åëÅÜäáÉ≈ÉåÇ=ïáêÇ=ÇáÉëÉê=äçÖáëÅÜÉ=tÉêíI=Ç~ë=sÉêÖäÉáÅÜëêÉëìäí~íI=áå=Ç~ë=äáåâë=ëíÉJ ÜÉåÇÉ=wáÉäI=ÇÉå=äçÖáëÅÜÉå=péÉáÅÜÉêéä~íò=p2=ÖÉÄê~ÅÜíK===== t~åå=ÖÉÜí=Ç~ë=iáÅÜí=~å\=tÉåå=ÇáÉ=pÅÜ~äíÉê=ÉåíëéêÉÅÜÉåÇ=ëíÉÜÉåK== råÇ=Ç~ë=ãìëë=ÇìêÅÜ=ÉáåÉ=äçÖáëÅÜÉ=cçêãÉä=ÄÉëÅÜêáÉÄÉå=ïÉêÇÉåW== aÉê= t~ÜêÜÉáíëïÉêí= ÇÉë= çÄÉêÉå= wïÉáÖÉë= ÇÉê= pÅÜ~äíìåÖ= ÉêÖáÄí= ëáÅÜ= ïÉÖÉå= ÇÉê= eáåíÉêÉáå~åÇÉêëÅÜ~äíìåÖ=~ìë=== p1 and (p2 or p4) and p3
a~ÄÉá=áëí=ÇáÉ=m~ê~ääÉäëÅÜ~äíìåÖ=áå=ÇÉê=jáííÉ=ãáí=or=ÄÉêΩÅâëáÅÜíáÖí=ïçêÇÉåK= cΩê=ÇÉå=ìåíÉêÉå=wïÉáÖ=ÇÉê=pÅÜ~äíìåÖ=ÑáåÇÉí=ã~å=ÇÉå=êÉëìäíáÉêÉåÇÉå=t~ÜêÜÉáíëJ ïÉêí=~ìë== p5 and (p6 or True)
aÉåå=ÇÉê=pÅÜ~äíÉê=p6=áëí=é~ê~ääÉä=ÖÉëÅÜ~äíÉí=ãáí=§ÄÉêÄêΩÅâìåÖI=áããÉê=TrueK= pÅÜäáÉ≈äáÅÜ= ãΩëëÉå= ÄÉáÇÉ= wïÉáÖÉ= é~ê~ääÉä= ÖÉëÅÜ~äíÉí= ïÉêÇÉåX= ~å= ÇáÉëÉ= m~ê~ääÉäJ ëÅÜ~äíìåÖ=ëÅÜäáÉ≈í=ëáÅÜ=òìã=pÅÜäìëë=éT=~åW= ((p1 and (p2 or p4) and p3) or (p5 and (p6 or True))) and p7
OMM= =
NMKO== péÉáÅÜÉêéä®íòÉ=ÑΩê=ÉáåòÉäåÉ=wÉáÅÜÉå=Eqóé=`Ü~êF= aáÉëÉ=äçÖáëÅÜÉ=cçêãÉä=ÄÉêÉÅÜåÉí=~ìë=ÇÉå=ëáÉÄÉå=pÅÜ~äíÉêëíÉääìåÖÉå=ÇÉå=dÉë~ãíJ t~ÜêÜÉáíëïÉêíK=a~ãáí=â~åå=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=ÖÉëÅÜêáÉÄÉå=ïÉêÇÉåX=ÄÉá=häáÅâ= ~ìÑ=ÇÉå=_ìííçå=ïáêÇ=ÇáÉ=i~ãéÉ=ÉáåJ=çÇÉê=~ìëÖÉëÅÜ~äíÉíK== _áäÇ=NMKT=òÉáÖí=ÉáåÉ=ÇÉê=îáÉäÉå=ã∏ÖäáÅÜÉå=pÅÜ~äíÉêëíÉääìåÖÉå=ìåÇ=Ç~ë=bêÖÉÄåáëK= procedure TForm1.Button1Click(Sender: TObject); var p1,p2,p3,p4,p5,p6,p7: Boolean; begin
//Vereinbarungen //Ausführungsteil
if RadioGroup1.ItemIndex=0 then p1:=True else p1:=False; p2:=RadioGroup2.ItemIndex=0; p3:=RadioGroup3.ItemIndex=0; p4:=RadioGroup4.ItemIndex=0; p5:=RadioGroup5.ItemIndex=0; p6:=RadioGroup6.ItemIndex=0; p7:=RadioGroup7.ItemIndex=0; if ((p1 and (p2 or p4) and p3) or (p5 and (p6 or True))) and p7 then Label1.Caption:='Ein';Label1.Color:=RGB(0,255,0) else Label1.Caption:='Aus';Label1.Color:=RGB(255,0,0) end;
== _áäÇ=NMKTW=píêçã=ÑäáÉ≈í=ÇìêÅÜ=ÇÉå=çÄÉêÉå=wïÉáÖ=
10.2
Speicherplätze für einzelne Zeichen (Typ Char)
tÉåå=áã=sÉêÉáåÄ~êìåÖëíÉáä=áå=ÉáåÉê=bêÉáÖåáëéêçòÉÇìê== var z: Char;
ëíÉÜíI= ïáêÇ= ãáí= z= Éáå= NJ_óíÉJpéÉáÅÜÉêéä~íò= òìê= ^ìÑå~ÜãÉ= ÉáåÉë= ÉáåòÉäåÉå= wÉáJ ÅÜÉåë= ~åÖÉÑçêÇÉêíK= a~= ãáí= ÉáåÉã= _óíÉ= EëK= ^ÄëÅÜåáíí= TKPKNF= ÇáÉ= Ö~åòÉå= w~ÜäÉå= îçå= 0=Äáë= 255=Ç~êÖÉëíÉääí=ïÉêÇÉå=â∏ååÉåI=â~åå=Éáå= CharJpéÉáÅÜÉêéä~íò=ORS=îÉêJ ëÅÜáÉÇÉåÉ=wÉáÅÜÉå=~ìÑåÉÜãÉåK== OMN =
NM=káÅÜíåìãÉêáëÅÜÉ=péÉáÅÜÉêéä®íòÉ= aáÉ=wìçêÇåìåÖ=ÉêÑçäÖí=å~ÅÜ=ÇÉê=ÄÉâ~ååíÉå=^p`ffJq~ÄÉääÉW== 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95
! " # $ % & ' ( ) * + , . / 0 1 2 3 4 5 6 7 8 9 : ; < = > ?
@ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z [ \ ] ^ _
96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127
` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~
_Éáã=`çÇÉïÉêí=32=ÄÉÖáååÉå=ÇáÉ=Ç~êëíÉääÄ~êÉå=wÉáÅÜÉå=ãáí=ÇÉã=iÉÉêòÉáÅÜÉåK= aáÉ= `çÇÉïÉêíÉ= Ç~îçê= ïÉêÇÉå= ~ÄÖÉëéÉáÅÜÉêíI= ïÉåå= Éáå= kìíòÉê= ~åÇÉêÉ= q~ëíÉå= ÇêΩÅâíI=ÄÉáëéáÉäëïÉáëÉ=ÉåíëéêáÅÜí=ÇÉê=^p`ffJtÉêí= 27=ÇÉê=q~ëíÉ= Esc K=aÉê=^p`ffJ tÉêí=13=ÉåíëéêáÅÜí=ÇÉê= Enter =Jq~ëíÉK== • aáÉ=`çÇÉïÉêíÉ= 48=Äáë=57=ëáåÇ=ÇÉå=wÉáÅÜÉå=kìää=Äáë=kÉìå=îçêÄÉÜ~äíÉåK=sçå= 65= Äáë= 90= ÄÉÑáåÇÉå= ëáÅÜ= ÇáÉ= dêç≈ÄìÅÜëí~ÄÉåI= áã= _ÉêÉáÅÜ= îçå= 97= Äáë= 122= ÑáåÇÉå= ëáÅÜ=ÇáÉ=häÉáåÄìÅÜëí~ÄÉå=ÇÉë=ÉåÖäáëÅÜÉå=^äéÜ~ÄÉíëK==
OMO= =
NMKO== péÉáÅÜÉêéä®íòÉ=ÑΩê=ÉáåòÉäåÉ=wÉáÅÜÉå=Eqóé=`Ü~êF= aáÉ= _ÉäÉÖìåÖ= ÇÉê= ^p`ffJtÉêíÉ= 0= Äáë= 127= áëí= ~ìÑ= àÉÇÉã= `çãéìíÉê= ÇÉê= tÉäí= ÉáåJ ÜÉáíäáÅÜK=cΩê=ÇÉå=oÉëí=îçå=128=Äáë=255=â~åå=Éë=råíÉêëÅÜáÉÇÉ=ÖÉÄÉåI=ÜáÉê=â∏ååÉå= ÉåíëéêÉÅÜÉåÇ=ÇÉã=ëéÉòáÑáëÅÜÉå=wÉáÅÜÉåë~íò=ÇÉê=àÉïÉáäáÖÉå=i~åÇÉëëéê~ÅÜÉ=pçåJ ÇÉêêÉÖÉäìåÖÉå=ÖÉíêçÑÑÉå=ïÉêÇÉåK=aáÉ=íΩêâáëÅÜÉ=péê~ÅÜÉ=ÄÉáëéáÉäëïÉáëÉ=ÄÉåìíòí= Éáå=á=çÜåÉ=mìåâí=Ó=ÇáÉëÉë=wÉáÅÜÉå=áëí=~ÄÉê=äáåâë=åáÅÜí=ÉåíÜ~äíÉåK=a~ÑΩê=Äê~ìÅÜí= ÇáÉ=ÇÉìíëÅÜÉ=péê~ÅÜÉ=ÇáÉ=rãä~ìíÉ=ìåÇ=Ç~ë=ł≈K== cçäÖäáÅÜ=ïÉêÇÉå=~ìÑ=`çãéìíÉêå=áå=ÇÉê=qΩêâÉá=ÇáÉ=^p`ffJtÉêíÉ=îçå= 128=Äáë= 255= ~åÇÉêë= ÄÉäÉÖí= ëÉáåI= ÇÉå= dÉÖÉÄÉåÜÉáíÉå= ÇÉë= i~åÇÉë= ÉåíëéêÉÅÜÉåÇK= pç= áëí= Éë= áå= ~ääÉå=i®åÇÉêåI=ÇáÉ=ãáí=ÇÉå=pí~åÇ~êÇJ^p`ffJwÉáÅÜÉå=åáÅÜí=~ìëâçããÉåK== jáí=_äáÅâ=~ìÑ=ÇáÉ=^p`ffJq~ÄÉääÉ=ä®ëëí=ëáÅÜ=~ìÅÜ=Éêâä®êÉåI=ïáÉ=ÇáÉ=häÉáåÉêJÖê∏≈ÉêJ _ÉòáÉÜìåÖÉå= òïáëÅÜÉå= wÉáÅÜÉå= òìëí~åÇÉ= âçããÉåW= báå= wÉáÅÜÉå= ïáêÇ= âäÉáåÉê= ~äë=Éáå=~åÇÉêÉë=~åÖÉëÉÜÉåI=ïÉåå=ÇÉê=òìÖÉÜ∏êáÖÉ=^p`ffJtÉêí=âäÉáåÉê=áëíK=^ìë=ÇÉê= ^p`ffJq~ÄÉääÉ=â∏ååÉå=ïáê=ÇÉãòìÑçäÖÉ=~ÄäÉëÉåW= ‘#‘ < ‘(‘< ‘0‘< ‘A‘< ‘Z‘< ‘\‘ ‘a‘< ‘z‘< ‘~‘
kìå=ïáêÇ=~ìÅÜ=ÇáÉ=wÉáäÉ= if (Key < '0') or (Key > '9') then ...=~ìë=^ÄëÅÜåáíí= RKNKQ=îÉêëí®åÇäáÅÜÉêI=ãáí=ÇÉêÉå=eáäÑÉ=ïáê=ÑÉëíëíÉääíÉåI=çÄ=ÇÉê=kìíòÉê=ÉáåÉ=q~ëíÉ=ÖÉJ ÇêΩÅâí= Ü~íI= ÇáÉ= ëáÅÜ= áã= wáÑÑÉêåJ_ÉêÉáÅÜ= ÄÉÑáåÇÉíW= aÉê= qÉëí= áëí= ÑΩê=~ääÉ=q~ëíÉå= ãáí= ^p`ffJtÉêíÉå= äáåâë= îçå= 48= ìåÇ= êÉÅÜíë= îçå= 57= ÉêÑΩääíK= aáÉ= ëáååîçääÉ= sÉêÖ~ÄÉ= ÇÉê= ^p`ffJtÉêíÉ=ä®ëëí=ìåë=ÇÉåâÉåI=Ç~ëë=ÇÉê=oÉÅÜåÉê=Ç~ë=^äéÜ~ÄÉí=âÉååÉå=ïΩêÇÉK== pçää=Éáå=ÄÉëíáããíÉë=wÉáÅÜÉå=áå=ÉáåÉå=CharJpéÉáÅÜÉêéä~íò=ÖÉÄê~ÅÜí=ïÉêÇÉåI=áëí=Éë= áå=ÉáåÑ~ÅÜÉ= eçÅÜâçãã~ë= ‘‘=òì=ëÉíòÉåK=aÉê=wìïÉáëìåÖëÄÉÑÉÜä= z:=‘0‘=ÄÉäÉÖí= z= ãáí= ÇÉã= wÉáÅÜÉå= kìääK= aáÉ= w~Üä= kìää= Ç~ÖÉÖÉå= â~åå= åìê= áå= ÉáåÉå= ÇÉê= IntegerJ péÉáÅÜÉêéä®íòÉ=ÖÉÄê~ÅÜí=ïÉêÇÉåI=z:=0=ãáí=var z: Char;=ï®êÉ=ÖêìåÇÑ~äëÅÜK= • aÉäéÜáJm~ëÅ~ä=ëíÉääí=ÇáÉ=ÄÉáÇÉå=cìåâíáçåÉå= Chr=ìåÇ= Ord=ÄÉêÉáíI=ãáí=ÇÉêÉå=eáäÑÉ= òì= ÉáåÉã= ÖÉÖÉÄÉåÉå= ^p`ffJtÉêí= ÇáÉ= òìÖÉÜ∏êáÖÉ= _ÉäÉÖìåÖ= ìåÇ= ìãÖÉâÉÜêí= òì= ÉáåÉã=ÄÉëíáããíÉå=wÉáÅÜÉå=ÇÉê=òìÖÉÜ∏êáÖÉ=^p`ffJtÉêí=ÉêÜ~äíÉå=ïÉêÇÉå=â~ååK== var z: Char; z_asc: Byte;
//Byte reicht aus
z:=Chr(z_asc)
//ASCII-Wert Zeichen
z_asc:=Ord(z);
//Zeichen ASCII-Wert
_áäÇ=NMKU=òÉáÖí=ÉáåÉ=âäÉáåÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉI=ãáí=ÇÉêÉå=eáäÑÉ=ïáê=ÇÉå=rãÖ~åÖ= ãáí=CharJpéÉáÅÜÉêéä®íòÉåI=ASCIIJtÉêíÉå=ëçïáÉ=ãáí=Chr=ìåÇ=Ord=ΩÄÉå=ïçääÉåK== == ========================tÉê= Ç~ë= ÑçäÖÉåÇÉ= aÉäéÜáJmêçàÉâí= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 10= ÇáÉ= zipJa~íÉá= DKap10.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap10= ÇáÉ= mêçàÉâíJa~íÉá= proj_102.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap10=ÇáÉ=a~íÉá=proj_102.bdsproj=~ìëòìï®ÜäÉåK== == OMP =
NM=káÅÜíåìãÉêáëÅÜÉ=péÉáÅÜÉêéä®íòÉ= =
= _áäÇ=NMKUW=wÉáÅÜÉå=ìåÇ=òìÖÉÜ∏êáÖÉ=^p`ffJtÉêíÉ== aáÉ= çÄÉêëíÉ= pÅêçääÄ~ê= ïáêÇ= ãáí= ÇÉã= jáåáãìã= ÉáåÖÉëíÉääí= ~ìÑ= 65= ìåÇ= ãáí= ÇÉã= j~ñáãìã=~ìÑ=90=Ó=Ç~ë=áëí=ÇÉê=^p`ffJ_ÉêÉáÅÜ=ÇÉê=dêç≈ÄìÅÜëí~ÄÉåK=_Éá=sÉê®åÇÉJ êìåÖ=ÇÉë=oÉÖäÉêë=ëçääÉå=êÉÅÜíë=åÉÄÉåÉáå~åÇÉê=^p`ffJtÉêí=ìåÇ=wÉáÅÜÉå=áå=òïÉá= i~ÄÉä=~ìëÖÉÖÉÄÉå=ïÉêÇÉåK= procedure TForm1.ScrollBar1Change(Sender: TObject); var z : Char; z_asc: Byte; begin
//Vereinbarungen
//Ausführungsteil z_asc:=ScrollBar1.Position; //Transport Datenkern->Sp.-platz z:=Chr(z_asc); Label1.Caption:=IntToStr(z_asc); Label2.Caption:=z
end;
aáÉ=bêÉáÖåáëéêçòÉÇìê=ï®êÉ=~ìÅÜ=îçääëí®åÇáÖ=çÜåÉ=péÉáÅÜÉêéä®íòÉ=ã∏ÖäáÅÜW= procedure TForm1.ScrollBar1Change(Sender: TObject); begin Label1.Caption:=IntToStr(ScrollBar1.Position); Label2.Caption:=Chr(ScrollBar1.Position) end;
táê=Ü~ÄÉå=òáÉãäáÅÜ=ä~åÖÉ=Eîçå=^ÄëÅÜåáíí=OKO=Äáë=^ÄëÅÜåáíí=TKNKPF=_ÉåìíòÉêçÄÉêJ Ñä®ÅÜÉå=ÜÉêÖÉëíÉääí=ìåÇ=bêÉáÖåáëéêçòÉÇìêÉå=éêçÖê~ããáÉêíI=ìåÇ=Éë=ÖáåÖ=~ìÅÜ=çÜJ åÉ=péÉáÅÜÉêéä®íòÉK=^ÄÉê=Ó=îÉêÖäÉáÅÜÉå=ïáê=ÇçÅÜ=ìåÇ=ÇÉåâÉå=ïáê=áå=ÇáÉ=wìâìåÑíW= aáÉ= sÉêïÉåÇìåÖ= îçå= péÉáÅÜÉêéä®íòÉå= Éêã∏ÖäáÅÜí= ìåë= ÖêìåÇë®íòäáÅÜ= ÇáÉ= âä~êÉ= aêÉáíÉáäìåÖ=ÇÉë=fåÜ~äíë=àÉÇÉê=bêÉáÖåáëéêçòÉÇìêW== • fåíÉêÉëëáÉêÉåÇÉ= a~íÉå= ~ìë= ÇÉå= a~íÉåâÉêåÉå= ÇÉê= lÄàÉâíÉ= áå= ÖÉÉáÖåÉíÉ= péÉáJ ÅÜÉêéä®íòÉ=ÜçäÉå= • oÉÅÜåÉå=L=~êÄÉáíÉå=ãáí=ÇÉå=péÉáÅÜÉêéä®íòÉå=EâìêòÉI=ëéêÉÅÜÉåÇÉ=k~ãÉåF= • EoΩÅâFJqê~åëéçêí=ÇÉê=bêÖÉÄåáëëÉ=áå=ÇáÉ=a~íÉåâÉêåÉ= _ÉåìíòÉå=ïáê=Ç~ÖÉÖÉå=ëí®åÇáÖ=ÇáÉ=lÄàÉâíÉ=ãáí=áÜêÉå=ä~åÖÉå=k~ãÉå=ìåÇ=ÇáÉ=ÉJ ÄÉåÑ~ääë= åáÅÜí= âìêòÉå= k~ãÉå= ÇÉê= éêçéÉêíáÉëI= ÖÉÜí= Ö~åò= ëÅÜåÉää= ÇáÉ= §ÄÉêëáÅÜí= îÉêäçêÉåK=cÉÜäÉê=ïÉêÇÉå=ï~ÜêëÅÜÉáåäáÅÜÉêK== OMQ= =
NMKP== péÉáÅÜÉêéä®íòÉ=ÑΩê=wÉáÅÜÉåÑçäÖÉå=Eqóé=píêáåÖF= táêÇ=ÇÉê=oÉÖäÉê=ÇÉê=ãáííäÉêÉå=pÅêçääÄ~ê=ÄÉïÉÖí=ÉêëÅÜÉáåÉå=êÉÅÜíë=ÇáÉ=ÉáåÖÉëíÉääJ íÉå=^p`ffJtÉêíÉ=ìåÇ=ÇáÉ=òìÖÉÜ∏êáÖÉå=häÉáåÄìÅÜëí~ÄÉåX=ÇáÉ=ìåíÉêÉ=pÅêçääÄ~ê=äáÉÑÉêí= ëÅÜäáÉ≈äáÅÜ= ÇáÉ= wáÑÑÉêåK= aáÉ= òìÖÉÜ∏êáÖÉå= bêÉáÖåáëéêçòÉÇìêÉå= ÖäÉáÅÜÉå= ÇÉê= ÉÄÉå= ÇáëâìíáÉêíÉåK== få=ÇÉê=îçêäÉíòíÉå=wÉáäÉ=ëçää=ÄÉá=q~ëíÉåÇêìÅâ=ÉáåÉë=kìíòÉêë=áã=qÉñíÑÉåëíÉê=Ç~ë=ÖÉJ ÇêΩÅâíÉ=wÉáÅÜÉå=ãáí=^p`ffJtÉêí=~ìëÖÉÖÉÄÉå=ïÉêÇÉåW= procedure TForm1.Edit1KeyPress(Sender: TObject; var Key: Char); var z : Char; z_asc: Byte; begin z:=Key; z_asc:=Ord(z); Label7.Caption:=IntToStr(z_asc); Label8.Caption:=z end;
rãÖÉâÉÜêí=ëçää=ÄÉá=ûåÇÉêìåÖ=áã=ìåíÉêÉå=qÉñíÑÉåëíÉê=ÇÉê=fåÜ~äí=~äë=^p`ffJtÉêí= ÄÉíê~ÅÜíÉí=ïÉêÇÉåI=Ç~ë=òìÖÉÜ∏êáÖÉ=wÉáÅÜÉå=ëçääÉå=~åÖÉòÉáÖí=ïÉêÇÉåW= procedure TForm1.Edit2Change(Sender: TObject); var z : Char; z_asc: Byte; begin z_asc:=StrToInt(Edit2.Text); z:=Chr(z_asc); Label10.Caption:=IntToStr(z_asc); Label10.Caption:=z eåd;
10.3
Speicherplätze für Zeichenfolgen (Typ String)
tÉåå=ÇáÉ=^åíïçêí=ÉáåÉë=kìíòÉêë=åáÅÜí=ÖÉê~ÇÉ=~ìë=ÇÉå=_ìÅÜëí~ÄÉå=łj=çÇÉê=łn= ÄÉëíÉÜíI= êÉáÅÜí= Éáå= CharJpéÉáÅÜÉêéä~íò= òìã= péÉáÅÜÉêå= ÉáåÉê= åáÅÜíåìãÉêáëÅÜÉå= kìíòÉêÉáåÖ~ÄÉ=âÉáåÉëÑ~ääë=~ìëK== táê=ÄÉå∏íáÖÉå=Ç~ÑΩê=ÉáåÉå=péÉáÅÜÉêéä~íòI=ÇÉê=ÉáåÉå=qÉñíI=ÇK=ÜK=ÉáåÉ=wÉáÅÜÉåÑçäJ ÖÉI=ëéÉáÅÜÉêå=â~ååK=báå=ÇÉê~êíáÖÉê=péÉáÅÜÉêéä~íò=ãáí=ÇÉã=k~ãÉå=tx=ïáêÇ=ãáí=ÉáJ åÉê=ÇÉê=ÄÉáÇÉå=ÑçäÖÉåÇÉå=sÉêÉáåÄ~êìåÖÉå=ÄÉêÉáíÖÉëíÉääíW= var tx: ShortString; var tx: String;
fã=ÉêëíÉå=c~ääÉ=ëíÉääí=aÉäéÜá=ORS=_óíÉ=ÑΩê= tx=ÄÉêÉáíK=a~ë=ÉêëíÉ=_óíÉ=ïáêÇ=ÑêÉáÖÉJ Ü~äíÉåI=ìã=ëé®íÉê=òì=êÉÖáëíêáÉêÉåI=ïáÉ=îáÉäÉ=_óíÉ=í~íë®ÅÜäáÅÜ=ãáí=wÉáÅÜÉå=ÄÉäÉÖí= ëáåÇK=bë=áëí=Ç~ë=ëç=ÖÉå~ååíÉ=łi®åÖÉåÄóíÉK=aÉê=oÉëí=â~åå=ÖÉåìíòí=ïÉêÇÉåK== OMR =
NM=káÅÜíåìãÉêáëÅÜÉ=péÉáÅÜÉêéä®íòÉ= • få= ÉáåÉã= ShortStringJpéÉáÅÜÉêéä~íò= â∏ååÉå= ÑçäÖäáÅÜ= wÉáÅÜÉåÑçäÖÉå= Äáë= òìê= j~ñáã~ää®åÖÉ=îçå=ORR=wÉáÅÜÉå=~ÄÖÉëéÉáÅÜÉêí=ïÉêÇÉåK== • tÉê=ä®åÖÉêÉ=píêáåÖë=~ÄëéÉáÅÜÉêå=ã∏ÅÜíÉI=ÇÉê=ãìëë=ÉáåÉå=péÉáÅÜÉêéä~íò=îçã= qóé=String=~åÑçêÇÉêåK=a~åå=Äê~ìÅÜí=Éê=ëáÅÜ=âÉáåÉ=pçêÖÉå=òì=ã~ÅÜÉåI=çÄ=ÇÉê= péÉáÅÜÉêéä~íò=ÖÉåΩÖÉåÇ=h~é~òáí®í=ÄÉëáíòíK== táê=ïÉêÇÉå=áã=å®ÅÜëíÉå=h~éáíÉä=~ìëëÅÜäáÉ≈äáÅÜ=ãáí= ShortStringJpéÉáÅÜÉêéä®íòÉå= ~êÄÉáíÉåI=Ç~=ëáÉ=ÑΩê=ìåëÉêÉ=^åïÉåÇìåÖÉå=î∏ääáÖ=~ìëêÉáÅÜÉåÇ=ëáåÇK== pé®íÉêI=îçê=~ääÉã=~Ä=^ÄëÅÜåáíí=NOKQI=ïáêÇ=Éë=åçíïÉåÇáÖ=ïÉêÇÉåI=péÉáÅÜÉêéä®íòÉ= îçã=qóé= String=òì=îÉêïÉåÇÉåI=Ç~=áå=aÉäéÜá=ULOMMR=Ó=áã=dÉÖÉåë~íò=òì=ÑêΩÜÉJ êÉå= aÉäéÜáJsÉêëáçåÉå= Ó= ÇáÉ= hçåîÉêíáÉêìåÖëÑìåâíáçå= Val= åáÅÜí= ãáí= ShortString= ~êÄÉáíÉíK=== wìÉêëí=ïÉêÇÉå=ïáê=ÇáÉ=ïáÅÜíáÖëíÉå=cìåâíáçåÉå=ìåÇ=mêçòÉÇìêÉå=âÉååÉå=äÉêåÉåI= ÇáÉ=aÉäéÜáJm~ëÅ~ä=ÑΩê=ÇáÉ=StringJ^êÄÉáí=òìê=sÉêÑΩÖìåÖ=ëíÉääíK== jáí=ÇÉê=sçâ~ÄÉä= StringJ^êÄÉáí=ïÉêÇÉå=ïáê=~Ä=àÉíòí=âìêò=~ää=Ç~ë=ÄÉòÉáÅÜåÉåI=ï~ë= áå= ÇáÉ= oìÄêáâ= rãÖ~åÖ= ãáí= wÉáÅÜÉåÑçäÖÉå= çÇÉê= JâÉííÉåI= ^êÄÉáí= ãáí= ShortStringJ= çÇÉê=StringJpéÉáÅÜÉêéä®íòÉå=Ñ®ääíK== bÄÉåëç=ïÉêÇÉå=ïáê=ÇÉê=hΩêòÉ=Ü~äÄÉê=ïÉåáÖÉê=îçå= qÉñíÉå=çÇÉê=wÉáÅÜÉåâÉííÉåI= ëçåÇÉêå=Ü®ìÑáÖ=ÉáåÑ~ÅÜ=îçå=píêáåÖë=ëéêÉÅÜÉåK== a~ë= áëí= ìåíÉê= mêçÖê~ããáÉêÉêå= ëç= ΩÄäáÅÜ= Ó= ìåÇ= ~äë= mêçÖê~ããáÉêÉê= â∏ååÉå= ïáê= ìåë=ÇçÅÜ=ïçÜä=ä~åÖë~ã=ÄÉòÉáÅÜåÉåK= =
OMS= =
==
11 11.1
Arbeit mit Zeichenfolgen (Strings) String-Funktionen und -Prozeduren
aÉäéÜáJm~ëÅ~ä= ëíÉääí= ÉáåÉ= oÉáÜÉ= îçå= StringJcìåâíáçåÉå= ìåÇ= StringJmêçòÉÇìêÉå= ÄÉêÉáíI= ãáí= ÇÉêÉå= eáäÑÉ= ^ìÑÖ~ÄÉå= òìê= qÉñíÄÉ~êÄÉáíìåÖ= ìåÇ= qÉñí~å~äóëÉ= ÖÉä∏ëí= ïÉêÇÉå=â∏ååÉåK== • cìåâíáçåÉå= äáÉÑÉêå= ëíÉíë= ÉáåÉå= ÉáåòáÖÉå= tÉêíX= ëáÉ= ïÉêÇÉå= îÉêïÉåÇÉíI= áåÇÉã= ÇÉê=bêÖÉÄåáëïÉêí=ÇÉê=cìåâíáçå=áå=ÉáåÉå=ÖÉÉáÖåÉíÉå=péÉáÅÜÉêéä~íò=çÇÉê=ÉáåÉå= qÉëí=ÖÉäÉåâí=ïáêÇK== j~åÅÜÉ= cìåâíáçåÉå= ÄÉå∏íáÖÉå= ÖÉïáëëÉ= ^åÖ~ÄÉåI= Ç~ãáí= ëáÉ= ~êÄÉáíÉå= â∏ååÉåX= ÇáÉëÉ= ^åÖ~ÄÉå= ëáåÇ= Ç~åå= áå= êìåÇÉå= hä~ããÉêå= ÜáåíÉê= ÇÉå= cìåâíáçåëå~ãÉå= Éáåòìíê~ÖÉåK=^åÇÉêÉ=cìåâíáçåÉå= ÄÉå∏íáÖÉå=åáÅÜíëX=Ççêí=ÉåíÑ~ääÉå=~ìÅÜ=ÇáÉ=êìåJ ÇÉå=hä~ããÉêå=ÜáåíÉê=ÇÉã=cìåâíáçåëå~ãÉåK= táê=ïÉêÇÉå=ÉáåëíïÉáäÉå=éê~Öã~íáëÅÜ=~å=ÇÉå=rãÖ~åÖ=ãáí=cìåâíáçåÉå=ÜÉê~åÖÉJ ÜÉå= ìåÇ= ìåë= ~åÜ~åÇ= îáÉäÉê= _ÉáëéáÉäÉ= áã= rãÖ~åÖ= ãáí= ÇÉå= ïáÅÜíáÖëíÉå= îçå= áÜJ åÉå=ΩÄÉåK= • mêçòÉÇìêÉå=ëáåÇ=mêçÖê~ããëíΩÅâÉåI=ÇáÉ=ÉáåÉ=táêâìåÖ=Ü~ÄÉåK=aáÉëÉ=táêâìåÖ= â~åå= áå= ÇÉê= sÉê®åÇÉêìåÖ= îçå= fåÜ~äíÉå= áå= ÉáåÉã= çÇÉê= ãÉÜêÉêÉå= péÉáÅÜÉêJ éä®íòÉå=ÄÉëíÉÜÉåI=ëáÉ=â~åå=~ÄÉê=~ìÅÜ=î∏ääáÖ=ìå~ÄÜ®åÖáÖ=îçå=péÉáÅÜÉêéä®íòÉå= ëÉáåK=mêçòÉÇìêÉå=ïÉêÇÉå=ëíÉíë= ~ìÑÖÉêìÑÉåI=ÇK=ÜK=ëáÉ=Ü~ÄÉå=áå=ÉáåÉã= wìïÉáJ ëìåÖëÄÉÑÉÜä=åáÅÜíë=òì=ëìÅÜÉåK=
11.1.1
Wichtige String-Funktionen
== k~ãÉ=ÇÉê=cìåâíáçå= CompareStr
cìåâíáçå=äáÉÑÉêí=
cìåâíáçå=ÄÉå∏íáÖí=
StringW=ÉêëíÉê=píêáåÖå~ãÉ= [MI=Ñ~ääë=NKpíêáåÖ=äÉñK====StringW=òïÉáíÉê=píêáåÖå~ãÉ= IntegerW==
Concat
== =
===Öê∏≈Éê=~äë=OK=píêáåÖ= ZMI=Ñ~ääë=ÄÉáÇÉ=píêáåÖë== ===ÖäÉáÅÜ= YMI=Ñ~ääë=NK=píêáåÖ=äÉñK== ===âäÉáåÉê=~äë=OK=píêáåÖ= StringW=bêÖÉÄåáë=ÇÉê====òïÉá=çÇÉê=ãÉÜêÉêÉ=StringëI=ÇáÉ= ==========sÉêâÉííìåÖ= ~åÉáå~åÇÉêÖÉÑΩÖí=ïÉêÇÉå=ëçääÉå=
OMT =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= Copy
=
Length
LowerCase
StringW=qÉáäëíêáåÖI===== StringW===k~ãÉ=ÇÉë=píêáåÖI== ===ÇÉê=áåëÄÉëçåÇÉêÉ====IntegerW=pí~êíéçëáíáçå=ÇÉë=qÉáäJ= ===åìê=~ìë=ÉáåÉã=wÉáJ= =============ëíêáåÖI== ===ÅÜÉå=ÄÉëíÉÜÉå== IntegerW=^åò~Üä=ÇÉê=ÜÉê~ìëòìä∏J= ===â~åå= =============ëÉåÇÉå=wÉáÅÜÉå= IntegerW=i®åÖÉ=ÇÉë== StringW===k~ãÉ=ÇÉë=píêáåÖ= ===píêáåÖ== StringW=bêÖÉÄåáë=ãáí== StringI==ÇÉëëÉå=dêç≈ÄìÅÜëí~ÄÉå=áå== ===~ìëëÅÜäáÉ≈äáÅÜÉå== =============häÉáåÄìÅÜëí~ÄÉå=ìãÖÉJ= ===häÉáåÄìÅÜëí~ÄÉå= =============ï~åÇÉäí=ïÉêÇÉå=ëçääÉå= ByteW=mçëáíáçåI=~å=ÇÉê= StringW===hìêòÉê=píêáåÖI=â~åå=~ìÅÜ== ===ÇÉê=qÉáäëíêáåÖ=Ç~ë== =============~ìë=ÉáåÉã=wÉáÅÜÉå== ===ÉêëíÉ=j~ä=áã== =============ÄÉëíÉÜÉå== StringW==ä~åÖÉê=píêáåÖ= ===ä~åÖÉå=píêáåÖ== ===~ìÑíêáíí=== StringW=bêÖÉÄåáë=ãáí== StringI==ÇÉëëÉå=häÉáåÄìÅÜëí~ÄÉå=áå=== ===~ìëëÅÜäáÉ≈äáÅÜÉå== dêç≈ÄìÅÜëí~ÄÉå=ìãÖÉJ= ===dêç≈ÄìÅÜëí~ÄÉå= =============ï~åÇÉäí=ïÉêÇÉå=ëçääÉå=
Pos
UpperCase
• aáÉ= cìåâíáçå= IntToStrI= ãáí= ÇÉêÉå= eáäÑÉ= ïáê= ÇÉå= fåÜ~äí= ÉáåÉë= Ö~åòò~ÜäáÖÉå== péÉáÅÜÉêéä~íòÉë=òì=ÉáåÉê=wÉáÅÜÉåÑçäÖÉ=âçåîÉêíáÉêÉå=â∏ååÉåI=ÇáÉ=Ç~åå=áå=ÉáåÉ= jáííÉáäìåÖ= ÄòïK= ÇÉå= a~íÉåâÉêå= ÉáåÉë= qÉñíÑÉåëíÉêëI= ÉáåÉë= i~ÄÉäë= ìëïK= íê~åëJ éçêíáÉêí=ïÉêÇÉå=â~ååI=âÉååÉå=ïáê=ÄÉêÉáíë=~ìë=îáÉäÉå=_ÉáëéáÉäÉåK== a~ÑΩê=â∏ååÉå=ïáê=ÇáÉ=ÉåíëéêÉÅÜÉåÇÉ=wÉáäÉ=ÇÉê=q~ÄÉääÉ=ëÅÜçå=ëÉäÄëí=ÉåíïÉêÑÉåW== StringW=wÉáÅÜÉåÑçäÖÉI==Integer çÇÉê=Byte:=péÉáÅÜÉêéä~íòI== ===ÇáÉ=~ìëëáÉÜí=ïáÉ== =============ÇÉëëÉå=fåÜ~äí=áå=wÉáÅÜÉåJ= ===ÇáÉ=Ö~åòÉ=w~Üä= =============ÑçäÖÉ=ìãÖÉï~åÇÉäí=ïÉêJ= =============ÇÉå=ëçää=
IntToStr
• däÉáÅÜÉêã~≈Éå= ÄÉâ~ååí= áëí= ìåë= ÇáÉ= cìåâíáçå= StrToIntI= ãáí= ÇÉêÉå= eáäÑÉ= ïáê= ÉáåÉ= wÉáÅÜÉåÑçäÖÉI= ïÉåå= ëáÉ= ëáÅÜ= òì= ÉáåÉê= Ö~åòÉå= w~Üä= ìãï~åÇÉäå= ä~ëëÉå= â~ååI=òì=ÉáåÉê=Ö~åòÉå=w~Üä=âçåîÉêíáÉêÉå=â∏ååÉåW= = StrToInt
IntegerW=w~ÜäI=ÇáÉ==
String:=wÉáÅÜÉåÑçäÖÉI=ÇáÉ=~ìëëáÉÜí==
===ëáÅÜ=~ìë=ÇÉê==wÉáJ= ============ïáÉ=ÉáåÉ=Ö~åòÉ=w~Üä=ìåÇ== ===ÅÜÉåÑçäÖÉ=ÉêÖáÄí== ============áå=ÉáåÉ=ëçäÅÜÉ=ìãÖÉï~åJ= ===EÑ~ääë==ã∏ÖäáÅÜF= ============ÇÉäí=ïÉêÇÉå=â~åå= OMU= =
NNKO== cáåÇÉåI=w®ÜäÉå=ìåÇ=i∏ëÅÜÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå=
11.1.2
Wichtige String-Prozeduren
^ìÅÜ=ÇáÉ=ÑçäÖÉåÇÉ=q~ÄÉääÉ=ÉêÜÉÄí=âÉáåÉëÑ~ääë=^åëéêìÅÜ=~ìÑ=sçääëí®åÇáÖâÉáíI=~ÄÉê= ÇáÉ=ÄÉáÇÉå=ïáÅÜíáÖëíÉå=mêçòÉÇìêÉåI=ÇáÉ=ïáê=áå=ÇÉå=îáÉäÉå=_ÉáëéáÉäÉå=ÇáÉëÉë=ìåÇ= ÇÉê=ÑçäÖÉåÇÉå=h~éáíÉä=ÄÉå∏íáÖÉåI=ëáåÇ=~ìÑÖÉÑΩÜêíK== = k~ãÉ=ÇÉê=mêçòÉÇìê= Delete
Insert
táêâìåÖ= báå=qÉáä=ÉáåÉë=píêáåÖ= ïáêÇ=ÖÉä∏ëÅÜí=
aÉê=báåÑΩÖÉJpíêáåÖ= ïáêÇ=áå=ÇÉå=_~ëáëJ píêáåÖ=~å=îçêÖÉÖÉÄÉJ åÉê=mçëáíáçå=ÉáåÖÉÑΩÖí=
== == == == ==
mêçòÉÇìê=ÄÉå∏íáÖí= StringW==k~ãÉ=ÇÉë=píêáåÖI== IntegerW=pí~êíéçëáíáçå=ÇÉë=qÉáäJ=
=============ëíêáåÖI== IntegerW=^åò~Üä=ÇÉê=ÜÉê~ìëòìä∏J= =============ëÅÜÉåÇÉå=wÉáÅÜÉå= String: báåÑΩÖÉJpíêáåÖ= String: _~ëáëJpíêáåÖ= Integer: mçëáíáçå=
========================tÉê= ÇáÉ= ÑçäÖÉåÇÉå= aÉäéÜáJmêçàÉâíÉ= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 11= ÇáÉ= zipJa~íÉá= DKap11.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap11= ÇáÉ= mêçàÉâíJa~íÉá= proj_11?.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap11=ÇáÉ=a~íÉá=proj_11?.bdsproj=~ìëòìï®ÜäÉåK== a~ë=cê~ÖÉòÉáÅÜÉå=áëí=Ç~åå=àÉïÉáäë=ÇìêÅÜ=ÇáÉ=wáÑÑÉêåÑçäÖÉ=ÇÉë=råíÉêâ~éáíÉäë=òì=ÉêJ ëÉíòÉå=E_ÉáëéáÉäW=a~ë=mêçàÉâí= ~ìë=^ÄëÅÜåáíí=NNKOKN=ÑáåÇÉí= ëáÅÜ=áå=ÇÉê=mêçàÉâíÇ~íÉá= proj_1121.dpr=ÄòïK=proj_1121.bdsproj)= =
11.2
Finden, Zählen und Löschen von Zeichen und Mustern
11.2.1
Finden von Zeichen und Mustern
_áäÇ=NNKN=òÉáÖí=ìåë=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ=ÇÉê=îáÉê=_ìííçåë=ÇáÉ=îáÉê=òì=ä∏ëÉåÇÉå= ^ìÑÖ~ÄÉåK== få=ÇÉê=bêÉáÖåáëéêçòÉÇìê=òìã=häáÅâ=~ìÑ=ÇÉå=çÄÉêëíÉå=_ìííçå=ëçää=äÉÇáÖäáÅÜ=ÑÉëíÖÉJ ëíÉääí=ïÉêÇÉåI=çÄ=áå=ÇÉê=áã=çÄÉêÉå=qÉñíÑÉåëíÉê=ãáí=ÇÉã=k~ãÉå= Edit1=ÉáåÖÉÖÉÄÉJ åÉå= wÉáÅÜÉåÑçäÖÉ= Ç~ë= wÉáÅÜÉå= 'e'= ÉåíÜ~äíÉå= áëíK= wìê= i∏ëìåÖ= ÇáÉëÉë= mêçÄäÉãë= â∏ååÉå=ïáê=òïÉÅâã®≈áÖ=ÇáÉ=cìåâíáçå=Pos=îÉêïÉåÇÉåI=ÇáÉ=ÉáåÉ=kìää=äáÉÑÉêíI=ïÉåå= Éë=Ç~ë=wÉáÅÜÉå=åáÅÜí=ÖáÄíI=~åëçåëíÉå=~ÄÉê=ÇáÉ=mçëáíáçå=ÇÉë=ÉêëíÉå=^ìÑíêÉíÉåëK== OMV =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= =
= _áäÇ=NNKNW=cáåÇÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå== táê= ëçääíÉå= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= ëç= ëÅÜêÉáÄÉåI= Ç~ëë= ïáê= Ç~ë= ÖÉëìÅÜíÉ= wÉáÅÜÉå= åáÅÜí=~äë=ëí~íáëÅÜÉå=qÉñí= 'e'=áå=ÇáÉ=êìåÇÉå=hä~ããÉêå=ÜáåíÉê= Pos=Éáåíê~ÖÉåI=ëçåJ ÇÉêå=~ìÅÜ=Ç~ÑΩê=ÉáåÉå=péÉáÅÜÉêéä~íò=îÉêïÉåÇÉåK== a~åå= ÉêÖáÄí= ëáÅÜ= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= häáÅâ= ~ìÑ= ÇÉå= òïÉáíÉå= _ìííçåI= ÄÉá= ÇÉã=Éáå=îçêÖÉÖÉÄÉåÉë=wÉáÅÜÉå=òì=ìåíÉêëìÅÜÉå=áëíI=ÖäÉáÅÜ=~åëÅÜäáÉ≈ÉåÇK======= procedure TForm1.Button1Click(Sender: TObject); var text, zeichen: ShortString; begin text:=Edit1.Text; zeichen:='e'; if Pos(zeichen,text)>0
then Label2.Caption:='ja' else Label2.Caption:='nein'
end; procedure TForm1.Button2Click(Sender: TObject); var text, zeichen: ShortString; begin text:=Edit1.Text; zeichen:=Edit2.Text; if Pos(zeichen,text)>0 then Label4.Caption:='ja' else Label4.Caption:='nein' end;
báå= ÉáåòÉäåÉë= wÉáÅÜÉå= áëí= åìê= Éáå= péÉòá~äÑ~ää= ÉáåÉë= EáK= ~ääÖK= ãÉÜêÉêÉ= wÉáÅÜÉå= ìãÑ~ëëÉåÇÉåF=qÉñíãìëíÉêëK== aÉëÜ~äÄ= â∏ååÉå= ïáê= áå= ÖäÉáÅÜÉê= tÉáëÉ= ÇáÉ= cìåâíáçå= Pos= ~ìÅÜ= òìê= i∏ëìåÖ= ÇÉê= ÇêáííÉå=ìåÇ=îáÉêíÉå=^ìÑÖ~ÄÉ=ÄÉåìíòÉåW= ONM= =
NNKO== cáåÇÉåI=w®ÜäÉå=ìåÇ=i∏ëÅÜÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå= procedure TForm1.Button3Click(Sender: TObject); var text, muster: ShortString; begin text:=Edit1.Text; muster:='chs'; if Pos(muster,text)>0 then Label5.Caption:='ja' else Label5.Caption:='nein' end; procedure TForm1.Button4Click(Sender: TObject); var text, muster: ShortString; begin text:=Edit1.Text; muster:=Edit3.Text; if Pos(muster,text)>0 then Label7.Caption:='ja' else Label7.Caption:='nein' end;
jáí= ÇÉê= sÉêïÉåÇìåÖ= ÇÉê= ÄÉáÇÉå= îÉêëÅÜáÉÇÉåÉå= k~ãÉå= zeichen= ìåÇ= muster= áå= ÇÉå=ÄÉáÇÉå=bêÉáÖåáëéêçòÉÇìêÉåJm~~êÉå=ëéáÉÖÉäí=ëáÅÜ=ÇáÉ=^ìÑÖ~ÄÉåëíÉääìåÖ=ÇÉìíJ äáÅÜ=áã=m~ëÅ~äJqÉñí=ïáÇÉêK== táê= Ü®ííÉå= ÄÉáÇÉ= j~äÉ= ~ìÅÜ= ÇáÉ= k~ãÉå= xx27prbf96yqf= ï®ÜäÉå= â∏ååÉå= Ó= Éë= ï®êÉ=åáÅÜí=Ñ~äëÅÜ=ÖÉïÉëÉåKKK=
11.2.2
Zählen von Zeichen und Mustern
táÉÇÉê=ïçääÉå=ïáê=ÉáåÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=E_áäÇ=NNKOF=òìã=^ìëÖ~åÖëéìåâí=ÑΩê= ÇáÉ=_ÉëÅÜ®ÑíáÖìåÖ=ãáí=ÇáÉëÉê=Ü®ìÑáÖ=~ìÑíêÉíÉåÇÉå=^ìÑÖ~ÄÉåâä~ëëÉ=ã~ÅÜÉåK=
== _áäÇ=NNKOW=w®ÜäÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå= ONN =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= aáÉ= ^ìÑÖ~ÄÉåëíÉääìåÖÉå= ëáåÇ= îáÉä= ~åëéêìÅÜëîçääÉê= ~äë= áã= îçêáÖÉå= ^ÄëÅÜåáííI= ÑçäÖäáÅÜ=ãΩëëÉå=ïáê=~ìÅÜ=ãÉÜê=~å=dÉáëí=áåîÉëíáÉêÉåK== cΩê=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=çÄÉêëíÉå=_ìííçå=Äê~ìÅÜÉå=ïáê= • ÇáÉ=cìåâíáçå= LengthI=ÇáÉ=ìåë=ÜáäÑíI=ÇáÉ=i®åÖÉ=ÇÉë=ÉáåÖÉÖÉÄÉåÉå=qÉñíÉë=ÑÉëíòìJ ëíÉääÉåK= pÅÜäáÉ≈äáÅÜ= ÉêÑ~ÜêÉå= Ç~ãáíI= ïáÉ= îáÉäÉ= wÉáÅÜÉå= ïáê= ÉáåòÉäå= ~ÄÑê~ÖÉå= ãΩëëÉåK== • ÇáÉ= cìåâíáçå= CopyI= ãáí= ÇÉêÉå= eáäÑÉ= ïáê= ~ìë= ÇÉã= qÉñí= wÉáÅÜÉå= ÑΩê= wÉáÅÜÉå= ÜÉê~ìëä∏ëÉå= â∏ååÉåI= ìã= Éë= ãáí= ÇÉã= ÖÉÖÉÄÉåÉå= wÉáÅÜÉå= îÉêÖäÉáÅÜÉå= òì= â∏ååÉå= • ÉáåÉå=w®ÜäïÉêâëëéÉáÅÜÉêéä~íò= • ÇáÉ=áå=^ÄëÅÜåáíí=V=~ìëÑΩÜêäáÅÜ=Éêâä®êíÉ=w®ÜäëÅÜäÉáÑÉI=ìã=îáÉäÉ=ÖäÉáÅÜ~êíáÖÉ=_ÉJ ÑÉÜäÉI=ÇáÉ=ëáÅÜ=åìê=áå=w~ÜäÉåïÉêíÉå=ìåíÉêëÅÜÉáÇÉåI=~ìÑëÅÜêÉáÄÉå=òì=â∏ååÉå= ^ì≈ÉêÇÉã=ãΩëëÉå=ïáê=ïáëëÉåI=Ç~ëë=Ç~ë=ÉêëíÉ=wÉáÅÜÉå=áå=ÉáåÉã= String=ÇáÉ=mçëáJ íáçå=báåë=Ü~í=Eáã=råíÉêëÅÜáÉÇ=òì=ÉáåÉê=iáëíÉI=ÄÉá=ÇÉê=ÇáÉ=ÉêëíÉ=wÉáäÉ=ÇáÉ=mçëáíáçå= kìää=Ü~íFK=cçäÖäáÅÜ=ÉêÖáÄí=ëáÅÜ=ÇáÉ=mçëáíáçå=ÇÉë=äÉíòíÉå=wÉáÅÜÉåë=áå=ÉáåÉã= String= ~ìë=ÇÉëëÉå=i®åÖÉK= kìå=ëáåÇ=~ääÉ=sçêÄÉíê~ÅÜíìåÖÉå=~ÄÖÉëÅÜäçëëÉåI=ìåÇ=ïáê=â∏ååÉå=ìåë=ÇáÉ=ÉêëíÉå= ÄÉáÇÉå=bêÉáÖåáëéêçòÉÇìêÉå=~åëÉÜÉåK== páÉ= ìåíÉêëÅÜÉáÇÉå= ëáÅÜ= ïáÉÇÉê= åìê= áå= ÇÉê= ^êí= ÇÉê= _ÉäÉÖìåÖ= ÇÉë= péÉáÅÜÉêéä~íòÉë= zeichenK== procedure TForm1.Button1Click(Sender: TObject); var text, zeichen
: ShortString;
// Vereinbarungen
lepos, anzahl,i : Byte; begin text:=Edit1.Text;lepos:=Length(text); zeichen:='e'; anzahl:=0;
//lepos=letzte Position //Belegung mit statischem Text //Zählwerk auf Null setzen
for i:=1 to lepos do
//Zählschleife
begin if Copy(text,i,1)=zeichen then anzahl:=anzahl+1 end; Label2.Caption:=IntToStr(anzahl) end;
= ONO= =
//Konvertierung für Ausgabe
NNKO== cáåÇÉåI=w®ÜäÉå=ìåÇ=i∏ëÅÜÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå= procedure TForm1.Button2Click(Sender: TObject); var text, zeichen
: ShortString;
lepos, anzahl,i : Byte; begin text:=Edit1.Text;lepos:=Length(text); zeichen:=Edit2.Text;
//Belegung aus Textfenster geholt
anzahl:=0; for i:=1 to lepos do
//Zählschleife
begin if Copy(text,i,1)=zeichen then anzahl:=anzahl+1 end; Label4.Caption:=IntToStr(anzahl) end;
t~ë= ®åÇÉêí= ëáÅÜI= ïÉåå= åáÅÜí= Ç~ë= ^ìÑíêÉíÉå= ÉáåÉë= ÉáåòÉäåÉå= wÉáÅÜÉåëI= ëçåÇÉêå= ãÉÜêÉêÉê=wÉáÅÜÉåI=ÇK=ÜK=ÉáåÉë=qÉñíãìëíÉêëI=ÖÉò®Üäí=ïÉêÇÉå=ëçää\== a~åå=ãìëë=áå=ÇÉê=CopyJcìåâíáçå= if Copy(text,i,1)=zeichen then anzahl:=anzahl+1
~åëíÉääÉ=ÇÉê=báåë=ÇáÉ=i®åÖÉ=ÇÉë=qÉñíãìëíÉêë=ëíÉÜÉåK=a~ë=áëí=~ääÉëK== cΩê=ÇáÉ=i®åÖÉ=ÇÉë=qÉñíãìëíÉêë=ïáêÇ=áå=ÇÉå=ÑçäÖÉåÇÉå=ÄÉáÇÉå=bêÉáÖåáëéêçòÉÇìJ êÉå=ÇÉê=péÉáÅÜÉêéä~íò=ãáí=ÇÉã=k~ãÉå=mulen=EÑΩê=MuëíÉêlänÖÉF=îÉêïÉåÇÉíK= procedure TForm1.Button3Click(Sender: TObject); var text, muster
: ShortString;
lepos, mulen, anzahl, i: Byte; begin text:=Edit1.Text;lepos:=Length(text); muster:='chs';mulen:=Length(muster);
//mulen=Muster-Länge
anzahl:=0; for i:=1 to lepos do begin if Copy(text,i,mulen)=muster then anzahl:=anzahl+1 end; Label5.Caption:=IntToStr(anzahl) end;
ONP =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= procedure TForm1.Button4Click(Sender: TObject); var text, muster
: ShortString;
lepos, mulen, anzahl,i : Byte; begin text:=Edit1.Text
;
lepos:=Length(text); muster:=Edit3.Text;
//Muster aus Textfenster holen
mulen:=Length(muster); anzahl:=0; for i:=1 to lepos do begin if Copy(text,i,mulen)=muster then anzahl:=anzahl+1 end; Label7.Caption:=IntToStr(anzahl) end;
11.2.3
Löschen von Zeichen und Mustern
_áäÇ= NNKP= òÉáÖí= ìåë= ãáí= ÇÉå= _ÉëÅÜêáÑíìåÖÉå= ÇÉê= îáÉê= _ìííçåë= ÇáÉ= òì= ä∏ëÉåÇÉå= ^ìÑÖ~ÄÉåW=
== _áäÇ=NNKPW=i∏ëÅÜÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå== aáÉ= fÇÉÉ= áëí= Ö~åò= ÉáåÑ~ÅÜW= jáí= eáäÑÉ= ÉáåÉê= w®ÜäëÅÜäÉáÑÉ= ìåÇ= ÇÉê= CopyJcìåâíáçå= ÑáåÇÉå=ïáê=ÜÉê~ìëI=ïç=ëáÅÜ=Éáå=ÜÉê~ìë=òì=ïÉêÑÉåÇÉë=wÉáÅÜÉå=ÄÉÑáåÇÉíI=Ç~ë=ÉåíJ ÑÉêåÉå=ïáê=Ç~åå=ãáí=eáäÑÉ=ÇÉê=mêçòÉÇìê=DeleteK== dÉë~Öí=ìåÇ=ÖÉí~åI=ëÉÜÉå=ïáê=ìåë=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=~åW== ONQ= =
NNKO== cáåÇÉåI=w®ÜäÉå=ìåÇ=i∏ëÅÜÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå= procedure TForm1.Button1Click(Sender: TObject); var text, zeichen: ShortString; lepos, i
: Byte;
begin text:=Edit1.Text; lepos:=Length(text); zeichen:='e'; for i:=1 to lepos do begin if Copy(text,i,1)=zeichen then Delete(text,i,1) end; Label2.Caption:=text end;
báÖÉåíäáÅÜ= äçÖáëÅÜ\= råÇ= ïÉåå= òì= çÄÉêÑä®ÅÜäáÅÜ= ÖÉíÉëíÉí= ïáêÇ= ëÅÜÉáåíÛë= ~ìÅÜ= òì= ëíáããÉåK=^ÄÉê=ëÉÜÉå=ïáê=ìåë=áå=_áäÇ=NNKQ=Éáå=Ö~åò=Éêëí~ìåäáÅÜÉë=bêÖÉÄåáë=~å>==
= _áäÇ=NNKQW=qÉñí=ìåÇ=bêÖÉÄåáë=ÇÉê=bêÉáÖåáëéêçòÉÇìê= kìå=ÄÉÑáåÇÉå=ïáê=ìåë=áå=bêâä®êìåÖëåçíK=táÉ=âçããí=ÇáÉëÉ=^ìëÖ~ÄÉ=òìëí~åÇÉ\== ^äëçW= péÉáÅÜÉêéä~íò= text= Ü~í= òìÉêëí= V= wÉáÅÜÉå= ìåÇ= ÇÉå= fåÜ~äí= exeeyeeezK= lepos= ÉêÜ®äí=ÇÉå=fåÜ~äí=VK=kìå=ÄÉÖáååí=ÇáÉ=w®ÜäëÅÜäÉáÑÉ=áÜêÉ=^êÄÉáíW= • i=ïáêÇ=~ìÑ=N=ÖÉëÉíòíK=^å=ÇáÉëÉê=mçëáíáçå=áëí=Éáå= ‘e‘K=cçäÖäáÅÜ=ÄÉâçããí= Delete= òì=íìåI=ÇÉê=péÉáÅÜÉêéä~íò=text=ÄÉâçããí=ÇÉå=åÉìÉå=fåÜ~äí=xeeyeeezK= • i= ïáêÇ= ~ìÑ= O= ÖÉëÉíòí= ìåÇ= ìåíÉêëìÅÜí= ~å= ÇáÉëÉê= mçëáíáçå= ÇÉå= áåòïáëÅÜÉå= îÉê®åÇÉêíÉå= fåÜ~äí= îçå= textK= xeeyeeez= Ü~í= ~å= òïÉáíÉê= mçëáíáçå=Éáå= ‘e‘I= ÑçäÖJ äáÅÜ=ïáêÇ=ïáÉÇÉê=ÖÉä∏ëÅÜíI=text=ÄÉâçããí=xeyeeezK= • i= ïáêÇ= ~ìÑ= P= ÖÉëÉíòíI= ìåÇ= ÇáÉëÉë= xeyeeez= ïáêÇ= ~å= ÇÉê= mçëáíáçå= P= ìåíÉêëìÅÜíK= açêí=âÉáå=‘e‘I=ÑçäÖäáÅÜ=âÉáå=DeleteK= • i= ïáêÇ= ~ìÑ= Q= ÖÉëÉíòíI= xeyeeez= ïáêÇ= ~å= mçëáíáçå= Q= ìåíÉêëìÅÜíK= ‘e‘= ÖÉÑìåÇÉåI= i∏ëÅÜìåÖI=åÉìÉê=fåÜ~äí=îçå=textW=xeyeezK= • i= ïáêÇ= ~ìÑ= R= ÖÉëÉíòíI= xeyeez= ïáêÇ= ~å= mçëáíáçå= R= ìåíÉêëìÅÜíI= ‘e‘= ÖÉÑìåÇÉåI= ïáÉÇÉê=i∏ëÅÜìåÖI=åÉìÉê=fåÜ~äí=îçå=textW=xeyezK== ONR =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= i= ÇìêÅÜä®ìÑí= åçÅÜ= ÇáÉ= tÉêíÉ= S= Äáë= VI= ~ÄÉê= ïç= åáÅÜíë= òì= ìåíÉêëìÅÜÉå= áëíI= ïáêÇ=
~ìÅÜ=åáÅÜíë=ÖÉÑìåÇÉå=ìåÇ=Éêëí=êÉÅÜí=åáÅÜí=ÖÉä∏ëÅÜíK== pç=Éêâä®êí=ëáÅÜ=Ç~ë=bêÖÉÄåáëW=a~ÇìêÅÜI=Ç~ëë=ëáÅÜ=ÇÉê=råíÉêëìÅÜìåÖëÖÉÖÉåëí~åÇ= îçå= j~ä= òì= j~ä= ®åÇÉêå= EìåÇ= Ç~ÄÉá= îÉêâΩêòÉåF= â~ååI= ÇáÉ= i~ìÑî~êá~ÄäÉ= i= ~ÄÉê= ìåîÉêÇêçëëÉå=îçêï®êíë=ëíΩêãíI=âçããí=ÇÉê=äçÖáëÅÜÉ=cÉÜäÉê=òìëí~åÇÉK== tç=äáÉÖí=ÇáÉ=i∏ëìåÖ\== táê=ãΩëëÉå=ÉÄÉå=Ç~ÑΩê=ëçêÖÉåI=Ç~ëë=ÄÉá=àÉÇÉã=åÉìÉå=pÅÜäÉáÑÉåÇìêÅÜÖ~åÖ=ïáÉJ ÇÉê=îçå=îçêå=ãáí=ÇÉê=råíÉêëìÅÜìåÖ=ÇÉë=fåÜ~äíë=îçå= text=~åÖÉÑ~åÖÉå=ïáêÇK=a~J ÑΩê=ÄÉåìíòÉå=ïáê=ÉáåÉ=òïÉáíÉ=i~ìÑî~êá~ÄäÉ=jW= for i:=1 to lepos do begin for j:=1 to i do begin if Copy(text,j,1)=zeichen then Delete(text,j,1) end end;
fã=qÉñí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ã~ÅÜÉå=ïáê=òìê=sÉêÉáåÑ~ÅÜìåÖ=ÇÉê=pÅÜêÉáÄ~êÄÉáí= Ç~åå=~ÄÉê=îçå=ÇÉê=^ìëå~ÜãÉêÉÖÉäìåÖ=ÑΩê=w®ÜäëÅÜäÉáÑÉå=dÉÄê~ìÅÜW== • píÉÜí= áã= fååÉêÉå= ÇÉê= w®ÜäëÅÜäÉáÑÉ= åìê= Éáå= ÉáåòáÖÉê= _ÉÑÉÜäI= â∏ååÉå= ÇáÉ= begin...endJ^åïÉáëìåÖëâä~ããÉêå=ïÉÖÖÉä~ëëÉå=ïÉêÇÉåK== aáÉ=ÉêëíÉå=ÄÉáÇÉå=bêÉáÖåáëéêçòÉÇìêÉå=Ü~ÄÉå=Ç~åå=ÑçäÖÉåÇÉë=^ìëëÉÜÉåW== procedure TForm1.Button1Click(Sender: TObject); var text, zeichen: ShortString; lepos, i,j
: Byte;
begin text:=Edit1.Text;lepos:=Length(text); zeichen:='e';
//oder zeichen:=Edit2.Text; für Button 2
for i:=1 to lepos do for j:=1 to i do if Copy(text,j,1)=zeichen then Delete(text,j,1); Label2.Caption:=text end;
dÉÜí= Éë= ìã= Ç~ë= i∏ëÅÜÉå= ÉáåÉë= jìëíÉêëI= ãìëë= ëçïçÜä= áå= ÇÉê= CopyJcìåâíáçå= ~äë= ~ìÅÜ=áå=ÇÉê=DeleteJmêçòÉÇìê=ÇáÉ=i®åÖÉ=ÇÉë=jìëíÉêë=ÄÉêΩÅâëáÅÜíáÖí=ïÉêÇÉåW==
ONS= =
NNKP== bêëÉíòÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå= procedure TForm1.Button3Click(Sender: TObject); var text, muster lepos,mulen,i,j
: ShortString; : Byte;
begin text:=Edit1.Text;lepos:=Length(text); muster:='wa';
//oder muster:=Edit3.Text; für Button 4
mulen:=Length(muster); for i:=1 to lepos do for j:=1 to i do if Copy(text,j,mulen)=muster then Delete(text,j,mulen); Label5.Caption:=text end;
cΩê=~ääÉI=ÇáÉ=ãáí=ÇÉå=ÄÉáÇÉå= îÉêëÅÜ~ÅÜíÉäíÉå=w®ÜäëÅÜäÉáÑÉå=åçÅÜ=áÜêÉ=äáÉÄÉ=kçí= Ü~ÄÉåI=ïáêÇ=áã=å®ÅÜëíÉå=^ÄëÅÜåáíí=ÉáåÉ=~äíÉêå~íáîÉ=sçêÖÉÜÉåëïÉáëÉ=îçêÖÉëíÉääíI= ÇáÉ=ãáí=åìê=ÉáåÉê=w®ÜäëÅÜäÉáÑÉ=~ìëâçããí=ìåÇ=Ç~ãáí=ÄÉëëÉê=òì=îÉêëíÉÜÉå=áëíK==
11.3
Ersetzen von Zeichen und Mustern
_áäÇ=NNKR=òÉáÖí=ìåë=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ=ÇÉê=ÄÉáÇÉå=_ìííçåë=ÇáÉ=ÄÉáÇÉå=^ìÑÖ~J ÄÉåX= ïáê= ïçääÉå= ÇáÉëã~ä= ÖäÉáÅÜ= ëçäÅÜÉ= ~ääÖÉãÉáåÉå= s~êá~åíÉå= ÄÉÜ~åÇÉäåI= ÄÉá= ÇÉåÉå= îçã= kìíòÉê= ÇáÉ= ÄÉáÇÉå= wÉáÅÜÉå= ÄòïK= ÇáÉ= ÄÉáÇÉå= jìëíÉê= áå= qÉñíÑÉåëíÉê= ÉáåÖÉÖÉÄÉå=ïÉêÇÉåK==
== _áäÇ=NNKRW=bêëÉíòÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå== wìê=i∏ëìåÖ=ÇÉê=ÄÉáÇÉå=^ìÑÖ~ÄÉå=ïçääÉå=ïáê=òïÉá=píê~íÉÖáÉå=âÉååÉå=äÉêåÉåW== aáÉ=ÉêëíÉ=píê~íÉÖáÉ=ÉêÖ®åòí=äÉÇáÖäáÅÜ=ÇÉå=îçêáÖÉå=^ÄëÅÜåáííW=k~ÅÜ=ÇÉã=i∏ëÅÜÉå= ÇÉë= wÉáÅÜÉåë= ÄòïK= ÇÉë= jìëíÉêë= ïáêÇ= ãáí= ÇÉê= InsertJmêçòÉÇìê=ëçÑçêí= ÉáåÖÉÑΩÖíK=
ONT =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= iÉáÇÉê=ÖáÄí=Éë=~ÄÉê=Ççêí=~ìÅÜ=ïáÉÇÉê=äçÖáëÅÜÉ=cÉÜäÉê=Ó=ìåÇ=ÉêåÉìí=^åä~ëë=òìã= áåíÉåëáîÉå=k~ÅÜÇÉåâÉåK= aáÉ=òïÉáíÉ=píê~íÉÖáÉ=áëí=ÉáåÑ~ÅÜÉê=òì=îÉêëíÉÜÉå=Ó=ëáÉ=Ä~ëáÉêí=~ìÑ=ÇÉã=kÉì~ìÑÄ~ì= ÇÉë=bêÖÉÄåáëJpíêáåÖëK==
11.3.1
Finden, Löschen und Einfügen
tÉåå=ïáê=ÇáÉ=péÉáÅÜÉêéä®íòÉ=ÑΩê=Ç~ë= o~ìëJwÉáÅÜÉå=ãáí= raus=ìåÇ=ÑΩê=Ç~ë=oÉáåJ wÉáÅÜÉå=ãáí=rein=ÄÉåÉååÉåI=ÉêÖáÄí=ëáÅÜ=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=häáÅâ=~ìÑ=ÇÉå= çÄÉêÉå=_ìííçå=êÉÅÜí=ÉáåÑ~ÅÜ=~äë=bêïÉáíÉêìåÖ=~ìë=ÇÉã=îçêáÖÉå=^ÄëÅÜåáííW== táêÇ= ãáí= ÇÉê= CopyJcìåâíáçå= Éáå= wÉáÅÜÉå= ÖÉÑìåÇÉåI= ÑçäÖí= áå= ÇÉê= áååÉêÉå= w®ÜäJ ëÅÜäÉáÑÉ=å~ÅÜ=ÇÉê= i∏ëÅÜìåÖ=ãáí= Delete=ìåãáííÉäÄ~ê= ãáííÉäë= Insert=Ç~ë= báåÑΩÖÉå= ÇÉë=bêëÉíòìåÖëòÉáÅÜÉåë=~å=ÇÉêëÉäÄÉå=mçëáíáçåW=== procedure TForm1.Button1Click(Sender: TObject); var text, raus, rein: ShortString; lepos, i,j
: Byte;
begin text:=Edit1.Text; lepos:=Length(text); raus:=Edit2.text; rein:=Edit3.Text; for i:=1 to lepos do for j:=1 to i do if Copy(text,j,1)=raus then begin Delete(text,j,1); Insert(rein,text,j) end; Label4.Caption:=text end;
kìå=ÖáÄí=Éë=áã=fååÉêÉå=ÇÉë=qÉëíëI=ÇÉê=ÇÉå=fåÜ~äí=ÇÉê= jJpÅÜäÉáÑÉ=~ìëã~ÅÜíI=òïÉá= _ÉÑÉÜäÉI=ÑçäÖäáÅÜ=áëí=ÇáÉ=^ìëå~ÜãÉêÉÖÉä=åáÅÜí=ãÉÜê=~åïÉåÇÄ~êK== a~ë=fååÉêÉ=ÇÉê= jJpÅÜäÉáÑÉ= Ç~ÖÉÖÉå=Ü~í= áããÉê=åçÅÜ= åìê= ÉáåÉå=ł_ÉÑÉÜä=Ó=å®ãJ äáÅÜ=ÇáÉëÉå=qÉëíK=aáÉ=iJpÅÜäÉáÑÉ=ÉåíÜ®äí=åìê=ÇáÉ=jJpÅÜäÉáÑÉK== cçäÖäáÅÜ=Ç~êÑ=ÄÉáÇÉ=j~äÉ=ÇáÉ=^ìëå~ÜãÉêÉÖÉä=ÑΩê=w®ÜäëÅÜäÉáÑÉå=~åÖÉï~åÇí=ïÉêJ ÇÉåK== rã= Éë= åçÅÜ= Éáåã~ä= òì= ë~ÖÉåW= tÉê= ëáÅÜ= ìåëáÅÜÉê= ÑΩÜäíI= ã~ÅÜí= åáÅÜíë= Ñ~äëÅÜI= ïÉåå=Éê=^ìëå~ÜãÉêÉÖÉäå=åáÅÜí=îÉêïÉåÇÉí=ìåÇ=~ìëÑΩÜêäáÅÜ=éêçÖê~ããáÉêíW=== ONU= =
NNKP== bêëÉíòÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå= for i:=1 to lepos do begin
//Inneres der i-Schleife beginnt
for j:=1 to i do begin
//Inneres der j-Schleife beginnt
if Copy(text,j,1)=raus then begin
//Inneres des Tests beginnt
Delete(text,j,1); Insert(rein,text,j) end end
//Inneres des Tests endet //Inneres der j-Schleife endet
end;
//Inneres der i-Schleife endet
aáÉëÉ= bêÉáÖåáëéêçòÉÇìê= â~åå= ã~å= å~ÅÜ= eÉêòÉåëäìëí= ~ìëíÉëíÉå= Ó= ëáÉ= ~êÄÉáíÉí= áããÉê=êáÅÜíáÖK== léíáãáëíáëÅÜ=åÉÜãÉå=ïáê=ÇÉëÜ~äÄ=ÖäÉáÅÜ=ÇáÉ=~åÇÉêÉ=bêÉáÖåáëéêçòÉÇìê=òìã=bêëÉíJ òÉå=ÇÉë=jìëíÉêë=áå=^åÖêáÑÑI=ëáÉ=ãΩëëíÉ=ÇçÅÜ=áå=ÖäÉáÅÜÉê=tÉáëÉ=ÑìåâíáçåáÉêÉåW= procedure TForm1.Button2Click(Sender: TObject); var text, raus, rein: ShortString; lepos,mulen,i,j : Byte; begin text:=Edit1.Text; raus:=Edit4.text; rein:=Edit5.Text; lepos:=Length(text); mulen:=Length(raus); for i:=1 to lepos do for j:=1 to i do if Copy(text,j,mulen)=raus then begin Delete(text,j,mulen);Insert(rein,text,j) end; Label7.Caption:=text end;
açÅÜ= ëÅÜçå= ïáÉÇÉê= ïáê= ìåëÉêÉ= bìéÜçêáÉ= ÖÉÇ®ãéÑíK= bêëÉíòÉå= ïáê= Éáå= îçêÖÉÖÉJ ÄÉåÉë=jìëíÉê=ÇìêÅÜ=Éáå=âΩêòÉêÉë=çÇÉê=ÖäÉáÅÜä~åÖÉë=jìëíÉêI=ÖÉÜí=~ääÉë=ÖìíK=^ÄÉê= ïÉÜÉI=ïÉåå=ÇáÉ=ÜáåÉáåâçããÉåÇÉ=wÉáÅÜÉåÑçäÖÉ=ä®åÖÉêI=ïçã∏ÖäáÅÜ=îáÉä=ä®åÖÉê= ~äë=Ç~ë=ło~ìëJjìëíÉê=áëíK= = ONV =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= få=_áäÇ=NNKS=ìåÇ=_áäÇ=NNKT=ëÉÜÉå=ïáê=ÇáÉ=jáëëÉêÑçäÖÉK=tçê~å=äáÉÖí=Éë\==
= _áäÇ=NNKSW=a~ë=äÉíòíÉ=jìëíÉê=ïáêÇ=åáÅÜí=ÉêëÉíòí====
== _áäÇ=NNKTW=aáÉ=äÉíòíÉå=ÄÉáÇÉå=jìëíÉê=ïÉêÇÉå=åáÅÜí=ÉêëÉíòí== bêáååÉêå=ïáê=ìåë=~å=ÇÉå=îçêáÖÉå=^ÄëÅÜåáííK=aáÉ=i~ìÑî~êá~ÄäÉ= i=ÄÉïÉÖí=ëáÅÜ=îçå= báåë=Äáë=òìê=i®åÖÉ=ÇÉë=ìêëéêΩåÖäáÅÜÉå=qÉñíÉëI=~äëç=Äáë=11K== pÅÜçå=å~ÅÜ=ÇÉã=ÉêëíÉå=jìëíÉêí~ìëÅÜ=áëí=ÇÉê=qÉñí=~ÄÉê=ìã=Éáå=wÉáÅÜÉå=E_áäÇ=NNKSF= ÄÉòáÉÜìåÖëïÉáëÉ=ëçÖ~ê=ìã=îçääÉ=ëÉÅÜë=wÉáÅÜÉå=E_áäÇ=NNKTF=ä®åÖÉê=ÖÉïçêÇÉåK== • a~ë=ÜÉá≈íI=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=ÄÉÉåÇÉí=áÜêÉ=^êÄÉáí=îáÉä=òì=òÉáíáÖK== bë=ï®êÉ=òì=ΩÄÉêäÉÖÉåI=ïáÉ=ã~å=Ç~ÑΩê=ëçêÖíI=Ç~ëë=~ìÅÜ=áå=ÇáÉëÉã=c~ää=Éñ~âí=Äáë= òìã=pÅÜäìëë=ÇÉë=ÖÉê~ÇÉ=Éåíëí~åÇÉåÉå=píêáåÖë=îÉêÖäáÅÜÉåI=ÖÖÑK=ÖÉä∏ëÅÜí=ìåÇ=ÉáåJ ÖÉÑΩÖí=ïáêÇK=sáÉä=pé~≈=ÄÉáã=håçÄÉäå>== táê=ïçääÉå=ìåë=ëí~ííÇÉëëÉå=ÉáåÉê=î∏ääáÖ=~åÇÉêÉå=píê~íÉÖáÉ=òìïÉåÇÉåI=ÇáÉ= çÜåÉ= ÇáÉ=mêçòÉÇìêÉå=Delete=ìåÇ=Insert=~ìëâçããíK==
11.3.2
Neuaufbau eines zweiten Strings
aáÉ= sçêÖÉÜÉåëïÉáëÉ= áëí= ~ìë= ÇÉã= qÉñí= ÇÉê= bêÉáÖåáëéêçòÉÇìê= ìåÇ= ~åÜ~åÇ= ÇÉê= hçããÉåí~êÉ=ÉêëáÅÜíäáÅÜW= OOM= =
NNKP== bêëÉíòÉå=îçå=wÉáÅÜÉå=ìåÇ=jìëíÉêå= procedure TForm1.Button1Click(Sender: TObject); var alttext, neutext, raus, rein, zeichen: ShortString; lepos, i
: Byte;
begin alttext:=Edit1.Text;lepos:=Length(alttext); raus:=Edit2.text; rein:=Edit3.Text; neutext:='';
//In neutext soll das Ergebnis entstehen
for i:=1 to lepos do begin zeichen:=Copy(alttext,i,1);
//Zeichen wird herauskopiert
if zeichen=raus then neutext:=neutext+rein else neutext:=neutext+zeichen end; Label4.Caption:=neutext end;
aÉê= wáÉäJpíêáåÖ= neutext= ïáêÇ= òìÉêëí= áåáíá~äáëáÉêíI= ÇK= ÜK= ãáí= ÇÉã= äÉÉêÉå= píêáåÖ= ''= ÄÉäÉÖí= Ó= Ç~ë= â~åå= ã~å= îÉêÖäÉáÅÜÉå= ãáí= ÇÉã= kìääëÉíòÉå= îçå= w®ÜäïÉêâëJ= çÇÉê= pìããÉåëéÉáÅÜÉêéä®íòÉåK== ^åëÅÜäáÉ≈ÉåÇ=ïáêÇ=wÉáÅÜÉå=ÑΩê=wÉáÅÜÉå=~ìë=ÇÉã=~äíÉå=píêáåÖ=ÜÉê~ìëâçéáÉêíK=fëí= Ç~ë= wÉáÅÜÉå= łëÅÜäÉÅÜíI= ïáêÇ= ëí~ííÇÉëëÉå= Ç~ë= bêëÉíòìåÖëòÉáÅÜÉå= ~å= neutext= ~åJ ÖÉÑΩÖíK== fëí=Ç~ë=wÉáÅÜÉå=łÖìíI=ãìëë=åáÅÜí=ÉêëÉíòí=ïÉêÇÉåI=Éë=ïáêÇ=ëÉäÄëí=~å= neutext=~åJ ÖÉâÉííÉíK== pç=ÉåíëíÉÜí=áå=ÇÉã=péÉáÅÜÉêéä~íò=neutext=ëÅÜäáÉ≈äáÅÜ=Ç~ë=ÖÉëìÅÜíÉ=bêÖÉÄåáëK== §ÄêáÖÉåë=ëÉá=ÜáÉê=~åÖÉãÉêâíI=Ç~ëë=Ç~ãáí=~ìÅÜ=ëÉÜê=Öìí=ÇáÉ=^ìÑÖ~ÄÉ=i∏ëÅÜÉå=ÉáJ åÉë=wÉáÅÜÉåë=ä∏ëÄ~ê=áëíW== for i:=1 to lepos do begin zeichen:=Copy(alttext,i,1); if zeichen raus then neutext:=neutext+zeichen end;
bë=ïáêÇ=ÉÄÉå=åìê=Ç~åå=ÇÉê=bêÖÉÄåáëJpíêáåÖ= neutext=ïÉáíÉêÉåíïáÅâÉäíI=ïÉåå=Ç~ë= ÖÉê~ÇÉ=ìåíÉêëìÅÜíÉ=wÉáÅÜÉå=åáÅÜí=Ç~ë=i∏ëÅÜòÉáÅÜÉå=áëíK=
OON =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= cΩê= Ç~ë= jìëíÉêJbêëÉíòÉå= ΩÄÉêåÉÜãÉå= ïáê= òìÉêëí= ÇáÉ= fÇÉÉ= ÇÉë= bêÖÉÄåáëJpíêáåÖëK= a~ãáí=ëáåÇ=ïáê=ÇÉå=ûêÖÉê=äçëI=Ç~ëë=ÇÉê=píêáåÖ=ä®åÖÉê=ìåÇ=ä®åÖÉê=ïÉêÇÉå=â∏ååíÉK== kìå=ãΩëëÉå=ïáê=åìê=åçÅÜ=Ç~ÑΩê= ëçêÖÉåI=Ç~ëë=Éáå= ÖÉÑìåÇÉåÉë= jìëíÉê=áã= ~äíÉå= píêáåÖ=ÄÉá=ÇÉê=å®ÅÜëíÉå=råíÉêëìÅÜìåÖ=łΩÄÉêëéêìåÖÉå=ïáêÇK== a~ë=ëÅÜ~ÑÑÉå=ïáê=ÇìêÅÜ=sÉêïÉåÇìåÖ=ÉáåÉë=péÉáÅÜÉêéä~íòÉë= posI=áå=ÇÉã=ÇáÉ=mçJ ëáíáçå=ÑçêíÖÉëÅÜêáÉÄÉå=ïáêÇI=~Ä=ÇÉê=ÇáÉ=å®ÅÜëíÉ=^å~äóëÉ=ëí~ííÑáåÇÉíK== táêÇ=âÉáå=ło~ìëJjìëíÉê=ÖÉÑìåÇÉåI=ÖÉÜí=ÇáÉ=mçëáíáçå=ìã=ÉáåÉå=tÉêí=å~ÅÜ=êÉÅÜíëK= tìêÇÉ= Éáå= ło~ìëJjìëíÉê= ÖÉÑìåÇÉå= ëéêáåÖí= ÇáÉ= mçëáíáçå= ìã= ÇÉëëÉå= i®åÖÉ= å~ÅÜ= êÉÅÜíëW= procedure TForm1.Button2Click(Sender: TObject); var alttext, neutext, raus, rein, muster, zeichen: ShortString; lepos, i, pos, rauslen
: Byte;
begin alttext:=Edit1.Text; raus:=Edit4.text; rein:=Edit5.Text; lepos:=Length(alttext); rauslen:=Length(raus); neutext:=''; pos:=1; for i:=1 to lepos do begin muster:=Copy(alttext,pos,rauslen); zeichen:=Copy(alttext,pos,1); if muster=raus then begin neutext:=neutext+rein; pos:=pos+rauslen end else begin neutext:=neutext+zeichen;pos:=pos+1 end end; Label7.Caption:=neutext end;
aáÉëÉ= ÉáåÑ~ÅÜÉ= píê~íÉÖáÉ= áëí= ãáí= ÉáåÉê= ûåÇÉêìåÖ= ëçÑçêí= ~åïÉåÇÄ~ê= ÑΩê= ÇáÉ= ^ìÑJ Ö~ÄÉåëíÉääìåÖ=ÇÉë=îçêáÖÉå=^ÄëÅÜåáííëI=Ç~ë=jìëíÉêJi∏ëÅÜÉåW=== if muster=raus then begin neutext:=neutext+''; pos:=pos+rauslen end else begin neutext:=neutext+zeichen;pos:=pos+1 end
OOO= =
NNKR== sÉêÖäÉáÅÜÉ=îçå=wÉáÅÜÉåÑçäÖÉå=
11.4
Palindrom-Test
báåÉ= wÉáÅÜÉåÑçäÖÉ= ÜÉá≈í= m~äáåÇêçãI= ïÉåå= ã~å= ÄÉáã= iÉëÉå= îçå= äáåâë= å~ÅÜ= êÉÅÜíë=Ç~ëëÉäÄÉ=ÉêÜ®äí=ïáÉ=ÄÉá=iÉëÉå=îçå=êÉÅÜíë=å~ÅÜ=äáåâëK== aÉã=Öêç≈Éå=mÜáäçëçéÜÉå=pÅÜçéÉåÜ~ìÉê=ïáêÇ=Ç~ë=m~äáåÇêçã=~ìë=_áäÇ=NNKU=òìJ ÖÉëÅÜêáÉÄÉåW==
== _áäÇ=NNKUW=m~äáåÇêçã= cΩê=ìåë=äÉáíÉí=ëáÅÜ=å~íΩêäáÅÜ=ÇáÉ=ÉåíëéêÉÅÜÉåÇÉ=mêçÖê~ããáÉê~ìÑÖ~ÄÉ=~ÄK== fÜêÉ=i∏ëìåÖW=wÉáÅÜÉå=ÑΩê=wÉáÅÜÉå=~ìë=alttext=ïáêÇ=äáåâë=~å=neutext=~åÖÉâÉííÉíW= procedure TForm1.Button1Click(Sender: TObject); var alttext, neutext, zeichen: ShortString; lepos, i
: Byte;
begin alttext:=Edit1.Text; lepos:=Length(alttext); neutext:='';
//in neutext soll das Ergebnis entstehen
for i:=1 to lepos do begin zeichen:=Copy(alttext,i,1); neutext:=zeichen + neutext
//Zeichen links anketten
end; Label2.Caption:=neutext end;
11.5
Vergleiche von Zeichenfolgen
11.5.1
Lexikografischer Vergleich
_Éíê~ÅÜíÉå= ïáê= ÇáÉëã~ä= òìÉêëí= ÉáåÉ= bêÉáÖåáëéêçòÉÇìê= òìê= aÉãçåëíê~íáçå= ÇÉê= táêâìåÖëïÉáëÉ=ÇÉê=cìåâíáçå=CompareStrW== OOP =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= procedure TForm1.Button1Click(Sender: TObject); var tx1, tx2 : ShortString; vergleich: Integer; begin tx1:=Edit1.Text; tx2:=Edit2.Text; vergleich:=CompareStr(tx1,tx2); if vergleich0 then Label3.Caption:='Der untere Text steht im Telefonbuch vorn' end;
tÉåå= píêáåÖë= îÉêÖäáÅÜÉå= ïÉêÇÉåI= ÉêÑçäÖí= ÇáÉëÉê= sÉêÖäÉáÅÜ= ëíÉíë= áã= äÉñáâçÖê~ÑáJ ëÅÜÉå=páååÉW== • aÉê=łâäÉáåÉêÉ=píêáåÖ=ëíÉÜí=áã=qÉäÉÑçåÄìÅÜ=îçê=ÇÉã=łÖê∏≈ÉêÉå=píêáåÖK== a~ÄÉá= ÉåíëÅÜÉáÇÉí= òìÉêëí= Ç~ë= ÉêëíÉ= wÉáÅÜÉåK= kìê= ÄÉá= däÉáÅÜÜÉáí= ÇÉê= ÉêëíÉå= wÉáJ ÅÜÉå=ïáêÇ=å~ÅÜ=ÇÉå=òïÉáíÉå=wÉáÅÜÉå=ÉåíëÅÜáÉÇÉå=ìëïK== báå= píêáåÖI= ÇÉê= òÉáÅÜÉåÖäÉáÅÜ= ÇÉã= ^åÑ~åÖ= ÉáåÉë= ~åÇÉêÉå= píêáåÖë= áëíI= ëíÉÜí= áã= qÉäÉÑçåÄìÅÜ=ÉÄÉåÑ~ääë=ïÉáíÉê=îçêå=EMai=îçê=MaierFK== cΩê=ÇáÉ=wÉáÅÜÉåJsÉêÖäÉáÅÜÉ=Öáäí=ÇáÉ=^åçêÇåìåÖ=ÇÉê=^p`ffJq~ÄÉääÉ=EëáÉÜÉ=^ÄëÅÜåáíí= NMKOFK=jáí=ÇÉå=_áäÇÉêå=NNKV=Äáë=NNKNO=ïÉêÇÉå=ÉáåáÖÉ=_ÉáëéáÉäÉ=îçêÖÉÑΩÜêíW==
== _áäÇ=NNKVW=_Éá=ÖäÉáÅÜÉå=^åÑ®åÖÉå=ÉåíëÅÜÉáÇÉí=ÇáÉ=hΩêòÉ=
== _áäÇ=NNKNMW=dêç≈ÄìÅÜëí~ÄÉå=îçê=häÉáåÄìÅÜëí~ÄÉå= OOQ= =
NNKR== sÉêÖäÉáÅÜÉ=îçå=wÉáÅÜÉåÑçäÖÉå= =
== _áäÇ=NNKNNW=wáÑÑÉêå=îçê=_ìÅÜëí~ÄÉå=
== _áäÇ=NNKNOW=wïÉáí~ìëÉåÇ=áëí=âäÉáåÉê=~äë=U= a~ë=äÉíòíÉ=_ÉáëéáÉä=ã~ÅÜí=Éë=ïáÉÇÉê=Éáåã~ä=ÇÉìíäáÅÜW== • ^ìÅÜ=ïÉåå=ÇÉê=fåÜ~äí=ÉáåÉë=qÉñíÑÉåëíÉêë=~ìëëáÉÜí=ïáÉ=ÉáåÉ=w~Üä=Ó=Éë=áëí=âÉáåÉK= bë=áëí=ÉáåÉ=wÉáÅÜÉåÑçäÖÉ=ìåÇ=ïáêÇ=ÄÉáã=sÉêÖäÉáÅÜ=~ìÅÜ=ëç=ÄÉÜ~åÇÉäí=Ó=Ç~ë=ÉêëíÉ= wÉáÅÜÉå=ÉåíëÅÜÉáÇÉí=ÄÉêÉáíëI=ÇÉê=oÉëí=ëéáÉäí=ÄÉá=ÇÉëëÉå=råÖäÉáÅÜÜÉáí=ΩÄÉêÜ~ìéí= âÉáåÉ=oçääÉ=ãÉÜêK== ^åëíÉääÉ= ÇÉê= cìåâíáçå= CompareStr= â∏ååÉå= ïáê= å~íΩêäáÅÜ= ~ìÅÜ= ÇáÉ= ÖÉïçÜåíÉå= råÖäÉáÅÜìåÖëòÉáÅÜÉå=áå=ÇÉå=qÉëíë=îÉêïÉåÇÉåW= if tx1tx2 then Label3.Caption:='Der untere Text steht im Telefonbuch vorn'
11.5.2
Minimax in Listen
báåÉ= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= ÉåíÜ®äí= ÇáÉ= iáëíÉ= ãáí= ÇÉå= k~ãÉå= ÇÉê= ëÉÅÜòÉÜå= _ìåJ ÇÉëä®åÇÉê= ëçïáÉ= òïÉá= _ìííçåëK= Button1= íê®Öí= ÇáÉ= ^ìÑëÅÜêáÑí= Suche Land mit längstem NamenI=Button2=íê®Öí=ÇáÉ=^ìÑëÅÜêáÑí=Suche lexikografisch letztes LandK== OOR =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= få=ÄÉáÇÉå=c®ääÉå=Ü~åÇÉäí=Éë=ëáÅÜ=ìã=ÉáåÉ=j~ñáãìãëìÅÜÉ=ÉáåëÅÜäáÉ≈äáÅÜ=j~ñáJ ãìãJmçëáíáçåK==
= _áäÇ=NNKNPW=i~åÇ=ãáí=ä®åÖëíÉã=k~ãÉå==== pÉÜÉå= ïáê= ìåë= ÇáÉ= ÉêëíÉ= bêÉáÖåáëéêçòÉÇìê= òìã= bêÉáÖåáë= häáÅâ= ~ìÑ= ÇÉå= çÄÉêÉå= _ìííçå=ìåÇ=áÜê=bêÖÉÄåáë=~åW= procedure TForm1.Button1Click(Sender: TObject); var maxland
: ShortString;
lepos, maxpos, i: Byte; begin lepos:=Listbox1.Items.Count-1; maxland:=Listbox1.Items[0];
//Erste Zeile wird Kandidat
maxpos:=0;
//Position der ersten Zeile
for i:=1 to lepos do if Length(Listbox1.Items[i]) > Length(maxland) then begin maxland:=Listbox1.Items[i]; //Aktualisierung des Kandidaten maxpos:=i
//Aktualisierung der Position
end; Listbox1.ItemIndex:=maxpos
//Anzeige
end;
báåÉ= ^âíì~äáëáÉêìåÖI= ÇK= ÜK= ÉáåÉ= kÉìÄÉäÉÖìåÖ= ÇÉê= ÄÉáÇÉå= h~åÇáÇ~íÉåJpéÉáÅÜÉêJ éä®íòÉ= maxland=ìåÇ= maxpos=ÑáåÇÉí=áã=fåÜ~äí=ÇáÉëÉê=bêÉáÖåáëéêçòÉÇìê=ÖÉå~ì=Ç~åå= ëí~ííI=ïÉåå=ÉáåÉ=ä®åÖÉêÉ=wÉáäÉ=áå=ÇÉê=iáëíÉ=ÖÉÑìåÇÉå=ïìêÇÉK===
OOS= =
NNKR== sÉêÖäÉáÅÜÉ=îçå=wÉáÅÜÉåÑçäÖÉå= aÉãÖÉÖÉåΩÄÉê= ïÉêÇÉå= ÇáÉëÉ= ÄÉáÇÉå= péÉáÅÜÉêéä®íòÉ= áå= ÇÉê= òïÉáíÉå= bêÉáÖåáëJ éêçòÉÇìê= òìã= bêÉáÖåáë= häáÅâ= ~ìÑ= ÇÉå= ìåíÉêÉå= _ìííçå= åìê= Ç~åå= ~âíì~äáëáÉêíI= ïÉåå=ÉáåÉ=wÉáäÉ=áå=ÇÉê=iáëíÉ=ÖÉÑìåÇÉå=ïáêÇI=ÇáÉ=äÉñáâçÖê~ÑáëÅÜ=Öê∏≈Éê=áëíK== ^åëÅÜ~ìäáÅÜ= ÖÉëéêçÅÜÉåW= aÉê= h~åÇáÇ~í= ïáêÇ= ~âíì~äáëáÉêíI= ïÉåå= ÉáåÉ= wÉáäÉ= ÖÉJ ÑìåÇÉå=ïáêÇI=ÇáÉ=áã=qÉäÉÑçåÄìÅÜ=ïÉáíÉê=ÜáåíÉå=ëíÉÜÉå=ïΩêÇÉW== procedure TForm1.Button2Click(Sender: TObject); var maxland
: ShortString;
lepos, maxpos, i: Byte; begin lepos:=Listbox1.Items.Count-1; maxland:=Listbox1.Items[0];
//Erste Zeile wird Kandidat
maxpos:=0;
//Position der ersten Zeile
for i:=1 to lepos do if Listbox1.Items[i] > maxland then begin maxland:=Listbox1.Items[i]; //Aktualisierung des Kandidaten maxpos:=i
//Aktualisierung der Position
end; Listbox1.ItemIndex:=maxpos
//Anzeige
end;
= _áäÇ=NNKNQW=iÉñáâçÖê~ÑáëÅÜ=äÉíòíÉë=i~åÇ= = OOT =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= ^åëíÉääÉ=ÇÉê=qÉëíòÉáäÉ=áå=ÇÉê=òïÉáíÉå=bêÉáÖåáëéêçòÉÇìê==== if Listbox1.Items[i] > maxland then
Ü®ííÉ=~ìÅÜ=ÖäÉáÅÜïÉêíáÖ== if CompareStr(Listbox1.Items[i],maxland)>0 then
ëíÉÜÉå=â∏ååÉåK== píêÉåÖÉ= mêçÖê~ããáÉêÉê= EìåÇ= mêçÖê~ããáÉêäÉÜêÉêF= ÖÉÜÉå= ~ìÅÜ= ëç= îçêI= ïÉáä= ëáÉ= ÇáÉ= wÉáÅÜÉå= +I= = âçåëÉèìÉåí= åìê= Ç~åå= ÉáåëÉíòÉåI= ïÉåå= Éë= ìã= w~ÜäÉå= ÖÉÜíK== cΩê= ÇáÉ= ^êÄÉáí= ãáí= wÉáÅÜÉåâÉííÉåJpéÉáÅÜÉêéä®íòÉå= Ç~ÖÉÖÉå= îÉêïÉåÇÉå= ëáÉ= åìê= ÇáÉ=ÄÉáÇÉå=StringJcìåâíáçåÉå=Concat=ìåÇ=CompareStrK==
11.5.3
Lottoziehung
bêëí=Éáåã~ä=ÄÉÑáåÇÉí=ëáÅÜ=åìê=Éáå=_ìííçå=~ìÑ=ÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉK=Ziehe eine Zahl im Lottospiel 6 aus 49=ëíÉÜí=Ç~ê~ìÑK==
kìå= ÖìíI= Ç~ë= áëí= åáÅÜí= ëÅÜïáÉêáÖI= ïáê= ÉêáååÉêå= ìåë= ~å= ÇÉå= ^ÄëÅÜåáíí= TKQKP= ãáí= ÇÉê=mêçòÉÇìê=Randomize=ìåÇ=ÇÉê=cìåâíáçå=RandomW== procedure TForm1.Button1Click(Sender: TObject); var zahl:Byte; begin Randomize; zahl:=1+Random(49); ShowMessage(IntToStr(zahl)) end;
açÅÜ= ïçÜáå= ãáí= ÇÉê= w~Üä\= wÉííÉä= åÉÜãÉå= ìåÇ= ~ìÑëÅÜêÉáÄÉå\= tçòì= Ü~ÄÉå= ïáê= ÇÉåå=Ç~ë=îáëìÉääÉ=bäÉãÉåí=Listbox\== mä~íòáÉêÉå= ïáê= òìë®íòäáÅÜ= ÉáåÉ= ~åÑ~åÖë= äÉÉêÉ= iáëíÉ= ~ìÑ= ÇÉê= _ÉåìíòÉêçÄÉêÑä®ÅÜÉK= jáí= ÇÉê= mêçòÉÇìê= Items.Add, dáÉ= áã= ^ÄëÅÜåáíí= NPKPKS= åçÅÜ= ÉáåÉ= oçääÉ= ëéáÉäÉå= ïáêÇI= â∏ååÉå= ïáê= Ç~åå= ìåëÉêÉ= ÖÉòçÖÉåÉå= w~ÜäÉå= å~ÅÜÉáå~åÇÉê= áå= ÇáÉ= iáëíÉ= Éáåíê~ÖÉå=ä~ëëÉåW= procedure TForm1.Button1Click(Sender: TObject); var zahl : Byte; zeile: ShortString; begin Randomize;zahl:=1+Random(49); zeile:= IntToStr(zahl); ListBox1.Items.Add(zeile) end;
OOU= =
NNKR== sÉêÖäÉáÅÜÉ=îçå=wÉáÅÜÉåÑçäÖÉå= _ÉÖÉáëíÉêåÇ=ëáÉÜí=Éë=~ÄÉê=åáÅÜí=~ìëI=ï~ë=ëáÅÜ=Ç~=áå=ÇÉê=iáëíÉ=ÉåíïáÅâÉäíW==
== _áäÇ=NNKNRW=báåÖÉíê~ÖÉåÉ=wáÉÜìåÖëÉêÖÉÄåáëëÉ== ^ääÉë=ÇìêÅÜÉáå~åÇÉê=ìåÇ=ÇáÉ=w~ÜäÉå=åáÅÜí=êÉÅÜíëÄΩåÇáÖK=jΩëëÉå=ïáê=å~ÅÜíê®ÖJ äáÅÜ=åçÅÜ=ÇáÉ=pçêíáÉêìåÖ=ÇÉê=iáëíÉ=éêçÖê~ããáÉêÉå\= kÉáåK=aÉåå=áã=lÄàÉâíáåëéÉâíçê=ÑΩê=ÇáÉ=iáëíÉ=ãáí=ÇÉã=k~ãÉå=ListBox1=ÑáåÇÉí=ëáÅÜ= ÇáÉ=báÖÉåëÅÜ~Ñí=Sorted=E_áäÇ=NNKNSFW=
== _áäÇ=NNKNSW=báÖÉåëÅÜ~Ñí=Sorted=== táêÇ= ÜáÉêI= ïáÉ= ~åÖÉòÉáÖíI= ~ìÑ= True= ìãÖÉëíÉääíI= ïáêÇ= àÉÇÉê= åÉìÉ= báåíê~Ö= áå= ÇáÉ= iáëíÉ=~å=ÇÉå=mä~íò=ÖÉÄê~ÅÜíI=ÇÉê=áÜã=äÉñáâçÖê~ÑáëÅÜ=òìëíÉÜíK== få= _áäÇ= NNKNT= ëÉÜÉå= ïáê= Éë= Ó= ìåÇ= ïáê= ïÉêÇÉå= ïáÉÇÉêìã= ÇÉìíäáÅÜ= ~ìÑ= ÇáÉ= bêJ âÉååíåáë=ÖÉëíç≈ÉåI=Ç~ëë=Éë=w~ÜäÉå=áå=iáëíÉå=åáÅÜí=ÖáÄíK== • ^ìÅÜ=ïÉåå=ÇáÉ=báåíê®ÖÉ=~ìëëÉÜÉå=ïáÉ=w~ÜäÉå=Ó=áå=táêâäáÅÜâÉáí=ëáåÇ=Éë=wÉáJ ÅÜÉåÑçäÖÉå=EqÉñíÉF=ìåÇ=ïÉêÇÉå=~ìÅÜ=ëç=ÄÉÜ~åÇÉäíK== aÉëÜ~äÄ=ÑáåÇÉí=ëáÅÜ=ÑçäÖäáÅÜ=áå=_áäÇ=NNKNR=ÇáÉ=O=å~ÅÜ=ÇÉê=NVI=ìåÇ=_áäÇ=NNKNT=ä®ëëí= ÉêâÉååÉåI=Ç~ëë=áå=àÉÇÉã=~åÇÉêÉå=c~ää=ÇáÉ=ÖäÉáÅÜÉ=páíì~íáçå=òì=ÄÉçÄ~ÅÜíÉå=áëíK== pçêÖÉå=ïáê=~ÄÉê=ãáí=ÇÉã=_ÉÑÉÜä== if Length(zeile)=1 then zeile:=' '+zeile;
Ç~ÑΩêI=Ç~ëë=ÇáÉ=ÉáåëíÉääáÖÉå=wáÉÜìåÖëÉêÖÉÄåáëëÉ=îçê=áÜêÉê=^ìÑå~ÜãÉ=áå=ÇáÉ=iáëíÉ= Éáå=iÉÉêòÉáÅÜÉå=îçê~åÖÉëíÉääí=ÄÉâçããÉå=ïáêÇ=~ìÅÜ=áã=w~ÜäÉåëáååÉ=êáÅÜíáÖ=ëçêJ íáÉêí=E_áäÇ=NNKNUFK= = OOV =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= =
= _áäÇ=NNKNTW=fããÉê=ïáÉÇÉê=ïáêÇ=äÉñáâçÖê~ÑáëÅÜ=ëçêíáÉêí=
= _áäÇ=NNKNUW=táêâìåÖ=ÇÉë=îçê~åÖÉëíÉääíÉå=iÉÉêòÉáÅÜÉåë= t~êìã=áëí=Ç~ë=ëç\=a~ë=iÉÉêòÉáÅÜÉå=Ü~í=ÇÉå=^p`ffJtÉêí= 32=EëK=^ÄëÅÜåáíí=NMKOF=Ó= ÑçäÖäáÅÜ= ïÉêÇÉå= píêáåÖëI= ÇáÉ= ãáí= ÇÉã= iÉÉêòÉáÅÜÉå= ÄÉÖáååÉåI= îçê= ~ääÉ= ~åÇÉêÉå= ÉáåëçêíáÉêíK== kìå=Ü~ÄÉå=ïáê=ÇáÉ=^ìëÖ~ÄÉ=áå=ëçêíáÉêíÉê=cçäÖÉK=dáÄí=Éë=åçÅÜ=ÉáåÉå=tìåëÅÜ\== _áäÇ=NNKNV=ÄÉ~åíïçêíÉí=ìåë=ÇáÉëÉ=cê~ÖÉW=bë=áëí=âÉáåÉëÑ~ääë=~ìëÖÉëÅÜäçëëÉåI=Ç~ëë= òïÉáJ=çÇÉê=ëçÖ~ê=ãÉÜêã~äë=ÇáÉ=ÖäÉáÅÜÉ=w~Üä=ÖÉòçÖÉå=ïáêÇ>==
== _áäÇ=NNKNVW=jÉÜêÑ~ÅÜòáÉÜìåÖ= t~ë=áëí=Ç~åå=òì=íìå\=sçê=ÇÉê=^ìÑå~ÜãÉ=áå=ÇáÉ=iáëíÉ=ãìëë=ÖÉéêΩÑí=ïÉêÇÉåI=çÄ= ÇáÉ=ëçÉÄÉå=ÖÉòçÖÉåÉ=w~Üä=ëÅÜçå=ÉåíÜ~äíÉå=áëíK== tÉåå=à~I=ïáêÇ=ÉÄÉå=åçÅÜ=Éáåã~ä=ÇÉê=wìÑ~ääëò~ÜäÉåJdÉåÉê~íçê=~åÖÉïçêÑÉåK===
OPM= =
NNKR== sÉêÖäÉáÅÜÉ=îçå=wÉáÅÜÉåÑçäÖÉå= pÉÜÉå= ïáê= ìåë= ÉáåÉ= j∏ÖäáÅÜâÉáíI= ïáÉ= ã~å= jÉÜêÑ~ÅÜòáÉÜìåÖÉå= îÉêÜáåÇÉêå= â~ååI=ëÅÜêáííïÉáëÉ=áå=ÇÉê=bêÉáÖåáëéêçòÉÇìê=~åK== bë= ïáêÇ= òìã= ÉêëíÉå= j~ä= ÇÉê= wìÑ~ääëò~ÜäÉåÖÉåÉê~íçê= ÖÉëí~êíÉíK= fëí= ÇáÉ= iáëíÉ= äÉÉêI= Äê~ìÅÜí=âÉáåÉ=mêΩÑìåÖ=ÉêÑçäÖÉåI=ÇáÉ=ÉêëíÉ=w~Üä=ïáêÇ=ëçÑçêí=å~ÅÜ=hçåîÉêíáÉêìåÖ= áå=ÇáÉ=iáëíÉ=~ìÑÖÉåçããÉåK== procedure TForm1.Button1Click(Sender: TObject); var zahl,lepos, i : Byte; zeile
: ShortString;
ist_drin
: Boolean;
begin Randomize;zahl:=1+Random(49); if ListBox1.Count=0 then begin zeile:= IntToStr(zahl); if Length(zeile)=1 then zeile:=' '+zeile; ListBox1.Items.Add(zeile) end
fåíÉêÉëë~åí=ïáêÇ=Éë=~Ä=ÇÉê=òïÉáíÉå=w~ÜäI=ÇK=ÜK=ïÉåå=ÇáÉ=iáëíÉ=åáÅÜí=ãÉÜê=äÉÉê=áëíK== aáÉ= mêΩÑìåÖI= çÄ= ÇáÉ= ëçÉÄÉå= ÖÉòçÖÉåÉ= w~Üä= ëÅÜçå= E~äë= wÉáÅÜÉåÑçäÖÉF= áå= ÇÉê= iáëíÉ=ëíÉÜíI=ä®ëëí=ëáÅÜ=åáÅÜí=~äë=ÉáåÑ~ÅÜÉê=qÉëí=ìãëÉíòÉåK== eáÉê=ÜáäÑí=ìåë=Éáå=äçÖáëÅÜÉê=péÉáÅÜÉêéä~íòI=ÇÉå=ïáê=ãáí= ist_drin=ÄÉòÉáÅÜåÉå=ïçäJ äÉå=ìåÇ=~åÑ~åÖë=ãáí=False=ÄÉäÉÖÉå=EÇáÉ=ëç=ÖÉå~ååíÉ=råëÅÜìäÇëîÉêãìíìåÖFW= else begin lepos:=ListBox1.Count-1; ist_drin:=False;
^åëÅÜäáÉ≈ÉåÇ=ïáêÇ=ÇáÉ=iáëíÉ=ÇìêÅÜëìÅÜíI=çÄ=ëáÅÜ=ÇáÉ=ëçÉÄÉå=ÖÉòçÖÉåÉ=w~Üä=Ççêí= ÑáåÇÉíK== tÉåå=à~I=ïáêÇ=ist_drin=ãáí=True=ÄÉäÉÖíK= ====
for i:=0 to lepos do if StrToInt(ListBox1.Items[i])=zahl then ist_drin:=True;
OPN =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= dáåÖ=ÇáÉ=mêΩÑìåÖ=åÉÖ~íáî=~ìëI=ÇK=ÜK=Ñ~åÇ=ëáÅÜ=ÇáÉ=w~Üä=åçÅÜ=åáÅÜí=áå=ÇÉê=iáëíÉ= ïáêÇ=ëáÉ=âçåîÉêíáÉêí=ìåÇ=~ìÑÖÉåçããÉåK=== ===
if ist_drin=False then begin zeile:= IntToStr(zahl); if Length(zeile)=1 then zeile:=' '+zeile; ListBox1.Items.Add(zeile) end end end;
t~ë=é~ëëáÉêí=~ÄÉêI=ïÉåå=ÇÉê=wìÑ~ääëò~ÜäÉåÖÉåÉê~íçê=ÉáåÉ=ëÅÜçå=ÖÉòçÖÉåÉ=w~Üä= ÖÉäáÉÑÉêí=Ü~í\== få= ìåëÉêÉê= bêÉáÖåáëéêçòÉÇìê= é~ëëáÉêí= Ç~åå= åáÅÜíëI= Ç~ë= ÜÉá≈íI= ÇÉê= kìíòÉê= ãìëë= ÉÄÉå=åçÅÜ=Éáåã~ä=âäáÅâÉåK=t®êÉ=Ç~ë=ëç=ëÅÜäáããI=ïÉåå=Ç~åå=ÉáåÉ=åÉííÉ=^ìÑÑçêJ ÇÉêìåÖ=ÉêëÅÜÉáåíW== if ist_drin=True then ShowMessage('Bitte noch einmal');
11.6
Ganze Zahlen mit Vorzeichen zulassen
^ìÅÜ= ÓOT= áëí= ÉáåÉ= Ö~åòÉ= w~ÜäK= _áëÜÉê= âçååíÉå= ïáê= åìê= Ç~ÑΩê= ëçêÖÉåI= Ç~ëë= Éáå= kìíòÉê=ÖÉòïìåÖÉå=ïáêÇI=éçëáíáîÉ=Ö~åòÉ=w~ÜäÉå=ÉáåòìÖÉÄÉåI=áåÇÉã=ïáê=ÇáÉ=łÑ~äJ ëÅÜÉå=q~ëíÉå=ïÉÖÑáåÖÉå=EëK=^ÄëÅÜåáíí=RKNKQFK== kìå=ïçääÉå=ïáê=ÇáÉ=^äíÉêå~íáîÉ=òìã=łtÉÖÑ~åÖÉå=âÉååÉå=äÉêåÉå=Ó=ÇáÉ=^âíáîáÉJ êìåÖ=ÄÉá=Éêä~ìÄíÉê=_ÉäÉÖìåÖK== ^ìÑ=ÉáåÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=ÄÉÑáåÇÉå=ëáÅÜ=åÉÄÉåÉáå~åÇÉê=Éáå=qÉñíÑÉåëíÉêI=~åJ Ñ~åÖë=äÉÉêI=ìåÇ=Éáå=_ìííçå=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ=VerarbeiteK== aÉê= _ìííçå= ïáêÇ= áã= lÄàÉâíáåëéÉâíçê= áå= ÇÉê= báÖÉåëÅÜ~Ñí= Enabled= ~ìÑ= False= ÑΩê= ÇÉå=pí~êí=îçêÉáåÖÉëíÉääíI=Éê=ÉêëÅÜÉáåí=Ç~ãáí=~åÑ~åÖë=áå~âíáî=ìåÇ=â~åå=åáÅÜí=ÄÉJ ÇáÉåí=ïÉêÇÉåK== fã=dÉÖÉåë~íò=òì=ÑêΩÜÉê=ä~ëëÉå=ïáê=ÇÉå=kìíòÉê=ÇáÉëã~ä=~ääÉëI=ï~ë=Éê=ëç=ã∏ÅÜíÉI= áå=Ç~ë=qÉñíÑÉåëíÉê=ÉáåíáééÉåK=aÉåå=ïáê=ëçêÖÉå=ÑΩê=cçäÖÉåÇÉëW== aÉê=_ìííçå=ïáêÇ=~ìíçã~íáëÅÜ=åìê=Ç~åå=~âíáîI=ïÉåå=áã=qÉñíÑÉåëíÉê=ÉáåÉ=Ö~åòÉ= w~ÜäI=ãáí=çÇÉê=çÜåÉ=sçêòÉáÅÜÉåI=âçêêÉâí=ÉáåÖÉíê~ÖÉå=ïáêÇK==== procedure TForm1.Edit1Change(Sender: TObject); var inhalt :ShortString; ist_ok : Boolean; lepos,i : Byte;
OPO= =
NNKT== nìÉêëìããÉå= begin inhalt:=Edit1.Text; lepos:=Length(inhalt);
//aus Textfenster holen
ist_ok:=True;
//Unschuldsvermutung //Prüfen des ersten Zeichens
if (Copy(inhalt,1,1)'9') then ist_ok:=False; if (Copy(inhalt,1,1)='+') or (Copy(inhalt,1,1)='-') then ist_ok:=True; //Prüfen ab Zeichen 2 for i:=2 to lepos do if (Copy(inhalt,i,1)'9') then ist_ok:=False; if ist_ok then Button1.Enabled:=True
//Konsequenz
else Button1.Enabled:=False end;
wìÉêëí= ïáêÇ= ÖÉéêΩÑíI= çÄ= Ç~ë= ÉêëíÉ= wÉáÅÜÉå= ÉáåÉ= wáÑÑÉê= áëíK= tÉåå= åáÅÜíI= ïáêÇ= ist_ok= ~ìÑ= False= ÖÉëÉíòíK= c~ääë= ~ÄÉê= ÇáÉëÉ= łkáÅÜíòáÑÑÉê= ~å= ÉêëíÉê= píÉääÉ= ëéÉòáÉää= Ç~ë=mäìëJ=çÇÉê=jáåìëòÉáÅÜÉå=áëíI=â~åå= ist_ok=ïáÉÇÉê=òìêΩÅâ=~ìÑ= True=ÖÉëÅÜ~äíÉí= ïÉêÇÉåK=^Ä=ÇÉã=òïÉáíÉå=wÉáÅÜÉå=~ääÉêÇáåÖë=ëáåÇ=åìê=åçÅÜ=wáÑÑÉêå=Éêä~ìÄíK=
=== _áäÇ=NNKOMW=d~åòÉ=w~Üä=ãáí=sçêòÉáÅÜÉå=áëí=Éêä~ìÄí=
11.7
Quersummen
11.7.1
Einfache Quersummen
få= ÉáåÉã= qÉñíÑÉåëíÉê= ÄÉÑáåÇÉí= ëáÅÜ= ÉáåÉ= wÉáÅÜÉåÑçäÖÉI= ÇáÉ= ÉåíïÉÇÉê= Ö~åò= ~ìë= wáÑÑÉêå=ÄÉëíÉÜí=çÇÉê=òïáëÅÜÉå=ÇÉå=wáÑÑÉêå=òìê=ÄÉëëÉêÉå=iÉëÄ~êâÉáí=iÉÉêòÉáÅÜÉå= çÇÉê=qêÉååëíêáÅÜÉ=Ü~íK== _Éá= häáÅâ= ~ìÑ= ÇÉå= _ìííçå= ëçää= ÇáÉ= ÉáåÑ~ÅÜÉ= nìÉêëìããÉ= ÇÉê= wáÑÑÉêå= ÉêãáííÉäí= ïÉêÇÉåK=
OPP =
NN=^êÄÉáí=ãáí=wÉáÅÜÉåÑçäÖÉå=EpíêáåÖëF= =
== _áäÇ=NNKONW=nìÉêëìããÉ=ÇÉê=wáÑÑÉêå=ÖÉëìÅÜí===== få=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ïáêÇ=Ç~ë=ëç=çêÖ~åáëáÉêíI=Ç~ëë=áå=ÉáåÉê=w®ÜäëÅÜäÉáÑÉ=wÉáJ ÅÜÉå= ÑΩê= wÉáÅÜÉå= ~å~äóëáÉêí= ïáêÇW= fëí= Éë= ÉáåÉ= wáÑÑÉêI= ïáêÇ= ÇÉê= òìÖÉÜ∏êáÖÉ= w~ÜJ äÉåïÉêí=ãáííÉäë=ÇÉê=hçåîÉêíáÉêìåÖëÑìåâíáçå=StrToInt=òìê=pìããÉ=~ÇÇáÉêíW= procedure TForm1.Button1Click(Sender: TObject); var inhalt : ShortString; lepos, i: Byte; sum
: Integer;
begin inhalt:=Edit1.Text; lepos:=Length(inhalt); sum:=0;
//Initialisierung
for i:=1 to lepos do if (Copy(inhalt,i,1)>='0') and (Copy(inhalt,i,1)='0') and (Copy(inhalt,i,1)= få=ÇÉå=_áäÇÉêå=NOKO=ìåÇ=NOKP=áëí=Éêëí=Éáåã~ä=âÉáå=råíÉêëÅÜáÉÇ=òì=ëÉÜÉåX=~ääÉ=~åJ ÖÉòÉáÖíÉå=wáÑÑÉêå=ëáåÇ=ÖΩäíáÖX=Ç~ë=ÉåíëéêáÅÜí=~ìÅÜ=ÇÉå=dÉå~ìáÖâÉáíë~ìëë~ÖÉåK=
== _áäÇ=NOKQW=^ìëÖ~ÄÉ=áå=i~ÄÉäë= táÉ=_áäÇ=NOKQ=òÉáÖíI=®åÇÉêí=ëáÅÜ=ΩÄÉêÜ~ìéí=åáÅÜíëI=ïÉåå=ÇáÉ=ÇêÉá= âçåîÉêíáÉêíÉå= fåÜ~äíÉ=áå=ÇêÉá=i~ÄÉäë=~ìëÖÉÖÉÄÉå=ïÉêÇÉåK= lÑÑÉåëáÅÜíäáÅÜ=ÉêÖÉÄÉå=ëáÅÜ=òïÉá=tΩåëÅÜÉW== • fëí=Éë=ã∏ÖäáÅÜI=ÇáÉ=~ìëÖÉëéêçÅÜÉå=ìåéçéìä®êÉ=^ìëÖ~ÄÉ=ÇÉê=péÉáÅÜÉêéä~íòÄÉJ äÉÖìåÖ=áå=ÇáÉëÉê=Ü~äÄäçÖ~êáíÜãáëÅÜÉå=cçêã=òì=ÉêëÉíòÉå=ÇìêÅÜ=ÉáåÉ=cçêãI=ÇáÉ= àÉÇÉê=äÉëÉå=â~åå\== • råÇ= â∏ååÉå= ïáê= ïÉáíÉê= îÉêÜáåÇÉêåI= Ç~ëë= ÇáÉ= łoÉÅÜåÉêÑ~åí~ëáÉå= ~åÖÉòÉáÖí= ïÉêÇÉåI=ÇK=ÜK=â∏ååÉå=ïáê=~ìÅÜ=ÇáÉ=^ìëÖ~ÄÉ=ÇÉê=píÉääÉåò~Üä=ëíÉìÉêå\==
12.3.2
Formatsteuerung in Delphi und Delphi 8/2005
k~íΩêäáÅÜI= Ç~ë= ^ìëÖ~ÄÉÑçêã~í= â~åå= ã~å= ëíÉìÉêåI= ìåÇ= Éë= áëí= ~ìÅÜ= åáÅÜí= ëÅÜïÉêK= a~ÑΩê= ãΩëëÉå= ïáê= áå= ÇÉê= StrJmêçòÉÇìê= ÇÉå= k~ãÉå= ÇÉë= w~ÜäÉåJpéÉáÅÜÉêéä~íòÉë= ÇìêÅÜ=òïÉá=^åÖ~ÄÉå=ÉêÖ®åòÉåW== • ÇìêÅÜ=ÇáÉ=dÉë~ãíò~Üä=~ääÉê=~ìëòìÖÉÄÉåÇÉå=wÉáÅÜÉå=EÉáåëÅÜäáÉ≈äáÅÜ=ÇÉë=aÉòáJ ã~ä=ÓqêÉååòÉáÅÜÉåë=mìåâí=çÇÉê=hçãã~F=ëçïáÉ== • ÇìêÅÜ=ÇáÉ=w~Üä=ÇÉê=å~ÅÜ=ÇÉã=qêÉååòÉáÅÜÉå=~ìëòìÖÉÄÉåÇÉå=wáÑÑÉêåK== x_normal
:=314.123456789123456789123456789;
x_genau
:=314.123456789123456789123456789;
x_sehr_genau:=314.123456789123456789123456789;
OQO= =
NOKP== ^ìëÖ~ÄÉ= Str(x_normal:8:4,x_normal_str);
//4 Ziffern nach Punkt,3 davor
Str(x_genau:16:12,x_genau_str);
//12 Ziffern nach Punkt,3 davor
Str(x_sehr_genau:19:15,x_sehr_genau_str); //15 Ziffern nach Punkt,3 davor Label2.Caption:=x_normal_str; Label4.Caption:=x_genau_str; Label6.Caption:=x_sehr_genau_str;
_áäÇ= NOKR= òÉáÖí= ÇáÉ= ^ìëÖ~ÄÉI= ÇáÉ= ã~å= ãáí= ÇÉå= ~äíÉå= sÉêëáçåÉå= îçå= aÉäéÜá= Äáë= ÉáåëÅÜäáÉ≈äáÅÜ=sÉêëáçå=T=ÉêÜ®äíK== _áäÇ=NOKS=Ç~ÖÉÖÉå=òÉáÖí=ÇáÉ=^ìëÖ~ÄÉI=ïáÉ=ëáÉ=îçå=aÉäéÜá=U=ãáí=ÇÉêëÉäÄÉå=bêÉáÖJ åáëéêçòÉÇìê=ÉêòÉìÖí=ïáêÇK==
== _áäÇ=NOKRW=cçêã~íÖÉëíÉìÉêíÉ=^ìëÖ~ÄÉ=ãáí=~äíÉå=aÉäéÜáJsÉêëáçåÉå=
== _áäÇ=NOKRW=cçêã~íÖÉëíÉìÉêíÉ=^ìëÖ~ÄÉ=ãáí=aÉäéÜá=U= a~= ãΩëëÉå= ïáê= ÖÉå~ì= ÜáåëÉÜÉåI= ìã= ÇÉå= ïÉëÉåíäáÅÜÉå= råíÉêëÅÜáÉÇ= ÑÉëíëíÉääÉå= òì=â∏ååÉåW== • aáÉ= ~äíÉå= aÉäéÜáJsÉêëáçåÉå= Äáë= aÉäéÜá= T= ÖÉÄÉå= Ñçêã~íáÉêíÉ= aÉòáã~äò~ÜäÉå= ãáí=ÇÉã=ÉåÖäáëÅÜÉå=aÉòáã~äéìåâí=~ìëK== OQP =
NO=péÉáÅÜÉêéä®íòÉ=ÑΩê=aÉòáã~äÄêΩÅÜÉ= • aÉäéÜá= U= Ç~ÖÉÖÉå= ÖáÄí= Ñçêã~íáÉêíÉ= aÉòáã~äò~ÜäÉå= ãáí= ÇÉã= ÇÉìíëÅÜÉå= aÉòáJ ã~äâçãã~=~ìëK== tçê~å=ã~Ö=Ç~ë=äáÉÖÉå\=aÉê=dêìåÇ=ÑáåÇÉí=ëáÅÜ=áå=ÇÉê=ìåíÉêëÅÜáÉÇäáÅÜÉå=rãëÉíJ òìåÖ=ÇÉê=StrJmêçòÉÇìêK= aáÉëÉ=ÇêÉá=mêçÖê~ããòÉáäÉå=ïÉêÇÉå=ìåíÉêëÅÜáÉÇäáÅÜ=îÉê~êÄÉáíÉíW== Str(x_normal:8:4,x_normal_str);
//4 Ziffern nach Punkt,3 davor
Str(x_genau:16:12,x_genau_str);
//12 Ziffern nach Punkt,3 davor
Str(x_sehr_genau:19:15,x_sehr_genau_str); //15 Ziffern nach Punkt,3 davor
t®ÜêÉåÇ= ÇáÉ= ~äíÉå= aÉäéÜáJsÉêëáçåÉå= âêáíáâäçë= ÇÉå= aÉòáã~äéìåâí= ÇÉê= áåíÉêåÉå= w~ÜäÉåÇ~êëíÉääìåÖ=áå=ÇÉå=w~ÜäÉåëíêáåÖ=ÜáåΩÄÉêåÉÜãÉåI=~êÄÉáíÉí=aÉäéÜá=U=ÇáÑÑÉJ êÉåòáÉêíÉêK=j~å=â~åå=ëáÅÜ=Ç~ë=ëç=îçêëíÉääÉåI=Ç~ëë=aÉäéÜá=U=îçê=ÇÉê=rãëÉíòìåÖ= ÇÉê= StrJmêçòÉÇìê= ÄÉáã= _ÉíêáÉÄëëóëíÉã= łå~ÅÜÑê~ÖíI= ïÉäÅÜÉ= i®åÇÉêÉáåëíÉääìåÖ= Ççêí=îçêäáÉÖíK== råÇ=ïÉåå=ãáí=ÉáåÉã=~ìÑ=ÇÉìíëÅÜLaÉìíëÅÜä~åÇ=ÉáåÖÉëíÉääíÉå=_ÉíêáÉÄëëóëíÉã=ÖÉJ ~êÄÉáíÉí= ïáêÇI= ïáêÇ= ÑçäÖäáÅÜI= ~äë= pÉêîáÅÉI= ÇÉê= w~ÜäÉåëíêáåÖ= ãáí= ÇÉã= ä~åÇÉëΩÄäáJ ÅÜÉå=aÉòáã~äJqêÉååòÉáÅÜÉå=îÉêëÉÜÉåK==== tÉê=Éë=~ìëéêçÄáÉêÉå=â~åå=Ó=aÉäéÜá=OMMR=ëÅÜÉáåí=ïáÉÇÉê=ÇÉå=ÉåÖäáëÅÜÉå=aÉòáJ ã~äéìåâí=òì=ÄêáåÖÉåK==
12.3.3
Punkt und Komma in der Ausgabe
t~ë= ïáê= áå= ÇÉå= i~ÄÉäë= çÇÉê= áå= ÇÉã= ShowMessageJcÉåëíÉê= ëÉÜÉåI= Ç~ë= áëí= åáÅÜí= ãÉÜê= ÇÉê= w~ÜäÉåáåÜ~äí= ÇÉë= àÉïÉáäáÖÉå= péÉáÅÜÉêéä~íòÉëI= ëçåÇÉêå= ÇáÉ= Ç~ê~ìë= ÉêJ òÉìÖíÉ= wÉáÅÜÉåÑçäÖÉK= cçäÖäáÅÜ= â∏ååÉå= ïáê= ÄÉá= _ÉÇ~êÑ= ãáí= ~ääÉå= jáííÉäå= ÇÉê= StringJ_É~êÄÉáíìåÖI=ÇáÉ=ïáê=áã=^ÄëÅÜåáíí=NNKP=âÉååÉå=ÖÉäÉêåí=Ü~ÄÉåI=~å=ÇáÉëÉå= qÉñíJfåÜ~äíÉå=ûåÇÉêìåÖÉå=îçêåÉÜãÉåK== cΩê=ÇÉìíëÅÜÉ=kìíòÉê=ÄÉÇÉìíÉí=Ç~ëI=Ç~ëë=ïáêI=ëçÑÉêå=ïáê=ãáí=ÉáåÉã=aÉäéÜá=~êÄÉáJ íÉåI= Ç~ë= ÇÉå= aÉòáã~äéìåâí= ÄêáåÖíI= ÇáÉëÉå= ëÉäÄëíîÉêëí®åÇäáÅÜ= áå= ÇÉê= ^åòÉáÖÉ= ÇìêÅÜ=Ç~ë=ÇÉìíëÅÜÉ=aÉòáã~äâçãã~=ÉêëÉíòÉå=ëçääíÉåK== pÉÜÉå=ïáê=ìåë=~åI=ïáÉ=Ç~ë=áå=ÇÉã=StringJpéÉáÅÜÉêéä~íò=x_normal_str=ÉêÑçäÖíW==== lepos:=Length(x_normal_str); pktpos:=0; for i:=1 to lepos do
//Punktposition ermitteln
if Copy(x_normal_str,i,1)='.' then pktpos:=i; Delete(x_normal_str,pktpos,1);
//Löschen des Punktes
Insert(',',x_normal_str,pktpos);
//Einfügen des Kommas
OQQ= =
NOKP== ^ìëÖ~ÄÉ= aáÉ= ÜáÉêÑΩê= ÄÉå∏íáÖíÉå= péÉáÅÜÉêéä®íòÉ= leposI= pktpos= ìåÇ= i= ãΩëëÉå= å~íΩêäáÅÜ= ~ìÅÜ=~ã=_ÉÖáåå=ÇÉë=fåÜ~äíë=ÇÉê=bêÉáÖåáëéêçòÉÇìê=îÉêÉáåÄ~êí=ïÉêÇÉåX=Éë=êÉáÅÜí= ÇÉê=qóé= ByteI=ÇÉåå=âäÉáåÉê=~äë= 0=çÇÉê=Öê∏≈Éê=~äë= 255=ïáêÇ=áÜê=fåÜ~äí=ëáÅÜÉê=åáÅÜí= ïÉêÇÉåK== pçïçÜä=áã=ÉáåÑ~ÅÜÉå=qÉëí=~äë=~ìÅÜ=áå=ÇÉê=w®ÜäëÅÜäÉáÑÉ=ïìêÇÉ=ÜáÉê=îçå=ÇÉê=^ìëJ å~ÜãÉêÉÖÉäìåÖ= dÉÄê~ìÅÜ= ÖÉã~ÅÜíW= aáÉ= ^åïÉáëìåÖëâä~ããÉêå= begin...end= ïìêÇÉå=ïÉÖÖÉä~ëëÉåK== bë= ëÉá= åçÅÜ= Éáåã~ä= Ç~ê~ìÑ= ÜáåÖÉïáÉëÉåI= Ç~ëë= ^åÑ®åÖÉê= åáÅÜíë= Ñ~äëÅÜ= ã~ÅÜÉåI= ïÉåå= ëáÉ= ÇÉê~êíáÖÉ= ^ìëå~ÜãÉêÉÖÉäå= åáÅÜí= áå= ^åëéêìÅÜ= åÉÜãÉå= ìåÇ= Ç~ÑΩê= ÉíJ ï~ë=ãÉÜê=ëÅÜêÉáÄÉåW== for i:=1 to lepos do begin if Copy(x_normal_str,i,1)='.' then begin pktpos:=i end end;
a~ÄÉá= áëí= ÜáåíÉê= ÇÉã= wìïÉáëìåÖëÄÉÑÉÜä= pktpos:=i= âÉáå= íêÉååÉåÇÉë= pÉãáâçäçå= å∏íáÖI=Éë=âçããí=âÉáå=ïÉáíÉêÉê=_ÉÑÉÜä=áã=g~JwïÉáÖ=ÇáÉëÉë=qÉëíëK== a~ë=íêÉååÉåÇÉ=pÉãáâçäçå=ãìëë=àÉíòí=ÜáåíÉê=ÇÉã=äÉíòíÉå= end=ëíÉÜÉåI=ÇÉåå=Ç~åå= ÑçäÖÉå=åçÅÜ=ïÉáíÉêÉ=_ÉÑÉÜäÉK== tÉåå=~ääÉ=ÇêÉá=w~ÜäÉåëíêáåÖë=ÉåíëéêÉÅÜÉåÇ=ÄÉÜ~åÇÉäí=ïçêÇÉå=ëáåÇI=ãìëë=~ìÅÜ= ãáí=~äíÉå=aÉäéÜáJsÉêëáçåÉå=ìåÇ=aÉäéÜá=OMMR=ÇáÉ=^ìëÖ~ÄÉ=ãáí=ÇÉã=hçãã~=ïáÉ= áå=_áäÇ=NOKS=òì=ëÉÜÉå=ëÉáåK== táêÇ= ÇÉêëÉäÄÉ= nìÉääíÉñíI= ÇÉê= ÄÉá= ~äíÉå= aÉäéÜáJsÉêëáçåÉå= ÉêÑçäÖêÉáÅÜ= ï~êI= ãáí= aÉäéÜá= U= îÉê~êÄÉáíÉíI= ëç= ÉêÖáÄí= ëáÅÜI= ïáÉ= áå= _áäÇ= NOKT= òì= ëÉÜÉå= áëíI= ÉáåÉ= âìêáçë= ~ìëëÉÜÉåÇÉ=ìåÇ=ìåÄê~ìÅÜÄ~êÉ=^ìëÖ~ÄÉK==
== _áäÇ=NOKTW=aÉäéÜáJUJ^ìëÖ~ÄÉ=ÄÉá=mìåâíJhçãã~JbêëÉíòìåÖ= OQR =
NO=péÉáÅÜÉêéä®íòÉ=ÑΩê=aÉòáã~äÄêΩÅÜÉ= táÉ=â~åå=ëáÉ=Éêâä®êí=ïÉêÇÉå\=^ìëÖ~åÖëéìåâí=áëí=ÇáÉ=ëÅÜçå=Éêï®ÜåíÉ=q~íë~ÅÜÉI= Ç~ëë=aÉäéÜá=U=ÑΩê=ÇÉìíëÅÜÉ=kìíòÉê=ÇÉå=w~ÜäÉåëíêáåÖ=~ìíçã~íáëÅÜ=ãáí=ÇÉã=aÉòáJ ã~äâçãã~=îÉêëáÉÜíK== a~ë= ÄÉÇÉìíÉíI= Ç~ëë= àÉÇÉê= sÉêëìÅÜI= ÇÉå= mìåâí= ÇìêÅÜ= Ç~ë= hçãã~= òì= ÉêëÉíòÉåI= ëÅÜÉáíÉêå=ãìëëI=ïÉáä=Éë=Ö~ê=âÉáåÉå=mìåâí=ÖáÄíK== cçäÖäáÅÜ=áëí=ÇÉê=qÉëí=áã=fååÉêå=ÇÉê=w®ÜäëÅÜäÉáÑÉ=åáÉã~äë=ÉêÑΩääíW== aÉê= péÉáÅÜÉêéä~íò= pktpos= ÄÉÜ®äí= ëÉáåÉ= ^åÑ~åÖëÄÉäÉÖìåÖ= kìääI= ìåÇ= Ç~ãáí= ïáêÇ= îçå=Delete=ìåÇ=Insert=Ç~ë=ÉêëíÉ=wÉáÅÜÉå=ÄÉÜ~åÇÉäíK== aáÉ=ÉêëíÉ=wáÑÑÉê=3=ïáêÇ=ÇÉãå~ÅÜ=Ñ~äëÅÜ=ÇìêÅÜ=Ç~ë=hçãã~=ÉêëÉíòíK=== lepos:=Length(x_normal_str); pktpos:=0; for i:=1 to lepos do
//Punktposition ermitteln
if Copy(x_normal_str,i,1)='.' then pktpos:=i; Delete(x_normal_str,pktpos,1);
//Löschen des Punktes
Insert(',',x_normal_str,pktpos);
//Einfügen des Kommas
tÉäÅÜÉê=^ìëïÉÖ=ÄáÉíÉí=ëáÅÜ=~å\=báå=ÉáåÑ~ÅÜÉê=qÉëí=ä∏ëí=Ç~ë=mêçÄäÉãW== if pktpos>0 then begin Delete(x_normal_str,pktpos,1); Insert(',',x_normal_str,pktpos) end;
aáÉëÉ=bêÉáÖåáëéêçòÉÇìê=~êÄÉáíÉí=áå=~ääÉå=aÉäéÜáJsÉêëáçåÉå=âçêêÉâíW== dáÄí=Éë=áã= w~ÜäÉåëíêáåÖ=ÉáåÉå=aÉòáã~äéìåâíI=ïáêÇ=ÇáÉëÉê=ÇìêÅÜ=Ç~ë= aÉòáã~äJ âçãã~=ÉêëÉíòíK=dáÄí=Éë=âÉáåÉåI=é~ëëáÉêí=åáÅÜíëK==== a~ë=ï~ê=ÇÉê=tÉÖ=òìã=ÇÉìíëÅÜÉå=aÉòáã~äJqêÉååòÉáÅÜÉåK== pç=~åÖÉåÉÜã=Éë=~ÄÉê=áëíI=ïÉåå=Éáå=ÇÉìíëÅÜÉê=kìíòÉê=áå=ÇÉå=^ìëÖ~ÄÉå=ÉáåÉê=_ÉJ åìíòÉêçÄÉêÑä®ÅÜÉ= Ç~ë= îÉêíê~ìíÉ= aÉòáã~äâçãã~= ëáÉÜíI= ëç= ìå~åÖÉåÉÜã= ïáêÇ= Ç~ë= ÑΩê=ÇÉå=mêçÖê~ããáÉêÉêW== aÉåå= ÇáÉëÉê= Ehçãã~JFStringI= ÇÉê= áå= ÇÉê= q~í= Ç~åå= ~ìëëáÉÜí= ïáÉ= ÉáåÉ= ÇÉìíëÅÜÉ= w~ÜäI= ä®ëëí= ëáÅÜ= ëÉáåÉêëÉáíë= ÑΩê= ïÉáíÉêÉ= w~ÜäÉåJsÉê~êÄÉáíìåÖÉå= ΩÄÉêÜ~ìéí= åáÅÜí= åìíòÉåK=a~åå=áëí=ïáÉÇÉê=ÇÉê=ÉåÖäáëÅÜÉ=aÉòáã~äéìåâí=ÖÉÑê~ÖíK== açÅÜ=Ç~îçå=Ü~åÇÉäí=ÇÉê=å®ÅÜëíÉ=^ÄëÅÜåáííK=====
OQS= =
NOKQ== bêÑ~ëëìåÖ=îçå=aÉòáã~äÄêΩÅÜÉå=
12.4
Erfassung von Dezimalbrüchen
bêåÉìí=áëí=~å=ÇÉê=wÉáíI=~å=ÇáÉ=ΩÄÉê~ìë=ïáÅÜíáÖÉ=q~íë~ÅÜÉ=òì=ÉêáååÉêåI=Ç~ëë== • fåÜ~äíÉ=îçå= qÉñíÑÉåëíÉêåI=i~ÄÉäëI=iáëíÉå=ìëïK= ~ìÅÜ=Ç~ååI=ïÉåå=ëáÉ= ~ìëëÉÜÉå= ïáÉ=w~ÜäÉåI=âÉáåÉ=îÉê~êÄÉáíÄ~êÉå=w~ÜäÉå=ëáåÇK=páÉ=ëáåÇ=ëíÉíë=åìê=qÉñíÉI=ÇK=ÜK= wÉáÅÜÉåÑçäÖÉåK== få= ^ÄëÅÜåáíí= TKNKO= äÉêåíÉå= ïáê= âÉååÉåI= ïáÉ= ïáê= ãáí= eáäÑÉ= ÇÉê= aÉäéÜáJm~ëÅ~äJ cìåâíáçå= StrToInt= ÇÉå= fåÜ~äí= ÉáåÉë= StringJpéÉáÅÜÉêéä~íòÉëI= ïÉåå= Éê= ïáÉ= ÉáåÉ= Ö~åòÉ= w~Üä= ~ìëëáÉÜíI= âçåîÉêíáÉêÉå= ìåÇ= áå= ÉáåÉå= ëÉáåÉê= dê∏≈É= ÉåíëéêÉÅÜÉåÇÉå= Ö~åòò~ÜäáÖÉå=péÉáÅÜÉêéä~íò=ÄêáåÖÉå=ä~ëëÉå=â∏ååÉåK== a~ãáí= Éë= Ç~ÄÉá= åáÅÜí= òì= ÉáåÉê= cÉÜäÉêãÉäÇìåÖ= çÇÉê= ïçã∏ÖäáÅÜ= òì= ÉáåÉã= ^ÄJ ëíìêò=ÇÉë=mêçÖê~ããë=âçããíI=ãìëëíÉå=ïáê=Ç~ÑΩê=ëçêÖÉåI=Ç~ëë=ÇáÉ=cìåâíáçå= StrToInt=Éêëí=Ç~åå=òìã=báåë~íò=âçããÉå=Ç~êÑI=ïÉåå=ÇáÉ=hçåîÉêíáÉêìåÖ=ãáí=páÅÜÉêJ ÜÉáí=ÉêÑçäÖêÉáÅÜ=ã∏ÖäáÅÜ=áëíK== a~ÑΩê=äÉêåíÉå=ïáê=áã=^ÄëÅÜåáíí=RKNKQ=Ç~ë=łtÉÖÑ~åÖÉå=Ñ~äëÅÜÉê=q~ëíÉå=âÉååÉåI= ëç=Ç~ëë=âÉáå=kìíòÉê=Éíï~ë=~åÇÉêÉë=~äë=wáÑÑÉêåÑçäÖÉå=ÉáåÖÉÄÉå=â~ååK== tÉáä= Ç~ÄÉá= ~ÄÉê= ~ìÅÜ= Ç~ë= jáåìëòÉáÅÜÉå= łïÉÖÖÉÑ~åÖÉå= ïáêÇI= ÉêÑìÜêÉå= ïáê= áã= ^ÄëÅÜåáíí=NNKSI=ïáÉ=ÇìêÅÜ=ÖÉÉáÖåÉíÉ=píêáåÖJ^å~äóëÉ=Ç~ë=^âíáîáÉêÉå=çÇÉê=aÉ~âíáJ îáÉêÉå=îçå=píÉìÉêÉäÉãÉåíÉå=ã∏ÖäáÅÜ=ïáêÇI=àÉ=å~ÅÜÇÉãI=çÄ=ÇáÉ=wáÑÑÉêåÑçäÖÉ=âçåJ îÉêíáÉêÄ~ê=çÇÉê=åáÅÜí=âçåîÉêíáÉêÄ~ê=áëíK== ^ìÅÜ=ÜáÉê=ÉêÖáÄí=ëáÅÜ=ÇáÉ=cê~ÖÉI=çÄ=aÉäéÜáJm~ëÅ~ä=ìåë=åáÅÜí=ãáí=ÉáåÉê=ÖäÉáÅÜ~êíáJ ÖÉå= cìåâíáçåI= îáÉääÉáÅÜí= ãáí= ÇÉã= k~ãÉå= StrToSingle= çÇÉê= ®ÜåäáÅÜI= ÄÉÜáäÑäáÅÜ= ëÉáå=â∏ååíÉK== tÉåå= Ç~ë= ÇÉê= c~ää= ï®êÉI= ãΩëëíÉå= ïáê= ãáí= ÉáåÉã= Öêç≈ÉåI= ëçÖ~ê= ëÉÜê= Öêç≈Éå= mêçÄäÉã=ÄÉëÅÜ®ÑíáÖÉåW=táÉ=ïΩêÇÉå=ïáê=Ç~åå=éêΩÑÉå=ìåÇ=ëáÅÜÉêå=â∏ååÉåI=Ç~ëë= í~íë®ÅÜäáÅÜ=åìê=âçåîÉêíáÉêÄ~êÉ=píêáåÖë=~å=ÇáÉëÉ=cìåâíáçå=ΩÄÉêÖÉÄÉå=ïÉêÇÉå\=jáí= sçêòÉáÅÜÉåI=çÜåÉ=sçêòÉáÅÜÉåI=ãáí=aÉòáã~äéìåâíI=çÜåÉ=aÉòáã~äéìåâíI=áå=ΩÄäáJ ÅÜÉê=cçêãI=áå=Ü~äÄäçÖ~êáíÜãáëÅÜÉê=cçêã=ìëïK=ìëÑK=Ó=ïáÉ=ëçääíÉ=ã~å=ÇáÉëÉ=sáÉäJ Ñ~äí=éêΩÑÉå=â∏ååÉå\==== hÉáåÉ=pçêÖÉ=Ó=Ç~ë=~ääÉë=åáããí=ìåë=ÇáÉ=mêçòÉÇìê=Val=îçå=aÉäéÜáJm~ëÅ~ä=~ÄK==
12.4.1
Prozedur Val
aáÉ=mêçòÉÇìê=Val=ÄÉå∏íáÖí=ÇêÉá=^åÖ~ÄÉåI=ìã=ïáêâÉå=òì=â∏ååÉåW== • wìÉêëí=ÄÉå∏íáÖí=ëáÉ=ÇÉå= k~ãÉå=ÇÉë= ShortString=çÇÉê= StringJpéÉáÅÜÉêéä~íòÉë= EÄÉá=aÉäéÜá=U=åìê=String=Éêä~ìÄíFI=áå=ÇÉã=ÇáÉ=wÉáÅÜÉåÑçäÖÉ=ëíÉÜíI=ÇáÉ=òì=ÉáåÉê= w~Üä=ÖÉã~ÅÜí=ïÉêÇÉå=ëçääK== • tÉáíÉê=Äê~ìÅÜí=ëáÉ=ÇÉå=k~ãÉå=ÇÉë=é~ëëÉåÇÉå=w~ÜäÉåëéÉáÅÜÉêéä~íòÉëI=ÇÉê=áã= bêÑçäÖëÑ~ääÉ=ãáí=ÇÉê=w~Üä=ÄÉäÉÖí=ïÉêÇÉå=ëçääK==
OQT =
NO=péÉáÅÜÉêéä®íòÉ=ÑΩê=aÉòáã~äÄêΩÅÜÉ= • aêáííÉåë= ÄÉå∏íáÖí= ëáÉ= ÇÉå= k~ãÉå= ÉáåÉë= IntegerJpéÉáÅÜÉêéä~íòÉëI= áå= ÇÉå= ÇáÉ= mêçòÉÇìê= ÇáÉ= kìää= ÄêáåÖíI= ïÉåå= ÇáÉ= hçåîÉêíáÉêìåÖ= ã∏ÖäáÅÜ= ï~êX= ~åÇÉêåÑ~ääë= ïáêÇ= ÉáåÉ= îçå= kìää= îÉêëÅÜáÉÇÉåÉ= w~Üä= áå= ÇáÉëÉå= fåÑçêã~íáçåëJpéÉáÅÜÉêéä~íò= ÖÉÄê~ÅÜíK==
== _áäÇ=NOKUW=hçåîÉêíáÉêÄ~êÉ=fåÜ~äíÉ=ÉáåÉë=qÉñíÑÉåëíÉêë=
== _áäÇ=NOKVW=káÅÜíJâçåîÉêíáÉêÄ~êÉ=fåÜ~äíÉ= aáÉ=ÑçäÖÉåÇÉ=bêÉáÖåáëéêçòÉÇìê=òÉáÖí=ÇÉå=kìíòÉå=ÇáÉëÉë= fåÑçêã~íáçåëJpéÉáÅÜÉêJ éä~íòÉëI=ÇÉê=~ìÅÜ=ÇÉå=é~ëëÉåÇÉå=k~ãÉå=ÄÉâçããÉå=ëçääíÉW== procedure TForm1.Button1Click(Sender: TObject); var x_str: String; x: Double; x_info: Integer;
OQU= =
NOKQ== bêÑ~ëëìåÖ=îçå=aÉòáã~äÄêΩÅÜÉå= begin x_str:=Edit1.Text; Val(x_str,x,x_info);
//Auslesen des Textfeldes //Konvertierungsversuch
if x_info=0 then ShowMessage('Inhalt ist konvertierbar') else ShowMessage('Inhalt ist nicht konvertierbar') end;
_áäÇ=NOKU=òÉáÖí=ÉáåÉ=oÉáÜÉ=îçå=báåíê®ÖÉå=áå=ÇÉã=qÉñíÑÉåëíÉêI=ÄÉá=ÇÉåÉå=ÇáÉ= ValJ mêçòÉÇìê=ÇáÉ=hçåîÉêíáÉêÄ~êâÉáí=ÑÉëíëíÉääíK== _áäÇ= NOKV= ÇÉãçåëíêáÉêí= Ç~ÖÉÖÉå= báåíê®ÖÉI= ÇáÉ= ä~ìí= ^ìëâìåÑí= îçå= Val= åáÅÜí= áå= ÉáåÉ= w~Üä= ìãÖÉï~åÇÉäí= ïÉêÇÉå= â∏ååÉå= ìåÇLçÇÉê= åáÅÜí= áå= ÇÉå= péÉáÅÜÉêéä~íò= ÇÉë=~åÖÉÖÉÄÉåÉå=qóéë=é~ëëÉåK===
12.4.2
Aktivierung und Deaktivierung von Steuerelementen
aÉê= aÉäéÜáJm~ëÅ~äJmêçòÉÇìê= Val= ëÉá= a~åâ= Ó= ãáí= áÜêÉê= eáäÑÉ= áëí= Éë= éêçÄäÉãäçë= ã∏ÖäáÅÜI= ÄÉá= àÉÇÉã= îçã= kìíòÉê= ~ìëÖÉä∏ëíÉå= bêÉáÖåáë= ûåÇÉêìåÖ= áã= qÉñíÑÉåëíÉê= ÇáÉ= hçåîÉêíáÉêÄ~êâÉáí= ÇÉë= ~âíìÉää= îçêÜ~åÇÉåÉå= fåÜ~äíë= éêΩÑÉå= òì= ä~ëëÉå= ìåÇ= ÉåíëéêÉÅÜÉåÇ=píÉìÉêÉäÉãÉåíÉ=~âíáîáÉêÉå=çÇÉê=ÇÉ~âíáîáÉêÉå=òì=â∏ååÉåK== • jáííÉäë=Val=â∏ååÉå=píÉìÉêÉäÉãÉåíÉ=~âíáîáÉêí=ïÉêÇÉåI=ïÉåå=ÇáÉ=hçåîÉêíáÉêìåÖ= ÇÉë=píêáåÖë=òìê=w~Üä=ã∏ÖäáÅÜ=áëíK== • jáííÉäë= Val= â∏ååÉå= píÉìÉêÉäÉãÉåíÉ= ÇÉ~âíáîáÉêí= ïÉêÇÉåI= ïÉåå= ÇáÉ= hçåîÉêíáÉJ êìåÖ=ÇÉë=píêáåÖë=òìê=w~Üä=åáÅÜí=ã∏ÖäáÅÜ=áëíK== _Éíê~ÅÜíÉå=ïáê=Ç~òì=Éáå=qÉñíÑÉåëíÉê=ìåÇ=ÉáåÉå=_ìííçåX=ÇÉê=_ìííçå=áëí=òì=_ÉÖáåå= ÇÉê= i~ìÑòÉáí= áå~âíáî= EbáÖÉåëÅÜ~Ñí= Enabled= ~ìÑ= False= îçêÉáåÖÉëíÉääíFK= _áäÇ= NOKNM= òÉáÖíI= ïáÉ= ÇÉê= _ìííçå= ãáí= eáäÑÉ= ÇÉê= ÑçäÖÉåÇÉå= bêÉáÖåáëéêçòÉÇìê= ÄÉá= kìíòÉêÉáåJ ïáêâìåÖ=áã=qÉñíÑÉåëíÉê=~âíáî=çÇÉê=áå~âíáî=ïáêÇK==
== _áäÇ=NOKNMW=wìJ=ìåÇ=^ÄëÅÜ~äíÉå=ÇÉë=_ìííçåë== OQV =
NO=péÉáÅÜÉêéä®íòÉ=ÑΩê=aÉòáã~äÄêΩÅÜÉ= procedure TForm1.Edit1Change(Sender: TObject); var x_str : String; x: Double; x_info: Integer; begin x_str:=Edit1.Text; Val(x_str,x,x_info); if x_info=0 then Button1.Enabled:=True else Button1.Enabled:=False end;
12.4.3
Nutzerunterstützung I: Behandlung falscher Tasten
pÅÜ∏å=ìåÇ=Öìí=Ó=ïáê=â∏ååÉå=ìåëI=ïÉåå=ïáê=ÇáÉ=mêçòÉÇìê= Val=ÉáåëÉíòÉåI=ëáÅÜÉê= ëÉáåI=Ç~ëë=Éë=ÖÉïáëë=âÉáåÉå=mêçÖê~ãã~Äëíìêò=ÖÉÄÉå=ïáêÇ=ìåÇ=Ç~ëë=~ìÅÜ=âÉáåÉ= ãóëíáëÅÜÉ= cÉÜäÉêãÉäÇìåÖ= ÇÉå= kìíòÉê= îÉêìåëáÅÜÉêå= ïáêÇI= ëçääíÉ= ëÉáå= báåíê~Ö= áå= ÉáåÉã=qÉñíÑÉåëíÉê=åáÅÜí=òì=ÉáåÉê=w~Üä=ÖÉã~ÅÜí=ïÉêÇÉå=â∏ååÉåK== pçääíÉå=ïáê=ÇÉå=kìíòÉê=~ääÉáå=ä~ëëÉåI=áÜã=äÉÇáÖäáÅÜ=ïáÉ=áå=_áäÇ=NOKNN=ÉáåÉå=åÉíJ íÉå=_ÉÇáÉåìåÖëÜáåïÉáë=åÉÄÉå=Ç~ë=báåÖ~ÄÉÑÉåëíÉê=ëÅÜêÉáÄÉå\==
== _áäÇ=NOKNNW=eáåïÉáë=~å=ÇÉå=kìíòÉê= a~ëI=ëç=ë~ÖÉå=~äíÖÉÇáÉåíÉ=mêçÖê~ããáÉêÉêI=áëí=î∏ääáÖ=çÜåÉ=tÉêíK=tÉê=~ìÑ=ÇáÉ=hçåJ òÉåíê~íáçå=ÇÉë=kìíòÉêë=îÉêíê~ìíI=ÇÉê=Ü~í=~ìÑ=p~åÇ=ÖÉÄ~ìíK== kÉáåI=Ç~=ëçääíÉå=ïáê=ÇçÅÜ=ãÉÜê=íìåK== _ÉáëéáÉäïÉáëÉ= ~ääÉ= q~ëíÉå= łïÉÖÑ~åÖÉåI= ÇáÉ= ÖÉïáëë= åáÅÜíë= ãáí= ÉáåÉê= w~ÜäÉåÉáåJ Ö~ÄÉ=òì=íìå=Ü~ÄÉå=â∏ååÉåK=kìê=ÇáÉ=wáÑÑÉêå=ìåÇ=ÇÉå=mìåâí=ìåÇ=Ç~ë=jáåìëòÉáJ ÅÜÉå=Éêä~ìÄÉåK== lÇÉê=Ó=åçÅÜ=ÄÉëëÉêW=kìê=ÇáÉ=wáÑÑÉêå=ìåÇ=Ç~ë=hçãã~=ìåÇ=Ç~ë=jáåìëòÉáÅÜÉå=ÉêJ ä~ìÄÉåI=ìåÇ=~ìíçã~íáëÅÜ=~ìë=ÇÉã=hçãã~=ÇÉå=mìåâí=ã~ÅÜÉåK=dÉÜí=Ç~ë\== k~íΩêäáÅÜI= ëÉÜÉå= ïáê= ìåë= Ç~òì= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= EkáÅÜíJpí~åÇ~êÇJF= bêJ ÉáÖåáë=OnKeyPress=Ełq~ëíÉ=ÖÉÇêΩÅâíF=~å=ÇÉã=qÉñíÑÉåëíÉê=Edit1=~åW== procedure TForm1.Edit1KeyPress(Sender: TObject; var Key: Char); begin if (Key'9') then if Key=',' then Key:='.' else if Key'-' then Key:=Chr(27) end;
ORM= =
NOKQ== bêÑ~ëëìåÖ=îçå=aÉòáã~äÄêΩÅÜÉå= táêÇ=âÉáåÉ=wáÑÑÉêåí~ëíÉ=ÖÉÇêΩÅâíI=ïáêÇ=áå=ÇÉê=bêÉáÖåáëéêçòÉÇìê=~åëÅÜäáÉ≈ÉåÇ=ÖÉJ éêΩÑíI=çÄ=Éë=Ç~ë=hçãã~= ï~êK=t~ê=Éë=Ç~ë= hçãã~I=ïáêÇ=Ç~ê~ìë=ÇÉê=mìåâí=ÖÉJ ã~ÅÜíK== ^åÇÉêåÑ~ääëI=ïìêÇÉ=âÉáåÉ=wáÑÑÉê=ìåÇ=âÉáå=hçãã~=ÖÉíáééíI=ïáêÇ=ïÉáíÉê=ÖÉéêΩÑíI= çÄ=ÇÉê=kìíòÉê=Éáå=jáåìëòÉáÅÜÉå=ÉáåÖ~ÄK== qê~Ñ= ~ìÅÜ= Ç~ë= åáÅÜí= òìI= ïáêÇ= ÇÉê= tÉêí= ÇÉê= ÖÉÇêΩÅâíÉå= q~ëíÉ= ÉêëÉíòí= ÇìêÅÜ= ÇáÉ= q~ëíÉ=ãáí=ÇÉã=^p`ffJtÉêí=27I=Ç~ë=áëí=ÇáÉ=ìåëÅÜ®ÇäáÅÜÉ= ESC Jq~ëíÉK= wìê=§ÄìåÖ=ëÉá=~ääÉå=^åÑ®åÖÉêå=ÉãéÑçÜäÉåI=ÇáÉëÉ=îÉêâΩêòí=áåÉáå~åÇÉê=ÖÉëÅÜ~ÅÜJ íÉäíÉå=qÉëíë=~ìëÑΩÜêäáÅÜ=ãáí=ÇÉå=^åïÉáëìåÖëâä~ããÉêå= begin...end=~ìÑòìëÅÜêÉáJ ÄÉåK=a~ë=ëÅÜ®êÑí=ÇÉå=_äáÅâ=ÑΩê=ÇáÉ=áååÉïçÜåÉåÇÉ=içÖáâK= tÉê=~ÄÉê=Öä~ìÄíI=Ç~ëë=ëáÅÜ=Ç~å~ÅÜ=ÇáÉ=sÉêïÉåÇìåÖ=ÇÉê=mêçòÉÇìê= Val=ÉêΩÄêáÖíI= ïÉåå= ÇáÉ= Ñ~äëÅÜÉå= q~ëíÉå= ïÉÖÖÉÑ~åÖÉå= ìåÇ= hçãã~ë= òì= mìåâíÉå= ÖÉã~ÅÜí= ïÉêÇÉåI=ÇÉê=ã∏ÖÉ=ëáÅÜ=_áäÇ=NOKNO=~åëÉÜÉåW== ^ìÅÜ=ãáí=ÇáÉëÉå=Éêä~ìÄíÉå=q~ëíÉå=â~åå=îáÉä=råëáåå=ÉáåÖÉíê~ÖÉå=ïÉêÇÉåK==
== _áäÇ=NOKNOW=bêä~ìÄíÉ=q~ëíÉåI=~ÄÉê=åáÅÜí=âçåîÉêíáÉêÄ~êÉê=báåíê~Ö== eáÉê=áëí=ÉÄÉå=ÇáÉ=páíì~íáçå=~åÇÉêë=ìåÇ=îáÉä=âçãéäáòáÉêíÉê=~äë=ÄÉá=éçëáíáîÉå=Ö~åJ òÉå= w~ÜäÉåX= Ççêí= Äê~ìÅÜíÉå= ïáê= åìê= ÇáÉ= wáÑÑÉêå= òìä~ëëÉåI= ìåÇ= ëÅÜçå= ï~ê= ÇÉê= báåíê~Ö=âçåîÉêíáÉêÄ~êK==
12.4.4
Nutzerunterstützung II: Information bei Fokusverlust
hÉÜêÉå=ïáê=òìêΩÅâ=òì=ÇÉå=j∏ÖäáÅÜâÉáíÉåI=ÇáÉ=ìåë=ÇáÉ=mêçòÉÇìê=Val=ãáí=áÜêÉê=fåJ Ñçêã~íáçå=ΩÄÉê=ÉêÑçäÖêÉáÅÜÉ=ÄòïK=ÉêÑçäÖäçëÉ=hçåîÉêíáÉêìåÖ=äáÉÑÉêíK== a~åå=â∏ååÉå=ïáêI=ïáÉ=áå=^ÄëÅÜåáíí=NOKQKO=ÄÉëÅÜêáÉÄÉåI=píÉìÉêÉäÉãÉåíÉ=ÉåíëéêÉJ ÅÜÉåÇ=~âíáîáÉêÉå=çÇÉê=ÇÉ~âíáîáÉêÉåK= bë=ÖáÄí=~ÄÉê=páíì~íáçåÉåI=áå=ÇÉåÉå=ÉáåÉ=~åÇÉêÉ=^êí=ÇÉê=oÉ~âíáçå=~ìÑ=Ñ~äëÅÜÉ=kìíJ òÉêÉáåÖ~ÄÉå=ÉêÑçäÖÉå=ëçääíÉK== aÉåâÉå= ïáê= ~å= ÉáåÉ= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= ãáí= ÇêÉá= báåÖ~ÄÉÑÉåëíÉêåI= ïáÉ= ëáÉ= áå= _áäÇ=NOKNP=òì=ëÉÜÉå=áëíW== aÉê=kìíòÉê=ëçää=ÇêÉá=EaÉòáã~äJF=w~ÜäÉå=ÉáåÖÉÄÉåI=ÇáÉ=ÄÉá=häáÅâ=~ìÑ=ÇÉå=_ìííçå= ïÉáíÉê=îÉê~êÄÉáíÉí=ïÉêÇÉåK== ^ìÅÜ= ïÉåå= ïáê= òì= ÇÉã= bêÉáÖåáë= q~ëíÉåÇêìÅâ= áå= àÉÇÉã= qÉñíÑÉåëíÉê= ÉáåÉ= bêÉáÖJ åáëéêçòÉÇìê=ëÅÜêÉáÄÉåI=ÇáÉ=åìê=wáÑÑÉêå=ìåÇ=jáåìëòÉáÅÜÉå=òìä®ëëí=ìåÇ=hçãã~= òì=mìåâí=ã~ÅÜíI=ëç=áëí=ÇçÅÜ=Ó=ëáÉÜÉ=_áäÇ=NOKNO=Ó=Ç~ãáí=âÉáåÉëïÉÖë=Ö~ê~åíáÉêíI= Ç~ëë=ëáÅÜ=áããÉê=âçåîÉêíáÉêÄ~êÉ=báåíê®ÖÉ=áå=~ääÉå=ÇêÉá=qÉñíÑÉåëíÉêå=ÄÉÑáåÇÉåK== ORN =
NO=péÉáÅÜÉêéä®íòÉ=ÑΩê=aÉòáã~äÄêΩÅÜÉ= =
== _áäÇ=NOKNPW=aêÉá=qÉñíÑÉåëíÉê=ÑΩê=åìãÉêáëÅÜÉ=kìíòÉêÉáåÖ~ÄÉå= táê= â∏ååíÉå= òìë®íòäáÅÜ= ÇêÉá= bêÉáÖåáëéêçòÉÇìêÉå= òì= ÇÉå= pí~åÇ~êÇJbêÉáÖåáëëÉå= ûåÇÉêìåÖ=áå=àÉÇÉã=qÉñíÑÉåëíÉê=ëÅÜêÉáÄÉåK= aÉê=fåÜ~äí=àÉÇÉê=bêÉáÖåáëéêçòÉÇìê=ÄÉëíÉÜí=Ç~åå=ëíÉíë=~ìë=ÇÉê=§ÄÉêéêΩÑìåÖ=~ääÉê= ÇêÉá= cÉåëíÉêáåÜ~äíÉX= åìê= ïÉåå= ëáÅÜ= ~ääÉ= fåÜ~äíÉ= âçåîÉêíáÉêÉå= ä~ëëÉåI= ïáêÇ= ÇÉê= _ìííçå=òìÖÉëÅÜ~äíÉíW= procedure TForm1.Edit1Change(Sender: TObject); var
x1_str:String; x1:Double; x1_info:Integer; x2_str:String; x2:Double; x2_info:Integer; x3_str:String; x3:Double; x3_info:Integer;
begin x1_str:=Edit1.Text; x2_str:=Edit2.Text; x3_str:=Edit3.Text; Val(x1_str,x1,x1_info); Val(x2_str,x2,x2_info); Val(x3_str,x3,x3_info); if (x1_info=0) and (x2_info=0) and (x3_info=0) then Button1.Enabled:=True else Button1.Enabled:=False end;
aáÉ=ÄÉáÇÉå=~åÇÉêÉå=bêÉáÖåáëéêçòÉÇìêÉå=Ü~ÄÉå=Éñ~âí=ÇÉåëÉäÄÉå=fåÜ~äíW= procedure TForm1.Edit2Change(Sender: TObject);
K.. identischer Inhalt ... end;
ORO= =
NOKQ== bêÑ~ëëìåÖ=îçå=aÉòáã~äÄêΩÅÜÉå= procedure TForm1.Edit3Change(Sender: TObject); ... identischer Inhalt ... end;
pç=â∏ååÉå=ïáê=Éë=ã~ÅÜÉåK=^ÄÉê=ï~ë=ÄáÉíÉí=ëáÅÜ=ÇÉã=kìíòÉê=Ç~ê\== bê= ãÉêâí= äÉÇáÖäáÅÜI= Ç~ëë= ëáÅÜ= ÇÉê= _ìííçå= òìëÅÜ~äíÉí= çÇÉê= ~ìÅÜ= åáÅÜí= òìëÅÜ~äíÉíI= ïÉåå=Éê=ãáí=~ääÉå=báåíê~ÖìåÖÉå=ÑÉêíáÖ=áëíK== pçä~åÖÉ=ÉáåÉë=ÇÉê=qÉñíÑÉåëíÉê=åçÅÜ=äÉÉê=áëíI=ÄäÉáÄí=ÇÉê=_ìííçå=ÉÄÉåÑ~ääë=áå~âíáî=Ó= äÉÉêÉ= píêáåÖë= ïÉêÇÉå= îçå= ÇÉê= mêçòÉÇìê= Val= ~äë= åáÅÜí= âçåîÉêíáÉêÑ®ÜáÖ= ÖÉãÉäÇÉíI= ìåÇ=Ç~ë=áëí=~ìÅÜ=Öìí=ëçK=== táêÇ=ÇÉê=_ìííçå=~ÄÉê=åáÅÜí=~âíáîI=ÄÉÖáååí=Ç~ë=o®íëÉäê~íÉå=ÇÉë=kìíòÉêëW=łfå=ïÉäJ ÅÜÉã= qÉñíÑÉåëíÉê= Ü~ÄÉ= áÅÜ= ãáÅÜ= ÇÉåå= îÉêíáééíI= ïçê~å= äáÉÖí= Éë= ïçÜäI= Ç~ëë= áÅÜ= åáÅÜí=ïÉáíÉêã~ÅÜÉå=â~åå\= aÉëÜ~äÄ= ïçääÉå= ïáê= ÉáåÉ= ~åÇÉêÉ= j∏ÖäáÅÜâÉáí= âÉååÉå= äÉêåÉåI= ÇáÉ= ìåãáííÉäÄ~ê= ïáêâë~ã=ïáêÇI=ïÉåå=ÇÉê=kìíòÉê=Ç~ë=qÉñíÑÉåëíÉê=îÉêä~ëëÉå=ïáääI=ìã=Éáå=~åÇÉêÉë= píÉìÉêÉäÉãÉåí=òì=ÄÉÇáÉåÉåK== aáÉëÉë= bêÉáÖåáë= kìíòÉê= îÉêä®ëëí= Ç~ë= qÉñíÑÉåëíÉê= áëí= ÖäÉáÅÜÄÉÇÉìíÉåÇ= Ç~ãáíI= Ç~ëë= ÇÉê=kìíòÉê=îÉêëìÅÜíI=ÇÉå=cçâìë=~ìÑ=Éáå=~åÇÉêÉë=píÉìÉêÉäÉãÉåí=òì=äÉåâÉåK== cçäÖäáÅÜ=íêáíí=Ç~åå=ÄÉá=ÇÉã=îÉêä~ëëÉåÉå=píÉìÉêÉäÉãÉåí=Ç~ë=EkáÅÜíJpí~åÇ~êÇJF=bêJ ÉáÖåáë=cçâìëîÉêäìëí=ÉáåK== få=^ÄëÅÜåáíí=OKPKP=Ü~ÄÉå=ïáê=ìåë=ëÅÜçå=Éáåã~ä=ãáí=ÇÉã=qÜÉã~=cçâìë=ÄÉëÅÜ®ÑJ íáÖíI=Ççêí=~ääÉêÇáåÖë=ÄÉÜ~åÇÉäíÉå=ïáê=Ü~ìéíë®ÅÜäáÅÜ=Ç~ë=bêÉáÖåáë=cçâìëÉêÜ~äíK= cΩê= ÇáÉëÉë= EkáÅÜíJpí~åÇ~êÇJF= bêÉáÖåáë= Ü~ííÉå= ïáê= ìåë= ãáííÉäë= OnEnter= ÇÉå= o~ÜJ ãÉå=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ÄÉëÅÜ~ÑÑÉå=â∏ååÉåK=== _ÉëÅÜ~ÑÑÉå= ïáê= ÇÉå= o~ÜãÉå= ÑΩê= Ç~ë= káÅÜíJpí~åÇ~êÇJbêÉáÖåáë= cçâìëîÉêäìëí= ~ìë= ÇÉê=oÉÖáëíÉêâ~êíÉ=bobfdkfppb=ÇÉë=lÄàÉâíáåëéÉâíçêë=ÇìêÅÜ=açééÉäâäáÅâ=áå=Ç~ë=äÉÉJ êÉ=ïÉá≈É=cÉäÇI=å~ÅÜÇÉã=ïáê=OnExit=E_áäÇ=NOKNQF=~ìëÖÉï®Üäí=Ü~ÄÉåK=
== _áäÇ=NOKNQW=bêÉáÖåáë=łcçâìëîÉêäìëí= ORP =
NO=péÉáÅÜÉêéä®íòÉ=ÑΩê=aÉòáã~äÄêΩÅÜÉ= pÅÜçå=ÉêÜ~äíÉå=ïáê=ÇÉå=o~ÜãÉå=ÑΩê=ÇáÉ=òìÖÉÜ∏êáÖÉ=bêÉáÖåáëéêçòÉÇìêW= procedure TForm1.Edit1Exit(Sender: TObject); begin .............. end;
råÇ=ÇÉê=fåÜ~äí\=tÉåå=ÇÉê=kìíòÉê=Ç~ë=qÉñíÑÉåëíÉê= Edit1=îÉêä~ëëÉå=ïáääI=ïáêÇ=ÇáÉ= hçåîÉêíáÉêÄ~êâÉáí=ÇÉë=fåÜ~äíë=ÖÉéêΩÑíK=fëí=ëáÉ=åáÅÜí=ÖÉÖÉÄÉåI=ÄÉâçããí=ÇÉê=kìíJ òÉê=ÉáåÉ=ÖÉòáÉäíÉ=fåÑçêã~íáçåW=== procedure TForm1.Edit1Exit(Sender: TObject); var x1_str:String; x1:Double; x1_info:Integer; begin x1_str:=Edit1.Text; Val(x1_str,x1,x1_info); if (x1_info0) then ShowMessage('Korrigieren Sie bitte die oberste Zahl') end;
få=ÖäÉáÅÜÉê=tÉáëÉ=ëíÉääÉå=ïáê=ÇáÉ=ÄÉáÇÉå=bêÉáÖåáëéêçòÉÇìêÉå=òì=ÇÉå=bêÉáÖåáëëÉå= cçâìëîÉêäìëí=ÄÉá=Edit2=ìåÇ=cçâìëîÉêäìëí=ÄÉá=Edit3=ÜÉêK== pç=ïáêÇ=ÇÉê=kìíòÉê=ìåãáííÉäÄ~ê=å~ÅÜ=ÇÉã=båÇÉ=ÉáåÉê=báåíáééJ^âíáçå=áåÑçêãáÉêíI= ïç=Éê=Éíï~ë=Ñ~äëÅÜ=ÖÉã~ÅÜí=Ü~í=E_áäÇ=NOKNRFK=
== _áäÇ=NOKNRW=dÉòáÉäíÉ=kìíòÉêáåÑç= ^ÄÉê=Ó=ÇÉê=kìíòÉêI=Ç~ë=ìåÇìêÅÜëáÅÜíáÖÉ=tÉëÉå>=t~ë=áëíI=ïÉåå=Éê=ëáÅÜ=åáÅÜí=~å= ÇáÉ=fåÑçêã~íáçå=Ü®äíI=ãìåíÉê=áå=~åÇÉêÉ=qÉñíÑÉåëíÉê=ïÉáíÉê=ÉáåÖáÄí\== tÉåå= Éê= ÇáÉ= cÉÜäÉêáåÑçêã~íáçå= â~äíÄäΩíáÖ= áÖåçêáÉêí= çÇÉê= Ö~ê= òì= äÉëÉå= îÉêÖáëëí\= a~åå=ÄäÉáÄí=ÇÉê=_ìííçå=áå~âíáîI=ìåÇ=Ç~ë=o®íëÉäê~íÉå=ÄÉÖáååí=îçå=kÉìÉãK== ORQ= =
NOKQ== bêÑ~ëëìåÖ=îçå=aÉòáã~äÄêΩÅÜÉå= §ÄêáÖÉåë=ãìëë=Éë=åáÅÜí=ìåÄÉÇáåÖí=Ä∏ë~êíáÖ=ëÉáåI=Ç~ëë=Éáå= kìíòÉê=ëçäÅÜ=Éáå= fåJ Ñçêã~íáçåëÑÉåëíÉê=ΩÄÉêäáÉëíK=j~å=ÇÉåâÉ=åìê=~å=àÉã~åÇI=ÇÉê=îáÉäÉ=w~ÜäÉå=ÉáåÖÉJ ÄÉå=ãìëë=ìåÇ=ÇáÉë=íìíI=çÜåÉ=ÉáÖÉåíäáÅÜ=~ìÑ=ÇÉå=_áäÇëÅÜáêã=Ç~ÄÉá=òì=ëÉÜÉåKKK= táÉ= â∏ååÉå= ïáê= ÇÉìíäáÅÜÉê= ~ìÑ= ÉáåÉå= cÉÜäÉê= ÜáåïÉáëÉå\= aÉå= kìíòÉê= îáÉääÉáÅÜí= ëçÖ~ê=òïáåÖÉåI=Éêëí=Éáåã~ä=ÇÉå=ÖÉê~ÇÉ=ÄÉÖ~åÖÉåÉå=cÉÜäÉê=òì=ÄÉëÉáíáÖÉåI=ÉÜÉ=Éê= ëáÅÜ=~åÇÉêÉå=aáåÖÉå=òìïÉåÇÉå=â~åå\== a~= ÜáäÑí= ìåë= òìÉêëí= ÇáÉ= aÉäéÜáJm~ëÅ~äJmêçòÉÇìê= BeepX= ëáÉ= ÉêòÉìÖí= ÉáåÉå= âäÉáåÉå= t~êåíçåK=a~ãáí=ÇÉê=kìíòÉê=~ìÑï~ÅÜíK=råÇ=ïÉáíÉê=ÜáäÑí=ìåë=ÇáÉ=mêçòÉÇìê= setFocusI= ÇáÉ= áå= ÇÉê= mìåâíäáëíÉ= ÇÉë= îáëìÉääÉå= lÄàÉâíë= Edit1= ÖÉÑìåÇÉå= ïÉêÇÉå= â~åå= E_áäÇ=NOKNSFK==
== _áäÇ=NOKNSW=mêçòÉÇìê=setFocus= táê=ÖêÉáÑÉå=Ç~ãáí=Éáå=ïÉåáÖ=îçêX=òì=ÇÉå=cìåâíáçåÉå=ìåÇ=mêçòÉÇìêÉå=îáëìÉääÉê= lÄàÉâíÉ=ïáêÇ=~ìëÑΩÜêäáÅÜ=ëé®íÉêI=áã=^ÄëÅÜåáíí=NPKPKQI=píÉääìåÖ=ÖÉåçããÉåK== a~ãáí=ÉêÜ®äí=ÇÉê=ÉåíëÅÜÉáÇÉåÇÉ=qÉáä=ÇÉê=bêÉáÖåáëéêçòÉÇìê=òìã=cçâìëîÉêäìëí=ÇÉë= qÉñíÑÉåëíÉêë=Edit1=ÇÉå=ÑçäÖÉåÇÉå=fåÜ~äíW= if (x1_info0) then begin Beep; //Warnton ShowMessage('Korrigieren Sie bitte die oberste Zahl'); Edit1.setFocus //Fokus wird auf Textfenster zurückgesetzt end
kìå=â~åå=ÇÉê=kìíòÉê=Ö~åò=ãΩÇÉ=çÇÉê=Ö~åò=áÖåçê~åí=ëÉáå=Ó=Éê=ÉêäÉÄí=ÇìêÅÜ=ÇÉå= _ÉÑÉÜä= Edit1.setFocus=ãáí=ÇÉã=cçâìëJoΩÅâëÉíòÉåI=ïáÉ=ÇÉê=cçâìë=~ìÑ=Ç~ë=qÉñíJ ÑÉåëíÉê= òìêΩÅâëéêáåÖíI= Ç~ë= Éê= ëçÉÄÉå= îÉêä~ëëÉå= ïçääíÉI= ìåÇ= ïáÉ= ÇÉëëÉå= fåÜ~äí= ëçÖ~ê=~ìíçã~íáëÅÜ=ëÉäÉâíáÉêí=ïáêÇK== pçI= Ç~ëë= Éê= ëçÑçêí= ÇÉå= ~äíÉåI= Ñ~äëÅÜÉå= báåíê~Ö= ΩÄÉêëÅÜêÉáÄÉå= â~ååK= _ÉëëÉê= ÖÉJ ë~ÖíI=Éê=ãìëëK=lÄ=Éê=ïáää=çÇÉê=åáÅÜíK== aÉåå= ~åëçåëíÉå= Ü®åÖí= Éê= áå= ÇÉê= pÅÜäÉáÑÉ= ÇÉê= _ÉÇáÉåÜ~åÇäìåÖÉå= ÑÉëíW= bê= ÖáÄí= Ñ~äëÅÜ= ÉáåI= ïáää= Ç~ë= cÉåëíÉê= îÉêä~ëëÉåI= ïáêÇ= ~ìÑ= ëÉáåÉå= cÉÜäÉê= ~ìÑãÉêâë~ã= ÖÉJ ã~ÅÜí=ìåÇ=òìêΩÅâ=áå=Ç~ë=qÉñíÑÉåëíÉê=ÖÉäÉåâíK=dáÄí=Éê=ïáÉÇÉê=Ñ~äëÅÜ=ÉáåI=ïáêÇ=Éê= ÄÉáã= sÉêëìÅÜ= ÇÉë= sÉêä~ëëÉåë= ïáÉÇÉê= ~ìÑãÉêâë~ã= ÖÉã~ÅÜí= ìåÇ= òìêΩÅâ= áå= Ç~ë= qÉñíÑÉåëíÉê=ÖÉäÉåâí=ìåÇ=ëç=ïÉáíÉêK=pçä~åÖÉI=Äáë=Éê=âçêêÉâí=Ü~åÇÉäíK=== pç=éêçÖê~ããáÉêí=ã~å=Ç~ë=bêòïáåÖÉå=ëáååîçääÉê=kìíòÉêÉáåÖ~ÄÉåK== ORR =
NO=péÉáÅÜÉêéä®íòÉ=ÑΩê=aÉòáã~äÄêΩÅÜÉ=
12.5
Rechnen mit Delphi
^å= ÉáåáÖÉå= _ÉáëéáÉäÉå= ïçääÉå= ïáê= ìåë= ~åëÉÜÉåI= ïáÉ= ãáí= aÉäéÜáJm~ëÅ~ä= êáÅÜíáÖJ ÖÉÜÉåÇ=ÖÉêÉÅÜåÉí=ïÉêÇÉå=â~ååK== k~íΩêäáÅÜ= ÄÉÖáååÉå= ïáê= ãáí= ÉáåÉê= âäÉáåÉå= oÉÅÜåÉêJlÄÉêÑä®ÅÜÉ= ÑΩê= ÇáÉ= îáÉê= dêìåÇêÉÅÜÉå~êíÉåK=a~åå=âçããí=ÇÉê=ÄÉâ~ååíÉ=q~ëÅÜÉåêÉÅÜåÉê=Ç~òìK=
12.5.1
Vier Grundrechenarten
aáÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=E_áäÇ=NOKNTF=ÄÉëíÉÜí=~ìë=òïÉá=báåÖ~ÄÉJqÉñíÑÉåëíÉêåI=îáÉê= _ìííçåë=ãáí=ÇÉå=_ÉëÅÜêáÑíìåÖÉå=ÑΩê=ÇáÉ=oÉÅÜÉå~êíÉå=ëçïáÉ=ÇÉã=bêÖÉÄåáëJi~ÄÉäK== ^åÑ~åÖë=ëçääÉå=~ääÉ=îáÉê=_ìííçåë=áå~âíáî=ëÉáå=EbáÖÉåëÅÜ~Ñí= Enabled=~ìÑ= False=îçêJ ÉáåÖÉëíÉääíFK=
== _áäÇ=NOKNTW=sáÉê=dêìåÇêÉÅÜÉå~êíÉå= ^ìÑ=ÇÉã=båíïìêÑ=E_áäÇ=NOKNUF=ëáÉÜí=ã~å=òìë®íòäáÅÜ=åçÅÜ=Ç~ë=qáãÉêJpóãÄçäX=ïáê= ïçääÉå=åáÅÜí=îÉêÖÉëëÉåI=Ç~ëë=Éáå=ãáíä~ìÑÉåÇÉê=ëÅÜåÉääÉê=mêΩÑJqáãÉê=EbáÖÉåëÅÜ~Ñí= Interval= ~ìÑ= RR= ÖÉëÉíòíF= ÇáÉ= _ìííçåë= ~ìíçã~íáëÅÜ= òìJ= çÇÉê= ~ÄëÅÜ~äíÉå= ïáêÇI= àÉ= å~ÅÜ=_ÉäÉÖìåÖ=ÇÉê=qÉñíÑÉåëíÉêK==
== _áäÇ=NOKNUW=qáãÉê=òìê=^âíáîáÉêìåÖ=ÇÉê=_ìííçåë= aÉëÜ~äÄ=ïçääÉå=ïáê=ìåë=òìÉêëí=ÇÉã=fåÜ~äí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=òìã=qáãÉêJbêJ ÉáÖåáë=òìïÉåÇÉåK== aÉê=qáãÉê=ëçää=ÄÉá=hçåîÉêíáÉêÄ~êâÉáí=ÄÉáÇÉê=cÉåëíÉêáåÜ~äíÉ=ÇáÉ=_ìííçåë=òìëÅÜ~äJ íÉåK=cΩê=Ç~ë=wìëÅÜ~äíÉå=ÇÉë=_ìííçåë=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ= Quotient=ïáêÇ=òìë®íòJ äáÅÜ=åçÅÜ=ÖÉéêΩÑíI=çÄ=ÇÉê=fåÜ~äí=ÇÉë=òïÉáíÉå=cÉåëíÉêë=åáÅÜí=kìää=áëíK==
ORS= =
NOKR== oÉÅÜåÉå=ãáí=aÉäéÜá= båíëéêÉÅÜÉåÇ= ÇáÉëÉê= ^ìÑÖ~ÄÉåëíÉääìåÖ= ãΩëëÉå= ïáê= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= qáãÉêJbêÉáÖåáë=áå=ÑçäÖÉåÇÉê=tÉáëÉ=éêçÖê~ããáÉêÉåW== procedure TForm1.Timer1Timer(Sender: TObject); var x1_str:String; x1:Double; x1_info:Integer; x2_str:String; x2:Double; x2_info:Integer; begin x1_str:=Edit1.Text; x2_str:=Edit2.Text; Val(x1_str,x1,x1_info); Val(x2_str,x2,x2_info); if (x1_info=0) and (x2_info=0) then begin Button1.Enabled:=True; Button2.Enabled:=True; Button3.Enabled:=True; if x20 then Button4.Enabled:=True end else begin Button1.Enabled:=False; Button2.Enabled:=False; Button3.Enabled:=False; Button4.Enabled:=False end end;
oÉÅÜí=ÉáåÑ~ÅÜ=áëí=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=ÑΩê=Ç~ë=bêÉáÖåáë=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ãáí= ÇÉê=_ÉëÅÜêáÑíìåÖ=SummeW== procedure TForm1.Button1Click(Sender: TObject); var x1_str:String; x1:Double; x1_info:Integer; x2_str:String; x2:Double; x2_info:Integer; erg: Double; erg_str: String; begin x1_str:=Edit1.Text;x2_str:=Edit2.Text; Val(x1_str,x1,x1_info);Val(x2_str,x2,x2_info); erg:=x1+x2; Str(erg:12:4,erg_str);Label4.Caption:=erg_str end;
ORT =
NO=péÉáÅÜÉêéä®íòÉ=ÑΩê=aÉòáã~äÄêΩÅÜÉ= aáÉ= ~åÇÉêÉå= ÇêÉá= oÉÅÜÉåJbêÉáÖåáëéêçòÉÇìêÉå= òìã= häáÅâ= ~ìÑ= ÇáÉ= ÇêÉá= ~åÇÉêÉå= _ìííçåë=ìåíÉêëÅÜÉáÇÉå=ëáÅÜ=Ç~îçå=åìê=~å=ÉáåÉê=ÉáåòáÖÉå=píÉääÉI=ÇÉã=léÉê~íáçåëJ òÉáÅÜÉåK== tÉê=Ç~ë=~ääÉë=~ìëéêçÄáÉêíI=ÇÉê=ÄÉãÉêâí=åçÅÜ=ÉáåÉ=råÖÉêÉáãíÜÉáíW== táêÇ= å~ÅÜ= ÑÉêíáÖÉã= ìåÇ= ~åÖÉòÉáÖíÉã= bêÖÉÄåáë= áå= ÉáåÉã= ÇÉê= ÄÉáÇÉå= báåÖ~ÄÉJ ÑÉåëíÉê=ÖÉ®åÇÉêíI=Ççêí=Éíï~ë=kÉìÉë=ÉáåÖÉíê~ÖÉåI=áëí=ÇáÉ=~åÖÉòÉáÖíÉ=w~Üä=ëáååäçëI= Ñ~äëÅÜK== a~ë= ÄÉÇÉìíÉíI= Ç~ëë= ïáê= ÄÉá= àÉÖäáÅÜÉê= ûåÇÉêìåÖ= áå= ÉáåÉã= ÇÉê= ÄÉáÇÉå= báåÖ~ÄÉJ cÉåëíÉê=ëçÑçêí=Ç~ë=bêÖÉÄåáëJi~ÄÉä=ä∏ëÅÜÉå=ëçääíÉåW== procedure TForm1.Edit1Change(Sender: TObject); begin Label4.Caption:='' end; procedure TForm1.Edit2Change(Sender: TObject); begin Label4.Caption:='' end;
i∏ëÅÜÉå=ÄÉÇÉìíÉí=ïáÉÇÉêìã=åáÅÜíë=~åÇÉêÉëI=~äë=Ç~ëë=Ç~ë= i~ÄÉä=ãáí=ÇÉã=äÉÉêÉå= píêáåÖ=''=ÄÉëÅÜêáÑíÉí=ïáêÇK==
12.5.2
Der Windows-Rechner
aáÉ= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= E_áäÇ= NOKNVF= ÄÉëíÉÜÉ= òìÉêëí= ÇÉê= báåÑ~ÅÜÜÉáí= Ü~äÄÉê= ~ìë= ÇÉã= Öêç≈Éå= i~ÄÉäI= ÇÉã= q~ëíÉåÑÉäÇ= ãáí= ÇÉå= wáÑÑÉêåí~ëíÉåI= ÉáåÉê= hçêêÉâíìêí~ëíÉI= ÇÉå=q~ëíÉå=ÑΩê=^ÇÇáíáçå=ìåÇ=pìÄíê~âíáçå=ìåÇ=ÇÉê= = =q~ëíÉ=ÑΩê=Ç~ë=bêÖÉÄåáëK== ^ìÑ= ÇáÉ= hçãã~í~ëíÉ= ëçïáÉ= ~ìÑ= jìäíáéäáâ~íáçå= ìåÇ= aáîáëáçå= ïçääÉå= ïáê= îçêÉêëí= îÉêòáÅÜíÉåX=ïÉê=Ç~ë=mêáåòáé=îÉêëí~åÇÉå=Ü~íI=â~åå=ëÉáåÉå=łoÉÅÜåÉê=Ç~åå=ÄÉäáÉJ ÄáÖ=~ìÑêΩëíÉåK== táêÇ=Ç~ë=~ääÉë=~ìëêÉáÅÜÉå\=kÉáå=Ó=ïáÉ=_áäÇ=NOKOM=òÉáÖíI=Äê~ìÅÜÉå=ïáê=åçÅÜ=ÇêÉá= ïÉáíÉêÉ=píÉìÉêÉäÉãÉåíÉI=ÇáÉ=ëé®íÉê=ìåëáÅÜíÄ~ê=ÖÉã~ÅÜí=ïÉêÇÉåK== aÉê=o~ÇáçÄìííçå=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ= anfügen=ïáêÇ=ÖÉÄê~ìÅÜíI=ìã=ÇÉå=~âíìÉäJ äÉå=báåÖ~ÄÉãçÇìë=òì=ëéÉáÅÜÉêåW== pÅÜçå=ÇÉê=häáÅâ=~ìÑ=ÇáÉ=q~ëíÉ= 1 =Ü~í=å®ãäáÅÜ=òïÉá=îÉêëÅÜáÉÇÉåÉ=táêâìåÖÉåW= • båíïÉÇÉê= Éê= ÄÉïáêâí= ÇáÉ= i∏ëÅÜìåÖ= ÇÉë= ÖÉë~ãíÉå= báåÖ~ÄÉJi~ÄÉäë= EïÉåå= îçêJ ÜÉê=ÉáåÉ=léÉê~íáçåëí~ëíÉ=çÇÉê=ÇáÉ=bêÖÉÄåáëí~ëíÉ=ÖÉÇêΩÅâí=ïçêÇÉå=ï~êFK== • lÇÉê= Éê= ÄÉïáêâí= Ç~ë= ^åÑΩÖÉå= ÇÉë= wÉáÅÜÉåë= ‘1‘= ~å= ÇÉå= fåÜ~äí= ÇÉë= báåÖ~ÄÉJ i~ÄÉäë=EïÉåå=ÖÉê~ÇÉ=ÇáÉ=báåÖ~ÄÉJwáÑÑÉêåÑçäÖÉ=~ìÑÖÉÄ~ìíLÑçêíÖÉëÉíòí=ïáêÇFK= ORU= =
NOKR== oÉÅÜåÉå=ãáí=aÉäéÜá=
= _áäÇ=NOKNVW=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=ÑΩê=ÉáåÑ~ÅÜÉå=oÉÅÜåÉê=
== _áäÇ=NOKOMW=båíïìêÑ=ÇÉë=q~ëÅÜÉåêÉÅÜåÉêë= pÉÜÉå= ïáê= ìåë= Ç~òì= ÄÉêÉáíë= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= pí~åÇ~êÇJbêÉáÖåáë= häáÅâ= ~ìÑ=_ìííçå=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ= 1 =~åW= procedure TForm1.Button1Click(Sender: TObject); begin if RadioButton1.Checked=False then begin RadioButton1.Checked:=True; Label1.Caption:='1' end else Label1.Caption:=Label1.Caption+'1' end;
aìêÅÜ=Ç~ë=báåëÅÜ~äíÉå=ÇÉë=o~ÇáçÄìííçåë=áã=g~JwïÉáÖ=ÇÉê=^äíÉêå~íáîÉ=ïáêÇ=ÖÉëáJ ÅÜÉêíI=Ç~ëë=å~ÅÜ=ÉáåÉê=kÉìÉáåÖ~ÄÉ=ÇáÉ=ïÉáíÉêÉå=q~ëíÉåÄÉí®íáÖìåÖÉå=òìã=^åÑΩJ ÖÉå=ÑΩÜêÉåK= ORV =
NO=péÉáÅÜÉêéä®íòÉ=ÑΩê=aÉòáã~äÄêΩÅÜÉ= a~ãáí=â∏ååÉå=ïáê=ÇáÉ=òÉÜå=bêÉáÖåáëéêçòÉÇìêÉå=ÑΩê=ÇÉå=häáÅâ=~ìÑ=àÉÇÉ=wáÑÑÉêåJ í~ëíÉ=éêçÖê~ããáÉêÉåK== aáÉ=hçêêÉâíìêí~ëíÉ= C =ä∏ëÅÜí=Ç~ë=báåÖ~ÄÉÑÉåëíÉê=ìåÇ=ëÉíòí=ÇÉå=o~ÇáçÄìííçå=~ìÑ= FalseI=Ç~ãáí=åÉì=ÉáåÖÉÖÉÄÉå=ïÉêÇÉå=â~ååW= procedure TForm1.Button11Click(Sender: TObject); begin Label1.Caption:=''; RadioButton1.Checked:=False end;
hçããÉå=ïáê=òìã=_ìííçå= + =W=_Éáã=häáÅâ=~ìÑ=ÇáÉëÉ=q~ëíÉ=ãìëë=ÇêÉáÉêäÉá=é~ëJ ëáÉêÉåW== • aÉê= fåÜ~äí= ÇÉë= báåÖ~ÄÉJi~ÄÉä= ãìëë= áêÖÉåÇïç= òïáëÅÜÉåÖÉëéÉáÅÜÉêí= ïÉêÇÉåK= a~ÑΩê= áëí= áã= _áäÇ= NOKNU= Éáå= i~ÄÉä= ãáí= ÇÉã= k~ãÉå= Label2= ìåÇ= ÇÉê= _ÉëÅÜêáÑJ íìåÖ=Register=îçêÖÉëÉÜÉåK== • aÉê=o~ÇáçÄìííçå=áëí=áå=ëÉáåÉê=éêçéÉêíó= Checked=~ìÑ= False=òì=ëÉíòÉåI=Ç~ãáí=ÇáÉ= å®ÅÜëíÉ=ÄÉí®íáÖíÉ=wáÑÑÉêåí~ëíÉ=åáÅÜí=~åÑΩÖíI=ëçåÇÉêå=ÉáåÉ=kÉìÉáåÖ~ÄÉ=ÄÉÖáååíK== • aáÉ= ^êí= ÇÉê= léÉê~íáçå= ãìëë= ÉÄÉåÑ~ääë= áêÖÉåÇïç= ÖÉëéÉáÅÜÉêí= ïÉêÇÉåI= Ç~ãáí= ÄÉáã=ëé®íÉêÉå=aêìÅâ=~ìÑ=ÇáÉ=q~ëíÉ= = =ÑÉëíÖÉëíÉääí=ïÉêÇÉå=â~ååI=çÄ=~ÇÇáÉêí= çÇÉê= ëìÄíê~ÜáÉêí= ïÉêÇÉå= ãìëëK= a~ÑΩê= áëí= áã= _áäÇ= NOKNU= Éáå= i~ÄÉä= ãáí= ÇÉã= k~ãÉå=Label3=ìåÇ=ÇÉê=_ÉëÅÜêáÑíìåÖ=aktuelle Operation=îçêÖÉëÉÜÉåK== råÇ=Ç~ë=áëí=ÇáÉ=ÉåíëéêÉÅÜÉåÇÉ=bêÉáÖåáëéêçòÉÇìêW= procedure TForm1.Button12Click(Sender: TObject); begin Label2.Caption:=Label1.Caption; RadioButton1.Checked:=False; Label3.Caption:='+' end;
hçããÉå=ïáê=òìã=_ìííçå==Z==W=a~=áã=i~ÄÉä=ãáí=ÇÉê=_ÉëÅÜêáÑíìåÖ= aktuelle Operation= ~ÄÖÉëéÉáÅÜÉêí= ïìêÇÉI= ãáí= ïÉäÅÜÉê= ÇÉê= q~ëíÉå= = += = çÇÉê= = -= = Ç~ë= oÉÖáëíÉê= îçêÜÉê= ÖÉÑΩääí= ïçêÇÉå= áëíI= â~åå= ÉåíëéêÉÅÜÉåÇ= ÖÉêÉÅÜåÉí= ìåÇ= ~ìëÖÉÖÉÄÉå= ïÉêJ ÇÉåK== a~ë=oÉÖáëíÉê=ïáêÇ=ÖÉä∏ëÅÜíI=ìåÇ=ÇÉê=o~ÇáçÄìííçå=ïáêÇ=áå=ëÉáåÉê=éêçéÉêíó=Checked= ~ìÑ= False=ÖÉëÉíòíI=Ç~ãáí=ÇáÉ=å®ÅÜëíÉ=ÄÉí®íáÖíÉ=wáÑÑÉêåí~ëíÉ=åáÅÜí=~åÑΩÖíI=ëçåÇÉêå= ÉáåÉ=kÉìÉáåÖ~ÄÉ=ÄÉÖáååíK==
OSM= =
NOKR== oÉÅÜåÉå=ãáí=aÉäéÜá= a~= ìåëÉê= ÉáåÑ~ÅÜÉê= q~ëÅÜÉåêÉÅÜåÉê= âÉáåÉ= hçãã~í~ëíÉ= Ü~íI= â∏ååÉå= ïáê= ~ìÑ= péÉáÅÜÉêéä®íòÉ=îÉêòáÅÜíÉå=ìåÇ=ÇáÉ=oÉÅÜåìåÖ=ÉáåÑ~ÅÜ=éêçÖê~ããáÉêÉåW=== procedure TForm1.Button14Click(Sender: TObject); begin if Label3.Caption='+' then Label1.Caption:=IntToStr( StrToInt(Label2.Caption)+ StrToInt(Label1.Caption) ); if Label3.Caption='-' then Label1.Caption:=IntToStr( StrToInt(Label2.Caption)StrToInt(Label1.Caption) ); RadioButton1.Checked:=False; Label2.Caption:=''; Label3.Caption:='' end;
a~ë=ï~êÛë=ëÅÜçåI=ÖêìåÇë®íòäáÅÜK=tÉê=ã∏ÅÜíÉI=â~åå=ïÉáíÉê=~ìëÄ~ìÉåW=q~ëíÉå=ÑΩê= j~ä=ìåÇ=aìêÅÜ=ÉêÖ®åòÉå=íÉëíÉåK== táÉ=êÉ~ÖáÉêí=ÉáÖÉåíäáÅÜ=ÇÉê=táåÇçïëJoÉÅÜåÉê=~ìÑ=ÉáåÉ=aáîáëáçå=ÇìêÅÜ=kìää=\== aáÉ= hçãã~Jq~ëíÉ= â~åå= ã~å= Ç~åå= åçÅÜ= ÜáåòìåÉÜãÉåI= ìåÇ= ëÅÜçå= ïáêÇ= ~ääÉë= îáÉä=âçãéäáòáÉêíÉêK=kìå=ãΩëëÉå=péÉáÅÜÉêéä®íòÉ=îÉêïÉåÇÉí=ïÉêÇÉå>= aÉê=^ìÑï~åÇ=Ü®äí=ëáÅÜ=åçÅÜ=áå=dêÉåòÉåI=ïÉåå=ÄÉáã=häáÅâ=~ìÑ=ÇáÉ=hçãã~Jq~ëJ íÉ=áã=báåÖ~ÄÉJi~ÄÉä=Éáå=mìåâí=ÉáåÖÉíê~ÖÉå=ïáêÇK=a~åå=ÉåíëíÉÜÉå=ëçÑçêí=âçåîÉêJ íáÉêÄ~êÉ=i~ÄÉäJfåÜ~äíÉ=Ó=ëçÑÉêå=ÖÉëáÅÜÉêí=áëíI=Ç~ëë=ëíÉíë=åìê=Ü∏ÅÜëíÉåë=Éáå=mìåâí= ÉáåÖÉíê~ÖÉå= ïÉêÇÉå= â~ååK= a~ë= ãìëë= áå= ÇÉê= bêÉáÖåáëéêçòÉÇìê= òìê= hçãã~í~ëíÉ= éêçÖê~ããáÉêí=ïÉêÇÉåI=ÉáåÉ=âäÉáåÉ=^Äò®Üä~ìÑÖ~ÄÉ=áëí=òì=ä∏ëÉåK== táää=ã~å=ëÉÜê=åìíòÉêÑêÉìåÇäáÅÜ=ëÉáå=ìåÇ=Ç~ë=hçãã~=~ìÅÜ=~åòÉáÖÉåI=ëíÉÜí=îçê= ÇÉê=oÉÅÜåìåÖ=òìë®íòäáÅÜ=åçÅÜ=Ç~ë=bêëÉíòÉå=ÇÉë=hçãã~ë=ÇìêÅÜ=ÇÉå=mìåâí=~åK== táÉÇÉê=ÉáåÉ=òìë®íòäáÅÜÉ=pÅÜïáÉêáÖâÉáíK== jáí= ÉáåÉã= ^åäáÉÖÉå= ïçääÉå= ïáê= ìåë= ~ÄÉê= ÇçÅÜ= åçÅÜ= áã= aÉí~áä= ÄÉëÅÜ®ÑíáÖÉå= Ó= ãáí=ÇÉå=hÉííÉåêÉÅÜåìåÖÉåK== tÉê=âÉååí=Ç~ë=åáÅÜíW== 1 plus 2 minus 4 plus 5 ist wie viel?
OSN =
NO=péÉáÅÜÉêéä®íòÉ=ÑΩê=aÉòáã~äÄêΩÅÜÉ= jáí= ÇÉê= ~âíìÉääÉå= båíïáÅâäìåÖëëíìÑÉ= ìåëÉêÉë= q~ëÅÜÉåêÉÅÜåÉêë= ãΩëëÉå= ïáê= òìê= i∏ëìåÖ=ÇáÉëÉê=^ìÑÖ~ÄÉ=ëç=îçêÖÉÜÉåW==1 + 2 = - 4 = + 5 = =K== wìÖÉÖÉÄÉåI=òáÉãäáÅÜ=ìãëí®åÇäáÅÜK=t~ë=ãΩëëÉå=ïáê=®åÇÉêåI=Ç~ãáí=ïáê=ïáÉ=ÄÉáã= táåÇçïëJoÉÅÜåÉê=âΩêòÉê=ÉáåíáééÉå=â∏ååÉåW==1 + 2 - 4 + 5 ===\== tç=äáÉÖí=Ç~ë=mêçÄäÉã\=== a~ë=mêçÄäÉã=äáÉÖí=áå=ÇÉå=bêÉáÖåáëéêçòÉÇìêÉå=ÑΩê=ÇáÉ=q~ëíÉå== +==ìåÇ== -==K=få=áÜJ åÉå= ãΩëëíÉ= ÉáåÑ~ÅÜ= åìê= ÖÉíÉëíÉí= ïÉêÇÉåI= çÄ= áã= i~ÄÉä= aktuelle Operation= Éáå= fåÜ~äí=îçêäáÉÖíK== tÉåå=ÖáÄí=Éë=~ìÅÜ=ÉáåÉå=fåÜ~äí=áã=oÉÖáëíÉêI=ìåÇ=Ç~åå=ïáêÇ=îçê=ÇÉã=qê~åëéçêí= îçã=báåÖ~ÄÉJi~ÄÉä=áåë=oÉÖáëíÉê=òìÉêëí=ÇáÉ=~åëíÉÜÉåÇÉ=oÉÅÜåìåÖ=~ìëÖÉÑΩÜêíK== pÉÜÉå=ïáê=ìåë=ÇáÉ=ÉåíëéêÉÅÜÉåÇ=ÉêÖ®åòíÉ=bêÉáÖåáëéêçòÉÇìê=ÑΩê=ÇÉå=mäìëJ_ìííçå= ~åW= procedure TForm1.Button12Click(Sender: TObject); begin if Label3.Caption='+' then Label1.Caption:=IntToStr( StrToInt(Label2.Caption)+ StrToInt(Label1.Caption) ); if Label3.Caption='-' then Label1.Caption:=IntToStr( StrToInt(Label2.Caption)StrToInt(Label1.Caption) ); Label2.Caption:=Label1.Caption; RadioButton1.Checked:=False; Label3.Caption:='+' end;
=
OSO= =
==
13
Prozeduren und Funktionen
få= ÇáÉëÉã= h~éáíÉä= ëíÉääÉå= ïáê= òìÉêëí= âìêò= òìë~ããÉåI= ïÉäÅÜÉ= cìåâíáçåÉå= ìåÇ= mêçòÉÇìêÉåI=ÇáÉ=ìåë=aÉäéÜáJm~ëÅ~ä=~äë=_Éëí~åÇíÉáäÉ=ÇÉê=péê~ÅÜÉ=äáÉÑÉêíI=ïáê=ÄáëJ ÜÉê=òì=ïÉäÅÜÉã=wïÉÅâ=îÉêïÉåÇÉí=Ü~ÄÉåK== ^åëÅÜäáÉ≈ÉåÇ=ïÉêÇÉå=ïáê=ÉáåáÖÉ=a~íìãëJ=ìåÇ=wÉáíÑìåâíáçåÉå=îçå=aÉäéÜáJm~ëJ Å~ä=âÉååÉå=äÉêåÉåK== _Éá= ÇÉå= ~êáíÜãÉíáëÅÜÉå= cìåâíáçåÉå= ãΩëëÉå= ïáê= ÉêâÉååÉåI= Ç~ëë= aÉäéÜáJm~ëÅ~ä= äÉáÇÉê=âÉáåÉ=mçíÉåòÑìåâíáçå=äáÉÑÉêíI=~ÄÉê=ïáê=ïÉêÇÉå=ìåë=òì=ÜÉäÑÉå=ïáëëÉåK== ^åëÅÜäáÉ≈ÉåÇ=âÉÜêÉå=ïáê=ïáÉÇÉê=òìêΩÅâ=òì=ìåëÉêÉå=îáëìÉääÉå=lÄàÉâíÉå=ìåÇ=ÉêJ Ñ~ÜêÉåI= ïáÉ= ãáí= cìåâíáçåÉå= ìåÇ= mêçòÉÇìêÉå= îáëìÉääÉê= lÄàÉâíÉ= ^ìëâΩåÑíÉ= ΩÄÉê= ÇÉå= a~íÉåâÉêå= ÉáåÖÉÜçäí= ìåÇ= j~åáéìä~íáçåÉå= áã= a~íÉåâÉêå= îçêÖÉåçããÉå= ïÉêÇÉå=â∏ååÉåK== báå= âäÉáåÉê= _Éáíê~Ö= ÄÉëÅÜ®ÑíáÖí= ëáÅÜ= ~ìÅÜ= ãáí= ÇÉê= j∏ÖäáÅÜâÉáíI= ÇìêÅÜ= sÉêïÉåJ ÇìåÖ=îçå=ÉáÖÉåÉå=mêçòÉÇìêÉå=pÅÜêÉáÄ~êÄÉáí=òì=ëé~êÉåI=îçê=~ääÉãI=ïÉåå=ÇáÉ=fåJ Ü~äíÉ=îáÉäÉê=bêÉáÖåáëéêçòÉÇìêÉå=áÇÉåíáëÅÜ=ëáåÇK=
13.1
Grundsätzliches
• mêçòÉÇìêÉå= ëáåÇ= îçêÖÉÑÉêíáÖíÉ= mêçÖê~ããëíΩÅâÉI= ÇáÉ= ÉáåÉ= táêâìåÖ= Ü~ÄÉåK= aáÉëÉ=táêâìåÖ=â~åå=áå=ÇÉê=sÉê®åÇÉêìåÖ=îçå=fåÜ~äíÉå=áå=ÉáåÉã=çÇÉê=ãÉÜêÉJ êÉå= péÉáÅÜÉêéä®íòÉå= ÄÉëíÉÜÉåI= ëáÉ= â~åå= ~ìÅÜ= î∏ääáÖ= ìå~ÄÜ®åÖáÖ= îçå= péÉáJ ÅÜÉêéä®íòÉå=ëÉáåK=mêçòÉÇìêÉå=ïÉêÇÉå=ëíÉíë=~ìÑÖÉêìÑÉåI=ÇK=ÜK=ëáÉ=Ü~ÄÉå=áå=ÉáJ åÉã= wìïÉáëìåÖëÄÉÑÉÜä= åáÅÜíë= òì= ëìÅÜÉåI= ÇÉåå= ëáÉ= Ü~ÄÉå= âÉáåÉ= nìÉääÉ= ìåÇ= âÉáå=wáÉäK= tÉåå= ÉáåÉ= mêçòÉÇìê= ÑΩê= áÜêÉ= táêâìåÖ= áêÖÉåÇïÉäÅÜÉ= ^åÖ~ÄÉå= Eòìã= _ÉáëéáÉä= k~ãÉå=îçå=péÉáÅÜÉêéä®íòÉåF=ÄÉå∏íáÖí=ãΩëëÉå=ÇáÉëÉ=å~ÅÜ=ÇÉã=mêçòÉÇìêå~ãÉå= áå=êìåÇÉå=hä~ããÉêå=~åÖÉÑΩÖí=ïÉêÇÉåK=_Éå∏íáÖí=ÉáåÉ=mêçòÉÇìê=åáÅÜíëI=ÉåíÑ~ääÉå= ÇáÉ=êìåÇÉå=hä~ããÉêå=ÜáåíÉê=ÇÉã=mêçòÉÇìêå~ãÉåK= • cìåâíáçåÉå=ëáåÇ=îçêÖÉÑÉêíáÖíÉ=mêçÖê~ããëíΩÅâÉI=ÇáÉ=ëíÉíë=ÉáåÉå=ÉáåòáÖÉå=tÉêí= äáÉÑÉêåK=báåÉ=cìåâíáçå=ïáêÇ=îÉêïÉåÇÉíI=áåÇÉã=ÇÉê=bêÖÉÄåáëïÉêí=ÇÉê=cìåâíáçå= áå=ÉáåÉå=ÖÉÉáÖåÉíÉå= péÉáÅÜÉêéä~íò=çÇÉê=ÉáåÉå=qÉëí= ÖÉäÉåâí=çÇÉê=~åÇÉêïÉáíáÖ= îÉê~êÄÉáíÉí=ïáêÇK== j~åÅÜÉ= cìåâíáçåÉå= ÄÉå∏íáÖÉå= ÖÉïáëëÉ= ^åÖ~ÄÉåI= Ç~ãáí= ëáÉ= ~êÄÉáíÉå= â∏ååÉåX= ÇáÉëÉ= ^åÖ~ÄÉå= ëáåÇ= Ç~åå= áå= êìåÇÉå= hä~ããÉêå= ÜáåíÉê= ÇÉå= cìåâíáçåëå~ãÉå= Éáåòìíê~ÖÉåK== OSP =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= ^åÇÉêÉ= cìåâíáçåÉå= ÄÉå∏íáÖÉå= åáÅÜíëX= Ççêí= ÉåíÑ~ääÉå= ÑçäÖäáÅÜ= ~ìÅÜ= ÇáÉ= êìåÇÉå= hä~ããÉêå=ÜáåíÉê=ÇÉã=cìåâíáçåëå~ãÉåK=
13.2
Prozeduren und Funktionen von Delphi-Pascal
13.2.1
Bisher bereits verwendete Prozeduren und Funktionen
_ÉêÉáíë=áã=^ÄëÅÜåáíí=OKO=ÄÉåìíòíÉå=ïáê=ÉáåÉ=ÉêëíÉ=mêçòÉÇìêI=ÇáÉ=ìåë=ÇáÉ=péê~ÅÜÉ= aÉäéÜáJm~ëÅ~ä=òìê=sÉêÑΩÖìåÖ=ëíÉääíK=páÉ=íê®Öí=ÇÉå=k~ãÉå= ShowMessage=ìåÇ=ëçêÖí= Ç~ÑΩêI= Ç~ëë= Éáå= jáííÉáäìåÖëÑÉåëíÉê= ãáí= ÉáåÉã= ÄÉëíáããíÉå= qÉñí= ~ìÑ= ÇÉã= _áäÇJ ëÅÜáêã=ÉêëÅÜÉáåíK== aÉê=^ÄëÅÜåáíí=TKN=ï~ê=ÇÉå=ÄÉáÇÉå=cìåâíáçåÉå=StrToInt=ìåÇ=IntToStr=ÖÉïáÇãÉíI= ãáí=ÇÉêÉå=eáäÑÉ=wÉáÅÜÉåÑçäÖÉåI=ïÉåå=ëáÉ=~ìëëÉÜÉå=ïáÉ=Ö~åòÉ=w~ÜäÉåI=òì=w~ÜäÉå= ÖÉã~ÅÜí=ïÉêÇÉå=â∏ååÉåI=ìãÖÉâÉÜêí=ïÉêÇÉå=w~ÜäÉå=ëíÉíë=òì=wÉáÅÜÉåÑçäÖÉåK== fã=^ÄëÅÜåáíí=TKQ=îÉêïÉåÇÉíÉå=ïáê=ÇáÉ=cìåâíáçå=Random=ìåÇ=ÇáÉ=mêçòÉÇìê=Randomize=òìê=bêòÉìÖìåÖ=îçå=Ö~åòÉå=wìÑ~ääëò~ÜäÉåK== ^ÄëÅÜåáíí=NMKO=ÄÉëÅÜ®ÑíáÖíÉ=ëáÅÜ=ãáí=ÇÉê=péÉáÅÜÉêìåÖ=ÉáåòÉäåÉê=wÉáÅÜÉåI=îçê=~äJ äÉã= ãáí= áÜêÉê= `çÇáÉêìåÖ= ìåÇ= ÇÉå= ^p`ffJtÉêíÉåK= få= ÇáÉëÉã= wìë~ããÉåÜ~åÖ= äÉêåíÉå=ïáê=ÇáÉ=cìåâíáçåÉå=Chr=ìåÇ=Ord=âÉååÉåK= pÅÜäáÉ≈äáÅÜ= ï~ê= ÇÉê= ^ÄëÅÜåáíí= NNKN= ÇÉå= ÄÉáÇÉå= mêçòÉÇìêÉå= Delete= ìåÇ= Insert= ìåÇ=ÇÉå=píêáåÖJcìåâíáçåÉå= CompareStrI= ConcatI= CopyI= LengthI= LowerCaseI= Pos=ìåÇ= UpperCase= ìåÇ= áÜêÉå= îáÉäÑ®äíáÖÉå= ^åïÉåÇìåÖëã∏ÖäáÅÜâÉáíÉå= ÄÉáã= rãÖ~åÖ= ãáí= wÉáÅÜÉåÑçäÖÉå=ÖÉïáÇãÉíK== få=^ÄëÅÜåáíí=NOKP=ëÅÜäáÉ≈äáÅÜ=ÄÉëÅÜ®ÑíáÖíÉå=ïáê=ìåë=ãáí=ÇÉã=~ìÑï®åÇáÖÉå=qÜÉJ ã~= ÇÉê= hçåîÉêíáÉêìåÖ= îçå= píêáåÖë= áå= fåÜ~äíÉ= ÑΩê= aÉòáã~äÄêìÅÜJpéÉáÅÜÉêéä®íòÉ= ìåÇ=ìãÖÉâÉÜêíK=lÜåÉ=ÇáÉ=ÄÉáÇÉå=hçåîÉêíáÉêìåÖëJmêçòÉÇìêÉå=Str=ìåÇ=Val=ï®êÉ= Ç~ë=åáÅÜí=ã∏ÖäáÅÜ=ÖÉïÉëÉåK=== == ========================tÉê= ÇáÉ= ÑçäÖÉåÇÉå= aÉäéÜáJmêçàÉâíÉ= åáÅÜí= ëÉäÄëí= ÉåíïáÅâÉäå= ã∏ÅÜíÉI= â~åå= îçå= http://www.w-g-m.de/delphi.htm= ΩÄÉê= Dateien für Kapitel 13= ÇáÉ= zipJa~íÉá= DKap13.zip=ãáí=òïÉá=lêÇåÉêå=ÜÉêìåíÉêä~ÇÉåK=táêÇ=ãáí=aÉäéÜá=T=ÖÉJ ~êÄÉáíÉíI= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= áã= lêÇåÉê= D7Kap13= ÇáÉ= mêçàÉâíJa~íÉá= proj_13?.dpr=~ìëòìï®ÜäÉåK=táêÇ=ãáí=aÉäéÜá=ULOMMR=ÖÉ~êÄÉáíÉíI=áëí=å~ÅÜ=a^qbf= = molgbhq=£cckbk=áã=lêÇåÉê=D8Kap13=ÇáÉ=a~íÉá=proj_13?.bdsproj=~ìëòìï®ÜäÉåK== a~ë=cê~ÖÉòÉáÅÜÉå=áëí=Ç~åå=àÉïÉáäë=ÇìêÅÜ=ÇáÉ=wáÑÑÉêåÑçäÖÉ=ÇÉë=råíÉêâ~éáíÉäë=òì=ÉêJ ëÉíòÉå=E_ÉáëéáÉäW=a~ë=mêçàÉâí= ~ìë=^ÄëÅÜåáíí=NPKOKO=ÑáåÇÉí= ëáÅÜ=áå=ÇÉê=mêçàÉâíÇ~íÉá= proj_1322.dpr=ÄòïK=proj_1322.bdsproj)= = = OSQ= =
NPKO== mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=îçå=aÉäéÜáJm~ëÅ~ä=
13.2.2
Datums- und Zeitfunktionen
aÉäéÜáJm~ëÅ~ä= ÖáÄí= ìåë= ÇáÉ= j∏ÖäáÅÜâÉáíI= Ç~ë= ~âíìÉääÉ= a~íìã= ìåÇ= ÇáÉ= ~âíìÉääÉ= rÜêòÉáí=~åòÉáÖÉå=òì=ä~ëëÉåK=aÉåå=ÇáÉ=ÄÉáÇÉå=cìåâíáçåÉå= Date=ìåÇ= Time=äáÉÑÉêå= ÇáÉëÉ=^åÖ~ÄÉåK== _ÉáÇÉ= cìåâíáçåÉå= ÄÉå∏íáÖÉå= åáÅÜíëI= ÑçäÖäáÅÜ= ëíÉÜí= ÉáåÉê= mêçÖê~ããáÉêìåÖ= ÉáåÉê= bêÉáÖåáëéêçòÉÇìêÉå=ÑΩê=ÇáÉ=a~íìãë~åòÉáÖÉ=ëÅÜÉáåÄ~ê=åáÅÜíë=áã=tÉÖÉW= procedure TForm1.Button1Click(Sender: TObject); begin Label1.Caption:=Date end;
k~íΩêäáÅÜ=ÖáÄí=Éë=~ÄÉê=ÇçÅÜ=ÉáåÉ= cÉÜäÉêãÉäÇìåÖK= t~êìã\=fããÉê=Ç~ëëÉäÄÉW=báå= i~ÄÉä= â~åå= åìê= ÄÉäÉÖí= ïÉêÇÉå= ãáí= ÉáåÉã= píêáåÖI= ìåÇ= Ç~ëI= ï~ë= ÇáÉ= cìåâíáçå= Date=äáÉÑÉêíI=áëí=ÉÄÉå= âÉáå=píêáåÖK=bë=Ü~í=Éáå= pçåÇÉêÑçêã~íI=ìåÇ=åìê=ãáííÉäë= ÇÉê= cìåâíáçå=DateToStrI=ÇÉêÉå=k~ãÉ=ÑΩê=ëáÅÜ=ëéêáÅÜíI=éêçÖê~ããáÉêÉå=ïáê=êáÅÜíáÖK= procedure TForm1.Button1Click(Sender: TObject); begin Label1.Caption:=DateToStr(Date) end;
_Éîçê=ïáê=ÄÉá=ÇÉê=wÉáí~åòÉáÖÉ=ÇÉå=ÖäÉáÅÜÉå=cÉÜäÉê=ÄÉÖÉÜÉåI=éêçÄáÉêÉå=ïáê=äáÉJ ÄÉê=ëçÑçêíI=çÄ=ÇáÉ=hçåîÉêíáÉêìåÖëÑìåâíáçåI=ÇáÉ=ÉáåÉ=wÉáí~åÖ~ÄÉ=òì=ÉáåÉã=píêáåÖ= ã~ÅÜí=ìåÇ=ï~ÜêëÅÜÉáåäáÅÜ=TimeToStr=ÜÉá≈íI=ìåë=ÇáÉ=rÜêòÉáí=áå=Éáå=i~ÄÉä=ÄêáåÖíK== procedure TForm1.Button2Click(Sender: TObject); begin Label2.Caption:=TimeToStr(Time) end;
páÉÜÉ= Ç~I= Éë= ÑìåâíáçåáÉêíK= açÅÜ= ~ìÅÜ= ÜáÉê= ÖáÄí= Éë= ÉáåÉå= råíÉêëÅÜáÉÇ= òïáëÅÜÉå= ÇÉã=~äíÉå=aÉäéÜá=ìåÇ=aÉäéÜá=UW=aÉäéÜá=U=äáÉÑÉêí=Ç~ë=g~Üê=ëíÉíë=îáÉêëíÉääáÖI=ï®ÜJ êÉåÇ=Ç~ë=~äíÉ=aÉäéÜá=Ç~ë=g~Üê=åìê=òïÉáëíÉääáÖ=~ìëÖáÄíK=>==
= _áäÇ=NPKNW=a~íìãëJ=ìåÇ=wÉáí~åòÉáÖÉ=áå=aÉäéÜá=U=
OSR =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= kìå= ïáëëÉå= ïáêI= ïáÉ= ïáê= a~íìã= ìåÇ= wÉáí= ~äë= ÉáåÑ~ÅÜÉ= wÉáÅÜÉåÑçäÖÉ= ÉêÜ~äíÉå= â∏ååÉåK= jáí= ÇÉå= píêáåÖJmêçòÉÇìêÉå= ìåÇ= JcìåâíáçåÉå= ä~ëëÉå= ëáÅÜ= ïÉáíÉêÉ= ^ìÑJ Ö~ÄÉå=ä∏ëÉåK== _ÉáëéáÉäëïÉáëÉ= ÇáÉ= ^ìëÖ~ÄÉ= ÇÉë= a~íìãë= ãáí= ÇÉå= ÇÉìíëÅÜÉå= jçå~íëå~ãÉåK= aÉåå=áå=_áäÇ=NPKN=ëÉÜÉå=ïáêI=Ç~ëë=jçå~íëåìããÉê=ìåÇ=mìåâí=áå=ÇÉã=~ìëÖÉÖÉJ ÄÉåÉå=píêáåÖ=~å=îáÉêíÉê=Äáë=ëÉÅÜëíÉê=píÉääÉ=ëíÉÜÉåK== i∏ëÉå=ïáê=Ç~ë=îáÉêíÉ=ìåÇ=ÑΩåÑíÉ=wÉáÅÜÉå=ÜÉê~ìëI=ã~ÅÜÉå=ÇáÉëÉ=wÉáÅÜÉåÑçäÖÉ=òì= ÉáåÉê= Ö~åòÉå= w~ÜäI= ÄÉäÉÖÉå= ÉåíëéêÉÅÜÉåÇ= ÉáåÉå= StringJpéÉáÅÜÉêéä~íò= ÑΩê= ÇÉå= jçå~íëå~ãÉå=ìåÇ=éê~âíáòáÉêÉå=ÇáÉ=bêëÉíòìåÖ=áå=ÇáÉëÉã=píêáåÖK= procedure TForm1.Button1Click(Sender: TObject); var dat_str, monat: ShortString; mon_nr
:Byte;
begin dat_str:=DateToStr(Date); mon_nr:=StrToInt(Copy(dat_str,4,2)); if mon_nr=1 then monat:='Januar'; if mon_nr=2 then monat:='Februar'; if mon_nr=3 then monat:='März'; if mon_nr=4 then monat:='April'; if mon_nr=5 then monat:='Mai'; if mon_nr=6 then monat:='Juni'; if mon_nr=7 then monat:='Juli'; if mon_nr=8 then monat:='August'; if mon_nr=9 then monat:='September'; if mon_nr=10 then monat:='Oktober'; if mon_nr=11 then monat:='November'; if mon_nr=12 then monat:='Dezember'; Delete(dat_str,4,3); Insert(' '+monat+' ',dat_str,4); Label1.Caption:=dat_str end;
i∏ëÉå=ïáê=åçÅÜ=ÉáåÉ=âäÉáåÉ=^ìÑÖ~ÄÉW=káÅÜí=ëÉäíÉå=ïáêÇ=ÖÉÑçêÇÉêíI=Ç~ëë=~ìÑ=ÉáåÉê= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ=ÉáåÉ=ãáíä~ìÑÉåÇÉ=wÉáí~åòÉáÖÉ=òì=ëÉÜÉå=ëÉáå=ëçääK=a~ë=mêçÄJ äÉã=ÄÉëíÉÜí=ÜáÉê=áå=ÇÉê=sçâ~ÄÉä=ãáíä~ìÑÉåÇK=aÉåå=ÇáÉ=wÉáí~åòÉáÖÉ=áå=ÉáåÉã=i~J ÄÉä=~âíì~äáëáÉêí=ëáÅÜ=åáÅÜí=îçå=ëÉäÄëíK==
OSS= =
NPKO== mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=îçå=aÉäéÜáJm~ëÅ~ä= aáÉ=i∏ëìåÖW=báå=qáãÉêI=ÇÉê=~ääÉê=ÜìåÇÉêí=jáääáëÉâìåÇÉå=ëÉáå=qáãÉêJbêÉáÖåáë=~ìëJ ëÅÜáÅâíK= råÇ= ÄÉá= àÉÇÉã= qáãÉêJbêÉáÖåáë= ïáêÇ= ÇáÉ= cìåâíáçå= Time= åÉì= ~ìÑÖÉêìÑÉå= ìåÇ=Üçäí=ÇáÉ=~âíìÉääÉ=wÉáíK=pç=ÉáåÑ~ÅÜ=áëí=Ç~ëW= procedure TForm1.Timer1Timer(Sender: TObject); begin Label3.Caption:=TimeToStr(Time) end;
= _áäÇ=NPKOW=qáãÉê=ÑΩê=ÇáÉ=ãáíä~ìÑÉåÇÉ=wÉáí= _ÉÇÉìíë~ã= ëáåÇ= ïÉáíÉê= ÇáÉ= ÄÉáÇÉå= EncodeJcìåâíáçåÉå= EncodeTime= ìåÇ= EncodeDateI= ÇáÉ= ÇáÉ= rãâÉÜêìåÖ= ÇÉê= cìåâíáçåÉå= TimeToStr= ìåÇ= DateToStr= Ç~êëíÉääÉåK= páÉ=âçåîÉêíáÉêÉå=ÉáåÉ=âä~ëëáëÅÜÉ=wÉáíJ=ÄòïK=a~íìãë~åÖ~ÄÉ=áå=ÇáÉ=çÄÉå=Éêï®ÜåJ íÉå=pçåÇÉêÑçêã~íÉK= aáÉ= EncodeTimeJcìåâíáçå= Éêï~êíÉí= îáÉê= Ö~åòò~ÜäáÖÉ= ^åÖ~ÄÉå= áå= îçêÖÉëÅÜêáÉÄÉJ åÉê=oÉáÜÉåÑçäÖÉW=píìåÇÉI=jáåìíÉI=pÉâìåÇÉ=ìåÇ=jáääáëÉâìåÇÉK== a~ê~ìë=ïáêÇ=Ç~åå=Ç~ë=áåíÉêåÉ=rÜêòÉáíJpçåÇÉêÑçêã~í=ÉêòÉìÖíI=ëç=Ç~ëë=òìê=hçåJ íêçääÉ=ïáÉÇÉê=ÇáÉ=oΩÅâï®êíëJhçåîÉêíáÉêìåÖ=ãáííÉäë=TimeToStr=å∏íáÖ=áëíW= ShowMessage(TimeToStr(EncodeTime(8,23,45,00)));
aáÉ= EncodeDateJcìåâíáçå= Éêï~êíÉí= ÇêÉá=Ö~åòò~ÜäáÖÉ=^åÖ~ÄÉå= áå= îçêÖÉëÅÜêáÉÄÉJ åÉê=oÉáÜÉåÑçäÖÉW=g~ÜêI=jçå~íëåìããÉêI=q~ÖÉëåìããÉêK== a~ê~ìë=ïáêÇ=Ç~åå=Ç~ë=áåíÉêåÉ=a~íìãëJpçåÇÉêÑçêã~í=ÉêòÉìÖíI=ëç=Ç~ëë=òìê=hçåJ íêçääÉ=ïáÉÇÉê=ÇáÉ=oΩÅâï®êíëJhçåîÉêíáÉêìåÖ=ãáííÉäë=DateToStr=å∏íáÖ=áëíW= ShowMessage(DateToStr(EncodeDate(2005,10,03)))
_áäÇÉå= ïáê= ÇáÉ= aáÑÑÉêÉåò= òïáëÅÜÉå= áåíÉêåÉå= wÉáíJpçåÇÉêÑçêã~íÉåI= ÉêÜ~äíÉå= ïáê= Ç~ãáí=~ìíçã~íáëÅÜ=ÇáÉ=wÉáíÇáÑÑÉêÉåò=áå=píìåÇÉåI=jáåìíÉå=ìåÇ=pÉâìåÇÉåW= ShowMessage(TimeToStr(EncodeTime(8,23,45,00) EncodeTime(5,43,57,00)) )
OST =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=
== _áäÇ=NPKPW=bêòÉìÖíÉ=áåíÉêåÉ=wÉáí~åÖ~ÄÉI=~ìëÖÉÖÉÄÉå=~äë=píêáåÖ=
== _áäÇ=NPKQW=bêòÉìÖíÉ=áåíÉêåÉ=a~íìãë~åÖ~ÄÉI=~ìëÖÉÖÉÄÉå=~äë=píêáåÖ=
= _áäÇ=NPKRW=wÉáíÇáÑÑÉêÉåò=áåíÉêå=ÄÉêÉÅÜåÉí==
13.2.3
Arithmetische Funktionen
§ÄÉê~ìë= Öêç≈= áëí= Ç~ë= ^åÖÉÄçí= ~å= ~êáíÜãÉíáëÅÜÉå= cìåâíáçåÉå= áå= aÉäéÜáJm~ëÅ~ä= åáÅÜíK=k~íΩêäáÅÜI=Éë=ÖáÄí=Abs=ÑΩê=ÇÉå=_Éíê~ÖI=Ln=ÑΩê=ÇÉå=å~íΩêäáÅÜÉå=içÖ~êáíÜãìëI= Sqr=ÑΩê=ÇáÉ=nì~Çê~íò~ÜäI= Sqrt=ÑΩê=ÇáÉ=nì~Çê~íïìêòÉä=ìåÇ= Sin=ìåÇ= Cos=ÑΩê=ÇáÉ= ÄÉáÇÉå=ÖêìåÇäÉÖÉåÇÉå=íêáÖçåçãÉíêáëÅÜÉå=cìåâíáçåÉåK== ^ääÉ=ÇáÉëÉ=cìåâíáçåÉå=Éêï~êíÉå=ÉáåÉå=w~ÜäÉåïÉêí=çÇÉê=ÇÉå=k~ãÉå=ÉáåÉë=w~ÜJ äÉåëéÉáÅÜÉêéä~íòÉë= ìåÇ= äáÉÑÉêå= ãáí= Ü∏ÅÜëíã∏ÖäáÅÜÉê= dÉå~ìáÖâÉáí= áÜê= bêÖÉÄåáëK= pÉÜÉå=ïáê=ìåë=ëíÉääîÉêíêÉíÉåÇ=~åI=ïáÉ=ÇáÉ=tìêòÉä=~ìë=O=ÖÉòçÖÉå=ïáêÇW== procedure TForm1.Button1Click(Sender: TObject); var zahl, wurzel : Extended; wurzel_str
: String;
begin zahl:=2.0; wurzel:=Sqrt(zahl); Str(wurzel:18:16, wurzel_str); ShowMessage(wurzel_str) end;
OSU= =
NPKO== mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=îçå=aÉäéÜáJm~ëÅ~ä= iÉáÇÉê=ëíÉääí=ìåë=aÉäéÜáJm~ëÅ~ä=âÉáåÉ=cìåâíáçå=òìê=sÉêÑΩÖìåÖI=ãáí=ÇÉê=ïáê=ëçäÅÜ= ÉáåÉ=ÉáåÑ~ÅÜÉ=^ìÑÖ~ÄÉ=ïáÉ=ÇáÉ=_ÉêÉÅÜåìåÖ=îçå=O=ÜçÅÜ=NM=ä∏ëÉå=â∏ååÉåK==
= _áäÇ=NPKSW=tìêòÉä=~ìë=òïÉá= ^ÄÉê=ìåíÉê=sÉêïÉåÇìåÖ=ã~íÜÉã~íáëÅÜÉê=hÉååíåáëëÉ=â∏ååÉå=ïáê=ÇáÉëÉ=^ìÑÖ~ÄÉ= ãáí=eáäÑÉ=ÇÉê=ÄÉáÇÉå=cìåâíáçåÉå= Exp=ìåÇ= Ln=ÇçÅÜ=ä∏ëÉåK=aáÉ=bêÉáÖåáëéêçòÉÇìê= òÉáÖíI=ïáÉ=ïáê=îçêÖÉÜÉå=ãΩëëÉåI=ìåÇ=_áäÇ=NPKT=òÉáÖí=ìåë=Ç~ë=êáÅÜíáÖÉ=bêÖÉÄåáëW= procedure TForm1.Button2Click(Sender: TObject); var basis, exponent, ergebnis: Extended; ergebnis_str: String; begin basis:=2.0; exponent:=10; ergebnis:=Exp(exponent*Ln(basis)); Str(ergebnis:8:1, ergebnis_str);ShowMessage(ergebnis_str) end;
== _áäÇ=NPKTW=òïÉá=ÜçÅÜ=òÉÜå= báåÉ= áåíÉêÉëë~åíÉ= ^åïÉåÇìåÖ= ä®ëëí= ëáÅÜ= Ç~ãáí= éêçÖê~ããáÉêÉåW= táÉ= ÉåíïáÅâÉäí= ëáÅÜ=Éáå=dêìåÇâ~éáí~ä=ÄÉá=ÖÉÖÉÄÉåÉã=wáåëë~íò=áå=ëç=ìåÇ=ëç=îáÉä=g~ÜêÉå\== aÉê=j~íÜÉã~íáâ=ÉåíåÉÜãÉå=ïáê=ÇáÉ=ÉåíëéêÉÅÜÉåÇÉ=cçêãÉäW== (Anzahl der Jahre)
Kapital = Grundkapital*[(1+zinssatz/100)
]
_áäÇ=NPKU=òÉáÖí=ÇáÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉK=páÉ=ÉåíÜ®äí=ÇáÉ=qÉñíÑÉåëíÉê=òìê=báåÖ~ÄÉ= ÇÉê=a~íÉå=ëçïáÉ=ÉáåÉå=_ìííçå=ìåÇ=Éáå=i~ÄÉä=òìê=bêÖÉÄåáë~ìëÖ~ÄÉK== få=ÇÉê=bêÉáÖåáëéêçòÉÇìê=ãΩëëÉå=ïáê=Ç~ÑΩê=ëçêÖÉåI=Ç~ëë=åìê=ÄÉá=ëáååîçääÉå=báåJ Ö~ÄÉÇ~íÉå=EÄÉá=âçåîÉêíáÉêÄ~êÉå=píêáåÖë=áå=ÇÉå=qÉñíÑÉåëíÉêåF=ÖÉêÉÅÜåÉí=ïáêÇW==
OSV =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= procedure TForm1.Button1Click(Sender: TObject); var grundkap:Extended; grundkap_str:String; grundkap_info:Integer; zinssatz:Extended; zinssatz_str:String; zinssatz_info:Integer; endkap: Extended; endkap_str: String; jahre:Integer; basis, exponent: Extended; begin grundkap_str:=Edit1.Text; zinssatz_str:=Edit2.Text; jahre:=StrToInt(Edit3.Text);
//Edit3 darf nur Ziffern enthalten
Val(grundkap_str,grundkap,grundkap_info);
//Konvertierversuch
Val(zinssatz_str,zinssatz,zinssatz_info); if (grundkap_info=0) and (zinssatz_info=0) then begin basis:=1+zinssatz/100; exponent:=jahre; endkap:=grundkap*Exp(exponent*Ln(basis)); Str(endkap:15:2,endkap_str); Label9.Caption:=endkap_str end end;
a~= ïáê= ÇáÉ= cìåâíáçå= StrToInt= ÑΩê= ÇáÉ= hçåîÉêíáÉêìåÖ= ÇÉë= fåÜ~äíë= ÇÉë= ÇêáííÉå= qÉñíÑÉåëíÉêë= Edit3=áå=ÉáåÉ= IntegerJw~Üä=îÉêïÉåÇÉíÉåI=ãΩëëÉå=ïáê=ãáí=ÉáåÉê=ÄÉJ ëçåÇÉêÉåI=òìë®íòäáÅÜÉå=bêÉáÖåáëéêçòÉÇìê=Ö~ê~åíáÉêÉåI=Ç~ëë=áå=ÇáÉëÉë=qÉñíÑÉåëíÉê= åìê=wáÑÑÉêå=ÉáåÖÉíê~ÖÉå=ïÉêÇÉå=â∏ååÉåW== procedure TForm1.Edit3KeyPress(Sender: TObject; var Key: Char); begin if (Key'9') then Key:=Chr(27) end;
kìå= â∏ååÉå= ïáê= å~ÅÜ= eÉêòÉåëäìëí= êÉÅÜåÉåW= fã= g~ÜêÉ= NMTT= òçÖ= eÉáåêáÅÜ= ÇÉê= sáÉêíÉ=òìê=_ì≈É=ΩÄÉê=ÇáÉ=^äéÉå=å~ÅÜ=`~åçëë~K= OTM= =
NPKP== mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=îáëìÉääÉê=lÄàÉâíÉ= =
= _áäÇ=NPKUW=eÉáåêáÅÜ=ÇÉê=sáÉêíÉ=ÜÉìíÉ= ^åÖÉåçããÉåI= eÉáåêáÅÜ= Ü®ííÉ= Ç~ã~äëI= îçê= VOU= g~ÜêÉåI= áã= sçêÄÉáÖÉÜÉå= åìê= ÉáJ åÉå=ÉáåòáÖÉå=bìêçJ`Éåí=áå=^ìÖëÄìêÖ=ÄÉáã=_~åâÜ~ìë=cìÖÖÉê=EçÇÉê=ÇÉêÉå=sçêJ Ö®åÖÉêF=ãáí=P=mêçòÉåí=à®ÜêäáÅÜÉê=sÉêòáåëìåÖ=~åÖÉäÉÖíK== táÉ=êÉáÅÜ=ï®êÉ=Éê=ÇÉåå=ÜÉìíÉ\=_áäÇ=NPKU=âä®êí=ìåë=~ìÑK=tÉê=Ü®ííÉ=Ç~ë=ÖÉÇ~ÅÜíW=U= hçãã~=NU=jáääá~êÇÉå=bìêç=ï®êÉå=Éë=ÜÉìíÉK=pÅÜ~ÇÉI=Ç~ëë=ÇÉê=eÉáåêáÅÜ=Ç~ë=åáÅÜí= ãÉÜê=ÉêäÉÄÉå=â~ååK=
13.3
Prozeduren und Funktionen visueller Objekte
13.3.1
Wiederholung: Visuelle Objekte
bêáååÉêå= ïáê= ìåë= ~å= Ç~ë= pÅÜÉã~I= ãáí= ÇÉëëÉå= eáäÑÉ= ïáê= ìåë= áã= ^ÄëÅÜåáíí= OKNKO= ÇÉã=_ÉÖêáÑÑ=ìåÇ=ÇÉã=sÉêëí®åÇåáë=ÉáåÉë=îáëìÉääÉå=lÄàÉâíë=å®ÜÉêå=âçååíÉåK=aÉê= a~íÉåâÉêå=áëí=ìåãáííÉäÄ~ê=îÉêÄìåÇÉå=ãáí=ÇÉã=ëáÅÜíÄ~êÉå=qÉáäI=ìåÇ=ãáííÉäë=îÉêJ ëÅÜáÉÇÉåÉê=jÉÅÜ~åáëãÉå=áëí=Éë=ã∏ÖäáÅÜI=ãáí=ÇÉã=a~íÉåâÉêå=łìãòìÖÉÜÉåK==
== _áäÇ=NPKVW=sáëìÉääÉë=lÄàÉâí= wì= ÇÉå= éêçéÉêíáÉë= EbáÖÉåëÅÜ~ÑíÉåF= Äê~ìÅÜÉå= ïáê= åáÅÜíë= ãÉÜê= òì= ë~ÖÉåX= ãáí= áÜJ åÉå=Ü~ÄÉå=ïáê=~ìëÑΩÜêäáÅÜ=ÖÉåìÖ=ÖÉ~êÄÉáíÉíK== OTN =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= sçê=~ääÉã=ãáí=ÇÉå=ãÉáëíÖÉÄê~ìÅÜíÉå=éêçéÉêíáÉëI=ÇáÉ=ëçÖ~ê=áå=Ç~ë=oÉÖáëíÉêÄä~íí=bfJ dbkp`e^cqbk=ÇÉê=lÄàÉâíáåëéÉâíçêÉå=~ìÑÖÉåçããÉå=ïìêÇÉåK== páÉ=Éêã∏ÖäáÅÜÉå=ÇÉå=ÇáêÉâíÉå=~âíáîÉå=ìåÇ=é~ëëáîÉå=wìÖêáÑÑ=~ìÑ=ÄÉëíáããíÉ=^åÖ~J ÄÉå=áã=a~íÉåâÉêåK==
13.3.2
Eigenschaften aus der Punktliste: properties
káÅÜí= ~ääÉ= éêçéÉêíáÉë= ëáåÇ= áå= ÇÉã= ÖÉå~ååíÉå= oÉÖáëíÉêÄä~íí= ~ìÑÖÉÑΩÜêíI= ëçåÇÉêå= åìê=ÇáÉ=ïáÅÜíáÖëíÉåK=fã=^ÄëÅÜåáíí=QKTKP=ïìêÇÉ=ëÅÜçå=Éáåã~ä=îçêÖÉÑΩÜêíI=ïáÉ=ïáê= ÇáÉ=k~ãÉå=ïÉáíÉêÉê=éêçéÉêíáÉë=ÑáåÇÉå=â∏ååÉåW=k~ÅÜ=ÇÉã=báåíáééÉå=ÇÉë=mìåâíÉë= ÜáåíÉê=ÇÉã=k~ãÉåë=ÇÉë=îáëìÉääÉå=lÄàÉâíë=EÜáÉê=áëí=Éë=ListBox1F=ãΩëëÉå=ïáê=ÉáåÉ= âå~ééÉ=pÉâìåÇÉ=ï~êíÉåK=a~åå=ÉêëÅÜÉáåí=ÇáÉ=mìåâíäáëíÉK== páÉ= ïáÉÇÉêÜçäí= òìÉêëí= ÇáÉ= ~ìë= ÇÉã= lÄàÉâíáåëéÉâíçê= ÄÉâ~ååíÉå= éêçéÉêíáÉë= E_áäÇ= NPKNMFK= a~ÄÉá= í~ìÅÜí= åáÅÜí= ãÉÜê= Ç~ë= ÇÉìíëÅÜÉ= tçêí= łbáÖÉåëÅÜ~ÑíÉåI= ëçåÇÉêå= ÇáÉ=aÉäéÜáJm~ëÅ~äJsçâ~ÄÉä=property=~ìÑK=
== _áäÇ=NPKNMW=mìåâíäáëíÉ=ãáí=ÄÉâ~ååíÉå=báÖÉåëÅÜ~ÑíÉå= • éêçéÉêíáÉë= EbáÖÉåëÅÜ~ÑíÉåF= ÉêâÉååí= ã~å= áå= ÇÉê= mìåâíäáëíÉ= ~å= ÇÉã= îçê~åÖÉJ ëíÉääíÉå=pÅÜäΩëëÉäïçêí=propertyK=== få=^ÄëÅÜåáíí=QKTKP=ïìêÇÉ=ëÅÜçå=Éáåã~ä=ÖÉëÅÜáäÇÉêíI=ïáÉ=ïáê=ÇìêÅÜ=ÖÉòáÉäíÉ=pìÅÜÉ= áå=ÇÉê=mìåâíäáëíÉ=ÇáÉàÉåáÖÉ=éêçéÉêíó=ÑáåÇÉå=â∏ååÉåI=ãáí=ÇÉêÉå=eáäÑÉ=ÇáÉ=j~êâáÉJ êìåÖ=áå=ÉáåÉê=iáëíÄçñ=~ìë=ÇÉã=a~íÉåâÉêå=ÖÉÜçäí=çÇÉê=áã=a~íÉåâÉêå= îÉê®åÇÉêí= ïÉêÇÉå=â~ååK=_áäÇ=NPKNN=òÉáÖí=ÇáÉ=ÖÉÑìåÇÉåÉå=wÉáäÉK==
== _áäÇ=NPKNNW=éêçéÉêíó=ItemIndex= få=_áäÇNPKNM=ìåÇ=_áäÇ=NPKNN=ëáåÇ=ÇáÉ=ÄÉáÇÉå=wÉáäÉå== property Enabled:Boolean property ItemIndex:Integer
OTO= =
NPKP== mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=îáëìÉääÉê=lÄàÉâíÉ= ÜÉêîçêÖÉÜçÄÉåK= táê= ëÉÜÉåW= _ÉáÇÉ= j~äÉ= ëíÉÜí= ÜáåíÉê= ÇÉã= açééÉäéìåâí= ÇÉê= qóé= ÇÉê= àÉïÉáäáÖÉå= éêçéÉêíóW= aáÉ= éêçéÉêíó= Enabled= ÄÉå∏íáÖíLäáÉÑÉêí= ÉáåÉå= ÇÉê= ÄÉáÇÉå= t~ÜêÜÉáíëïÉêíÉ= True= çÇÉê= FalseI= ÇáÉ= éêçéÉêíó= ItemIndex= ÄÉå∏íáÖíLäáÉÑÉêí= ÉáåÉå= IntegerJtÉêíK== a~ë=áëí=ÇÉê=pÉêîáÅÉ=îçå=aÉäéÜáW= • aáÉ= mìåâíäáëíÉ= ÉêëÉíòí= ìåëI= ïÉåå= ïáê= ëáÉ= ïáëëÉåÇ= ~ìëïÉêíÉå= â∏ååÉåI= ìåíÉê= rãëí®åÇÉå=ÇÉå=òÉáíê~ìÄÉåÇÉå=_äáÅâ=áå=ÉáåÉ=açâìãÉåí~íáçåK===
13.3.3
Funktionen aus der Punktliste
_Éíê~ÅÜíÉå= ïáê= _áäÇ= NPKNM= åçÅÜ= Éáåã~ä= ëÉÜÉå= ïáê= áå= ÇÉê= ìåíÉêëíÉå= wÉáäÉ= Ç~ë= åÉìÉ= pÅÜäΩëëÉäïçêí= functionK= aáÉ= cê~ÖÉI= ïçÜÉê= ïáê= ÉêÑ~ÜêÉåI= ïÉäÅÜÉ= cìåâíáçJ åÉå=Éë=ÖáÄíI=ãáí=ÇÉêÉå=eáäÑÉ= fåÑçêã~íáçåÉå=~ìë=ÇÉã=a~íÉåâÉêå=ÖÉÜçäí=ïÉêÇÉå= â∏ååÉåI=áëí=Ç~ãáí=ÄÉ~åíïçêíÉíW== • jáí=ÇÉã=pÅÜäΩëëÉäïçêí= function=ëáåÇ=áå=ÇÉê=mìåâíäáëíÉ=~ääÉ=îÉêÑΩÖÄ~êÉå=cìåâJ íáçåÉå=ÇÉë=àÉïÉáäáÖÉå=îáëìÉääÉå=lÄàÉâíë=ÖÉâÉååòÉáÅÜåÉíK== tÉåå= ïáê= ÄáëÜÉê= ïáëëÉå= ïçääíÉåI= ïáÉ= îáÉäÉ= wÉáÅÜÉå= ëáÅÜ= áå= ÉáåÉã= qÉñíÑÉåëíÉê= ÄÉÑáåÇÉåI=Ü~ÄÉå=ïáê=ÇÉå=fåÜ~äí=ÇÉë=qÉñíÑÉåëíÉêë=ãáí=ÇÉê=éêçéÉêíó= Text=áå=ÉáåÉå= StringJpéÉáÅÜÉêéä~íò=íê~åëéçêíáÉêíK=a~ê~ìÑ=Ü~ÄÉå=ïáê=ÇáÉ=aÉäéÜáJm~ëÅ~äJcìåâíáçå= Length=~åÖÉï~åÇíK== pÉÜÉå=ïáê=ìåë=~ÄÉê=áå=_áäÇ=NPKNO=ÉáåÉå=^ìëëÅÜåáíí=~ìë=ÇÉê=mìåâíäáëíÉ=òì=ÉáåÉã= qÉñíÑÉåëíÉê=ãáí=ÇÉã=k~ãÉå=Edit1=~åK==
== _áäÇ=NPKNOW=cìåâíáçå=GetTextLen=ÉáåÉë=qÉñíÑÉåëíÉêë= açêí=ÑáåÇÉå=ïáê=í~íë®ÅÜäáÅÜ=ÉáåÉ=cìåâíáçå=ãáí=ÇÉã=k~ãÉå= GetTextLenK=wìÖÉÖÉJ ÄÉåI=çÜåÉ=båÖäáëÅÜJhÉååíåáëëÉ=ìåÇ=ÉáåÉ=ÖÉïáëëÉ=bêÑ~ÜêìåÖ=ïáêÇ=Éë=~åÑ~åÖë=Éáå= ïÉåáÖ= ëÅÜïáÉêáÖ= ëÉáåI= ÖÉòáÉäí= ÇáÉ= mìåâíäáëíÉ= å~ÅÜ= ÉáåÉê= ÄÉëíáããíÉå= cìåâíáçå= ~ÄòìëìÅÜÉå=Ó=~ÄÉê=ìåã∏ÖäáÅÜ=áëí=Éë=åáÅÜíK==== tÉäÅÜÉ=_ÉÇÉìíìåÖ=Ü~í=ÇáÉ=ÜÉêîçêÖÉÜçÄÉåÉ=wÉáäÉ== function GetTextLen: Integer
áå= _áäÇ= NPKNOI= ïáÉ= ãΩëëÉå= ïáê= ëáÉ= äÉëÉå\= aáÉ= ÑÉííÖÉÇêìÅâíÉ= wÉáÅÜÉåÑçäÖÉ= GetTextLen= ÄÉòÉáÅÜåÉí= ÇÉå= k~ãÉå= ÇÉê= cìåâíáçåK= táÉ= ëÅÜçå= ãÉÜêÑ~ÅÜ= ÄÉíçåíI= áëí= ÇáÉ=pÅÜêÉáÄïÉáëÉ=ãáí=ÇÉå=dêç≈J=ìåÇ=häÉáåÄìÅÜëí~ÄÉå=åáÅÜí=ïáÅÜíáÖI=ÉÄÉåëç=Öìí= â∏ååíÉå=ïáê=~ìÅÜ=ëÅÜêÉáÄÉå=geTTEXTlen=çÇÉê=gettEXtLenK== OTP =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= aáÉ= îçå= ÇÉå= aÉäéÜáJpÅÜ∏éÑÉêå= îçêÖÉëÅÜä~ÖÉåÉ= pÅÜêÉáÄïÉáëÉ= ÜÉÄí= àÉÇçÅÜ= Ç~ë= `Ü~ê~âíÉêáëíáëÅÜÉ=ÜÉêîçêI=ï~êìã=ëçääíÉ=ã~å=ëáÉ=åáÅÜí=ΩÄÉêåÉÜãÉå\== eáåíÉê= ÇÉã= k~ãÉå= ïáêÇ= ã~åÅÜã~ä= åçÅÜ= Éáåã~ä= Ç~ë= pÅÜäΩëëÉäïçêí= function= ïáÉÇÉêÜçäíK= cçäÖí= ÇáÉëÉã= pÅÜäΩëëÉäïçêí= ÉáåÉ= áå= êìåÇÉ= çÇÉê= ÉÅâáÖÉ= hä~ããÉêå= ÉáåÖÉëÅÜäçëëÉåÉ=^ìÑò®ÜäìåÖI=ïáêÇ=Ç~ãáí=Éêâä®êíI=Ç~ëë=ÇÉê=cìåâíáçå=ÖÉïáëëÉ=^åJ Ö~ÄÉå=ΩÄÉêÖÉÄÉå=ïÉêÇÉå=ãΩëëÉåI=Ç~ãáí=ëáÉ=áÜê=bêÖÉÄåáë=ÉêãáííÉäå=ìåÇ=ïÉáíÉêJ ÖÉÄÉå=â~ååK=táê=ïÉêÇÉå=ïÉáíÉê=ìåíÉå=ÉáåÉ=páíì~íáçå=ÉêäÉÄÉåI=ïç=ÉáåÉ=ÇÉê~êíáÖÉ= ^åÖ~ÄÉ=åçíïÉåÇáÖ=ïáêÇK== få=_áäÇ=NPKNO=ÑÉÜäí=ÇáÉ=táÉÇÉêÜçäìåÖ=ÇÉë=pÅÜäΩëëÉäïçêíÉë= functionI=ÑçäÖäáÅÜ=ÄÉJ å∏íáÖí=ìåëÉêÉ=cìåâíáçå=GetTextLen=çÑÑÉåëáÅÜíäáÅÜ=âÉáåÉ=^åÖ~ÄÉåK== pÅÜäáÉ≈äáÅÜ= ÑçäÖí= Éáå= açééÉäéìåâí= ìåÇ= ~åëÅÜäáÉ≈ÉåÇ= ÄÉá= ÇÉê= cìåâíáçå= GetTextLen=Ç~ë=pÅÜäΩëëÉäïçêí=IntegerK=a~ãáí=ïáêÇ=ÇÉê=qóé=ÇÉë=bêÖÉÄåáëïÉêíÉë=ÇÉê=cìåâJ íáçå=ÄÉëÅÜêáÉÄÉåK= gÉÇÉê=mêçÖê~ããáÉêÉê=ÉêÑ®Üêí=Ç~ãáíI=Ç~ëë=Éê=ÇÉå=bêÖÉÄåáëïÉêí=îçå= GetTextLen=áå= ÉáåÉå= IntegerJpéÉáÅÜÉêéä~íò=çÇÉê=òK=_K=ãáí=eáäÑÉ=ÇÉê=cìåâíáçå= IntToStr=áå=ÉáåÉ= ^ìëÖ~ÄÉ=äÉåâÉå=â~ååK===
== _áäÇ=NPKNPW=cìåâíáçåëïÉêíJsÉêïÉåÇìåÖ=áå=ÇÉê=bêÉáÖåáëéêçòÉÇìê= _Éíê~ÅÜíÉå=ïáê=ÉáåÉ=âäÉáåÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=ãáí=ÉáåÉã=qÉñíÑÉåëíÉê= Edit1=ìåÇ= ÉáåÉã=i~ÄÉäI=Ç~ë=îçå=aÉäéÜá=ÇÉå=k~ãÉå=Label1=ÉêÜáÉäíK== OTQ= =
NPKP== mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=îáëìÉääÉê=lÄàÉâíÉ= tÉåå=ÇÉê=kìíòÉê=áã=qÉñíÑÉåëíÉê=ÉáåÉ=ûåÇÉêìåÖ=îçêåáããíI=ëçää=~ìíçã~íáëÅÜ=áã= i~ÄÉä=ÇáÉ=~âíìÉääÉ=^åò~Üä=ÇÉê=wÉáÅÜÉå=áã=qÉñíÑÉåëíÉê=ÉêëÅÜÉáåÉåK== aáÉ=bêÉáÖåáëéêçòÉÇìê=ïáêÇ=Ö~åò=âìêòW== procedure TForm1.Edit1Change(Sender: TObject); begin Label1.Caption:=IntToStr(Edit1.getTextLen) end;
_áäÇ= NPKNP= îÉê~åëÅÜ~ìäáÅÜí= ÇÉå= ^Ää~ìÑK= _Éá= ÇÉê= ÉåíëéêÉÅÜÉåÇÉå= kìíòÉêÉáåïáêJ âìåÖ= ïáêÇ= îçã= bêÉáÖåáëÜ®åÇäÉê= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= bêÉáÖåáë= ûåÇÉêìåÖ= áã=qÉñíÑÉåëíÉê=ÖÉÑìåÇÉå=ìåÇ=ÖÉëí~êíÉíK== aáÉ=bêÉáÖåáëéêçòÉÇìê=Üçäí=ëáÅÜ=ãáí=eáäÑÉ=ÇÉê=cìåâíáçå= GetTextLen=~ìë=ÇÉã=a~J íÉåâÉêå= ÇÉë= qÉñíÑÉåëíÉêë= ÇáÉ= i®åÖÉ= ÇÉë= fåÜ~äíëI= îÉê~êÄÉáíÉí= ÇáÉëÉ= ÇìêÅÜ= rãJ ï~åÇäìåÖ= áå= ÉáåÉ= wÉáÅÜÉåÑçäÖÉ= ìåÇ= íê~åëéçêíáÉêí= ÇáÉëÉ= wÉáÅÜÉåÑçäÖÉ= ΩÄÉê= ÇáÉ= ÄÉâ~ååíÉ=éêçéÉêíó=Caption=áå=ÇÉå=a~íÉåâÉêå=ÇÉë=LabelJlÄàÉâíëK== däÉáÅÜòÉáíáÖ= ãáí= ÇÉê= ^åâìåÑí= áå= ÇáÉëÉã= a~íÉåâÉêå= ÉêÑçäÖí= ÇáÉ= ^åòÉáÖÉ= ~äë= _ÉJ ëÅÜêáÑíìåÖ=ÇÉë=i~ÄÉäëK====
13.3.4
Prozeduren aus der Punktliste
kÉÜãÉå= ïáê= ÉáåÉ= iáëíÉ= ãáí= ÇÉã= k~ãÉå= ListBox1I= ÇÉêÉå= fåÜ~äí= åáÅÜí= äÉÉê= ëÉáå= ëçääK= häáÅâí= ÇÉê= kìíòÉê= ~ìÑ= ÉáåÉ= ÄÉëíáããíÉ= wÉáäÉI= ëÉíòí= Éê= ÇáÉ= j~êâáÉêìåÖ= ~ìÑ= ÇáÉëÉ=wÉáäÉ=çÇÉê=ÄÉëí®íáÖí=ÇáÉ=j~êâáÉêìåÖK== táê=ïçääÉå=ìåë=ãáí=ÇÉê=cê~ÖÉ=ÄÉëÅÜ®ÑíáÖÉåI=ïáÉ=ÇÉê=fåÜ~äí=ÉáåÉê=bêÉáÖåáëéêçòÉÇìê= ~ìëëÉÜÉå=ãìëëI=ÇáÉ=òìã=bêÉáÖåáë=häáÅâ=áå=ÇÉê=iáëíÉ=ÇáÉ=~åÖÉâäáÅâíÉ=wÉáäÉ=~ìë=ÇÉê= iáëíÉ=ÉåíÑÉêåí=ìåÇ=ÇáÉ=j~êâáÉêìåÖ=~ìÑ=ÇáÉ=Ç~êΩÄÉê=ëíÉÜÉåÇÉ=wÉáäÉ=ëÉíòíK== cê~ÖÉå=ïáê=òìÉêëí=Ç~ë=oÉÖáëíÉêÄä~íí=bfdbkp`e^cqbk=ÇÉë=lÄàÉâíáåëéÉâíçêë=ÇÉê=iáëíJ ÄçñI=çÄ=Éë=ÉáåÉ=éêçéÉêíó=ÖáÄíI=ÇáÉ=ìåë=ÇáÉ=~âíìÉääÉ=mçëáíáçå=ÇÉê=j~êâáÉêìåÖ=äáÉJ ÑÉêíK=cÉÜä~åòÉáÖÉK=^äëçW=pìÅÜÉ=áå=ÇÉê=mìåâíäáëíÉI=píáÅÜïçêí=éêçéÉêíóK=a~=ïÉêÇÉå= ïáê=ÑΩåÇáÖ=E_áäÇ=NPKNQFK==
== _áäÇ=NPKNQW=éêçéÉêíó=ItemIndex=áå=ÇÉê=mìåâíäáëíÉ= kìå= ÖÉÜí= ÇáÉ= pìÅÜÉ= ïÉáíÉêK= táê= Äê~ìÅÜÉå= łÉíï~ëI= Ç~ë= ÉáåÉ= wÉáäÉ= áå= ÇÉê= iáëíÉ= ä∏ëÅÜíK=fëí=ÇáÉëÉë=łbíï~ë=ìåíÉê=ÇÉå=báÖÉåëÅÜ~ÑíÉåI=ÇÉå=cìåâíáçåÉåI=çÇÉê=ìåíÉê= ÇÉå=mêçòÉÇìêÉå=òì=ëìÅÜÉå\== OTR =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= §ÄÉêäÉÖÉå=ïáêW=a~ë=i∏ëÅÜÉå=ÉáåÉê=wÉáäÉ=áëí=ÉáåÉ=^âíáçåI=ÉáåÉ=táêâìåÖK=cçäÖäáÅÜ= ãΩëëÉå=ïáê=ìåíÉê=ÇÉå=mêçòÉÇìêÉå=ëìÅÜÉåK== qáééÉå= ïáê= ÇÉå= mìåâí= å~ÅÜ= Listbox1= Éáå= ìåÇ= ï~êíÉå= ÇáÉ= pÉâìåÇÉK= báåÉ= cΩääÉ= ~å=mêçòÉÇìêÉå=ïáêÇ=ìåë=Ç~=~åÖÉÄçíÉå=Ó=~ÄÉê=âÉáåÉI=ÇáÉ=áêÖÉåÇïáÉ=îçã=k~ãÉå= ÜÉê=ìåëÉêÉ=^ìÑÖ~ÄÉ=ÉêÑΩääÉå=â∏ååíÉK=t~ë=íìå\== wÉáäÉ=çÇÉê=báåíê~Ö=ÜÉá≈í=~ìÑ=båÖäáëÅÜ= ItemK=^ääÉ=wÉáäÉå=ëáåÇ=ÇáÉ= ItemsK=sáÉääÉáÅÜí= âçããÉå=ïáê=ïÉáíÉêI=ïÉåå=ïáê= ListBox1.Items.=ÉáåíáééÉå=ìåÇ=Ç~åå=ÇáÉ=pÉâìåJ ÇÉ=ï~êíÉå\== fããÉêÜáå= ëíÉÜÉå= áã= oÉÖáëíÉêÄä~íí= bfdbkp`e^cqbk= ÇÉë= lÄàÉâíáåëéÉâíçêë= åÉÄÉå= Items=ÇêÉá=mìåâíÉ=Ó=Ç~ë=ä®ëëí=ÇçÅÜ=~ìÑ=ãÉÜê=ÜçÑÑÉåK=sáÉääÉáÅÜí=~ìÑ=ÉáåÉ=ëÉâìåJ Ç®êÉ=mìåâíäáëíÉK===
= _áäÇ=NPKNRW=mêçòÉÇìê=Delete=áå=ÇÉê=ëÉâìåÇ®êÉå=mìåâíäáëíÉ= _áäÇ=NPKNR=òÉáÖí=ìåëI=Ç~ëë=ïáê=bêÑçäÖ=Ü~ÄÉåK=kìå=ãΩëëÉå=ïáê=åìê=åçÅÜ=ÇáÉ=ÜÉêJ îçêÖÉÜçÄÉåÉ=wÉáäÉ=áåíÉêéêÉíáÉêÉåW= procedure Delete(Index: Integer)
bë= ÖáÄí= êìåÇÉ= hä~ããÉêå= Ó= ÑçäÖäáÅÜ= Äê~ìÅÜí= ÇáÉ= mêçòÉÇìê= òìã= båíÑ~äíÉå= áÜêÉê= táêâìåÖ=ÉáåÉ=IntegerJ^åÖ~ÄÉK=råÇ=Ç~ë=áëíI=î∏ääáÖ=äçÖáëÅÜI=çÑÑÉåëáÅÜíäáÅÜ=ÇáÉ=mçJ ëáíáçå= ÇÉêàÉåáÖÉå= wÉáäÉI= ÇáÉ= îÉêëÅÜïáåÇÉå= ëçääW= cΩê= ÇáÉ= ÉêëíÉ= wÉáäÉ= ÇáÉ= mçëáíáçå= kìääI=ÑΩê=ÇáÉ=òïÉáíÉ=wÉáäÉ=ÇáÉ=mçëáíáçå=báåë=ìåÇ=ëç=ïÉáíÉêK== kìå=â∏ååÉå=ïáê=ìåë=ÇÉå=o~ÜãÉå=ÇÉê=bêÉáÖåáëéêçòÉÇìê=òìã=pí~åÇ~êÇJbêÉáÖåáë= häáÅâ=áå=ÇÉê=iáëíÉ=ÄÉëÅÜ~ÑÑÉå=ìåÇ=ÇÉå=fåÜ~äí=ëÅÜêÉáÄÉåW== procedure TForm1.ListBox1Click(Sender: TObject); var pos: Byte; begin pos:=ListBox1.ItemIndex; Listbox1.Items.Delete(pos); ListBox1.ItemIndex:=pos-1;
//Position der markierten Zeile merken //markierte Zeile löschen //Markierung neu setzen
end;
_áäÇ= NPKNS= îÉê~åëÅÜ~ìäáÅÜí= Ç~ë= sçêÖÉÜÉåW= §ÄÉê= ÇÉå= ła~íÉåâÉêåJj~åáéìäáÉJ êìåÖëJjÉÅÜ~åáëãìë=EéêçéÉêíóF= ItemIndex=ïáêÇ=ÇáÉ=mçëáíáçå=ÇÉê=j~êâáÉêìåÖ=~ìë= ÇÉã=a~íÉåâÉêå=ÖÉÜçäíK==
OTS= =
NPKP== mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=îáëìÉääÉê=lÄàÉâíÉ=
== _áäÇ=NPKNSW=i∏ëÅÜÉå=ÉáåÉê=wÉáäÉ=ìåÇ=åÉìÉ=j~êâáÉêìåÖ== a~å~ÅÜ=â~åå=ãáí=eáäÑÉ=ÇÉë=~åÇÉêÉå=ła~íÉåâÉêåJj~åáéìäáÉêìåÖëJjÉÅÜ~åáëãìë= EéêçÅÉÇìêÉF= Delete= ΩÄÉê= ÉåíëéêÉÅÜÉåÇÉ= sÉê®åÇÉêìåÖ= áã= a~íÉåâÉêå= ÇáÉ= i∏J ëÅÜìåÖ=ÇÉê=wÉáäÉ=ÉêÑçäÖÉåK== pÅÜäáÉ≈äáÅÜ=ïáêÇ=áå=~åÇÉêÉê=oáÅÜíìåÖ=ΩÄÉê=ÇÉå=ła~íÉåâÉêåJj~åáéìäáÉêìåÖëJjÉJ ÅÜ~åáëãìë= EéêçéÉêíóF= ItemIndex= áã= a~íÉåâÉêå= EìåÇ= Ç~ãáí= ~ìÅÜ= ëçÑçêí= áå= ÇÉê= ëáÅÜíÄ~êÉå=iáëíÉF=ÉáåÉ=åÉìÉ=mçëáíáçå=ÇÉê=j~êâáÉêìåÖ=ÉáåÖÉëíÉääíK== cΩê=ÇáÉ=áå=^åÑΩÜêìåÖëòÉáÅÜÉå=ÖÉëÉíòíÉ=sçâ~ÄÉä=ła~íÉåâÉêåJj~åáéìäáÉêìåÖëJjÉJ ÅÜ~åáëãìë=ÖáÄí=Éë=áå=ÇÉê=q~í=ÉáåÉå=ëÉÜê=ïáÅÜíáÖÉå=c~ÅÜ~ìëÇêìÅâ=ÇÉê=fåÑçêã~J íáâK=j~å=ëéêáÅÜí=çÑÑáòáÉää=ìåÇ=âìêò=ìåÇ=íêÉÑÑÉåÇ=îçå=pÅÜåáííëíÉääÉåK=
13.3.5
Schnittstellen
aáÉ= mìåâíäáëíÉ= òì= ÉáåÉã= îáëìÉääÉå= lÄàÉâí= äáÉÑÉêí= ìåíÉê= ÇÉå= pÅÜäΩëëÉäï∏êíÉêå= propertyI= function=ìåÇ= procedure=ÉáåÉ=îçääëí®åÇáÖÉ=§ÄÉêëáÅÜí=ΩÄÉê=ÇáÉ=îçêÜ~åJ ÇÉåÉå=pÅÜåáííëíÉääÉåK== a~ë=ÜÉá≈íI=ÇáÉ=mìåâíäáëíÉ=áåÑçêãáÉêí=ΩÄÉê=ÇáÉ=j∏ÖäáÅÜâÉáíÉå== • ãáííÉäë=ÉáåÉê= property=EÇÉìíëÅÜW=báÖÉåëÅÜ~ÑíF=ÉáåòÉäåÉ=tÉêíÉ=~ìë=ÇÉã=a~íÉåJ âÉêå=òì=ÜçäÉå=ìåÇLçÇÉê=áã=a~íÉåâÉêå=òì=îÉê®åÇÉêåI== • ãáííÉäë=ÉáåÉê= function=EÇÉìíëÅÜW=cìåâíáçåF=ÉáåÉå=ÉáåòÉäåÉå=tÉêí=òì=ÉêÜ~äíÉåI= ÇÉê=ΩÄÉê=ÇáÉ=páíì~íáçå=áã=a~íÉåâÉêå=^ìëâìåÑí=ÖáÄí= OTT =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= • ãáííÉäë= ÉáåÉê= procedure= EÇÉìíëÅÜW= mêçòÉÇìêF= ÉáåÉ= táêâìåÖ= áã= a~íÉåâÉêå= òì= ÉêòáÉäÉåK= a~ÄÉá= ä~ëëÉå= ÇáÉ= báåíê®ÖÉ= áå= ÇÉê= mìåâíäáëíÉ= òìë®íòäáÅÜ= ÉêâÉååÉåI= ïÉäÅÜÉå= qóé= ÇáÉ=~âíáî=çÇÉê=é~ëëáî=ÄÉÜ~åÇÉäíÉå=tÉêíÉ=àÉïÉáäë=Ü~ÄÉåK= wìë®íòäáÅÜ=ÉêÑ®Üêí=ã~åI=çÄ=ÉáåÉ=cìåâíáçå=çÇÉê=ÉáåÉ=mêçòÉÇìê=ÄÉá=áÜêÉê=sÉêïÉåJ ÇìåÖ=çÇÉê=ÄÉá=áÜêÉã=^ìÑêìÑ=òìë®íòäáÅÜÉ=^åÖ~ÄÉå=ÄÉå∏íáÖíI=ÇáÉ=Ç~åå=áå=êìåÇÉå= çÇÉê=ÉÅâáÖÉå=hä~ããÉêå=Éáåòìíê~ÖÉå=ëáåÇK==
13.3.6
Ausnahmen
pÉáí= ÇÉê= båíïáÅâäìåÖ= òì= _ÉÖáåå= ÇÉê= ëáÉÄòáÖÉê= g~ÜêÉ= ~äë= áÇÉ~äÉ= iÉÜêëéê~ÅÜÉ= Ü~í= ÇáÉ=mêçÖê~ããáÉêëéê~ÅÜÉ=m~ëÅ~ä=îáÉäÑ®äíáÖÉ=tÉáíÉêÉåíïáÅâäìåÖÉå=ÇìêÅÜÖÉã~ÅÜíK== pç= ïìêÇÉ= ëáÉ= ÄÉá= báåÄÉííÉå= áå= ÇáÉ= mêçÖê~ããáÉêìãÖÉÄìåÖ= qìêÄç= m~ëÅ~ä= ÑΩê= âçããÉêòáÉääÉ= ^åïÉåÇìåÖÉå= áåíÉêÉëë~åíI= å~íΩêäáÅÜ= â~ãÉå= ~ìÅÜ= ÉáåáÖÉ= åÉìÉ= péê~ÅÜÉäÉãÉåíÉ=ÜáåòìK== aÉäéÜáJm~ëÅ~ä=áëí=ïáÉÇÉê=ÉáåÉ=åÉìÉI=~ííê~âíáîÉ=mêçÖê~ããáÉêìãÖÉÄìåÖK= páÉ=åìíòí=ÇáÉ=dêìåÇáÇÉÉå=ìåÇ=ÇáÉ=oÉÖÉäå=îçå=m~ëÅ~äI=ìã=ÇÉå=rãÖ~åÖ=ãáí=îáJ ëìÉääÉå= lÄàÉâíÉå= òì= Éêã∏ÖäáÅÜÉå= ìåÇ= îáÉäÑ®äíáÖÉ= ìåÇ= äÉáëíìåÖëÑ®ÜáÖÉ= bêÉáÖåáëJ éêçòÉÇìêÉå=ëÅÜêÉáÄÉå=òì=â∏ååÉåK== _Éá= àÉÇÉê= tÉáíÉêÉåíïáÅâäìåÖ= ÖáåÖ= ~ÄÉê= ~ìÅÜ= Éáå= ïÉåáÖ= îçå= ÇÉê= hä~êÜÉáíI= ÇÉê= hçåëÉèìÉåòI=ÇÉê=wáÉäëíêÉÄáÖâÉáí=ÇÉë=ìêëéêΩåÖäáÅÜÉå=m~ëÅ~ä=îÉêäçêÉåK= kìå= ÉêäÉÄÉå= ïáê= ÄáëïÉáäÉå= ~åëíÉääÉ= ÇÉë= łã~å= ãìëë= ÇáÉ= cçêãìäáÉêìåÖ= łã~å= â~åå=ëçI=~ÄÉê=Éë=ÖÉÜí=~ìÅÜ=ëçK= pÉÜÉå=ïáê=Éë=ìåë=~å=òïÉá=_ÉáëéáÉäÉå=~åW== wìã= ^åÑΩÖÉå= ÉáåÉë= String= ~å= ÉáåÉ= iáëíÉ= ÑáåÇÉå= ïáê= å~ÅÜ= ÇÉã= báåíáééÉå= îçå= Listbox1.Items.=ÇáÉ=cìåâíáçå=Add=E_áäÇ=NPKNTFK==
== _áäÇ=NPKNTW=cìåâíáçå=Add== aáÉ=^ìëë~ÖÉ=áëí=âä~êW=eáÉê=Ü~åÇÉäí=Éë=ëáÅÜ=ìã=ÉáåÉ=cìåâíáçåI=ÇáÉ=ÉáåÉ=^åÖ~ÄÉI= å®ãäáÅÜ=ÉáåÉå= StringI=ÄÉå∏íáÖíI=ÇÉå=ëáÉ=ìåíÉå=~å=ÇáÉ=iáëíÉ=~åÜ®åÖíK=páÉ=ÖáÄí=ÉáJ åÉå=IntegerJtÉêí=òìêΩÅâK==
OTU= =
NPKP== mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=îáëìÉääÉê=lÄàÉâíÉ= báå=^ìÑêìÑ=ëÅÜÉáåí=îÉêÄçíÉå=òì=ëÉáåW=aáÉëÉ=cìåâíáçå=â~åå=åìê=ëç=ÖÉåìíòí=ïÉêJ ÇÉåI=Ç~ëë=ÇÉê=oΩÅâÖ~ÄÉïÉêí=áêÖÉåÇïáÉ=îÉêïÉåÇÉí=ïáêÇI=òìã=_ÉáëéáÉäI=áåÇÉã=Éê= áå=ÉáåÉå=é~ëëÉåÇÉå=péÉáÅÜÉêéä~íò=ÖÉäÉåâí=ïáêÇK== açÅÜ=ï~ë=é~ëëáÉêíI=ïÉåå=ÇáÉ=ÑçäÖÉåÇÉ=bêÉáÖåáëéêçòÉÇìê=~ÄÖÉ~êÄÉáíÉí=ïáêÇ\== procedure TForm1.ListBox1Click(Sender: TObject); begin Listbox1.Items.Add('Zusatzzeile');
//Aufruf einer Funktion
end;
hÉáåÉ= cÉÜäÉêãÉäÇìåÖI= âÉáåÉ= _ÉëÅÜïÉêÇÉI= Ç~ëë= ÇÉê= bêÖÉÄåáëïÉêí= åáÅÜí= îÉê~êJ ÄÉáíÉí=ïáêÇK=hä~ëëáëÅÜÉë=m~ëÅ~ä=Ü®ííÉ=Ç~ë=åáÅÜí=ÖÉÇìäÇÉíK== kìå= ÖìíI= îáÉääÉáÅÜí= áëíÛë= Éáå= aêìÅâÑÉÜäÉê= áå= ÇÉê= mìåâíäáëíÉI= ìåÇ= Add= áëí= áå= táêâJ äáÅÜâÉáí=ÉáåÉ=mêçòÉÇìê\=a~åå=ï®êÉ=~ääÉë=áå=lêÇåìåÖK== ^ääÉêÇáåÖë=ãΩëëíÉ=Ç~åå=ÄÉá=ÉáåÉê=îÉêëìÅÜíÉå=sÉêïÉåÇìåÖ=ÇÉë=oΩÅâÖ~ÄÉïÉêíÉë= ÇÉê=cìåâíáçå=ÉáåÉ=cÉÜäÉêãÉäÇìåÖ=âçããÉåK= procedure TForm1.ListBox1Click(Sender: TObject); begin ShowMessage(IntToStr(Listbox1.Items.Add('Zusatzzeile'))); end;
_áäÇ= NPKNU= òÉáÖí= ÉëW= ^åëíÉääÉ= ÇÉê= cÉÜäÉêãÉäÇìåÖ= äáÉÑÉêí= Ç~ë= jáííÉáäìåÖëÑÉåëíÉê= ìåë=çÑÑÉåëáÅÜíäáÅÜ=ÇáÉ=mçëáíáçå=ÇÉê=~åÖÉÑΩÖíÉå=wÉáäÉK==
== _áäÇ=NPKNUW=oΩÅâÖ~ÄÉïÉêí=ÇÉê=cìåâíáçå=Add== táê= Ü~ÄÉå= ÉêäÉÄíW= báåÉ= aÉäéÜáJm~ëÅ~äJcìåâíáçå= Ç~êÑ= ã~åÅÜã~ä= ëçÖ~ê= ~ìÑÖÉêìJ ÑÉå=ïÉêÇÉåK== táê=ïçääÉå=áã=òïÉáíÉå=_ÉáëéáÉä=ÇáÉ=_ÉëÅÜêáÑíìåÖ=ÇÉê=äÉíòíÉå=wÉáäÉ=ÉáåÉê=iáëíÉ=áå= ÉáåÉê=bêÉáÖåáëéêçòÉÇìê=îÉê~êÄÉáíÉåI=ÑçäÖäáÅÜ=ÜçäÉå=çÇÉê=îÉê®åÇÉêåK== _áäÇ=NPKNV=òÉáÖí=ìåë=Ç~ë=bêÖÉÄåáë=ìåëÉêÉê=pìÅÜÉ=áå=ÇÉê=ëÉâìåÇ®êÉå=mìåâíäáëíÉI= å~ÅÜÇÉã=ïáê=Listbox1.Items.=ÉáåÖÉíáééí=ìåÇ=ÉáåÉ=pÉâìåÇÉ=ÖÉï~êíÉí=Ü~ÄÉåK== aáÉ=pÅÜäìëëÑçäÖÉêìåÖ=äáÉÖí=~ìÑ=ÇÉê=e~åÇW==
OTV =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= aáÉ= ^ìÑÖ~ÄÉ= â~åå= åìê= ãáí= ÇÉê= ÑçäÖÉåÇÉå= bêÉáÖåáëéêçòÉÇìê= ìåíÉê= sÉêïÉåÇìåÖ= ÇÉê= éêçéÉêíó= Strings= ÖÉä∏ëí= ïÉêÇÉåI= ëç= ïáÉ= ëáÉ= áå= ÇÉê= mìåâíäáëíÉ= ÇçâìãÉåíáÉêí= áëíW== procedure TForm1.ListBox1Click(Sender: TObject); var lepos: Byte; begin lepos:=Listbox1.Count-1; ShowMessage(Listbox1.Items.Strings[lepos]) end;
= _áäÇ=NPKNVW=éêçéÉêíó=Items.Strings= açÅÜ= ïáÉ= Öêç≈= áëí= ÇáÉ= §ÄÉêê~ëÅÜìåÖI= ïÉåå= ~åÖÉëáÅÜíë= ÉáåÉë= çÑÑÉåëáÅÜíäáÅÜÉå= cÉÜäÉêë= EtÉÖä~ëëÉå= îçå= StringsF= áå= ÑçäÖÉåÇÉê= bêÉáÖåáëéêçòÉÇìê= âÉáåÉ= cÉÜäÉêJ ãÉäÇìåÖ=âçããíW== procedure TForm1.ListBox1Click(Sender: TObject); var lepos: Byte; begin lepos:=Listbox1.Count-1; ShowMessage(Listbox1.Items[lepos])
//Fehler! Strings vergessen.
end;
• aÉäéÜáJm~ëÅ~ä= ä®ëëí= òìê= bêòáÉäìåÖ= ÉáåJ= ìåÇ= ÇÉëëÉäÄÉå= mêçÖê~ããáÉêÉÑÑÉâíë= ÇìêÅÜ~ìë=ãÉÜêÉêÉ=j∏ÖäáÅÜâÉáíÉå=òìK== a~ë= ëÉá= ΩÄêáÖÉåë= ~ìÅÜ= ~ääÉå= iÉëÉêáååÉå= ìåÇ= iÉëÉêå= ÇáÉëÉë= _ìÅÜÉë= ÖÉë~ÖíI= ÇáÉ= ã~åÅÜÉ=aáåÖÉ=Ö~åò=~åÇÉêë=ã~ÅÜÉå=ìåÇ=íêçíòÇÉã=bêÑçäÖ=Ü~ÄÉåK== k~íΩêäáÅÜI=îáÉäÉ=ÇÉê=ÜáåòìÖÉâçããÉåÉå=j∏ÖäáÅÜâÉáíÉå=ëáåÇ=ÄÉèìÉã=ìåÇ=ÉêäÉáÅÜJ íÉêå=Ç~ë=mêçÖê~ããáÉêÉåK=aÉê=hçåëÉèìÉåò=ÇÉê=péê~ÅÜÉ=~ÄÉê=íìå=ëáÉ=åáÅÜí=ÖìíK==
13.4
Simulation einer Supermarkt-Kasse
13.4.1
Aufgabenstellung
^å= ÉáåÉã= Éíï~ë= Öê∏≈ÉêÉå= mêçàÉâí= ïçääÉå= ïáê= Ç~ë= dÉäÉêåíÉ= òìë~ããÉåÑ~ëëÉåÇ= ~åïÉåÇÉåK== OUM= =
NPKQ== páãìä~íáçå=ÉáåÉê=pìéÉêã~êâíJh~ëëÉ= táê=ïçääÉå=ÇáÉ=sçêÖ®åÖÉ=~å=ÉáåÉê=pìéÉêã~êâíJh~ëëÉ=ëáãìäáÉêÉåI=ïçÄÉá=ïáê=~å= ÉáåÉå= ®äíÉêÉå= çÇÉê= ÉáåÑ~ÅÜÉå= pìéÉêã~êâí= ÇÉåâÉå= ëçääíÉåI= ÇÉê= âÉáåÉ= pÅ~ååÉêJ h~ëëÉå=ÄÉëáíòíK== aáÉ=h~ëëáÉêÉêáå=ÄÉå∏íáÖí=ÉáåÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉI=ãáí=ÇÉê=ëáÉ=ã∏ÖäáÅÜëí=ëÅÜåÉääI= ÄÉèìÉã=ìåÇ=òïÉÅâã®≈áÖ=ÇáÉ=^êíáâÉäÄÉòÉáÅÜåìåÖI=ÇÉå=báåòÉäéêÉáëI=ÇáÉ=^åò~Üä= ìåÇ=ÇÉå=jÉÜêïÉêíëíÉìÉêë~íò=àÉÇÉê=t~êÉ=ÉáåÖÉÄÉå=â~åå=E_áäÇ=NPKOMFK== _Éáã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=Übernehmen=ëçää=ÑçäÖÉåÇÉë=ÉêÑçäÖÉåW= • aáÉ=^êíáâÉäÄÉòÉáÅÜåìåÖ=ëçää=áå=ÇÉê=^êíáâÉäJiáëíÉ=~åÖÉÑΩÖí=ïÉêÇÉå= • ^ìë=báåòÉäéêÉáë=ìåÇ=ÉáåÖÉÖÉÄÉåÉê=^åò~Üä=ëçää=ÇÉê=dÉë~ãíéêÉáë=ÉêãáííÉäí=ìåÇ= áå=ÇÉê=òïÉáíÉå=iáëíÉ=ÉáåÖÉíê~ÖÉå=ïÉêÇÉå=Ó=å~íΩêäáÅÜ=åìê=ãáí=ÇÉå=òïÉá=aÉòáJ ã~äëíÉääÉå=ÜáåíÉê=ÇÉã=mìåâíK== • dÉÜ∏êí=ÇÉê=^êíáâÉä=òì=ÇÉå=ãáí=ëáÉÄÉå=mêçòÉåí=jÉÜêïÉêíëíÉìÉê=ÄÉäÉÖíÉå=t~J êÉå=ÇÉë=dêìåÇÄÉÇ~êÑëI=ïáêÇ=ÇáÉ=ÉåíÜ~äíÉåÉ=jÉÜêïÉêíëíÉìÉê=~å=ÇáÉ=ÇêáííÉ=iáëíÉ= ~åÖÉÑΩÖíI=ÇáÉ=îáÉêíÉ=iáëíÉ=ÄÉâçããí=áå=ÇáÉëÉê=wÉáäÉ=ÉáåÉ=kìääK== • rãÖÉâÉÜêí=ïáêÇ=ÇáÉ=ÉåíÜ~äíÉåÉå=jÉÜêïÉêíëíÉìÉê=ÄÉá=ãáí=NS=mêçòÉåí=ÄÉäÉÖíÉå= t~êÉå=~å=ÇáÉ=îáÉêíÉ=iáëíÉ=~åÖÉÑΩÖíK== pç= ÉåíëíÉÜí= ï®ÜêÉåÇ= ÇÉë= h~ëëáÉêîçêÖ~åÖë= áå= ÇÉå= îáÉê= iáëíÉå= ÇÉê= h~ëëÉåòÉííÉäX= ~åÑ~åÖë=ïçääÉå=ïáê=Ççêí=âÉáåÉ=ûåÇÉêìåÖÉå=òìä~ëëÉåI=ÇÉëïÉÖÉå=ëçääÉå=ÇáÉ=iáëJ íÉå=~ìÅÜ=ëíÉíë=áå~âíáî=ëÉáåK==
== _áäÇ=NPKOMW=bêÑ~ëëìåÖëéÜ~ëÉ=ÇÉê=hìåÇÉåï~êÉ= k~ÅÜ=ÇÉê=§ÄÉêå~ÜãÉ=ïÉêÇÉå== • ÇáÉ=báåÖ~ÄÉÑÉåëíÉê=ÑΩê=ÇáÉ=^êíáâÉäÄÉòÉáÅÜåìåÖ=ÖÉä∏ëÅÜíI== • ÇáÉ=^åò~Üä=ïáêÇ=~ìÑ=ÇÉå=pí~åÇ~êÇ=łN=òìêΩÅâÖÉëÉíòíI== • ÇáÉ=jÉÜêïÉêíëíÉìÉê=~ìÑ=ÇáÉ=ΩÄäáÅÜÉå=NS=mêçòÉåí=ÉáåÖÉëíÉääíI== • ÇÉê=cçâìë=ëéêáåÖí=áå=Ç~ë=ÉêëíÉ=báåÖ~ÄÉÑÉåëíÉêX== OUN =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= aáÉ=å®ÅÜëíÉ=t~êÉ=â~åå=ëçÑçêí=ÉêÑ~ëëí=ïÉêÇÉåK== _Éá= ÇÉê= bêÑ~ëëìåÖ= ëçääÉå= ÇìêÅÜ= ÉåíëéêÉÅÜÉåÇÉ= bêÉáÖåáëéêçòÉÇìêÉå= ã∏ÖäáÅÜÉ= ÉäÉãÉåí~êÉ=qáééÑÉÜäÉê=îçå=îçêåÜÉêÉáå=~ìëÖÉëÅÜäçëëÉå=ïÉêÇÉåK== _Éá= ÇÉê= báåÖ~ÄÉ= áå= Ç~ë= qÉñíÑÉåëíÉê= báåòÉäéêÉáë= ïÉêÇÉå= åìê= wáÑÑÉêå= ìåÇ= Ç~ë= hçãã~=~âòÉéíáÉêíX=Ç~ÄÉá=ïáêÇ=Ç~ë=hçãã~=~ìíçã~íáëÅÜ=òìã=mìåâí=ìãÖÉï~åJ ÇÉäíK=c~äëÅÜÉ=q~ëíÉå=ïÉêÇÉå=ÇìêÅÜ=ÇáÉ= Esc Jq~ëíÉ=ÉêëÉíòíK== _Éá=ÇÉê=báåÖ~ÄÉ=áå=Ç~ë=qÉñíÑÉåëíÉê=^åò~Üä=ïÉêÇÉå=åìê=ÇáÉ=wáÑÑÉêåí~ëíÉå=M=Äáë=V= ~âòÉéíáÉêíK=^ääÉ=~åÇÉêÉå=q~ëíÉåÄÉí®íáÖìåÖÉå=ÄäÉáÄÉå=ïáêâìåÖëäçëK== aÉê= _ìííçå= ãáí= ÇÉê= _ÉëÅÜêáÑíìåÖ= = Bezahlen= = ïáêÇ= å~íΩêäáÅÜ= Éêëí= Ç~åå= ëáååîçääI= ïÉåå=ãáåÇÉëíÉåë=Éáå=^êíáâÉä=áå=ÇáÉ=iáëíÉå=~ìÑÖÉåçããÉå=ïìêÇÉK=aÉëÜ~äÄ=áëí=Éê= ~ã=^åÑ~åÖ=ÇÉë=h~ëëáÉêÉåë=áå~âíáî=ìåÇ=ëçää=ëáÅÜ=~ìíçã~íáëÅÜ=Éêëí=Ç~åå=òìëÅÜ~äJ íÉåI=ïÉåå=Éê=ëáååîçää=ïáêÇK== _Éáã= häáÅâ= ~ìÑ= ÇÉå= _ìííçå= _Éò~ÜäÉå= ïÉêÇÉå= òìÉêëí= ÇÉê= _ìííçå= §ÄÉêåÉÜãÉå= ëçïáÉ= ÇáÉ= ÇêÉá= báåÖ~ÄÉÑÉåëíÉê= ÉáåëÅÜäáÉ≈äáÅÜ= o~ÇáçÖêìééÉ= ÑΩê= ÇÉå= jÉÜêïÉêíJ ëíÉìÉêë~íò=áå~âíáîK== aÉê=_ìííçå==Bezahlen==ëÉäÄëí=îÉêëÅÜïáåÇÉíI=Éê=ïáêÇ=åáÅÜí=òïÉáã~ä=ÖÉÄê~ìÅÜíK=
== _áäÇ=NPKONW=k~ÅÜ=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ł_Éò~ÜäÉå= pÉÅÜë= i~ÄÉäë= ïÉêÇÉå= Ç~ÑΩê= ëáÅÜíÄ~êW= aêÉá= Éêâä®êÉåÇÉ= _ÉëÅÜêáÑíìåÖÉå= ìåÇ= ÇêÉá= i~ÄÉäë=ÑΩê=ÇáÉ=dÉë~ãíëìããÉI=ÇáÉ=ÇÉê=hìåÇÉ=òì=ò~ÜäÉå=Ü~í=ëçïáÉ=EÑΩê=áÜå=òìê= fåÑçêã~íáçå=ìåÇ=ÑΩê=Ç~ë=cáå~åòJ=çÇÉê=~åÇÉêÉ=ûãíÉêF=ÑΩê=ÇáÉ=áå=ÇÉê=dÉë~ãíëìãJ ãÉ=ÉáåÖÉëÅÜäçëëÉåÉ=jÉÜêïÉêíëíÉìÉêI=ÇáÉ=ëáÅÜ=~ìë=ÇÉå=TJmêçòÉåíJ^êíáâÉäå=ÉêÖ~Ä= ìåÇ=ÇáÉ=~åÇÉêÉI=ÇáÉ=ëáÅÜ=~ìë=ÇÉå=NSJmêçòÉåíJ^êíáâÉäå=ÉêÖ~ÄK== a~ë=áëí=áå=àÉÇÉã=pìéÉêã~êâí=ëç=ΩÄäáÅÜK= fëí=ÇáÉ=_Éò~ÜäìåÖ=ÉêÑçäÖíI=âäáÅâí=ÇáÉ=h~ëëáÉêÉêáå=~ìÑ= Nächster Kunde I=ìåÇ=Ç~ë= ^åÑ~åÖëÄáäÇ= E_áäÇ= NPKOOF= òìê= bêÑ~ëëìåÖ= ÇÉê= t~êÉå= ÉêëÅÜÉáåí= ïáÉÇÉê= ãáí= ÇÉå= pí~åÇ~êÇJbáåëíÉääìåÖÉå= ^åò~Üä= ÖäÉáÅÜ= N= ìåÇ= jtJp~íò= ÖäÉáÅÜ= NSBK= aáÉ= iáëíÉå= ëáåÇ=äÉÉêI=ÇÉê=_Éò~ÜäJ_ìííçå=áëí=áå~âíáîI=Edit1=áëí=ÑçâìëëáÉêíK== OUO= =
NPKQ== páãìä~íáçå=ÉáåÉê=pìéÉêã~êâíJh~ëëÉ= báå=îçêÉáäáÖÉê=häáÅâ=~ìÑ=ÇÉå=_ìííçå= Übernehmen =ÑΩÜêí=òì=ÇÉê=âêáíáëÅÜÉå=oÉ~âJ íáçåI=Ç~ëë=åçÅÜ=âÉáå=Äê~ìÅÜÄ~êÉê=báåòÉäéêÉáë=îçêÜ~åÇÉå=áëí=E_áäÇ=NPKOPF==
= _áäÇ=NPKOOW=k~ÅÜ=ÇÉã=_Éò~ÜäÉåW=k®ÅÜëíÉê=hìåÇÉ=ïáêÇ=Éêï~êíÉí=
== _áäÇ=NPKOPW=§ÄÉêéêΩÑìåÖ=ÇÉë=báåòÉäéêÉáëÉë= dÉåÉêÉää=áëí=åáÅÜí=ëáÅÜÉêI=Ç~ëë=ãáí=ÇÉå=wáÑÑÉêåí~ëíÉå=ìåÇ=ÇÉã=hçãã~=ëíÉíë=Éáå= Äê~ìÅÜÄ~êÉê=báåíê~Ö=áã=qÉñíÑÉåëíÉê=báåòÉäéêÉáë=ÉåíëíÉÜí=Ó=ã~å=ÇÉåâÉ=åìê=~å=ÇáÉ= íêçíò=ÇÉë=tÉÖÑ~åÖÉåë=Ñ~äëÅÜÉê=q~ëíÉå=~âòÉéíáÉêíÉ=wÉáÅÜÉåÑçäÖÉ=1,,34,00K== aÉëÜ~äÄ= ãìëë= ÄÉá= åáÅÜí= âçåîÉêíáÉêÄ~êÉã= báåíê~Ö= áã= báåòÉäéêÉáëJcÉäÇ= ÉáåÉ= é~ëJ ëÉåÇÉ= oÉ~âíáçå= éêçÖê~ããáÉêí= ïÉêÇÉåK= _ÉáëéáÉäëïÉáëÉ= ÉáåÉ= ä~ìíëí~êâÉ= fåÑçêã~J íáçå= ~å= ÇáÉ= h~ëëáÉêÉêáå= ìåÇ= Ç~ë= ~åëÅÜäáÉ≈ÉåÇÉ= cçâìëJoΩÅâëÉíòÉå= áå= Ç~ë= qÉñíJ ÑÉåëíÉêK=
13.4.2
Entwurf der Benutzeroberfläche
fã=_áäÇ=NPKOQ=áëí=ÇáÉ=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=áå=áÜêÉê=båíïìêÑëÑçêã=òì=ëÉÜÉåK=báåáÖÉ= ÇÉê= ãáí= eáäÑÉ= ÇÉë= lÄàÉâíáåëéÉâíçêë= îçêÉáåÖÉëíÉääíÉå= pí~êíJbáÖÉåëÅÜ~ÑíÉå= ëáåÇ= ëÅÜçå= ÉêâÉååÄ~êI= ~åÇÉêÉ= åçÅÜ= åáÅÜíK= iÉíòíÉêÉë= ÄÉíêáÑÑí= îçê= ~ääÉã= ÇáÉ= îçêÉáåÖÉJ ëíÉääíÉ=råëáÅÜíÄ~êâÉáí=ìåÇ=få~âíáîáí®í=ÉáåáÖÉê=îáëìÉääÉê=lÄàÉâíÉK== iáåâë=ìåíÉê=ÇÉã=_ìííçå= Bezahlen =áëí=Éáå=qáãÉê=ÉêâÉååÄ~êX=Éê=ëçää=áã=eáåíÉêJ ÖêìåÇ=ëÅÜåÉää=ãáíä~ìÑÉå=ìåÇ=ëí®åÇáÖ=éêΩÑÉåI=çÄ=ÇÉê=_ìííçå=ëáååîçää=çÇÉê=ìåëáåJ åáÖ=áëí=ìåÇ=áÜå=ÉåíëéêÉÅÜÉåÇ=~âíáîáÉêÉå=çÇÉê=ÇÉ~âíáîáÉêÉåK= OUP =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= =
= _áäÇ=NPKOQW=båíïìêÑ=ÇÉê=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=
13.4.3
Namensvergabe
aÉäéÜá= îÉêÖ~Ä= ÇáÉ= k~ãÉå= ÑΩê= ÇáÉ= píÉìÉêÉäÉãÉåíÉ= áå= ÇÉê= oÉáÜÉåÑçäÖÉI= ïáÉ= ëáÉ= ï®ÜêÉåÇ=ÇÉê=båíïìêÑëéÜ~ëÉ=~ìë=ÇÉå=oÉÖáëíÉêâ~êíÉå=pq^ka^oa=ÄòïK=pvpqbj=ÇÉê= tÉêâòÉìÖäÉáëíÉ=~ìÑ=Ç~ë=cçêãìä~ê=ÖÉòçÖÉå=ïìêÇÉåK== a~ë= qÉñíÑÉåëíÉê= ÑΩê= ÇáÉ= ^êíáâÉäÄÉòÉáÅÜåìåÖ= ÄÉâ~ã= ÑçäÖäáÅÜ= ÇÉå= k~ãÉå= Edit1I= Ç~ë=qÉñíÑÉåëíÉê=ÑΩê=ÇÉå=báåòÉäéêÉáë=ÜÉá≈í=Edit2I=ÑΩê=ÇáÉ=^åò~Üä=Edit3K=aáÉ=o~ÇáçJ ÖêìééÉ=êÉÅÜíë=ÜÉá≈í= RadioGroup1I=ÇáÉ=ÇêÉá=_ìííçåë=îçå=çÄÉå=å~ÅÜ=ìåíÉå=ÜÉá≈Éå= Button1I=Button2=ìåÇ=Button3K== aáÉ= îáÉê= iáëíÉå= ~ã= ìåíÉêÉå= _áäÇê~åÇ= ÜÉá≈Éå= ListBox1= Äáë= ListBox4I= ÇÉê= qáãÉê= íê®Öí=ÇÉå=k~ãÉå=Timer1K== bíï~ë= ìåäçÖáëÅÜI= ~ÄÉê= Éêâä®êÄ~êI= áëí= ÇáÉ= k~ãÉåëîÉêÖ~ÄÉ= ÑΩê= ÇáÉ= ÇêÉá= ^ìëÖ~ÄÉJ i~ÄÉä=Ó=ÇÉåå=áããÉêÜáå=ÄÉÑáåÇÉå=ëáÅÜ=åáÅÜí=ïÉåáÖÉê=~äë=ÇêÉáòÉÜå=i~ÄÉä=~ìÑ=ÇÉã= cçêãìä~êK== pç=ÉêÖ~Ä=Éë=ëáÅÜI=Ç~ëë=Ç~ë=^ìëÖ~ÄÉJi~ÄÉä=ÑΩê=ÇÉå=òì=ò~ÜäÉåÇÉå=_Éíê~Ö=ÇÉå=k~J ãÉå=Label8=ÄÉâ~ã=ìåÇ=ÇáÉ=ÄÉáÇÉå=^ìëÖ~ÄÉJi~ÄÉäë=ÑΩê=ÇáÉ=jÉÜêïÉêíëíÉìÉê~åíÉáJ äÉ=ÄÉâ~ãÉå=îçå=aÉäéÜá=ÇáÉ=k~ãÉå=Label11=ìåÇ=Label13K== ^å= ÇáÉëÉê= píÉääÉ= â∏ååíÉ= ã~å= ëáÅÜ= ÇìêÅÜ~ìë= Ç~êΩÄÉê= ìåíÉêÜ~äíÉåI= ÑΩê= ÇÉê~êíáÖÉ= mêçàÉâíÉ= ÇçÅÜ= îçå= ÇÉê= áã= ^ÄëÅÜåáíí= NKQKO= ~ìëÖÉëéêçÅÜÉåÉå= bãéÑÉÜäìåÖ= ~ÄòìJ ïÉáÅÜÉå= ìåÇ= ÉáÖÉåÉI= ëéêÉÅÜÉåÇÉ= k~ãÉå= ÑΩê= ÇáÉ= píÉìÉêÉäÉãÉåíÉ= òì= îÉêÖÉÄÉåK= aÉåâÄ~ê=ï®êÉå=òìã=_ÉáëéáÉä== • ~åëíÉääÉ=îçå=Label8=ÇÉê=k~ãÉ=sum_lbl= • ~åëíÉääÉ=îçå=Label11=ÇÉê=k~ãÉ=sum7_lbl= • ~åëíÉääÉ=îçå=Label11=ÇÉê=k~ãÉ=sum16_lblK= OUQ= =
NPKQ== páãìä~íáçå=ÉáåÉê=pìéÉêã~êâíJh~ëëÉ=
13.4.4
Ereignisprozeduren
pÉÜÉå= ïáê= ìåë= å~ÅÜÉáå~åÇÉê= ÇáÉ= ëÉÅÜë= bêÉáÖåáëéêçòÉÇìêÉå= ~åI= ÇáÉ= òìê= i∏ëìåÖ= ÇÉê=^ìÑÖ~ÄÉåëíÉääìåÖ=ÄáëÜÉê=~ìëêÉáÅÜÉåK== wìÉêëí=ïçääÉå=ïáê=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=bêÉáÖåáë=q~ëíÉåÇêìÅâ=áã=qÉñíÑÉåëJ íÉê=ÑΩê=ÇÉå=báåòÉäéêÉáë=ÄÉíê~ÅÜíÉåW= procedure TForm1.Edit2KeyPress(Sender: TObject; var Key: Char); begin if (Key'9') then if Key=',' then Key:='.' else Key:=Chr(27) end;
a~åå= éêçÖê~ããáÉêÉå= ïáê= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= bêÉáÖåáë= q~ëíÉåÇêìÅâ= áã= qÉñíÑÉåëíÉê=ÑΩê=ÇáÉ=^åò~ÜäW= procedure TForm1.Edit3KeyPress(Sender: TObject; var Key: Char); begin if (Key'9') then Key:=Chr(27) end;=
_Éá=ÄÉáÇÉå=bêÉáÖåáëéêçòÉÇìêÉå=áëí=òì=ÄÉãÉêâÉåI=Ç~ëë=ïáê=îçå=ÇÉê=^ìëå~ÜãÉêÉJ ÖÉäìåÖ= dÉÄê~ìÅÜ= ÖÉã~ÅÜí= Ü~ÄÉåK= få= ÇÉê= çÄÉêÉå= bêÉáÖåáëéêçòÉÇìê= ëçÖ~ê= ÇêÉáJ ã~äW=áã=g~JwïÉáÖ=ÇÉë=®ì≈ÉêÉå=ÉáåÑ~ÅÜÉå=qÉëíë=ëçïáÉ=áã=g~J=ìåÇ=kÉáåJwïÉáÖ=ÇÉê= áååÉêÉå=^äíÉêå~íáîÉK== aÉê= dÉÄê~ìÅÜ= ÇÉê= ^åïÉáëìåÖëâä~ããÉêå= begin...end= ï®êÉ= ~ÄÉê= ~ìÅÜ= åáÅÜí= Ñ~äëÅÜ=ÖÉïÉëÉåI=ìåÇ=ÑΩê=^åÑ®åÖÉê=îáÉääÉáÅÜí=ÇçÅÜ=ÜáäÑêÉáÅÜW==== procedure TForm1.Edit2KeyPress(Sender: TObject; var Key: Char); begin if (Key'9') then begin if Key=',' then begin Key:='.' end else begin Key:=Chr(27) end end end;
^äë= ÇêáííÉ= bêÉáÖåáëéêçòÉÇìê= ëçää= ÇáÉ= bêÉáÖåáëéêçòÉÇìê= òìã= qáãÉêJbêÉáÖåáë= ÄÉJ íê~ÅÜíÉí= ïÉêÇÉåK= páÉ= éêΩÑí= ÇáÉ= òïÉáíÉ= iáëíÉW= tÉåå= ÇáÉëÉ= iáëíÉ= ãáåÇÉëíÉåë= ÉáåÉ= wÉáäÉ=ÉåíÜ®äíI=áëí=Ç~ë=_Éò~ÜäÉå=ÄÉêÉáíë=ëáååîçääW=
OUR =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= procedure TForm1.Timer1Timer(Sender: TObject); begin if ListBox2.Count>0 then Button2.Enabled:=True else Button2.Enabled:=False end;
hçããÉå= ïáê= òìê= ìãÑ~åÖêÉáÅÜëíÉå= bêÉáÖåáëéêçòÉÇìêI= òìã= bêÉáÖåáë= häáÅâ= ~ìÑ= ÇÉå= _ìííçå= = Übernehmen K= jáí= hçããÉåí~êÉå= ïÉêÇÉå= ÇáÉ= ÉáåòÉäåÉå= qÉáäÉ= ~ìëJ ÑΩÜêäáÅÜ= Éêâä®êíI= ëç= Ç~ëë= ãáí= ÉáåÉê= ^ìëå~ÜãÉ= âÉáåÉ= òìë®íòäáÅÜÉå= bêâä®êìåÖÉå= å∏íáÖ=ëáåÇW== procedure TForm1.Button1Click(Sender: TObject); var art_name
:String;
p_str:String; ep:Double; ep_info:Integer; anz:Byte; mws_satz:Byte; mw:Double;mw_str:String; gp:Double;gp_str:String; begin //Ausführungsteil: zuerst Daten in Sp.-plätze holen art_name:=Edit1.Text;ep_str:=Edit2.Text; anz:=StrToInt(Edit3.Text); if RadioGroup1.ItemIndex=0 then mws_satz:=7 else mws_satz:=16; Val(ep_str,ep,ep_info) if ep_info0 then
;
//Konvertierungsversuche //Reaktion bei unsinnigem Einzelpreis
begin ShowMessage('Preis nicht korrekt eingegeben'); Edit2.SetFocus end else begin
//Reaktion bei sinnvollem Einzelpreis
Listbox1.Items.Append(art_name); gp:=anz*ep;
//Eintrag Artikelbez. //Berechnung Gesamtpreis
Str(gp:9:2,gp_str); Listbox2.Items.Append(gp_str); if mws_satz=7 then
//Eintrag
//Mehrwertsteueranteil
begin mw:=gp*0.07/1.07; Str(mw:9:2,mw_str);
OUS= =
//Erläuterung unten Listbox3.Items.Append(mw_str);
NPKQ== páãìä~íáçå=ÉáåÉê=pìéÉêã~êâíJh~ëëÉ= Listbox4.Items.Append('
0.00')
end else
//Mehrwertsteueranteil
begin mw:=gp*0.16/1.16;
//Erläuterung unten
Str(mw:9:2,mw_str); Listbox4.Items.Append(mw_str); Listbox3.Items.Append('
0.00')
end; Edit1.Text:='';Edit2.Text:='';
//Textfenster löschen
Edit3.Text:='1';RadioGroup1.ItemIndex:=1;
//Standard einstellen
Edit1.SetFocus
//Fokus auf Artikelbezeichnung setzen
end end;
táÉ= ÄÉêÉÅÜåÉí= ã~å= ÇÉå= jÉÜêïÉêíëíÉìÉêJ^åíÉáä= ÄÉá= ÉáåÉã= p~íò= îçå= T= mêçòÉåí\= báå=ïÉåáÖ=_êìÅÜêÉÅÜåìåÖ=ÖÉÑ®ääáÖ\== brutto=netto + 0,07*netto=1,07*nettoI=ÑçäÖäáÅÜ=áëí=netto=brutto/1,07= mw=brutto-netto=brutto-brutto/1,07=brutto*[1-1/1,07]= =brutto*[(1,07-1)/1,07]=brutto*[0,07/1,07]=(brutto*0,07)/1,07
wìê=§ÄìåÖ=ëçääíÉ=ÇÉê=òïÉáÑÉäåÇÉ=iÉëÉê=ãáí=ÇÉêëÉäÄÉå=jÉíÜçÇáâ=ÇáÉ=cçêãÉä=ÑΩê= ÇÉå=jÉÜêïÉêíëíÉìÉê~åíÉáä=ÄÉá=ÇÉå=NSJmêçòÉåíJ^êíáâÉäå=å~ÅÜéêΩÑÉåK=a~ë=bêÖÉÄåáë= ëíÉÜí=áå=ÇÉê=bêÉáÖåáëéêçòÉÇìêK== t~ë=ÑÉÜäí=åçÅÜ\=aáÉ=bêÉáÖåáëéêçòÉÇìê=ÑΩê=ÇÉå=häáÅâ=~ìÑ=ÇÉå=_ìííçå== Bezahlen K= páÉ=ÄÉëíÉÜí=áã=tÉëÉåíäáÅÜÉå=~ìë=pìããÉåÄáäÇìåÖÉåW== procedure TForm1.Button2Click(Sender: TObject); var lepos,i:Byte; sum :Double; sum_str :String; sum7 :Double; sum7_str :String; sum16:Double; sum16_str:String; hilf_str:String;hilf:Double; hilf_info:Integer; begin
//Deaktivieren der Eingabe-Elemente
Button1.Enabled:=False; RadioGroup1.Enabled:=False; Edit1.Enabled:=False; Edit2.Enabled:=False; Edit3.Enabled:=False; //Hervorholen der Ausgabe-Label Label8.Visible:=True;Label9.Visible:=True;
OUT =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= Label10.Visible:=True;Label11.Visible:=True; Label13.Visible:=True;Label13.Visible:=True; //Summen der Listen 2 bis 4 berechnen lepos:=Listbox1.Count-1;sum:=0;sum7:=0;sum16:=0; for i:=0 to lepos do begin hilf_str:=ListBox2.Items[i];Val(hilf_str,hilf,hilf_info); sum:=sum+hilf;
//Konvertierbarkeit ist sicher
hilf_str:=ListBox3.Items[i];Val(hilf_str,hilf,hilf_info); sum7:=sum7+hilf; hilf_str:=ListBox4.Items[i];Val(hilf_str,hilf,hilf_info); sum16:=sum16+hilf; end; //Konvertierung zu Ausgabestrings und Ausgabe Str(sum:9:2,sum_str)
;Label8.Caption :=sum_str;
Str(sum7:9:2,sum7_str) ;Label11.Caption:=sum7_str; Str(sum16:9:2,sum16_str);Label13.Caption:=sum16_str; Button2.Visible:=False;Button3.Visible:=True
// Deaktivierung
end;
rã=ÑΩê=ÇáÉ=pìãã~íáçå=ÇáÉ=ÉáåòÉäåÉå=wÉáäÉå=~ìë=ÇÉå=ÇêÉá=iáëíÉå=òì=ÜçäÉåI=ïìêÇÉ= ÜáÉê=áããÉê=ÇáÉëÉäÄÉ=aêÉáÉêâçãÄáå~íáçå=hilf_strI=hilf=ìåÇ=hilf_info=îÉêïÉåÇÉíK== lÄïçÜä=~ìÑÖêìåÇ=ÇÉê=_ÉäÉÖìåÖ=ÇÉê=iáëíÉå=ëáÅÜÉê=ï~êI=Ç~ëë=ÇÉêÉå=fåÜ~äíÉ=ëíÉíë=òì= w~ÜäÉå=ÖÉã~ÅÜí=ïÉêÇÉå=âçååíÉåI=ãìëëíÉ=áå=ÇÉê=hçåîÉêíáÉêìåÖëJmêçòÉÇìê=ÇÉê=fåJ ÑçJpéÉáÅÜÉêéä~íò=~åÖÉÖÉÄÉå=ïÉêÇÉåK=tÉÖä~ëëÉå=ÑΩÜêí=òì=ÉáåÉê=cÉÜäÉêãÉäÇìåÖK= wìã=pÅÜäìëë=åçÅÜ=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òìã=häáÅâ=~ìÑ=ÇÉå=_ìííçå=ãáí=ÇÉê=_ÉJ ëÅÜêáÑíìåÖ= Nächster Kunde K= få= áÜê= ïÉêÇÉå= ~ìëëÅÜäáÉ≈äáÅÜ= sÉê®åÇÉêìåÖÉå= áå= páÅÜíÄ~êâÉáí=ìåÇ=^âíáîáí®í=ÑÉëíÖÉäÉÖíX=Ö~åò=òìã=pÅÜäìëë=ïáêÇ=ÇÉê=cçâìë=~ìÑ=Ç~ë= qÉñíÑÉåëíÉê=ÑΩê=ÇÉå=^êíáâÉäå~ãÉå=ÖÉêáÅÜíÉíW procedure TForm1.Button3Click(Sender: TObject); begin Label8.Visible :=False; Label9.Visible :=False; Label10.Visible:=False; Label11.Visible:=False; Label13.Visible:=False; Label13.Visible:=False; ListBox1.Clear;ListBox2.Clear; ListBox3.Clear;ListBox4.Clear; Button3.Visible:=False;Button2.Visible:=True;
OUU= =
NPKQ== páãìä~íáçå=ÉáåÉê=pìéÉêã~êâíJh~ëëÉ= Button1.Enabled:=True; RadioGroup1.Enabled:=True; Edit1.Enabled:=True;Edit2.Enabled:=True;Edit3.Enabled:=True; Edit1.SetFocus end;
13.4.5
Erweiterungen
bë=ÜÉêêëÅÜí=âÉáå=j~åÖÉä=~å=ÇáîÉêëÉå=sÉêÄÉëëÉêìåÖëã∏ÖäáÅÜâÉáíÉåK== ^äë= ÉêëíÉë= ãìëë= âçåëí~íáÉêí= ïÉêÇÉåI= Ç~ëë= ÇáÉ= ^åÖ~ÄÉå= ÉáåÉë= Éáåã~ä= ΩÄÉêåçãJ ãÉåÉå=^êíáâÉäë=ÄáëÜÉê=åáÅÜí=âçêêáÖáÉêÄ~ê=ëáåÇK=píÉääÉå=hìåÇÉ=çÇÉê=h~ëëáÉêÉêáå=áå= ÉáåÉê=ÇÉê=iáëíÉå=ÉáåÉå=Ñ~äëÅÜÉå=báåíê~Ö=ÑÉëíI=ãΩëëÉå=ÇáÉ=t~êÉå=ïáÉÇÉê=òìêΩÅâ=áå= ÇÉå=hçêÄK=råÇÉåâÄ~êK= a~=ëçääíÉ=Éáå=ïÉáíÉêÉê=_ìííçå== Korrektur =ÜÉäÑÉåK=bê=~âíáîáÉêí=ÇáÉ=iáëíÉåI=ëç=Ç~ëë= ÇáÉ=Ñ~äëÅÜÉ=wÉáäÉ=~åÖÉï®Üäí=ïÉêÇÉå=â~ååK=k~íΩêäáÅÜ=ëÉíòí=ÉáåÉ=t~Üä=áå=ÉáåÉê=ÇÉê= iáëíÉå=ÖäÉáÅÜ=áå=~ääÉå=îáÉê=iáëíÉå=ÇáÉ=j~êâáÉêìåÖK== aáÉëÉ=^åï~Üä=áå=ÉáåÉê=ÇÉê=îáÉê=iáëíÉå=ã~ÅÜí=Ç~åå=ÉáåÉå=ÑΩåÑíÉå=_ìííçå=ãáí=ÇÉê= ^ìÑëÅÜêáÑí= = Löschen= =òÉáíïÉáäáÖ=ëáÅÜíÄ~êK=k~íΩêäáÅÜ=ëçääíÉ=Ó=~ã=ÄÉëíÉå=òïÉáã~ä=Ó= êΩÅâÖÉÑê~Öí= ïÉêÇÉåI= çÄ= ~ìÅÜ= í~íë®ÅÜäáÅÜ= ÖÉä∏ëÅÜí= ïÉêÇÉå= ëçääK= k~ÅÜ= ÇÉê= i∏J ëÅÜìåÖ= îÉêëÅÜïáåÇÉí= ÇÉê= i∏ëÅÜÄìííçåI= ÇáÉ= iáëíÉå= ïÉêÇÉå= ïáÉÇÉê= áå~âíáîK= råÇ= ëç=ïÉáíÉêK== eÉìíòìí~ÖÉ=áëí=Éë=ΩÄäáÅÜI=Ç~ëë=ÉáåÉ=h~ëëáÉêÉêáå=åáÅÜí=ãÉÜê=ÇÉåâÉå=ìåÇ=êÉÅÜåÉå= ãìëëW=páÉ=íáééí=ÇÉå=tÉêí=ÇÉë=dÉäÇëÅÜÉáåë=ÉáåI=ÇÉå=áÜê=ÇÉê=hìåÇÉ=ÖáÄíI=ìåÇ=ÄÉJ âçããí=ëçÑçêí=Ç~ë=oΩÅâÖÉäÇ=~åÖÉòÉáÖíK=^ìÅÜ=Ç~ë=ï®êÉ=ÉáåÉ=ïÉáíÉêÉ=sÉêÄÉëëÉêìåÖK== råëÉêÉ=ÄáëÜÉêáÖÉ=i∏ëìåÖ=êÉ~ÖáÉêí=~ìÅÜ=Ç~ååI=ïÉåå=Ç~ë=qÉñíÑÉåëíÉê=ÑΩê=ÇáÉ=^êíáJ âÉäÄÉòÉáÅÜåìåÖ= äÉÉê= ÖÉä~ëëÉå= ïáêÇK= tÉê= ÇÉê= jÉáåìåÖ= áëíI= Ç~ëë= Ç~ë= åáÅÜí= òìÖÉJ ä~ëëÉå=ïÉêÇÉå=Ç~êÑI=ÇÉê=ãìëë=ÉåíëéêÉÅÜÉåÇ=ïÉáíÉê=ÉêÖ®åòÉåK== aáÉ= ÄÉäáÉÄíÉ= oΩÅâJ= ìåÇ= i∏ëÅÜí~ëíÉ= Ö~åò= êÉÅÜíë= áå= ÇÉê= wáÑÑÉêåêÉáÜÉI= ΩÄÉê= ÇÉê= båíÉêJq~ëíÉI= ïáêÇ= ÇìêÅÜ= ÇáÉ= ÄÉáÇÉå= bêÉáÖåáëéêçòÉÇìêÉå= òìã= bêÉáÖåáë= q~ëíÉåJ ÇêìÅâ=áå=Edit2=ÄòïK=Edit3=~ì≈Éê=_ÉíêáÉÄ=ÖÉëÉíòíK== c~äëÅÜ=ÉáåÖÉíáééíÉ=wáÑÑÉêåïÉêíÉI=~ìÅÜ=Ç~ë=â~åå=å~íΩêäáÅÜ=é~ëëáÉêÉåI=ãΩëëÉå=~ìÑJ ï®åÇáÖ=âçêêáÖáÉêí=ïÉêÇÉåK=sáÉääÉáÅÜí=áëí=Éë=ÇçÅÜ=ÄÉëëÉêI=~ääÉ=wÉáÅÜÉå=òìê=báåÖ~J ÄÉ= òìòìä~ëëÉå= ìåÇ= Éêëí= ÄÉá= cçâìëîÉêäìëíI= ïÉåå= ÇáÉ= h~ëëáÉêÉêáå= Éíï~ë= ~åÇÉêÉë= Éáåíê~ÖÉå=çÇÉê=ÄÉí®íáÖÉå=ïáääI=ïáÉ=áå=^ÄëÅÜåáíí=NOKQKQ=ÇáÉ=hçåîÉêíáÉêÄ~êâÉáí=ÇÉë= báåíê~ÖÉë=òì=éêΩÑÉå\== wìã=pÅÜäìëë=ÇáÉëÉë=âäÉáåÉå=h~í~äçÖë=~å=^åêÉÖìåÖÉåW=báå=êáÅÜíáÖÉê=h~ëëÉåòÉííÉä= ÉåíÜ®äí=å~íΩêäáÅÜ=ëíÉíë=ÇÉå=báåòÉäéêÉáë=àÉÇÉë=^êíáâÉäëK=h~ìÑíÉ=ÇÉê=hìåÇÉ=ãÉÜêÉêÉ= bñÉãéä~êÉ=ÇáÉëÉë=^êíáâÉäëI=áëí=~ìÅÜ=ÇáÉ=^åò~Üä=~ìÑ=ÇÉã=h~ëëÉåòÉííÉä=îÉêãÉêâíI= ìåÇ=Ç~å~ÅÜ=âçããí=Éêëí=ÇÉê=dÉë~ãíéêÉáëK== OUV =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= aáÉëÉê= ïáêÇ= ΩÄêáÖÉåë= ~ìÅÜ= ìåíÉå= ~ìÑ= ÇÉå= h~ëëÉåòÉííÉä= ÖÉÇêìÅâíI= ÉÄÉåëç= ïáÉ= ÇáÉ=~ìëòìïÉáëÉåÇÉå=jÉÜêïÉêíëíÉìÉê~åíÉáäÉK==== pÅÜäáÉ≈äáÅÜ=ëáåÇ=ïáê=ãáííäÉêïÉáäÉ=òï~ê=Ç~ê~å=ÖÉï∏ÜåíI=Ç~ëë=~ìÑÖêìåÇ=ÇÉê=§ÄÉêJ å~ÜãÉ= îçå= áåíÉêå~íáçå~äÉå= mêçÖê~ããÉå= ~ìÅÜ= áå= aÉìíëÅÜä~åÇ= ÇÉê= aÉòáã~äJ éìåâí= áããÉê= ∏ÑíÉê= ÉêëÅÜÉáåíI= çÄïçÜä= EïáÉ= ÄÉá= ìåëF= ÇáÉ= hçãã~í~ëíÉ= ÖÉÇêΩÅâí= ïìêÇÉK== oáÅÜíáÖ= ÇÉìíëÅÜ= ï®êÉ= ìåëÉêÉ= i∏ëìåÖ= Éêëí= Ç~ååI= ïÉåå= ëçïçÜä= áå= ÇÉå= báåÖ~ÄÉJ ÑÉåëíÉêåI=áå=ÇÉå=bêÖÉÄåáëJi~ÄÉä=ìåÇ=áå=ÇÉå=iáëíÉå=Ç~ë=hçãã~=òì=ëÉÜÉå=ï®êÉK= tÉê= ëáÅÜ= ÇáÉëÉ= sÉêÄÉëëÉêìåÖ= îçêåáããíI= ÇÉê= Ç~êÑ= ëáÅÜ= ~ìÑ= ÜçÜÉå= ^ìÑï~åÇ= ÖÉJ Ñ~ëëí=ã~ÅÜÉåK=aÉåå=îçê=àÉÇÉã=rãÖ~åÖ=ãáí=ÉáåÉê=wÉáÅÜÉåÑçäÖÉ=ÉáåÉë=qÉñíÑÉåëJ íÉêëI= ÉáåÉê= iáëíÉ= çÇÉê= ÉáåÉë= i~ÄÉäë= ãìëë= ÇáÉ= mìåâíJhçãã~JbêëÉíòìåÖ= çÇÉê= hçãã~JmìåâíJbêëÉíòìåÖ= å~ÅÜ= ^ÄëÅÜåáíí= NOKPKP= éêçÖê~ããáÉêí= ïÉêÇÉåK= a~åå= ïáêÇÛë=ÇçÅÜ=òáÉãäáÅÜ=ìåΩÄÉêëáÅÜíäáÅÜK=
13.5
Eigene Prozeduren
a~ë=pÅÜêÉáÄÉå=ÉáÖÉåÉê=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå=ïáêÇ=îçå=ÇÉã=jçãÉåí=~å= ëÅÜïáÉêáÖI=ïÉåå=áå=áÜåÉå=ÖÉïáëëÉ=^åÖ~ÄÉå=îÉê~êÄÉáíÉí=ïÉêÇÉå=ëçääÉåI=ÇáÉ=ÄÉáã= ^ìÑêìÑ=çÇÉê=ÇÉê=sÉêïÉåÇìåÖ=áå=ÇÉå=êìåÇÉå=hä~ããÉêå=ãáíÖÉíÉáäí=ïÉêÇÉå=ãΩëJ ëÉåK=a~åå=ãΩëëÉå=ÄÉáã=mêçÖê~ããáÉêÉå=ëç=ÖÉå~ååíÉ=mä~íòÜ~äíÉê=EÑçêã~äÉ=m~ê~J ãÉíÉêF=îÉêïÉåÇÉí=ïÉêÇÉåK== táê= ïçääÉå= ìåë= ÜáÉê= ãáí= ÉáåÉã= îÉêÖäÉáÅÜëïÉáëÉ= ÉáåÑ~ÅÜÉå= mêçÄäÉã= ÄÉëÅÜ®ÑíáJ ÖÉåI=ÇÉê=o~íáçå~äáëáÉêìåÖ=îçå=pÅÜêÉáÄ~êÄÉáí=ÇìêÅÜ=^ìëä~ÖÉêìåÖ=îçå=áÇÉåíáëÅÜÉå= _ÉÑÉÜäëãÉåÖÉå=áå=ÉáåÉ=ÉáÖÉåÉ=mêçòÉÇìêK= aáÉ=^ìÑÖ~ÄÉåëíÉääìåÖ=áëí=äÉáÅÜí=Éêâä®êíW=^ÅÜí=`ÜÉÅâÄçñÉå=íê~ÖÉå=îçå=êÉÅÜíë=å~ÅÜ= äáåâë=E_áäÇ=NPKORF=ÇáÉ=_ÉëÅÜêáÑíìåÖÉå=NI=OI=QI=UI=NSI=POI=SQ=ìåÇ=NOUK== a~êìåíÉê=ÄÉÑáåÇÉí=ëáÅÜ=Éáå=i~ÄÉä=ãáí=ëÅÜ∏åÉå=Öêç≈Éå=wáÑÑÉêåI=ÄÉáã=_ÉÖáåå=ÇÉê= i~ìÑòÉáí=ãáí=kìää=ÄÉäÉÖíK= dÉëìÅÜí=ëáåÇ=~ÅÜí=bêÉáÖåáëéêçòÉÇìêÉå=ÇÉê~êíI=Ç~ëë=ÄÉá=häáÅâ=~ìÑ=àÉÇÉ=`ÜÉÅâÄçñ= ëíÉíë=ÇáÉ=dÉë~ãíÄáä~åò=ÑÉëíÖÉëíÉääí=ìåÇ=Ç~ãáí=ÇáÉ=~âíìÉääÉ=_óíÉJ_ÉäÉÖìåÖ=~äë=aÉJ òáã~äò~Üä=~ìëÖÉÖÉÄÉå=ïáêÇ=EëáÉÜÉ=^ÄëÅÜåáíí=TKPKNFK== c~åÖÉå=ïáê=ãáí=ÇÉê=bêÉáÖåáëéêçòÉÇìê=òìê=Ö~åò=êÉÅÜíë=ëíÉÜÉåÇÉå=`ÜÉÅâÄçñ=~åW==
= _áäÇ=NPKORW=_ÉåìíòÉêçÄÉêÑä®ÅÜÉ=òìê=_óíÉJ_ÉäÉÖìåÖ= OVM= =
NPKR== báÖÉåÉ=mêçòÉÇìêÉå= procedure TForm1.CheckBox1Click(Sender: TObject); var dual: Byte; begin dual:=0; if Checkbox1.Checked=True then dual:=dual+1; if Checkbox2.Checked=True then dual:=dual+2; if Checkbox3.Checked=True then dual:=dual+4; if Checkbox4.Checked=True then dual:=dual+8; if Checkbox5.Checked=True then dual:=dual+16; if Checkbox6.Checked=True then dual:=dual+32; if Checkbox7.Checked=True then dual:=dual+64; if Checkbox8.Checked=True then dual:=dual+128; Label1.Caption:=IntToStr(dual) end;
kìå=âçããí=ÇáÉ=å®ÅÜëíÉ=bêÉáÖåáëéêçòÉÇìêW== procedure TForm1.CheckBox2Click(Sender: TObject); var dual:Byte; begin dual:=0; if Checkbox1.Checked=True then dual:=dual+1; if Checkbox2.Checked=True then dual:=dual+2; if Checkbox3.Checked=True then dual:=dual+4; if Checkbox4.Checked=True then dual:=dual+8; if Checkbox5.Checked=True then dual:=dual+16; if Checkbox6.Checked=True then dual:=dual+32; if Checkbox7.Checked=True then dual:=dual+64; if Checkbox8.Checked=True then dual:=dual+128; Label1.Caption:=IntToStr(dual) end;
pÉÜÉå=ïáê=ìåë=ÇáÉ=bêÉáÖåáëéêçòÉÇìêÉå=~åI=ëç=ëíÉääÉå=ïáê=ÑÉëíW== • aáÉ=fåÜ~äíÉ=ÄÉáÇÉê=bêÉáÖåáëéêçòÉÇìêÉå=ëáåÇ=~Äëçäìí=áÇÉåíáëÅÜK== råÇI= Ç~ë= ä®ëëí= ëáÅÜ= äÉáÅÜí= ΩÄÉêäÉÖÉåI= ~ìÅÜ= ÇáÉ= ~åÇÉêÉå= ëÉÅÜë= bêÉáÖåáëéêçòÉÇìJ êÉå=ïÉêÇÉå=áã=fååÉêÉå=ÖÉå~ì=ëç=~ìëëÉÜÉåK== a~ë=mêçÖê~ããáÉêÉå=ïáêÇ=òìê=ë~ìÄÉêÉå=hçéáÉê~êÄÉáíI=ëÅÜ~ÇÉ=ìã=ÇáÉ=ëÅÜ∏åÉ=wÉáíK==
OVN =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= a~=áëí=Éë=ÇçÅÜ=îáÉä=ê~íáçåÉääÉêI=Ç~ë= áããÉê=ÖäÉáÅÜÉ=fååÉêÉ=áå=ÉáåÉê=ÉáÖÉåÉå=mêçJ òÉÇìê= ~ÄòìäÉÖÉåI= ÇáÉ= ÄÉáëéáÉäëïÉáëÉ= ÇÉå= ëÅÜ∏åÉå= k~ãÉå= auswertung= ÄÉâçãJ ãÉå=â~ååW== procedure TForm1.auswertung; var dual:Byte; begin dual:=0; if Checkbox1.Checked=True then dual:=dual+1; if Checkbox2.Checked=True then dual:=dual+2; if Checkbox3.Checked=True then dual:=dual+4; if Checkbox4.Checked=True then dual:=dual+8; if Checkbox5.Checked=True then dual:=dual+16; if Checkbox6.Checked=True then dual:=dual+32; if Checkbox7.Checked=True then dual:=dual+64; if Checkbox8.Checked=True then dual:=dual+128; Label1.Caption:=IntToStr(dual) end;
a~å~ÅÜ= êÉÇìòáÉêÉå= ëáÅÜ= ÇáÉ= ~ÅÜí= ÉáÖÉåíäáÅÜÉå= bêÉáÖåáëéêçòÉÇìêÉå= å®ãäáÅÜ= åìê= åçÅÜ=àÉïÉáäë=~ìÑ=ÇÉå=^ìÑêìÑ=îçå=auswertungW== procedure TForm1.CheckBox1Click(Sender: TObject); begin auswertung end; ................. procedure TForm1.CheckBox8Click(Sender: TObject); begin auswertung end;
^ääÉêÇáåÖë=Ó=ÉáåÉ=p~ÅÜÉ=ÇΩêÑÉå=ïáê=åáÅÜí=îÉêÖÉëëÉåW== • táê=ãΩëëÉå=ìåëÉêÉ=ëÉäÄëí=ÖÉëÅÜêáÉÄÉåÉ=mêçòÉÇìê=çêÇåìåÖëÖÉã®≈=~åãÉäÇÉåK== a~ÑΩê=êáÅÜíÉå=ïáê=ìåëÉêÉå=_äáÅâ=áå=ÇÉê=nìÉääíÉñíJa~íÉá=~ìÑ=ÇÉå=çÄÉêÉå=qÉáä=ìåÇ= ÉêÖ®åòÉå=Ççêí=ÇáÉ=^åãÉäÇìåÖÉå=ÇÉê=~ÅÜí=bêÉáÖåáëéêçòÉÇìêÉåI=ÇáÉ=aÉäéÜá=~ìíçJ ã~íáëÅÜ= ÄÉáã= açééÉäâäáÅâ= ~ìÑ= ÇáÉ= `ÜÉÅâÄçñÉå= îçêå~ÜãI= ÇìêÅÜ= ìåëÉêÉ= ÉáÖÉåÉ= ^åãÉäÇìåÖW== OVO= =
NPKR== báÖÉåÉ=mêçòÉÇìêÉå= ........... type TForm1 = class(TForm) CheckBox1: TCheckBox; CheckBox2: TCheckBox; CheckBox3: TCheckBox; CheckBox4: TCheckBox; CheckBox5: TCheckBox; CheckBox6: TCheckBox; CheckBox7: TCheckBox; CheckBox8: TCheckBox; Label1: TLabel; procedure CheckBox1Click(Sender: TObject); procedure CheckBox2Click(Sender: TObject); procedure CheckBox3Click(Sender: TObject); procedure CheckBox4Click(Sender: TObject); procedure CheckBox5Click(Sender: TObject); procedure CheckBox6Click(Sender: TObject); procedure CheckBox7Click(Sender: TObject); procedure CheckBox8Click(Sender: TObject); procedure auswertung;
//Anmeldung der eigenen Prozedur
private ............
cÉÜäí= ÇáÉëÉ= ^åãÉäÇìåÖ= çÇÉê= áëí= ëáÉ= Ñ~äëÅÜ= ÖÉëÅÜêáÉÄÉåI= íÉáäí= aÉäéÜá= ÄÉáã= sÉêJ ëìÅÜI= ÇáÉ= _ÉåìíòÉêçÄÉêÑä®ÅÜÉ= òì= ÉêòÉìÖÉåI= ÄÉá= i~ìÑòÉáíÄÉÖáååI= ëÉáåÉ= hêáíáâ= ÇìêÅÜ=ÇáÉ=jÉäÇìåÖ= Fehler: undefinierter Bezeichner 'auswertung'
ìåãáëëîÉêëí®åÇäáÅÜ=ãáíK= råÇ=ï~êìã=ãΩëëÉå=ïáê=áå=ÇÉê=çÄÉêëíÉå=hçéÑòÉáäÉ=procedure TForm1.auswertung;= ëÅÜêÉáÄÉå\== a~ë=áëí=Ö~åò=ÉáåÑ~ÅÜ=òì=Éêâä®êÉåK== a~ë=cçêãìä~êI=ÇáÉ=Öêç≈É=eáåíÉêÖêìåÇÑä®ÅÜÉI=áëí=ÄÉâ~ååíäáÅÜ=ÉÄÉåÑ~ääë=Éáå=îáëìJ ÉääÉë=lÄàÉâí=EëK=^ÄëÅÜåáíí=OKOKTFK== a~ë=pí~åÇ~êÇJbêÉáÖåáë=ÑΩê=ÇáÉëÉë=lÄàÉâí=áëí=Ç~ë=bêÉáÖåáë=bêòÉìÖìåÖ=ÇÉë=cçêãìJ ä~êëI=ãáííÉäë=OnCreate=áã=lÄàÉâíáåëéÉâíçê=òì=ëÉÜÉåK==
OVP =
NP=mêçòÉÇìêÉå=ìåÇ=cìåâíáçåÉå= táê=Ü~ÄÉå=ÄáëïÉáäÉå=ÇáÉ=bêÉáÖåáëéêçòÉÇìê=òì=ÇáÉëÉã=bêÉáÖåáë=ÖÉåìíòíI=ìã=ÖÉJ ïáëëÉ=jÉêâã~äÉ=îçå=píÉìÉêÉäÉãÉåíÉå=òìã=pí~êí=ÇÉê=i~ìÑòÉáí=îçêòìÄÉêÉáíÉåI=ÇáÉ= ãáí= eáäÑÉ= ÇÉë= lÄàÉâíáåëéÉâíçêë= åáÅÜí= îçêÄÉêÉáíÉí= ïÉêÇÉå= âçååíÉå= EëK= ^ÄëÅÜåáíí= QKTKRFK= rã=ÇÉå=k~ãÉå=ÇÉë=cçêãìä~êë=Ü~ÄÉå=ïáê=ìåë=ÉáÖÉåíäáÅÜ=åáÉ=ÖÉâΩããÉêíX=ïçòì= ~ìÅÜ\= k~íΩêäáÅÜ= â∏ååÉå= ïáê= áÜå= ~ÄÉê= ~ìÅÜ= áå= ÇÉê= çÄÉêÉå= `çãÄçÄçñ= ÇÉë= lÄJ àÉâíáåëéÉâíçêë=E_áäÇ=NPKOSF=~ÄäÉëÉåK==
== _áäÇ=NPKOSW=k~ãÉ=ÇÉë=îáëìÉääÉå=lÄàÉâíë=Formular= a~ë= cçêãìä~ê= ÄÉâ~ã= îçå= aÉäéÜá= ÇÉå= k~ãÉå= Form1K= råÇ= ëÉÜÉå= ïáê= ìåë= ÇáÉ= mìåâíäáëíÉ=îçå=Form1=áå=_áäÇ=NPKOT=~åW=
== _áäÇ=NPKOTW=mìåâíäáëíÉ=ÇÉë=îáëìÉääÉå=lÄàÉâíë=Form1= gÉÇÉ= mìåâíäáëíÉI= ìåÇ= Ç~ãáí= âÉÜêÉå= ïáê= òìê= hÉêå~ìëë~ÖÉ= ÇÉë= ^ÄëÅÜåáííë= NPKPKR= òìêΩÅâI=ÉåíÜ®äí=Ç~ë=îçääëí®åÇáÖÉ=sÉêòÉáÅÜåáë=~ääÉê=îÉêÑΩÖÄ~êÉå=éêçéÉêíáÉëI=cìåâJ íáçåÉå=ìåÇ=mêçòÉÇìêÉå=ÇÉë=lÄàÉâíëK== aáÉ= ^åãÉäÇìåÖ= ìåëÉêÉê= mêçòÉÇìê= ìåÇ= ÇáÉ= eáåòìÑΩÖìåÖ= ÇÉê= wÉáÅÜÉåÑçäÖÉ= TForm1=òìã=mêçòÉÇìêå~ãÉå=Ó=Ç~ë=áëí=äÉíòíÉåÇäáÅÜ=åáÅÜíë=~åÇÉêë=~äë=ÇáÉ=bêïÉáíÉJ êìåÖ=ÇÉê=jÉåÖÉ=ÇÉê=ÇìêÅÜ=aÉäéÜá=ëÅÜçå=ÄÉêÉáíÖÉëíÉääíÉå=mêçòÉÇìêÉåK== =
OVQ= =
==
14
Mit Delphi: Pascal lernen
^äë= mêçÖê~ããáÉêëéê~ÅÜÉ= ÑΩê= ÇÉå= ~â~ÇÉãáëÅÜÉå= iÉÜêÄÉíêáÉÄ= áëí= m~ëÅ~ä= Éáåëíã~äë= Éåíëí~åÇÉåW= wì= _ÉÖáåå= ÇÉê= páÉÄòáÖÉê= g~ÜêÉ= ïìêÇÉ= ÇáÉëÉ= mêçÖê~ããáÉêëéê~ÅÜÉ= ~å= ÇÉê=báÇÖÉå∏ëëáëÅÜÉå=qÉÅÜåáëÅÜÉå=eçÅÜëÅÜìäÉ=áå=wΩêáÅÜ=îçå=kK=táêíÜ=ÉåíïáÅâÉäíK== ^åÑ~åÖë=ï~ê=ÇÉê=rãÖ~åÖ=ãáí=m~ëÅ~ä=êÉÅÜí=ãΩÜë~ãX=ã~å=ãìëëíÉ=ÑΩê=ÇáÉ=ÉáåòÉäJ åÉå=sÉê~êÄÉáíìåÖëëíìÑÉå=ÉáåÉë=nìÉääíÉñíÉë=å~ÅÜÉáå~åÇÉê=ÇáîÉêëÉ=eáäÑëéêçÖê~ãJ ãÉ=ëí~êíÉå=ìåÇ=Äê~ìÅÜíÉ=îáÉä=wÉáí=Äáë=òìê=eÉêëíÉääìåÖ=ÉáåÉë=ëóåí~âíáëÅÜ=ìåÇ=äçJ ÖáëÅÜ=ÑÉÜäÉêÑêÉáÉå=mêçÖê~ããëK=aÉëïÉÖÉå=ÑêáëíÉíÉ=m~ëÅ~ä=ÉáÖÉåíäáÅÜ=Éáå=pÅÜ~ííÉåJ Ç~ëÉáå=~äë=bñçí=áå=ÇÉê=mêçÖê~ããáÉê~ìëÄáäÇìåÖ=îçå=píìÇÉåíÉåK== a~ë= ®åÇÉêíÉ= ëáÅÜ= ëÅÜä~Ö~êíáÖI= ~äë= _çêä~åÇ= ÉáåÉ= áåíÉÖêáÉêíÉ= båíïáÅâäìåÖëìãÖÉJ ÄìåÖ= ìåíÉê= ÇÉã= k~ãÉå= qìêÄçJm~ëÅ~ä= ÜÉê~ìëÄê~ÅÜíÉI= áå= ÇÉê= Éáå= bÇáíçêI= Éáå= ëÅÜåÉääÉê= ìåÇ= äÉáëíìåÖëÑ®ÜáÖÉê= `çãéáäÉê= ìåÇ= ïÉáíÉêÉ= hçãéçåÉåíÉå= ÖÉåá~ä= òìJ ë~ããÉåÖÉÑ~ëëí=ï~êÉåI=ëç=Ç~ëë=îçå=åìå=~å=ÇÉê=rãÖ~åÖ=ãáí=m~ëÅ~äJmêçÖê~ããÉå= ëÉÜê= ÉáåÑ~ÅÜ= ïìêÇÉ= ìåÇ= m~ëÅ~ä= Ç~ãáí= áå= ÇáÉ= pÅÜìäÉå= ï~åÇÉêå= âçååíÉK= ^ìÅÜ= îáÉäÉ=^åïÉåÇÉê=áå=ÇÉê=mê~ñáë=åìíòíÉå=îçå=åìå=~å=Ç~ë=qìêÄçJm~ëÅ~ä=òìê=pçÑíï~J êÉJmêçÇìâíáçåK== _çêä~åÇ=ëÅÜìÑ=å~íΩêäáÅÜ=åáÅÜí=åìê=ÇáÉëÉ=áåíÉÖêáÉêíÉ=båíïáÅâäìåÖëìãÖÉÄìåÖI=ëçåJ ÇÉêå= ÑΩÖíÉ= ÇÉê= péê~ÅÜÉ= ÉáÖÉåÉ= hçãéçåÉåíÉå= ÜáåòìI= ëç= Ç~ëë= Éë= ÇìêÅÜ~ìë= ÖÉJ êÉÅÜíÑÉêíáÖí=ïìêÇÉI=åáÅÜí=ãÉÜê=îçå=êÉáåÉê=m~ëÅ~äJmêçÖê~ããáÉêìåÖI=ëçåÇÉêå=îçå= mêçÖê~ããáÉêìåÖ=áå=qìêÄçJm~ëÅ~ä=òì=ëéêÉÅÜÉåK== qìêÄçJm~ëÅ~ä= ïìêÇÉ= Äáë= áå= ÇáÉ= åÉìåòáÖÉê= g~ÜêÉ= ÜáåÉáå= âçåíáåìáÉêäáÅÜ= îÉêîçääJ âçããåÉíK= bë= ÉåíïáÅâÉäíÉ= ëáÅÜ= èì~ëá= òì= ÉáåÉã= pí~åÇ~êÇ= áå= ÇÉê= mêçÖê~ããáÉêJ ~ìëÄáäÇìåÖK=fåòïáëÅÜÉå=áëí=Éë=îçå=aÉäéÜá=ïÉáíÖÉÜÉåÇ=~ÄÖÉä∏ëí=ïçêÇÉåI=Éë=ÖáÄí= âÉáåÉ=åÉìÉå=sÉêëáçåÉå=îçå=qìêÄçJm~ëÅ~ä=ãÉÜêK== aáÉ= mêçÖê~ããáÉêìåÖ= îçå= ^åïÉåÇìåÖÉåI= ÇáÉ= ëáÅÜ= ~ìÑ= ëÅÜï~êòÉã= eáåíÉêÖêìåÇ= ãáí=ÉáåÑ~ÅÜÉå=cê~ÖÉå=~å=ÇÉå=kìíòÉê=ïÉåÇÉå=ìåÇ=áÜã=~äë=ÉáåòáÖÉ=oÉ~âíáçå=Ç~ë= báåíáééÉå= îçå= w~ÜäÉå= çÇÉê= qÉñíÉå= Éêä~ìÄÉåI= áëí= ~åÖÉëáÅÜíë= Öê~ÑáâÑ®ÜáÖÉê= c~êÄJ ÄáäÇëÅÜáêãÉ=åáÅÜí=ãÉÜê=òÉáíÖÉã®≈K== qêçíòÇÉã=ã~Ö=ÇáÉëÉê=ìåÇ=àÉåÉê=ÇÉå=qìêÄçJm~ëÅ~äJwÉáíÉå=Éáå=ïÉåáÖ=å~ÅÜíê~ìÉåX= âçååíÉ= ã~å= ÇçÅÜ= ãáí= qìêÄçJm~ëÅ~ä= ÇáÉ= mêáåòáéáÉå= ÇÉê= ëíêìâíìêáÉêíÉå= ìåÇ= ãçJ Çìä~êÉå= mêçÖê~ããáÉêìåÖ= Äáë= Üáå= òìê= çÄàÉâíçêáÉåíáÉêíÉå= mêçÖê~ããáÉêìåÖ= Öìí= äÉÜêÉå=ìåÇ=äÉêåÉåK== aáÉëÉë=h~éáíÉä=ëçää=òÉáÖÉåI=Ç~ëë=~ìÅÜ=aÉäéÜá=ëÉÜê=Öìí=Ç~òì=ÖÉÉáÖåÉí=ëÉáå=â~ååI= ÇáÉ= dêìåÇä~ÖÉå= ÇÉê= m~ëÅ~äJmêçÖê~ããáÉêìåÖI= ëç= ïáÉ= ÑêΩÜÉê= ãáí= qìêÄçJm~ëÅ~äI= òì=äÉÜêÉå=ìåÇ=òì=äÉêåÉåK== OVR =
NQ=jáí=aÉäéÜáW=m~ëÅ~ä=äÉêåÉå=
14.1
Einfache Delphi-Programmierumgebung für Pascal
táÉ=ï~ê=Ç~ë=ÑêΩÜÉê=ÄÉá=qìêÄçJm~ëÅ~ä\=gÉÇÉë=_ìÅÜ=ÄÉÖ~åå=Ç~ãáíW=aÉê=^åÑ®åÖÉê= ïìêÇÉ= ~ìëÑΩÜêäáÅÜ= ΩÄÉê= ÇáÉ= íÉÅÜåçäçÖáëÅÜÉå= pÅÜêáííÉ= ìåíÉêêáÅÜíÉíI= ÇáÉ= Éê= ìåíÉêJ åÉÜãÉå=ãìëëíÉI=ÄÉîçê=Éê=ΩÄÉêÜ~ìéí=ÄÉÖáååÉå=âçååíÉI=ëÉáåÉå=nìÉääíÉñí=ÉáåòìJ íáééÉåK=a~åå=ÑçäÖíÉ=jÉáå=ÉêëíÉë=mêçÖê~ãã=Ó=e~ääç=tÉäíI=ìåÇ=~åëÅÜäáÉ≈ÉåÇ=ïìêJ ÇÉ= Éêä®ìíÉêíI= ïáÉ= Éê= ÉáåíáééÉåI= ΩÄÉêëÉíòÉå= ìåÇ= ~ìëÑΩÜêÉå= ä~ëëÉå= â~ååK= råÇ= ëç= ïÉáíÉêK=j~ÅÜÉå=ïáê=Éë=ÖÉå~ì=ëçW== • pÅÜêáíí=NW=táê=ëí~êíÉå=ÉáåÉ=îÉêÑΩÖÄ~êÉ=sÉêëáçå=îçå=aÉäéÜáK= • pÅÜêáíí=O~W=EaÉäéÜáI=sÉêëáçå=T=çÇÉê=ÑêΩÜÉêFW=^ìÑ=ÇáÉ=ÄÉêÉáíë=îçêÜ~åÇÉåÉI=Öê~ìJ ÉI= ÖÉê~ëíÉêíÉ= cä®ÅÜÉ= ãáí= ÇÉê= §ÄÉêëÅÜêáÑí= Form1= òáÉÜÉå= ïáê= îçå= çÄÉå= ~ìë= ÇÉê= oÉÖáëíÉêâ~êíÉ= pq^ka^oa= ÇÉê= hçãéçåÉåíÉåé~äÉííÉ= ãáí= eáäÑÉ= ÇÉë= é~ëëÉåÇÉå= póãÄçäë=ÉáåÉ=pÅÜ~äíÑä®ÅÜÉ=EButtonFW== • pÅÜêáíí= OÄW= EaÉäéÜá= UFW= pçÑÉêå= ÉáåÉ= táääâçããÉåëJpÉáíÉ= áã= wÉåíêìã= ÇÉë= _áäÇJ ëÅÜáêãë= òì= ëÉÜÉå= áëíI= ïáêÇ= ÇáÉëÉ= ÖÉëÅÜäçëëÉåK= ^åëÅÜäáÉ≈ÉåÇ= ïáêÇ= a^qbf= kbr= s`iJclojri^o^ktbkarkd=ÖÉï®ÜäíK== bë=ÉêëÅÜÉáåí=ÉÄÉåÑ~ääë=ÇáÉ=Öê~ìÉI=ÖÉê~ëíÉêíÉ=cä®ÅÜÉ=ãáí=ÇÉê=§ÄÉêëÅÜêáÑí= Form1K= pçÑÉêå=åáÅÜí=îçêÜ~åÇÉåI=ïáêÇ=ãáííÉäë=^kpf`eqqlliJm^ibqqb=ÇáÉ=qççäJm~äÉííÉ= ~ìÑÖÉÄäÉåÇÉí=EãÉáëí=êÉÅÜíë=~ã=_áäÇê~åÇFK=^ìë=ÇÉêÉå=h~íÉÖçêáÉ=pq^ka^oa=ïáêÇ= ãáí=eáäÑÉ=ÇÉë=póãÄçäë=åÉÄÉå=TButton=ÉáåÉ=pÅÜ~äíÑä®ÅÜÉ=EButtonF=~ìÑ=ÇáÉ=Öê~ìÉ= cä®ÅÜÉ=ÖÉòçÖÉåK== • pÅÜêáíí= OÅW= EaÉäéÜá= OMMRFW= pçÑÉêå= ÉáåÉ= táääâçããÉåëJpÉáíÉ= áã= wÉåíêìã= ÇÉë= _áäÇëÅÜáêãë= òì= ëÉÜÉå= áëíI= ïáêÇ= ÇáÉëÉ= ÖÉëÅÜäçëëÉåK= ^åëÅÜäáÉ≈ÉåÇ= ïáêÇ= áã= cÉåëíÉê=qççäJm~äÉííÉ=EãÉáëí=êÉÅÜíë=ìåíÉåF=ÇáÉ=pÅÜ~äíÑä®ÅÜÉ= Kategorien =~åÖÉJ âäáÅâíI=~ìë=ÇÉã=~åÖÉòÉáÖíÉå=^åÖÉÄçí=ïáêÇ=Delphi-Projekte=~ìëÖÉï®ÜäíK== k~ÅÜ= açééÉäâäáÅâ= ~ìÑ= VCL-Formularanwendung= ÉêëÅÜÉáåí= ~ìÅÜ= ÜáÉê= ÇáÉ= Öê~ìÉI= ÖÉê~ëíÉêíÉ=cä®ÅÜÉ=ãáí=ÇÉê=§ÄÉêëÅÜêáÑí=Form1K=pçÑÉêå=åáÅÜí=îçêÜ~åÇÉåI=ïáêÇ=ãáíJ íÉäë= ^kpf`eqqlliJm^ibqqb= ÇáÉ= qççäJm~äÉííÉ= ~ìÑÖÉÄäÉåÇÉí= EãÉáëí= êÉÅÜíë= ~ã= _áäÇê~åÇFK=^ìë=ÇÉêÉå=h~íÉÖçêáÉ=pq^ka^oa=ïáêÇ=ãáí=eáäÑÉ=ÇÉë=póãÄçäë=åÉÄÉå= TButton=ÉáåÉ=pÅÜ~äíÑä®ÅÜÉ=EButtonF=~ìÑ=ÇáÉ=Öê~ìÉ=cä®ÅÜÉ=ÖÉòçÖÉåK==
= _áäÇ=NQKNW=cçêãN=ãáí=_ìííçå=
OVS= =
NQKN== báåÑ~ÅÜÉ=aÉäéÜáJmêçÖê~ããáÉêìãÖÉÄìåÖ=ÑΩê=m~ëÅ~ä= • pÅÜêáíí= PW= kìå= ëçääíÉå= ïáê= ÇáÉ= _ÉëÅÜêáÑíìåÖ= ÇÉë= _ìííçåë= ãáí= eáäÑÉ= ÇÉê= wÉáäÉ= Caption=ÇÉë=lÄàÉâíáåëéÉâíçêë=áå= Start=®åÇÉêåK=_áäÇ=NQKN=òÉáÖí=ÇáÉ=Éåíëí~åÇÉåÉ= páíì~íáçåK== • pÅÜêáíí=QW=báå=açééÉäâäáÅâ=~ìÑ=ÇáÉëÉå=_ìííçå=êÉáÅÜí=Ó=ìåÇ=ëÅÜçå=ÉêÜ~äíÉå=ïáê= Éáå=nìÉääíÉñíJcÉåëíÉê=ãáí=îáÉê=mêçÖê~ããòÉáäÉåI=áå=Ç~ë=áå=ÇáÉ=ÖÉâÉååòÉáÅÜåÉJ íÉå=wïáëÅÜÉåê®ìãÉ=ÇáÉ=sÉêÉáåÄ~êìåÖÉå=ìåÇ=_ÉÑÉÜäÉ=Éáåòìíê~ÖÉå=ëáåÇW== procedure TForm1.Button1Click(Sender: TObject); Platz für Vereinbarungen (falls notwendig) begin Platz für Befehle end; end.
a~=Ç~ë=~ÄëÅÜäáÉ≈ÉåÇÉ=end.=ãáí=ÇÉã=mìåâí=áå=wìâìåÑí=î∏ääáÖ=çÜåÉ=_ÉÇÉìíìåÖ= ÑΩê=ìåë=E~ÄÉê=åáÅÜí=ÑΩê=Ç~ë=aÉäéÜáJpóëíÉãF=ëÉáå=ïáêÇI=ïáêÇ=Éë=~Ä=àÉíòí=ÄÉá=ìåë= åáÅÜí=ãÉÜê=ïáÉÇÉêÖÉÖÉÄÉåK=bë=Ç~êÑ=~ÄÉê=åáÉã~äë=ÖÉä∏ëÅÜí=ïÉêÇÉåK= cΩê=Ç~ë=ÉêëíÉ=mêçÖê~ãã=ëÅÜä~ÖÉå=ïáê=å~íΩêäáÅÜ=îçêI=ÇÉå=_ÉÑÉÜä=~ääÉê=_ÉÑÉÜäÉ= òì=îÉêïÉåÇÉå=Ó=ïÉäÅÜÉë=_ìÅÜ=ÄÉÖáååí=åáÅÜí=ãáí=e~ääç=tÉäíW== procedure TForm1.Button1Click(Sender: TObject); begin ShowMessage('Hallo Welt') end;
• pÅÜêáíí=RW=a~åå=ëçääíÉ=ëÅÜçå=Éáåã~ä=ÖÉΩÄí=ïÉêÇÉåI=ïáÉ=ÖÉëéÉáÅÜÉêí=ïáêÇW= táê=ï®ÜäÉå=òìÉêëí=a^qbf^iibp=pmbf`ebokI= Ç~ÄÉá=ãΩëëÉå=ïáê=ÇÉå=lêÇåÉê= ~ìëï®ÜäÉåI=áå=ÇÉã=ÇáÉ=a~íÉáÉå=ÇÉë=mêçàÉâíë=ÖÉëéÉáÅÜÉêí=ïÉêÇÉå=ëçääÉåK== ^åëÅÜäáÉ≈ÉåÇ= ãΩëëÉå= ïáê= ÖÉå~ì= Ç~ê~ìÑ= ~ÅÜíÉåI= ïÉäÅÜÉ= cê~ÖÉ= ~ã= çÄÉêÉå= o~åÇ=ÇÉë=aá~äçÖÑÉåëíÉêë=ëíÉÜíI=ÇÉåå=ïáê=ãΩëëÉå=ëíÉíë=òïÉá=îÉêëÅÜáÉÇÉåÉ=k~J ãÉå=îÉêÖÉÄÉåK=bêëÅÜÉáåí=Ççêí=å®ãäáÅÜ=ÇáÉ=cê~ÖÉ== = Ç~åå= ëçääíÉ= ~å= ÇÉå= ÄÉ~ÄëáÅÜíáÖíÉå= a~íÉáå~ãÉå= åçÅÜ= Éáå= u= ~åÖÉÜ®åÖí= ïÉêJ ÇÉåX= òìã= _ÉáëéáÉä= â∏ååíÉå= ïáê= ÜáÉê= proj_141u= îÉêÖÉÄÉåK= aáÉ= båÇìåÖ= .pas= âçããí=~ìíçã~íáëÅÜ=Ç~òìK== ^åëÅÜäáÉ≈ÉåÇ= ÑçäÖí= å®ãäáÅÜ= åçÅÜ= ÇáÉ= òïÉáíÉ= cê~ÖÉ= å~ÅÜ= ÉáåÉã= òïÉáíÉå= k~J ãÉåI=ìåÇ=Ç~ë=ïáêÇ=Ç~åå=ëÅÜäáÉ≈äáÅÜ=ÇÉê=ïáÅÜíáÖÉI=ÉáÖÉåíäáÅÜÉ=mêçàÉâíå~ãÉW== ==
OVT =
NQ=jáí=aÉäéÜáW=m~ëÅ~ä=äÉêåÉå= eáÉê=ãΩëëÉå=ïáê=Ç~åå=Ç~ë=îçêÜáå=~åÖÉÜ®åÖíÉ= u=ÄÉáã=báåÖÉÄÉå=ÇÉë=k~ãÉåë= ïÉÖä~ëëÉåI= Ç~ë= ï®êÉ= òìã= _ÉáëéáÉä= åìê= proj_14K= råíÉê= ÇáÉëÉã= k~ãÉå= ïáêÇ= ëé®íÉê=Ç~ë=mêçàÉâí=áããÉê=ïáÉÇÉê=ÖÉ∏ÑÑåÉíK= • pÅÜêáíí= SW= fëí= ÇÉê= nìÉääíÉñí= áå= ÇÉå= a~íÉáÉå= ÉêÑçäÖêÉáÅÜ= ÖÉëéÉáÅÜÉêí= â~åå= Ç~ë= mêçÖê~ãã=ÖÉëí~êíÉí=ïÉêÇÉåK=aÉê=pí~êíîçêÖ~åÖ=ÉêÑçäÖí=áå=òïÉá=píìÑÉåW== wìÉêëí=ãΩëëÉå=ïáê=áå=ÇÉê=ÉêëíÉ=píìÑÉ=ãáí=ÇÉê=pÅÜ~äíÑä®ÅÜÉ==========çÇÉê=ãáí=ÇÉê= q~ëíÉ= F9 =ÇÉå=_ìííçå=~âíáîáÉêÉåK=a~ÄÉá=îÉêëÅÜïáåÇÉå=ÇáÉ=o~ëíÉêéìåâíÉ=~ìÑ= Form1I=ìåÇ=ÇÉê=_ìííçå=ïáêÇ=~åâäáÅâÄ~êK=aáÉ=ëçÖÉå~ååíÉ=i~ìÑòÉáí=ÄÉÖáååíK=== jáí= ÉáåÉã= ïÉáíÉêÉå= häáÅâ= ~ìÑ= ÇÉå= _ìííçå= ïáêÇ= áå= ÇÉê= òïÉáíÉå= píìÑÉ= ëÅÜäáÉ≈J äáÅÜ= Ç~ë= ÖÉëÅÜêáÉÄÉåÉ= mêçÖê~ãã= ÖÉëí~êíÉíI= Éë= âçããí= ÉåíïÉÇÉê= ÉáåÉ= cÉÜäÉêJ ãÉäÇìåÖI=ïÉåå=ÖÉÖÉå=ÇáÉ=oÉÖÉäå=ÇÉê=péê~ÅÜÉ=îÉêëíç≈Éå=ïìêÇÉI=çÇÉê=ÇáÉ=ÄÉJ ~ÄëáÅÜíáÖíÉ=táêâìåÖ=Ó=ÜáÉê=áå=_áäÇ=NQKO=òì=ëÉÜÉå=Ó=íêáíí=ÉáåK==
= = _áäÇ=NQKOW=táêâìåÖ=ÇÉë=e~ääçJtÉäíJmêçÖê~ããë= a~ë=jáííÉáäìåÖëÑÉåëíÉê=ïáêÇ=ÇìêÅÜ=häáÅâ=~ìÑ= OK =ÖÉëÅÜäçëëÉåX=~åëÅÜäáÉ≈ÉåÇ= â∏ååíÉ=ãáí=häáÅâ=~ìÑ=Start=Éáå=åÉìÉê=mêçÖê~ããä~ìÑ=ÖÉëí~êíÉí=ïÉêÇÉåK== táêÇ= Ç~ë= cÉåëíÉê= ÖÉëÅÜäçëëÉåI= ~ìÑ= ÇÉã= ëáÅÜ= ÇÉê= _ìííçå= Start= ÄÉÑáåÇÉíI= ÉêJ ëÅÜÉáåí=ïáÉÇÉê=ÇÉê= nìÉääíÉñí=ÇÉë=m~ëÅ~äJmêçÖê~ããëK=aáÉëÉê=â~åå=îÉê®åÇÉêíI= ΩJ ÄÉê= a^qbf^iibp= pmbf`ebok= ÖÉëéÉáÅÜÉêí= ìåÇ= ~åëÅÜäáÉ≈ÉåÇ= ãáí= ÇÉê= ÄÉëÅÜêáÉÄÉJ åÉå=wïÉáJpÅÜêáííJ^ìëÑΩÜêìåÖëíÉÅÜåçäçÖáÉ=ÉêåÉìí=~ìëÖÉÑΩÜêí=ïÉêÇÉåK== pçääíÉ=ÇÉê=nìÉääíÉñí=åáÅÜí=òì=ëÉÜÉå=ëÉáåI=ÜáäÑí=ÇáÉ=q~ëíÉ= F12 I=ëáÉ=ëÅÜ~äíÉí=òïáJ ëÅÜÉå= ÇÉê= båíïìêÑë~åëáÅÜí= Eáå= aÉäéÜá= U= ëéêáÅÜí= ã~å= îçã= aÉëáÖåÉêF= ãáí= ÇÉã= _ìííçå=ìåÇ=ÇÉã=nìÉääíÉñíÑÉåëíÉê=ìãK== aÉäéÜá= Ñê~Öí= ÄÉáã= _ÉÉåÇÉåI= ïáÉ= ΩÄäáÅÜI= çÄ= ~ääÉë= ÖÉëéÉáÅÜÉêí= ïÉêÇÉå= ëçääK= a~ë= ëçääíÉå=ïáê=áããÉê=éçëáíáî=ÄÉ~åíïçêíÉåK== táêÇ= aÉäéÜá= ÉêåÉìí= ÖÉëí~êíÉíI= ìã= ãáí= ÇÉã= mêçÖê~ãã= ïÉáíÉê= òì= ~êÄÉáíÉå= áëí= å~ÅÜ= a^qbfmolgbhq= £cckbk= ÇÉê= é~ëëÉåÇÉ= lêÇåÉê= òì= ï®ÜäÉå= ìåÇ= ìåÄÉÇáåÖí= ÇÉê=k~ãÉ=ÇÉê=mêçàÉâíÇ~íÉá=EçÜåÉ=~åÖÉÜ®åÖíÉë=uF=òì=ï®ÜäÉåK==
14.2
Ein- und Ausgabe
pÅÜ~ÇÉI=~ÄÉê=ÇáÉ=wÉáíÉå=îçå=Read=ìåÇ=ReadLnI=Write=ìåÇ=WriteLn=ëáåÇ=äÉáÇÉê=îçêJ ÄÉáK== bë= ÖáÄí= ÉÄÉå= ÇçÅÜ= råíÉêëÅÜáÉÇÉ= òïáëÅÜÉå= qìêÄçJm~ëÅ~ä= ìåÇ= aÉäéÜáJm~ëÅ~äK= sáÉäÉ=ëáåÇ=Éë=ï~ÜêÜ~ÑíáÖ=åáÅÜíI=~ÄÉê=ÜáÉê=òÉáÖÉå=ëáÉ=ëáÅÜ=ÇÉìíäáÅÜK=== OVU= =
NQKO== báåJ=ìåÇ=^ìëÖ~ÄÉ=
14.2.1
Ein- und Ausgabe von Zeichenfolgen (Strings)
a~ë= áëí= ÉáåÑ~ÅÜW= báå= ShortStringJpéÉáÅÜÉêéä~íò= çÇÉê= Éáå= StringJpéÉáÅÜÉêéä~íò= EÄÉáÇÉ= åÉÜãÉå= wÉáÅÜÉåÑçäÖÉå= ~ìÑI= ÇÉê= ÉêëíÉ= ~ÄÉê= åìê= ã~ñáã~ä= ORS= wÉáÅÜÉåF= ïáêÇ=ÇìêÅÜ=ÉáåÉ=InputBox=áã=kìíòÉêÇá~äçÖ=ÄÉäÉÖíW== procedure TForm1.Button1Click(Sender: TObject); var tx: ShortString; begin tx:=InputBox('Namenserfassung','Bitte Name eingeben','') end;
= _áäÇ=NQKPW=fåéìíÄçñ= a~ÄÉá=äÉÖíI=ïáÉ=_áäÇ=NQKP=òÉáÖíI=ÇÉê=báåíê~Ö=òïáëÅÜÉå=ÇÉã=ÉêëíÉå=m~~ê=îçå=eçÅÜJ âçãã~ë=ÇÉå=cÉåëíÉêíáíÉä=ÑÉëí=EÜáÉêW= NamenserfassungFI=ÇÉê=báåíê~Ö=òïáëÅÜÉå=ÇÉã= òïÉáíÉå= eçÅÜâçãã~é~~ê= ÑΩÜêí= Ç~òì= òìê= ~ìÑÑçêÇÉêåÇÉå= kìíòÉêáåÑçêã~íáçå== EÜáÉêW=Bitte Name eingebenFI=ÇáêÉâí=ΩÄÉê=ÇÉê=báåÖ~ÄÉòÉáäÉK== dáÄí=Éë=òïáëÅÜÉå=ÇÉã=ÇêáííÉå=eçÅÜâçãã~é~~ê=ÉáåÉå=báåíê~ÖI=ÉêëÅÜÉáåí=ÇáÉëÉê= ~äë=sçê~ÄJ_ÉäÉÖìåÖ=EDefaultJtÉêíF=áå=ÇÉê=báåÖ~ÄÉòÉáäÉ=ìåÇ=â~åå=ÄÉëí®íáÖí=çÇÉê= ΩÄÉêëÅÜêáÉÄÉå=ïÉêÇÉåK== aÉê=fåÜ~äí=ÉáåÉë=StringJ=çÇÉê=ShortStringJpéÉáÅÜÉêéä~íòÉë=ïáêÇ=ãáííÉäë=ShowMessage= ~ìëÖÉÖÉÄÉå=E_áäÇ=NQKQFI=ïçÄÉá=Éêâä®êÉåÇÉê=qÉñí=áå=eçÅÜâçãã~ë=òì=ëÉíòÉå=áëíK== aáÉ= ^ìëÖ~ÄÉòÉáäÉ= ïáêÇ= Ç~åå= ëç= îçêÄÉêÉáíÉíI= Ç~ëë= ÇÉê= ëí~íáëÅÜÉ= qÉñí= Sie trugen ein:=ãáí=ÇÉã=fåÜ~äí=ÇÉë=péÉáÅÜÉêéä~íòÉë=tx=ãáí=ÇÉã=mäìëòÉáÅÜÉå=îÉêâÉííÉí=ïáêÇW== procedure TForm1.Button1Click(Sender: TObject); var tx: ShortString; begin tx:=InputBox('Namenserfassung','Bitte Name eingeben',''); ShowMessage('Sie trugen ein: '+tx) end;
wì=ÄÉ~ÅÜíÉå=áëí=ÜáÉê=áå=ÇÉê=îáÉêíÉå=wÉáäÉ=Ç~ë=íêÉååÉåÇÉ=pÉãáâçäçåK== OVV =
NQ=jáí=aÉäéÜáW=m~ëÅ~ä=äÉêåÉå= • m~ëÅ~äJ_ÉÑÉÜäÉ= ãΩëëÉå= áããÉê= ãáí= ÉáåÉã= pÉãáâçäçå= îçåÉáå~åÇÉê= ÖÉíêÉååí= ïÉêÇÉåK= aáÉ= péêÉÅÜJ= ìåÇ= aÉåâïÉáëÉ= m~ëÅ~äJ_ÉÑÉÜäÉ= ïÉêÇÉå= ãáí= pÉãáâçäçå= ~ÄÖÉëÅÜäçëëÉå=áëí=Ñ~äëÅÜ=ìåÇ=ÑΩÜêí=çÑí=òì=cÉÜäÉêåK==
== _áäÇ=NQKQW=pÜçïjÉëë~ÖÉ=
14.2.2
Ausgabe von ganzen Zahlen (Integer)
báåÉ= ShowMessage=â~åå=áããÉê=åìê=wÉáÅÜÉåÑçäÖÉå=îÉê~êÄÉáíÉåK=cçäÖäáÅÜ=ãìëë=ÇÉê= fåÜ~äí= ÉáåÉë= IntegerJpéÉáÅÜÉêéä~íòÉë= òìÉêëí= áå= ÉáåÉ= wÉáÅÜÉåÑçäÖÉ= ìãÖÉï~åÇÉäí= ïÉêÇÉåI=ÄÉîçê=Éê=~ìëÖÉÖÉÄÉå=ïÉêÇÉå=â~ååK== a~ÑΩê=ÖáÄí=Éë=ÇáÉ=cìåâíáçå=IntToStrW= procedure TForm1.Button1Click(Sender: TObject); var tx: ShortString; nr: Integer; begin nr:=13; tx:=InputBox('Namenserfassung','Bitte Name eingeben',''); ShowMessage('Herr '+tx+' wohnt in Nr. '+IntToStr(nr)) end;
14.2.3
Ausgabe von Dezimalbrüchen (Single, Double, Extended)
cΩê=fåÜ~äíÉ=îçå=péÉáÅÜÉêéä®íòÉå=ÇÉê=ÖÉå~ååíÉå= qóéÉå=ÖáÄí=Éë=~ìÅÜ= hçåîÉêíáÉJ êìåÖëÑìåâíáçåÉåI=îÉêÖäÉáÅÜÄ~ê=ãáí=ÇÉã=IntToStr=ÄÉá=Ö~åòÉå=w~ÜäÉåK== _ÉëëÉê=áëí=Éë=~ÄÉêI=ãáí=eáäÑÉ=ÇÉê=îçêÜÉê=~ìÑòìêìÑÉåÇÉå=hçåîÉêíáÉêìåÖëéêçòÉÇìê= Str=~ìë=ÇÉã=w~ÜäÉåáåÜ~äí=ÉáåÉ=wÉáÅÜÉåÑçäÖÉ=òì=ÉêòÉìÖÉåK== aáÉëÉ=â~åå=Ç~åå=ΩÄÉê=ÉáåÉå= ShortStringJ=çÇÉê= StringJeáäÑëëéÉáÅÜÉêéä~íò=áå=ÇÉê= ShowMessage=îÉê~êÄÉáíÉí=ïÉêÇÉåW=== procedure TForm1.Button1Click(Sender: TObject); var x : Double; x_str: ShortString; begin x:=3.14159; Str(x,x_str); ShowMessage('Die Zahl Pi beginnt mit'+x_str) end;
PMM= =
NQKO== báåJ=ìåÇ=^ìëÖ~ÄÉ= _áäÇ=NQKR=òÉáÖíI=Ç~ëë=ÇáÉ=ëç=éêçÖê~ããáÉêíÉ=^ìëÖ~ÄÉ=åáÅÜí=ëÉÜê=Öìí=~ìëëáÉÜíK==
= _áäÇ=NQKR=táêâìåÖ=ÇÉê=StrJmêçòÉÇìê=çÜåÉ=cçêã~í~åÖ~ÄÉ= aÉëÜ~äÄ= ëçääíÉ= ã~å= ëíÉíë= áå= ÇÉê= StrJmêçòÉÇìê= ïÉáíÉêI= ÇìêÅÜ= açééÉäéìåâíÉ= ÖÉJ íêÉååíI=~åÖÉÄÉåI=ïáÉ=îáÉäÉ=píÉääÉå=áåëÖÉë~ãí=EÉáåëÅÜäáÉ≈äáÅÜ=ÇÉë=aÉòáã~äéìåâíÉë= ÄòïK= ÇÉë= aÉòáã~äâçãã~ë= ÄÉá= aÉäéÜá= UI= ïáÉ= áå= ^ÄëÅÜåáíí= NOKPKP= ~ìëÑΩÜêäáÅÜ= Ç~êÖÉäÉÖíF=ìåÇ=ïáÉ=îáÉäÉ=píÉääÉå=Ç~îçå=å~ÅÜ=ÇÉã=ÇÉòáã~äÉå=qêÉååòÉáÅÜÉå=~ìëJ òìÖÉÄÉå=ëáåÇW= Str(x:7:5,x_str);ShowMessage('Die Zahl Pi beginnt mit'+x_str)
a~åå=ä®ëëí=ëáÅÜ=Ç~ë=bêÖÉÄåáë=~ìÅÜ=ÉåíëéêÉÅÜÉåÇ=Öìí=äÉëÉåI=ïçÄÉá=áå=_áäÇ=NQKS= ÉêâÉååÄ~ê=ïáêÇI=Ç~ëë=åìå=ÜáåíÉê=łãáí=Éáå=iÉÉêòÉáÅÜÉå=ÑÉÜäíK==
== _áäÇ=NQKSW=StrJmêçòÉÇìê=ãáí=cçêã~íëíÉìÉêìåÖ=
14.2.4
Erfassung von ganzen Zahlen und Dezimalbrüchen
báåÉ= InputBox=â~åå=éêáåòáéáÉää=åìê= StringJ=çÇÉê= ShortStringJpéÉáÅÜÉêéä®íòÉ=ÑΩääÉåK= gÉÇÉê=sÉêëìÅÜI=ÇáÉ=InputBox=~äë=nìÉääÉ=ìåÇ=Ç~òì=áêÖÉåÇÉáåÉå=w~ÜäÉåëéÉáÅÜÉêéä~íò= ~äë=wáÉä=òì=îÉêïÉåÇÉåI=ïáÉ=Éë=ÑçäÖÉåÇÉë=mêçÖê~ãã=îÉêëìÅÜíI=ëÅÜä®Öí=ÑÉÜäK== procedure TForm1.Button1Click(Sender: TObject); var x : Double; begin x:=InputBox('Zahleneingabe','Geben Sie eine Zahl ein!','') end;
táê=ÉêÜ~äíÉå=ÉáåÉ=ÉåíëÅÜáÉÇÉåÉ=cÉÜäÉêãÉäÇìåÖ=ÇÉê=ÑçäÖÉåÇÉå=^êíW==
PMN =
NQ=jáí=aÉäéÜáW=m~ëÅ~ä=äÉêåÉå= t~ë=áëí=òì=íìå\== • gÉÇÉ=kìíòÉêÉáåÖ~ÄÉI=çÄ= qÉñí=çÇÉê=w~ÜäI=ãìëë=áããÉê=òìÉêëí= ~äë= wÉáÅÜÉåÑçäÖÉ= áå= ÉáåÉå= ShortStringJçÇÉê= StringJpéÉáÅÜÉêéä~íò= EÄÉá= aÉäéÜá= UW= åìê= StringF= ÖÉÄê~ÅÜí=ïÉêÇÉåK== a~ë=ÖáÄí=âÉáåÉ=hçåÑäáâíÉI=ÇÉåå=Éáå= ShortStringJ=çÇÉê= StringJpéÉáÅÜÉêéä~íò=åáããí= àÉÇÉ=kìíòÉêÉáåÖ~ÄÉ=~åK=d~åò=ÖäÉáÅÜI=çÄ=ëáÉ=~ìëëáÉÜí=ïáÉ=ÉáåÉ=w~Üä=çÇÉê=åáÅÜíK== tΩêÇÉ= ~åëÅÜäáÉ≈ÉåÇ= ~ÄÉê= ëçÑçêí= âêáíáâäçë= îÉêëìÅÜíI= ÇáÉ= kìíòÉêÉáåÖ~ÄÉ= ~äë= w~Üä= áå= ÉáåÉå= w~ÜäÉåëéÉáÅÜÉêéä~íò= òì= íê~åëéçêíáÉêÉåI= ëáåÇ= mêçÖê~ãã~ÄëíΩêòÉ= â~ìã= òì=îÉêãÉáÇÉåK== aÉåå= ïáÉ= ëÅÜåÉää= é~ëëáÉêí= ÉëI= Ç~ëë= ëáÅÜ= Éáå= kìíòÉê= îÉêíáééí= ìåÇ= Éíï~ë= ÉáåÖáÄíI= ï~ë=ëáÅÜ=åáÅÜí=òì=ÉáåÉê=w~Üä=ã~ÅÜÉå=ä®ëëíK=j~å=ÇÉåâÉ=åìê=~å=Ç~ë=ÇÉìíëÅÜÉ=aÉJ òáã~äâçãã~I=Ç~ë=òï~ê=ÑΩê=m~ëÅ~äJbáåÖ~ÄÉå=îÉêÄçíÉå=áëíI=~ÄÉê=ëáÅÜÉê=çÑí=îÉêëÉJ ÜÉåíäáÅÜ=ÄÉåìíòí=ïáêÇK== eáÉê=ÜáäÑí=ÇáÉ=aÉäéÜáJhçåîÉêíáÉêìåÖëéêçòÉÇìê=ValK== Val= îÉêä~åÖí= áããÉê= ÇêÉá= báåíê®ÖÉW= wìÉêëí= îÉêä~åÖí= Val= ÇÉå= k~ãÉå= ÇÉë= ShortStringJ=ÄòïK=StringJpéÉáÅÜÉêéä~íòÉëI=ÇÉê=ÇáÉ=kìíòÉêÉáåÖ~ÄÉ=~äë=wÉáÅÜÉåÑçäÖÉ=~ìÑJ
ÖÉåçããÉå=Ü~íK== a~åå= îÉêä~åÖí= Val= ÇÉå= k~ãÉå=ÇÉë=w~ÜäÉåëéÉáÅÜÉêéä~íòÉëI= áå= ÇÉå= ÇáÉ= òìê= w~Üä= ÖÉã~ÅÜíÉ= wÉáÅÜÉåÑçäÖÉ= EëçÑÉêå= ëáÉ= ëáÅÜ= ΩÄÉêÜ~ìéí= áå= ÉáåÉ= ÉåíëéêÉÅÜÉåÇÉ= w~Üä= âçåîÉêíáÉêÉå=ä®ëëíFI=ÖÉÄê~ÅÜí=ïÉêÇÉå=ëçääK= aáÉëÉê=w~ÜäÉåëéÉáÅÜÉêéä~íò=â~åå=ÄÉá=ÉáåÉã=hçåîÉêíáÉêìåÖëJjáëëÉêÑçäÖ=ÇìêÅÜ~ìë= ~ìÅÜ=äÉÉê=ÄäÉáÄÉåK== pÅÜäáÉ≈äáÅÜ=ïáêÇ=Ç~òì=Éáå=ÇêáííÉêI=Éáå= IntegerJpéÉáÅÜÉêéä~íò=ÄÉå∏íáÖíI=áå=ÇÉã=ÇáÉ= ValJmêçòÉÇìê=ãáííÉáäíI=çÄ=ÇáÉ=hçåîÉêíáÉêìåÖ=ÉêÑçäÖêÉáÅÜ=ï~ê=EfåÜ~äí= gleich= NullF= çÇÉê= çÄ= ÇáÉ= wÉáÅÜÉåÑçäÖÉ= åáÅÜí= òìê= w~Üä= ÖÉã~ÅÜí= ïÉêÇÉå= âçååíÉ= EfåÜ~äí= ungleich NullFK==^äë=mêçÖê~ããáÉêÉê=ãìëë=ã~å=ÑçäÖäáÅÜ=ãáí=ÇÉê=páíì~íáçå=êÉÅÜåÉåI= Ç~ëë=ÇÉê=w~ÜäÉåëéÉáÅÜÉêéä~íò=äÉÉê=ÄäÉáÄÉå=â~ååK=a~ë=Ü®åÖí=Ç~îçå=~ÄI=ï~ë=ÇÉê= kìíòÉê=ÉáåÖáÄíK=a~ë=ÑçäÖÉåÇÉ=mêçÖê~ãã=òÉáÖíI=ïáÉ=îçêòìÖÉÜÉå=áëíW= procedure TForm1.Button1Click(Sender: TObject); var x : Double; x_str: String;x_info: Integer; begin x_str:=InputBox('Zahleneingabe','Geben Sie eine Zahl ein!',''); Val(x_str,x,x_info); //Konvertierungsversuch if x_info=0 then begin // ... hier können Befehle zur Verarbeitung der Zahl stehen ShowMessage('Es war eine Zahl!'); //Beispiel end end;
PMO= =
NQKP== píêìâíìêáÉêíÉë=mêçÖê~ããáÉêÉå=ãáí=m~ëÅ~ä= táää=ã~å=ëáÅÜÉê=ëÉáåI=Ç~ëë=í~íë®ÅÜäáÅÜ= åìê=Ç~åå=ãáí=ÇÉê=ÉêÜ~äíÉåÉå=kìíòÉêÉáåJ Ö~ÄÉ=ÖÉ~êÄÉáíÉí=ïáêÇI=ïÉåå=ÇáÉëÉ=âçêêÉâí=EÉáåÉ=îÉêïÉêíÄ~êÉ=w~ÜäF=ï~êI= ëçääíÉå= ~ääÉ=ÇáÉëÄÉòΩÖäáÅÜÉå=_ÉÑÉÜäÉ=áå=Ç~ë=fååÉêÉ=ÇÉë=g~JwïÉáÖÉë=ÇÉë=ÉáåÑ~ÅÜÉå=qÉëíë== if x_info=0 then begin ... end
ÉáåÖÉíê~ÖÉå= ïÉêÇÉåK= ^ääÉë= ~åÇÉêÉ= ï®êÉ= e~ë~êÇI= ï®êÉ= ëÉÜê= òïÉáÑÉäÜ~ÑíÉë= sÉêJ íê~ìÉå=áå=ÇáÉ=hçåòÉåíê~íáçå=ìåÇ=ÇÉå=ÖìíÉå=táääÉå=ÇÉë=kìíòÉêëK== t~ë=ëçää=~ÄÉê=é~ëëáÉêÉåI=ïÉåå=ÇáÉ=kìíòÉêÉáåÖ~ÄÉ=åáÅÜí=~äë=w~Üä=îÉêïÉêíÄ~ê=áëí\== råëÉê=mêçÖê~ãã=ëíΩêòí=òï~ê=åáÅÜí=~ÄI=~ÄÉê=Éë=é~ëëáÉêí=Ç~åå=~ìÅÜ=åáÅÜíë=ïÉáíÉêK= cÉÜäÉáåÖ~ÄÉ=ìåÇ=pÅÜäìëëK=wáÉãäáÅÜ=ìåÄÉÑêáÉÇáÖÉåÇK== fã=^ÄëÅÜåáíí=NQKQKP=ïáêÇ= ëé®íÉê=Éêä®ìíÉêíI=ïáÉ=ïáê= ÇÉå=kìíòÉê= ÄÉá=c~äëÅÜÉáåÖ~J ÄÉå= ÉåíëéêÉÅÜÉåÇ= áåÑçêãáÉêÉå= ìåÇ= òìê= táÉÇÉêÜçäìåÖ= îÉê~åä~ëëÉå= â∏ååÉå= Ó= ëçä~åÖÉI=Äáë=Éê=ëáÅÜ=âçåòÉåíêáÉêí=ìåÇ=âçêêÉâí=ÉáåÖáÄíK== få=ÇáÉëÉã=wìë~ããÉåÜ~åÖ=ëÉá=~ìÅÜ=~ää=ÇÉåÉå=ÖÉ~åíïçêíÉíI=ÇáÉ=ÇáÉ=cê~ÖÉ=ëíÉääÉåI= ï~êìã= ÑΩê= ÇáÉ= _ÉäÉÖìåÖ= îçå= IntegerJpéÉáÅÜÉêéä®íòÉå= åáÅÜí= ÇáÉ= ~ìë= ^ÄëÅÜåáíí= TKNKO=ÄÉâ~ååíÉ=cìåâíáçå=StrToInt=îÉêïÉåÇÉí=ïáêÇ\= var x : Integer; begin x:=StrToInt(InputBox('Zahleneingabe','Bitte Zahl eingeben!','')) end;
aáÉ=^åíïçêí=áëí=ÉáåÑ~ÅÜI=ìåÇ=àÉÇÉê=â~åå=Éë=~ìëéêçÄáÉêÉåW=aáÉ= StrToIntJcìåâíáçå= â~åå=ìåâçêêÉâíÉ=kìíòÉêÉáåÖ~ÄÉå=åáÅÜí=~ÄÑ~åÖÉåX=ëáÉ=~êÄÉáíÉí=åìê=âçêêÉâíI=ïÉåå= ÇÉê=kìíòÉê=ÉáåÉ=wÉáÅÜÉåÑçäÖÉ=ÉáåÖáÄíI=ÇáÉ=ëáÅÜ=òì=ÉáåÉê=Ö~åòÉå=w~Üä=ã~ÅÜÉå=ä®ëëíK= _Éá=ìåâçêêÉâíÉê=kìíòÉêÉáåÖ~ÄÉ=äáÉÑÉêí=ëáÉ=~ÄÉê=ÉáåÉ=cÉÜäÉêãÉäÇìåÖ=ìåÇ=Ç~òì=ÉáJ åÉå=mêçÖê~ãã~ÄëíìêòK=aÉëÜ~äÄ=ïìêÇÉ=áå=^ÄëÅÜåáíí=RKNKQ=Ç~ÑΩê=ÖÉëçêÖíI=Ç~ëë=Ñ~äJ ëÅÜÉ= q~ëíÉå= ÇÉë= kìíòÉêë= ïÉÖÖÉÑ~åÖÉå= ïÉêÇÉåK= a~ë= ~ÄÉê= â∏ååÉå= ïáê= ÄÉá= sÉêJ ïÉåÇìåÖ=ÇÉê=InputBox=àÉÇçÅÜ=åáÅÜíK==
14.3
Strukturiertes Programmieren mit Pascal
• píêìâíìêáÉêíÉë= mêçÖê~ããáÉêÉå= ÄÉÇÉìíÉíI= Ç~ëë= àÉÇÉë= mêçÖê~ãã= ~ìë= ïÉåáÖÉå= _~ìëíÉáåÉåI=ÇÉå=píêìâíìêÉäÉãÉåíÉåI=òìë~ããÉåÖÉëÉíòí=ïáêÇK== a~=Éë=òì=àÉÇÉã=píêìâíìêÉäÉãÉåí=ÉáåÉå=òìÖÉÜ∏êáÖÉå=ëí~åÇ~êÇáëáÉêíÉå=Öê~ÑáëÅÜÉå= _~ìëíÉáå= ÖáÄíI= â~åå= ÇáÉ= mêçÖê~ããäçÖáâ= ~åÜ~åÇ= ÉáåÉë= _áäÇÉë= îçã= mêçÖê~ããI= ÇÉã=ëç=ÖÉå~ååíÉå=píêìâíçÖê~ããI=ÇáëâìíáÉêí=ïÉêÇÉåK====
14.3.1
Strukturelemente und ihre Umsetzung in Pascal
^äë= ïáÅÜíáÖëíÉ= píêìâíìêÉäÉãÉåíÉ= ëçääÉå= ÇáÉ= cçäÖÉI= ÇáÉ= ÇêÉá= cçêãÉå= ÇÉê= pÅÜäÉáÑÉ= ëçïáÉ=ÇáÉ=ÄÉáÇÉå=qÉëíë=îçêÖÉëíÉääí=ïÉêÇÉåK=
PMP =
NQ=jáí=aÉäéÜáW=m~ëÅ~ä=äÉêåÉå=
Umsetzung in Pascal Die Befehle werden nebenoder untereinander geschrieben, getrennt voneinander jeweils durch ein Semikolon:
Umsetzung in Pascal repeat Befehle des Schleifeninneren, getrennt durch Semikolon until ende_bedingung
Umsetzung in Pascal while lauf_bedingung do begin Befehle des Schleifeninneren, getrennt durch Semikolon end
Umsetzung in Pascal for zählvar:=anfwert to endwert do begin Befehle des Schleifeninhalts, getrennt jeweils mit Semikolon end
PMQ= =
NQKP== píêìâíìêáÉêíÉë=mêçÖê~ããáÉêÉå=ãáí=m~ëÅ~ä= for zählvar:=endwert downto anfwert do begin Befehle des Schleifeninhalts, getrennt jeweils mit Semikolon end
Umsetzung in Pascal if test then begin Befehle des JA-Zweiges, getrennt voneinander jeweils mit Semikolon end
Umsetzung in Pascal if test
then
begin Befehle des JA-Zweiges, getrennt voneinander jeweils mit Semikolon end else begin Befehle des NEIN-Zweiges, getrennt mit Semikolon end
PMR =
NQ=jáí=aÉäéÜáW=m~ëÅ~ä=äÉêåÉå=
14.3.2
Ausnahmeregelungen
• _ÉëíÉÜí=Ç~ë=fååÉêÉ=ÉáåÉê=âçéÑÖÉëíÉìÉêíÉå=pÅÜäÉáÑÉI=ÉáåÉê=w®ÜäëÅÜäÉáÑÉ=çÇÉê=ÉáJ åÉë=g^J=çÇÉê=kbfkJwïÉáÖÉë=áã=qÉëí=ÄòïK=^äíÉêå~íáîÉ=åìê=~ìë=ÉáåÉã=ÉáåòáÖÉå= _ÉÑÉÜä=çÇÉê=åìê=~ìë=ÉáåÉã=ÉáåòáÖÉå=píêìâíìêÉäÉãÉåíI=ëç=â~åå=~ìÑ=ÇáÉ=^åïÉáJ ëìåÖëâä~ããÉêå=begin...end=îÉêòáÅÜíÉí=ïÉêÇÉå=Eãìëë=~ÄÉê=åáÅÜíFW=
while lauf_bedingung do= ein Befehl oder Strukturelement
for zählvar:=anfwert to endwert do ein Befehl oder Strukturelement
if test then ein Befehl oder Strukturelement
= = _Éá=ÇÉê=^äíÉêå~íáîÉ=áëí=òì=ÄÉ~ÅÜíÉåI=Ç~ëë=îçê=else=åáÉã~äë=Éáå=pÉãáâçäçå=ëíÉÜÉå= Ç~êÑ=EÇÉåå=Ç~åå=Ö®ÄÉ=Éë=áã=g^JwïÉáÖ=ëçÑçêí=ïáÉÇÉê=òïÉá=_ÉÑÉÜäÉFW= if test then JA-Befehl oder Strukturelement else NEIN-Befehl od. Strukturelement
14.3.3
Tests
píÉääÉå=ïáê=åçÅÜ=ÇáÉ=cçêãÉå=îçå=qÉëíë=òìë~ããÉå=ìåÇ=ïÉáëÉå=~ìÑ=ÇáÉ=Ü®ìÑáÖëJ íÉå=cÉÜäÉê=ÜáåK= • qÉëí=~ìÑ=däÉáÅÜÜÉáíW= ==if linkeSeite = rechteSeite then...=== • qÉëí=~ìÑ=råÖäÉáÅÜÜÉáíW==if linkeSeite rechteSeite then...=== PMS= =
NQKQ== _ÉáëéáÉäÉ= • sÉêâåΩéÑìåÖ=òïÉáÉê=qÉëíë=ãáí=ìåÇW== if (test1) and (test2) then...= _ÉáëéáÉäW== if (a > 1) and (a < 3) then... j~å=ÄÉ~ÅÜíÉW=kìê=âçãéäÉííÉ=qÉëíë=ÇΩêÑÉå=îÉêâåΩéÑí=ïÉêÇÉå>=c~äëÅÜ=áëíW=============================== if (a > 1) and (< 3) then...
• sÉêâåΩéÑìåÖ=òïÉáÉê=qÉëíë=ãáí=çÇÉêW== if (test1) or (test2) then...= _ÉáëéáÉäW= if (a < 1) or (a > 3) then...
j~å=ÄÉ~ÅÜíÉ=ïáÉÇÉêW=kìê=âçãéäÉííÉ=qÉëíë=ÇΩêÑÉå=îÉêâåΩéÑí=ïÉêÇÉå>=c~äëÅÜ=áëíW===================== if (a < 1) or (> 3) then...
14.3.4
Ein- und Ausgaben
^ìÅÜ=ÑΩê=ÇáÉ=_ÉäÉÖìåÖ=îçå=péÉáÅÜÉêéä®íòÉå=áã=kìíòÉêÇá~äçÖ=ÄòïK=ÑΩê=ÇáÉ= ^ìëJ Ö~ÄÉ=ÇÉë=fåÜ~äíë=ÉáåÉë=péÉáÅÜÉêéä~íòÉë=~ìÑ=ÇÉå=_áäÇëÅÜáêã=ÖáÄí=Éë=ÉåíëéêÉÅÜÉåÇÉ= _áäÇÉêW== _ÉäÉÖìåÖ=ÉáåÉë=péÉáÅÜÉêéä~íòÉë=ÇìêÅÜ=kìíòÉêÇá~äçÖW==
= ^ìëÖ~ÄÉ=ÇÉë=fåÜ~äíë=ÉáåÉë=péÉáÅÜÉêéä~íòÉë=~ìÑ=ÇÉå=_áäÇëÅÜáêã==
= aáÉ=Éêä®ìíÉêåÇÉå=aá~äçÖíÉñíÉ=ÄÉá=báåJ=ìåÇ=^ìëÖ~ÄÉ=ÖÉÜ∏êÉå=åáÅÜí=áå=Éáå=píêìâJ íçÖê~ããX=ïáê=ïÉêÇÉå=~åëÅÜäáÉ≈ÉåÇ=áå=ÉáåáÖÉå=_ÉáëéáÉäÉå=ëÉÜÉåI=Ç~ëë=Ç~ãáí=ÇáÉ= aáëâìëëáçå=ÇÉê=mêçÖê~ããäçÖáâ=ïÉëÉåíäáÅÜ=ÉêäÉáÅÜíÉêí=ïáêÇK==
14.4
Beispiele
cΩê=àÉÇÉë=píêìâíìêÉäÉãÉåí=ÖáÄí=Éë=ÖÉïáëëÉ=pí~åÇ~êÇ~ìÑÖ~ÄÉåI=áå=ÇÉåÉå=Éë=ëÉáåÉ= ÅÜ~ê~âíÉêáëíáëÅÜÉ=^åïÉåÇìåÖ=ÑáåÇÉíK==
14.4.1
Strukturelement Folge
báåÑ~ÅÜ= ëíêìâíìêáÉêíÉ= mêçÖê~ããÉI= ÇáÉ= åìê= ~ìë= ÉáåÉê= ^ÄÑçäÖÉ= îçå= å~ÅÜÉáå~åÇÉê= ~ìëòìÑΩÜêÉåÇÉå=_ÉÑÉÜäÉå=ÄÉëíÉÜÉåI=ÄÉå∏íáÖÉå=åìê=ÇáÉëÉë=píêìâíìêÉäÉãÉåíK=j~å= ÄÉòÉáÅÜåÉí=ëçäÅÜÉ=mêçÖê~ããÉ=~ìÅÜ=ÖÉêå=~äë=äáåÉ~êÉ=mêçÖê~ããÉK==
PMT =
NQ=jáí=aÉäéÜáW=m~ëÅ~ä=äÉêåÉå= _ÉáëéáÉäW=báå=mêçÖê~ãã=ëçää=òïÉá=wÉáÅÜÉåÑçäÖÉå=ÉêÑ~ëëÉå=ìåÇ=òìë~ããÉåÑΩÖÉå=Ó= Éáåã~ä=ëçää=ÇáÉ=òïÉáíÉ=wÉáÅÜÉåÑçäÖÉ=êÉÅÜíë=~å=ÇáÉ=ÇáÉ=ÉêëíÉ=wÉáÅÜÉåÑçäÖÉ=~åÖÉJ âÉííÉí=ïÉêÇÉåI=Ç~ë=~åÇÉêÉ=j~ä=ëçää=ëáÉ=äáåâë=~åÖÉâÉííÉí=ïÉêÇÉåW=^ìë= Magde=ìåÇ= burg=ëçää=òìÉêëí=Magdeburg=ìåÇ=Ç~åå=burgMagde=ïÉêÇÉåK==== a~ë= píêìâíçÖê~ãã= ÉåíÜ®äí= åìê= Ç~ë= tÉëÉåíäáÅÜÉ= ÇÉë= mêçÖê~ãã~Ää~ìÑëX= Éêëí= ÄÉá= ÇÉê=~åëÅÜäáÉ≈ÉåÇÉå=rãëÉíòìåÖ=ÇÉë=píêìâíçÖê~ããë=áå=ÇÉå=mêçÖê~ããíÉñí=âçãJ ãÉå=sÉêÉáåÄ~êìåÖÉå=ìåÇ=aá~äçÖíÉñíÉ=ÜáåòìK== =
procedure TForm1.Button1Click(Sender: TObject); var tx1,tx2,tx3,tx4: ShortString;
//Vereinbarungen
begin tx1:=InputBox('Texteingabe','Erste Zeichenfolge:',''); tx2:=InputBox('Texteingabe','Zweite Zeichenfolge:',''); tx3:=tx1+tx2; tx4:=tx2+tx1; ShowMessage('Erster + zweiter Text: '+tx3); ShowMessage('Zweiter + erster Text: '+tx4); end;
14.4.2
Strukturelement Abweisschleife (kopfgesteuerte Schleife)
báå=íóéáëÅÜÉë=^åïÉåÇìåÖëÄÉáëéáÉä=ÑΩê=ÇáÉ=âçéÑÖÉëíÉìÉêíÉ=pÅÜäÉáÑÉ=áëí=ÇáÉ=rãëÉíJ òìåÖ=ÇÉê=ëç=ÖÉå~ååíÉå=cÉåëíÉêíÉÅÜåáâK== páÉ=ÄÉåìíòí=ã~å=Ç~ååI=ïÉåå=ãáí=ÉáåÉã=kìíòÉê=îÉêÉáåÄ~êí=ïìêÇÉI=Ç~ëë=Éê=ÄÉäáÉJ ÄáÖ=îáÉäÉ=wÉáÅÜÉåI=wÉáÅÜÉåÑçäÖÉå=çÇÉê=w~ÜäÉå=ÉáåÖÉÄÉå=Ç~êÑX=å~ÅÜ=ëÉáåÉê=äÉíòJ íÉå=báåÖ~ÄÉ=ëÅÜáÅâí=Éê=åçÅÜ=ÉáåÉ=îÉêÉáåÄ~êíÉ=wÉáÅÜÉåÑçäÖÉ=çÇÉê=w~Üä=ÜáåíÉêÜÉêI= ~å=ÇÉê=Ç~ë=mêçÖê~ãã=Ç~ë=båÇÉ=ÇÉê=báåÖ~ÄÉ=ÉêâÉååÉå=â~ååK== táê= ÉåíïÉêÑÉå= Éáå= mêçÖê~ããI= Ç~ë= ÉáåÉã= kìíòÉê= ëçä~åÖÉ= wÉáÅÜÉåÑçäÖÉå= ~ÄJ åáããíI=Äáë=Éê=ãáí=ÇÉê=báåÖ~ÄÉ=îçå=ÇêÉá=píÉêåÉå=ëáÖå~äáëáÉêíI=Ç~ëë=Éê=ÑÉêíáÖ=áëíK= PMU= =
NQKQ== _ÉáëéáÉäÉ= a~å~ÅÜ=ëçää=ÇáÉ=sÉêâÉííìåÖ=~ääÉê=báåÖ~ÄÉå=~ìëÖÉÖÉÄÉå=ïÉêÇÉåI=~ì≈ÉêÇÉã=ëçää= ãáíÖÉíÉáäí=ïÉêÇÉåI=ïáÉ=îáÉäÉ=báåÖ~ÄÉå=ΩÄÉêÜ~ìéí=ÉêÑçäÖíÉåK= a~òì= ïáêÇ= ÇáÉ= ÉêëíÉ= báåÖ~ÄÉ= áå= ÉáåÉã= báåÖ~ÄÉÑÉåëíÉê= ~ÄÖÉäÉÖí= EÇÉê= péÉáÅÜÉêJ éä~íò=â~åå=ÇìêÅÜ~ìë=ÇÉå=k~ãÉå= fenster=ÄÉâçããÉåFK=fëí=ÇáÉ=báåÖ~ÄÉ=Äê~ìÅÜJ Ä~ê=ïáêÇ=ëáÉ=îÉê~êÄÉáíÉíI=ìåÇ=ÇáÉ=å®ÅÜëíÉ=_ÉäÉÖìåÖ=ÇÉë=cÉåëíÉêë=â~åå=ÉêÑçäÖÉåK= wìã=pÅÜäìëë=ÉêÑçäÖÉå=ÇáÉ=ÄÉáÇÉå=^ìëÖ~ÄÉåK=
= procedure TForm1.Button1Click(Sender: TObject); var fenster, tx: ShortString; anzahl : Integer; begin tx:=''; anzahl:=0; //Initialisierung fenster:=InputBox('Texteingabe','Zeichenfolge eingeben:',''); while fenster'***' do begin tx:=tx+fenster; anzahl:=anzahl+1; fenster:=InputBox('Ende mit ***','Zeichenfolge eingeben:','') end; ShowMessage('Alles zusammen: '+tx); ShowMessage('Anzahl der Eingaben: '+IntToStr(anzahl)) end;
14.4.3
Strukturelement Nichtabweisschleife (fußgesteuerte Schleife)
aáÉ= Ñì≈ÖÉëíÉìÉêíÉ= pÅÜäÉáÑÉ= ïáêÇ= áããÉê= Ç~åå= îÉêïÉåÇÉíI= ïÉåå= å~ÅÜ= ÇÉê= ÉêëíÉå= ^âíáçå= òì= ΩÄÉêäÉÖÉå= áëíI= çÄ= ÉáåÉ= táÉÇÉêÜçäìåÖ= ëí~ííÑáåÇÉå= ãìëëI= Äáë= ÉáåÉ= ÖÉJ ïáëëÉ=^ìëëíáÉÖëÄÉÇáåÖìåÖ=ÉêÑΩääí=áëíK== PMV =
NQ=jáí=aÉäéÜáW=m~ëÅ~ä=äÉêåÉå= _ÉáëéáÉäW=báå=kìíòÉê=ëçää=ÖÉòïìåÖÉå=ïÉêÇÉåI=ÉáåÉ=wÉáÅÜÉåÑçäÖÉ=ÉáåòìÖÉÄÉåI=ÇáÉ= ìåÄÉÇáåÖí= ãáí= ÉáåÉã= dêç≈ÄìÅÜëí~ÄÉå= ÄÉÖáååÉå= ëçääK= e~í= ëÉáåÉ= báåÖ~ÄÉ= åáÅÜí= ÇáÉëÉ=báÖÉåëÅÜ~Ñí=ãìëë=Éê=ëÉáåÉ=báåÖ~ÄÉ=ïáÉÇÉêÜçäÉå=ìåÇ=ëç=ïÉáíÉêK=aÉê=kìíJ òÉê=Ü®åÖí=ëç=ä~åÖÉ=áå=ÇÉê=pÅÜäÉáÑÉ=ÑÉëíI=Äáë=Éê=âçêêÉâí=ÉáåÖáÄíK==
= procedure TForm1.Button1Click(Sender: TObject); var tx: ShortString; begin repeat tx:=InputBox('Texterfassung','Zeichenfolge eingeben:','') until (tx>='A') and (tx='A') and (tx