AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Zurück Delphi-PRAXiS Sprachen und Entwicklungsumgebungen Sonstige Fragen zu Delphi Delphi Parameter-Verarbeitung in Program-Unit

Parameter-Verarbeitung in Program-Unit

Ein Thema von Nicolai1234 · begonnen am 29. Jul 2005 · letzter Beitrag vom 29. Jul 2005
 
Benutzerbild von MaBuSE
MaBuSE

Registriert seit: 23. Sep 2002
Ort: Frankfurt am Main (in der Nähe)
1.840 Beiträge
 
Delphi 10 Seattle Enterprise
 
#5

Re: Parameter-Verarbeitung in Program-Unit

  Alt 29. Jul 2005, 16:54
Zitat von marabu:
ist schon klar - wenn du so abstruse Sachen machen willst, dann kannst du das Projekt nur noch mit dem command line compiler übersetzen, da die IDE es nicht mag, wenn du am project file rumfummelst.
In einer langen Partnerschaft, lernt man die Tücken seiner Freundin kennen.
Ich gehe mit meiner Delphi in solchen Fällen so um:

Delphi-Quellcode:
program Project1;

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

{$R *.res}

begin
  {$IFDEF FUER_DIE_BOESE_IDE} 
  Application.Initialize;
  Application.CreateForm(TForm1, Form1);
  Application.CreateForm(TForm2, Form2);
  Application.Run;
  {$ELSE}

  // hier steht unser Quelltext
  Application.Initialize;
  if UpperCase(ParamStr(1)) = 'SERVERthen
  begin
    Application.CreateForm(TForm1, Form1);
  end
  else
  begin
    Application.CreateForm(TForm2, Form2);
  end;
  Application.Run;
  {$ENDIF}
end.
Der Quelltext zw. IF und ELSE ist nur für die IDE und hat keine Funktion.
(Das Symbol darf natürlich nie definiert werden )
(°¿°) MaBuSE - proud to be a DP member
(°¿°) MaBuSE - proud to be a "Rüsselmops" ;-)
  Mit Zitat antworten Zitat
 

Themen-Optionen Thema durchsuchen
Thema durchsuchen:

Erweiterte Suche
Ansicht

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 10:05 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