unit WinForm4;
interface
uses
System.Drawing, System.Collections, System.ComponentModel,
System.Windows.Forms, System.Data;
type
TWinForm4 =
class(System.Windows.Forms.Form)
{$REGION 'Vom Designer verwalteter Code'}
strict private
/// <summary>
/// Erforderliche Designervariable.
/// </summary>
Components: System.ComponentModel.Container;
Button1: System.Windows.Forms.Button;
TextBox1: System.Windows.Forms.TextBox;
/// <summary>
/// Erforderliche Methode zur Unterstützung des Designers -
/// ändern Sie die Methode nicht mit dem Quelltext-Editor
/// </summary>
procedure InitializeComponent;
procedure Button1_Click(sender: System.
Object; e: System.EventArgs);
{$ENDREGION}
strict protected
/// <summary>
/// Ressourcen nach der Verwendung bereinigen
/// </summary>
procedure Dispose(Disposing: Boolean);
override;
private
{ Private-Deklarationen }
public
constructor Create;
end;
[assembly: RuntimeRequiredAttribute(TypeOf(TWinForm4))]
implementation
uses microsoft.Win32,system.IO;
{$AUTOBOX ON}
{$REGION 'Vom Windows Form-Designer erzeugter Code'}
/// <summary>
/// Erforderliche Methode zur Unterstützung des Designers --
/// ändern Sie die Methode nicht mit dem Quelltext-Editor
/// </summary>
procedure TWinForm4.InitializeComponent;
begin
Self.Button1 := System.Windows.Forms.Button.Create;
Self.TextBox1 := System.Windows.Forms.TextBox.Create;
Self.SuspendLayout;
//
// Button1
//
Self.Button1.Location := System.Drawing.Point.Create(144, 40);
Self.Button1.
Name := '
Button1';
Self.Button1.Size := System.Drawing.Size.Create(160, 40);
Self.Button1.TabIndex := 0;
Self.Button1.Text := '
Button1';
Include(Self.Button1.Click, Self.Button1_Click);
//
// TextBox1
//
Self.TextBox1.Location := System.Drawing.Point.Create(16, 160);
Self.TextBox1.
Name := '
TextBox1';
Self.TextBox1.Size := System.Drawing.Size.Create(488, 20);
Self.TextBox1.TabIndex := 1;
Self.TextBox1.Text := '
TextBox1';
//
// TWinForm4
//
Self.AutoScaleBaseSize := System.Drawing.Size.Create(5, 13);
Self.ClientSize := System.Drawing.Size.Create(528, 436);
Self.Controls.Add(Self.TextBox1);
Self.Controls.Add(Self.Button1);
Self.
Name := '
TWinForm4';
Self.Text := '
WinForm4';
Self.ResumeLayout(False);
end;
{$ENDREGION}
procedure TWinForm4.Dispose(Disposing: Boolean);
begin
if Disposing
then
begin
if Components <>
nil then
Components.Dispose();
end;
inherited Dispose(Disposing);
end;
constructor TWinForm4.Create;
begin
inherited Create;
//
// Erforderlich für die Unterstützung des Windows Forms-Designers
//
InitializeComponent;
//
// TODO: Fügen Sie nach dem Aufruf von InitializeComponent Konstruktorcode hinzu.
//
end;
procedure TWinForm4.Button1_Click(sender: System.
Object; e: System.EventArgs);
var reader: StreamReader;
output,s:
String;
begin
output := '
';
reader := &
File.OpenText('
c:\KB43.125');
TextBox1.text := reader.ReadLine();
end;
end.