вот рабочий https://forum.hiasm.com/getfile/39016
для flint2
Add(MainForm,2953706,56,112)
{
Width=397
Height=206
Caption="DLL Loader GUI unit creator v 1.0"
BorderStyle=1
Position=1
}
Add(Hub,2656210,112,161)
{
OutCount=6
link(onEvent1,2205889:In,[(289,167)(289,62)])
link(onEvent2,4084727:doOpen,[(291,174)(291,188)])
link(onEvent3,16431865:doData,[(281,181)(281,265)])
link(onEvent4,10458459:doString,[(223,188)(223,300)(610,300)(610,244)])
link(onEvent5,11237681:doFor,[(207,195)(207,254)(100,254)(100,342)])
link(onEvent6,15785492:In,[(140,202)(140,216)])
}
Add(Edit,10219768,931,105)
{
Left=10
Top=30
Width=120
Text="Lib"
link(onChange,2783604:doString,[(975,111)(975,146)(919,146)(919,181)])
}
Add(Label,3124908,511,84)
{
Left=10
Top=10
Width=67
Height=20
Caption="Name unit:"
}
Add(Edit,7378850,308,112)
{
Left=10
Top=85
Width=330
Text=""
link(onChange,14418460:doFileExists,[])
}
Add(Label,8328050,518,91)
{
Left=10
Top=60
Width=48
Height=20
Caption="Path dll"
}
Add(Button,6892583,175,112)
{
Left=350
Top=80
Width=30
Height=25
Caption="..."
link(onClick,10901991:doExecute,[])
}
Add(ProgressBar,6119334,518,238)
{
Left=10
Top=125
Width=370
Height=30
Ctl3D=0
WinStyle=4
Smooth=1
ProgressColor=8388608
Point(doMax)
}
Add(Button,4533112,56,161)
{
Left=140
Top=10
Width=240
Height=40
Enabled=1
Caption="Create unit array"
Point(doEnabled)
link(onClick,2656210:doEvent1,[])
}
Add(FileStream,4084727,308,182)
{
link(FileName,7378850:Text,[])
}
Add(DataToFile,13385590,308,329)
{
link(onGet,15172987:doEvent1,[])
link(Stream,4084727:Stream,[])
}
Add(FileStream,1336679,994,238)
{
Mode=1
link(FileName,3970706:Value,[])
}
Add(DataToFile,6175744,994,287)
{
Type=7
link(Stream,1336679:Stream,[])
}
Add(FormatStr,2783604,931,175)
{
Mask="%1.pas"
link(onFString,3970706:doValue,[])
link(Str1,15832197:Var2,[])
}
Add(DoData,16431865,434,259)
{
link(onEventData,6119334:doMax,[(497,265)(497,251)])
link(Data,10534104:Var3,[(440,229)])
}
Add(ODialog,10901991,231,112)
{
Filter="dll|*.dll|All|*.*"
Title="Open file to array unit"
link(onExecute,7378850:doText,[])
}
Add(For,11237681,112,336)
{
link(onEvent,9184030:doEvent1,[])
link(onStop,14663672:doEvent1,[])
link(End,11871736:Var1,[(125,317)])
}
Add(GetDataEx,10534104,364,224)
{
Angle=3
link(Data,4084727:Size,[(321,229)])
}
Add(Hub,9184030,252,336)
{
OutCount=3
link(onEvent1,13385590:doGet,[])
link(onEvent2,1191799:doWork2,[])
link(onEvent3,5628570:doOperation,[(280,356)(280,403)(44,403)(44,426)])
}
Add(Memory,3970706,994,175)
{
Default=String(Lib.pas)
}
Add(CounterEx,3819576,546,455)
{
Max=19
Default=-1
Point(onThroughMax)
Point(doValue)
link(onThroughMax,13744734:doEvent1,[])
}
Add(Convertor,12891520,539,329)
{
Mode=6
link(onResult,11653114:doEvent1,[])
}
Add(FormatStr,10458459,630,238)
{
Mask="{*******************************************************************************\r\n* *\r\n* DLL linking is based on a library generously provided by Benjamin *\r\n* Rosseaux, www.0ok.de, mailto:benjamin@0ok.de *\r\n* *\r\n* DllToPas(GUI)- andrestudio *\r\n* *\r\n*******************************************************************************}\r\nunit %1;\r\ninterface\r\nuses Kol,DLLLoader;\r\nvar %1DLL: TDLLLoader;\r\nimplementation\r\nconst %1Size = %2;\r\n%1Data: array[1..%1Size] of byte =("
link(onFString,4851216:doWork2,[(774,244)(774,293)])
link(Str1,7215427:Var1,[(636,159)])
link(Str2,10534104:Var1,[(643,218)(370,218)])
}
Add(GetDataEx,15832197,931,154)
{
link(Data,10219768:Text,[])
}
Add(FormatStr,5717964,637,329)
{
DataCount=1
Mask="$%1,"
Point(FString)
}
Add(StrCat,6673780,805,329)
{
Point(doClear)
link(Str1,12028095:Var3,[(811,315)(855,315)(855,383)])
}
Add(DoData,12649488,812,462)
{
link(onEventData,755183:doWork2,[])
link(Data,12028095:Var2,[])
}
Add(GetDataEx,12028095,812,378)
{
Angle=3
link(Data,6673780:Result,[(811,383)])
}
Add(Hub,13744734,721,462)
{
link(onEvent1,15473679:doWork2,[])
link(onEvent2,9453583:doWork3,[(796,475)])
}
Add(Hub,15172987,490,329)
{
link(onEvent1,12891520:doConvert,[])
link(onEvent2,3819576:doNext,[(525,342)(525,461)])
}
Add(LineBreak,16243331,931,238)
{
Caption="open"
link(Out,1336679:doOpen,[])
Primary=[2205889,-623,-182]
}
Add(HubEx,4851216,945,287)
{
link(onEvent,6175744:doPut,[])
}
Add(Hub,14663672,168,343)
{
OutCount=3
link(onEvent1,4084727:doClose,[(237,349)(237,195)])
link(onEvent2,4946385:doData,[(245,356)(245,391)])
link(onEvent3,14192059:doMessage,[(236,363)(236,440)])
}
Add(FormatStr,10473416,882,511)
{
DataCount=1
Mask="var DLLData: PStream;\r\ninitialization\r\n %1DLL := TDLLLoader.Create;\r\n DLLData := NewMemoryStream;\r\n DLLData.Write(%1Data,%1Size);\r\n %1DLL.Load(DLLData);\r\n DLLData.Free;\r\nfinalization\r\n %1DLL.Free;\r\nend.\r\n"
link(onFString,755183:doWork3,[(935,517)])
link(Str1,7215427:Var2,[])
}
Add(HubEx,755183,931,462)
{
link(onEvent,4851216:doWork3,[(949,468)])
}
Add(GetDataEx,7215427,882,154)
{
Angle=1
link(Data,15832197:Var1,[])
}
Add(LineBreak,11497051,931,259)
{
Caption="close"
link(Out,1336679:doClose,[(982,265)(982,251)])
Primary=[12542158,-245,259]
}
Add(LineBreak,11223368,385,462)
{
Caption="reset"
link(Out,5424015:doEvent1,[])
Primary=[15785492,-231,-252]
}
Add(DoData,4946385,308,385)
{
Data=Integer(0)
link(onEventData,1191799:doWork3,[(396,391)])
}
Add(HubEx,1191799,392,343)
{
link(onEvent,6119334:doPosition,[(411,349)(411,244)])
}
Add(Message,14192059,308,434)
{
Message="File create"
Caption="Info"
Icon=4
}
Add(Hub,5424015,441,462)
{
link(onEvent1,12417716:doData,[])
link(onEvent2,9453583:doWork2,[(645,475)(645,447)])
}
Add(FileTools,14418460,364,91)
{
link(onEnd,4533112:doEnabled,[(408,97)(408,44)(39,44)(39,167)])
}
Add(FormatStr,7696347,637,392)
{
DataCount=1
Mask="$%1);"
Point(FString)
}
Add(Hub,11653114,595,329)
{
link(onEvent1,5717964:doString,[])
link(onEvent2,7696347:doString,[(630,342)(630,398)])
}
Add(DoData,7202276,700,329)
{
link(onEventData,5204208:doWork2,[])
link(Data,5717964:FString,[(706,317)(679,317)(679,370)(643,370)])
}
Add(DoData,5444088,700,392)
{
link(onEventData,5204208:doWork3,[(760,398)])
link(Data,7696347:FString,[(706,380)(679,380)(679,437)(643,437)])
}
Add(HubEx,5204208,756,329)
{
link(onEvent,6673780:doStrCat,[])
}
Add(Hub,13249639,644,497)
{
OutCount=4
link(onEvent1,5444088:doData,[(689,503)(689,398)])
link(onEvent2,15473679:doWork3,[(774,510)])
link(onEvent3,10473416:doString,[])
link(onEvent4,12542158:In,[])
}
Add(If_else,186305,112,420)
{
link(onTrue,13249639:doEvent1,[(166,426)(166,503)])
link(onFalse,10342572:In,[])
link(Op2,11871736:Var2,[(125,387)(160,387)])
}
Add(LineBreak,13426288,637,301)
{
link(Out,7202276:doData,[(691,307)(691,335)])
Primary=[10342572,-455,126]
}
Add(GetDataEx,11871736,154,312)
{
Angle=1
link(Data,10534104:Var2,[(370,317)])
}
Add(Math,5628570,56,420)
{
Op2=1
link(onResult,186305:doCompare,[])
link(Op1,11237681:Position,[(62,387)(118,387)])
}
Add(HubEx,15473679,770,462)
{
link(onEvent,12649488:doData,[])
}
Add(HubEx,9453583,792,441)
{
Angle=3
link(onEvent,6673780:doClear,[(796,342)])
}
Add(DoData,12417716,483,462)
{
Data=Integer(-1)
link(onEventData,3819576:doValue,[])
}