Registriert seit: 6. Mai 2009
97 Beiträge
|
AW: Applikation initialisert "falsche" Unit
8. Jan 2016, 11:34
das sind recht große Units und viel Code drumrum - ich habe mal die uses rausgezogen, vielleicht hilft das schon.
Also die uses von uMainWerk bis zum type:
Delphi-Quellcode:
unit uMainWerk;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, Buttons, ComCtrls, ExtCtrls, ActnList, StdCtrls, Menus,
Provider, DB, DBClient, Grids, DBGrids, Mask, DBCtrls, ToolWin,
ImgList, SQLTimSt, DateUtils, dm_AutoLogin, uWerkGlob, RMSQLDataSet,
ufrmUrRM,
//FormRoller,
DM_GlobData,
//JvComponentBase, JvExControls, JvXPCore, JvXPButtons, JvSpeedButton
JvComponentBase, JvCaptionButton, JvExControls, JvXPCore, JvXPButtons,
JvExExtCtrls, JvExtComponent, JvXPCheckCtrls, JvSpeedButton,
RMContainer,
uIntList,
l14, cmbtll14, cmbtls14,
ZodPageControl,
ZodDBGrid,
RMGlob,
uRMObjects,
Dm_RMTV_Menu,
Dm_RMSB_Menu,
JvExDBGrids, JvDBGrid, JvDBUltimGrid, JvLabel, FMTBcd, SqlExpr, TB2Item,
TB2Dock, TB2Toolbar, JvImage, JvExStdCtrls, JvMemo, TB2ToolWindow,
AppEvnts
;
const
CON_MENGENTYP_PP = 0;
CON_MENGENTYP_QC = 1;
CON_MENGENTYP_KEINE = 2;
CON_NAMEPREFIX_PPINFOTV_TOOLBAR = ' TBToolbarPPInfoLAG';
CON_NAMEPREFIX_PPINFOTV_TOOLWINDOW = ' TBToolWindowPPInfoLAG';
CON_NAMEPREFIX_PPINFOTV_MEMZEITSTEMPEL = ' MemZeitStempelPPInfoLAG';
CON_MITPPINFOANZEIGE = FALSE;
CON_MITPPVERGLEICH = FALSE;
CON_UMAINWERK_STATUSBAR_PANELNO_PROGVERSION = 0;
CON_UMAINWERK_STATUSBAR_PANELNO_DATUM = 1;
CON_UMAINWERK_STATUSBAR_PANELNO_GEF = 2;
CON_UMAINWERK_STATUSBAR_PANELNO_QM_STATISTIK = 3;
CON_UMAINWERK_STATUSBAR_PANELNO_BENUTZER = 4;
type
TfrmMainWerk = class(TfrmUrRM)
und hier das gleiche von uMain:
Delphi-Quellcode:
unit uMain;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ExtCtrls, ComCtrls, ActnList, ImgList, ToolWin, Menus,
FMTBcd, DB, SqlExpr, RMGlob, dm_MakeTree, uRMObjects, ufrmUrRM, Fortschr,
RMSQLDataSet, RMBasisObject, sdl_SDLColors, ShellApi, CorEdit, mylabel,
ActiveX, ShlObj, ComObj, Provider, DBClient, Buttons,
Dm_GlobData, Dm_RMTV_Menu, AppEvnts,
JvComponentBase, JvCaptionButton, JvExControls, JvXPCore, JvXPButtons,
JvExExtCtrls, JvExtComponent, JvClock, JvXPCheckCtrls,
DragDrop, DropSource, DragDropFile, OleCtrls,
PdfLib_TLB, DM_Connection_MLaunch, JvExComCtrls, JvCoolBar, TB2Item,
TB2Dock, TB2Toolbar, TB2ExtItems, TB2ToolWindow, JvComCtrls,
JvCheckTreeView, Grids, DBGrids, JvExDBGrids, JvDBGrid, JvDBUltimGrid,
ZodPageControl, ZodDBGrid,
uRMPopupListEx, VirtualTrees, JvLabel
;
const
CON_UMAIN_STATUSBAR_PANELNO_BENUTZER = 0;
CON_UMAIN_STATUSBAR_PANELNO_LOGIN = 1;
CON_UMAIN_STATUSBAR_PANELNO_SUPERVISOR = 2;
CON_UMAIN_STATUSBAR_PANELNO_GEF = 3;
CON_UMAIN_STATUSBAR_PANELNO_QM_STATISTIK = 4;
CON_UMAIN_STATUSBAR_PANELNO_NODE_STATUS = 5;
CON_UMAIN_STATUSBAR_PANELNO_NODE_ICON = 6;
CON_UMAIN_STATUSBAR_PANELNO_NODE_TEXT = 7;
CON_UMAIN_STATUSBAR_PANELNO_STATUSINFO = 8;
type
TfrmMain = class(TfrmUrRM, IDropSource)
Die indirekte Abhängigkeit zu uMain ist in zwei Units gegeben: RMGlobFunc und uRMIni
Hier die uses von RMGolbFunc:
Delphi-Quellcode:
unit RMGlobFunc;
interface
uses
classes, SysUtils, Forms, Controls, ShellAPI, StrUtils,
Graphics, sdl_SDLColors, uIntList, CheckLst, MAPI,
StdCtrls, ActiveX, ShlObj, ComObj, ComCtrls,
JvComponentBase, JvCaptionButton, JvExControls, JvXPCore, JvXPButtons,
JvExExtCtrls, JvExtComponent, JvXPCheckCtrls, JvSpeedButton,
RMSQLDataSet,Types, Menus, ActnList, Printers, DBClient, DB, DBGrids, JPEG,
WinSock, Grids, ExtCtrls, CorEdit,
TB2Item, TB2Toolbar,
RMBasisObject,
uRMObjects,
uRMPing,
uRMPingDialog,
RMGlob,
RMGlobFuncUniversal,
l14
;
type
TRMGlobFuncException = class(TRMGlobFuncUniversalException);
type
TRMGlobFunc = class(TRMGlobFuncUniversal)
und hier die uses aus dem Vorgänger RMGlobFuncUniversal:
Delphi-Quellcode:
unit RMGlobFuncUniversal;
interface
uses
RMGlob,
classes, SysUtils, Forms, Controls, ShellAPI, StrUtils,
Graphics, sdl_SDLColors, uIntList, CheckLst, MAPI,
StdCtrls, ActiveX, ShlObj, ComObj, ComCtrls,
Types, Menus, ActnList, Printers, DBClient, DB, DBGrids, JPEG,
WinSock, Grids, ExtCtrls, CorEdit,
RMGlobFuncBasis, Windows, Contnrs
//RMSQLDataSet,
//JvComponentBase,
//JvCaptionButton, JvExControls, JvXPCore, JvXPButtons,
//JvExExtCtrls, JvExtComponent, JvXPCheckCtrls, JvSpeedButton,
//TB2Item, TB2Toolbar
;
type
TRMGlobFuncUniversalException = class(TRMGlobFuncBasisException);
// Für Registrierung
TDllRegisterServer = function: HResult; stdcall;
// für die Dateiausführung
TExecuteWaitEvent = procedure( const ProcessInfo: TProcessInformation;
var ATerminate: Boolean) of object;
type
TRMGlobFuncUniversal = class(TRMGlobFuncBasis)
und last but not least die uses von RMGlobFUncBasis
Delphi-Quellcode:
uses
classes, SysUtils, Forms
;
type
TRMGlobFuncBasisException = class( Exception);
// Für Registrierung
TRMGlobFuncBasis = class(TComponent)
Die uses der Unit uRMIni sieht so aus (Konstantendefinitionen gekürzt):
Delphi-Quellcode:
unit uRMIni;
interface
uses
SysUtils, Classes, FMTBcd, DBClient, Provider, DB, SqlExpr, DBXpress, Controls,
IniFiles, StrUtils, Dialogs, Forms,
uIntList, RMGlob
;
const
.
.
.
type
//----------------------------------------------------------------------------
// Fehlerklasse für Fehler innerhalb des Ini Tools
//----------------------------------------------------------------------------
TRMIniException = class( Exception);
//----------------------------------------------------------------------------
// INI-Tool zum Ermitteln von Informationen aus der globalen INI-Datei
//----------------------------------------------------------------------------
TRMIni = class(TIniFile)
|