Autor Beitrag
matze
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 4613
Erhaltene Danke: 24

XP home, prof
Delphi 2009 Prof,
BeitragVerfasst: Di 23.07.02 17:54 
Hallo !!!

Wie kann ich mein komplettes Delphi Project (Formular mit Kompos) in eine DLL auslagern und dann aus meinem Hauptproject (EXE) aufrufen ??
Ich hab mir zwar das Tutorial uas dem EasyDelphiHelper2000 durchgelesen aber nicht so ganz kapiert !!!

_________________
In the beginning was the word.
And the word was content-type: text/plain.
Steffer
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 299



BeitragVerfasst: Di 23.07.02 18:32 

_________________
Keine Signatur ...
cbs
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 207
Erhaltene Danke: 1



BeitragVerfasst: Di 23.07.02 18:36 
tag auch

ich hatte dis auch schon mal gemacht, das war glaub ich so:

nen ganz normales delphi projekt erstellen (mit formular) alles auf dem formular platzieren und dann inner projekt datei program in library ändern.

ich hatte damals allerdings probleme das formular dann mit showmodal aufzurufen. das formular hatte sich so verhalten als wenn ich es mit show aufgerufen hätte.

probiers mal aus

cbs
matze Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 4613
Erhaltene Danke: 24

XP home, prof
Delphi 2009 Prof,
BeitragVerfasst: Di 23.07.02 18:42 
ja cool !!

aber wie rufe ich dann das forumlar in der dll aus meiner EXE auf ??

_________________
In the beginning was the word.
And the word was content-type: text/plain.
Steffer
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 299



BeitragVerfasst: Di 23.07.02 18:49 
Also die Demo beinhaltet eine DLL und eine EXE.

Das Form wird per Procedure ZeigeFormular; external 'ProjectDLL.DLL' INDEX 1; aufgerufen ... oder?

_________________
Keine Signatur ...
cbs
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 207
Erhaltene Danke: 1



BeitragVerfasst: Di 23.07.02 18:53 
na du brauchst dann nur noch ne procedure in die projekt datei einfügen die dann das formular aufruft (und den export abschnitt nicht vergessen)
ausblenden Quelltext
1:
2:
3:
4:
5:
6:
Procedure ZeigeFormular;
begin
Form1:= TForm1.Create(nil);
Form1.ShowModal;
Form1.Release;
end;

aufrufen tust du das dann so:
ausblenden Quelltext
1:
Procedure ZeigeFormular; external 'ProjectDLL.DLL';					

guck dir mal das beispiel von Steffer's link an. obwohl dieses index 1 glaub ich weggelassen werden kann

mich würde mal interessieren ob das form ich wirklich modal angezeigt wird. also alle anderen form's deaktiviert sind. wie gesagt ich hatte mal probleme damit
Steffer
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 299



BeitragVerfasst: Di 23.07.02 18:58 
Du kannst den Index weglassen.

Es gibt 2 Möglichkeiten:
Entweder nur die Angabe des Namens, dann dauert die Suche aber länger, da alle Exports durchlaufen werden.
Oder du nimmst einen INDEX 1 .... trulala.
Dann wird der angegebene Index verwendet. Egal ob er stimmt oder nicht. Dafür geht die Suche schneller.

_________________
Keine Signatur ...
cbs
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 207
Erhaltene Danke: 1



BeitragVerfasst: Di 23.07.02 19:01 
ahso,

wie es scheint geht das mit dem showmodal in diesem bsp auch wirklich. ich hatte damals die dynamische einbindung der dll verwendet. könnte es daran liegen das das mit showmodal nicht so gefunzt hatte wie es sollte? wie gesagt das formular wurde so angezeigt als hätte ich es mit show aufgerufen!?!

hat da jemand ne ahnung?