Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   GUI-Design mit VCL / FireMonkey / Common Controls (https://www.delphipraxis.net/18-gui-design-mit-vcl-firemonkey-common-controls/)
-   -   Delphi Problem mit Form in DLL (https://www.delphipraxis.net/30036-problem-mit-form-dll.html)

fsaction 18. Sep 2004 20:27


Problem mit Form in DLL
 
Hallo zusammen,

Ich habe folgendes Problem:
Ich habe ein Form in eine DLL ausgelagert, das funktioniert auch wunderbar bis auf auf so Eigenschaften wie ClientWidth, Left etc. Wenn ich diese innerhalb der Form benutzen möchte z.B so
Delphi-Quellcode:
Label.Width:=Form.ClientWidth-100;
bekomme ich eine Zugriffsverletzung.

Weiß jemand wo hier das Problem liegt?
Danke schon mal im Voraus für die Hilfe!

Hier noch der Sourcecode der DLL-Prozedur zum Aufrufen der Form:
Delphi-Quellcode:
library list;

uses
  Forms,
  form in 'form.pas' {LIST_WINDOW};

{$E dll}

{$R *.res}

procedure SHOW_LIST; stdcall;
var FORM: TLIST_WINDOW;
begin
  FORM:=TLIST_WINDOW.Create(Application);
  FORM.ShowModal;
  FORM.Free;
end;

exports
  SHOW_LIST;

begin
end.

mischerr 19. Sep 2004 01:58

Re: Problem mit Form in DLL
 
Versuchs mal mit
Code:
Label.Width:= self.ClientWidth-100;
Ist aber ohne Gewähr...

Luckie 19. Sep 2004 02:08

Re: Problem mit Form in DLL
 
hast du dir das http://www.luckie-online.de/Delphi/Importe/Assarbad/ DLL Tutorial schon mal durchgelesen?

fsaction 19. Sep 2004 10:39

Re: Problem mit Form in DLL
 
Danke das mit 'self' funktioniert!


Alle Zeitangaben in WEZ +1. Es ist jetzt 15:55 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz