AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Zurück Delphi-PRAXiS Programmierung allgemein Win32/Win64 API (native code) Delphi Hauptform unsichtbar solange Form2 vorhanden
Thema durchsuchen
Ansicht
Themen-Optionen

Hauptform unsichtbar solange Form2 vorhanden

Ein Thema von wb32 · begonnen am 28. Aug 2003 · letzter Beitrag vom 28. Aug 2003
Antwort Antwort
axelf98

Registriert seit: 27. Aug 2003
Ort: Ennepetal
440 Beiträge
 
Delphi 2005 Personal
 
#1

Re: Hauptform unsichtbar solange Form2 vorhanden

  Alt 28. Aug 2003, 15:04
Das Problem könnte man vielleicht so lösen:

In der "Unit" Projekt1 (unter alle Units anzeigen) siehts ungefähr so aus (Project1 ist der Name des Projekts):

Delphi-Quellcode:
program Project1;

uses
  Forms,
  Unit1 in 'Unit1.pas{Form1};
  Unit2 in 'Unit2.pas{Form2};

{$R *.RES}

begin
  Application.Initialize;
  Application.CreateForm(TForm1, Form1);
  Application.CreateForm(TForm2, Form2);
  Application.Run;
end.
Wenn jetzt Form2 zuerst kommen soll, vertauscht man einfach die Einträge:

Delphi-Quellcode:
  Application.Initialize;
  Application.CreateForm(TForm2, Form2);
  Application.CreateForm(TForm1, Form1);
  Application.Run;
end.

Wenn jetzt Die Passwortangabe richtig war:
Delphi-Quellcode:
 form2.visible := false //Passwortfenster wech
 form1.visible := true //Anwendung sichtbar

HINWEIS: Da jetzt Form2 das Hauptform ist, muss das auch beim Beenden des Programms geschlossen werden: Einfach unter formX.close "form2.close" schreiben!
  Mit Zitat antworten Zitat
Antwort Antwort


Forumregeln

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

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

Gehe zu:

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