Robię to po raz pierwszy...
Idąc w ślad artykułu z 4programmers.net, zrobiłem nowego dll'a, wkleiłem do niego zawartość tego, co wcześniej miałem w button1click w formularzu(żeby przejrzyściej kod wyglądał), i... zapisuję, a dlla nie ma, ino dpr. Kombinując kliknąłem kompilację, i napisał że niezdefiniowane Memo1. To samo jak dusiłem F9.
Wie ktoś wtf i jak na to poradzić?
Ino kod nieco obcięty(bez całej, powtarzającej się składniowo zawartości pętli):
library Biosynth;
{ Important note about DLL memory management: ShareMem must be the
first unit in your library's USES clause AND your project's (select
Project-View Source) USES clause if your DLL exports any procedures or
functions that pass strings as parameters or function results. This
applies to all strings passed to and from your DLL--even those that
are nested in records and classes. ShareMem is the interface unit to
the BORLNDMM.DLL shared memory manager, which must be deployed along
with your DLL. To avoid using BORLNDMM.DLL, pass string information
using PChar or ShortString parameters. }
uses
SysUtils, Classes;
var
Abort: Boolean;
Pause: Boolean;
{$R *.res}
procedure Synthesis; stdcall; export;
var
i: Integer;
begin
Abort := False;
Pause := False;
i:=0;
while i <= Length(Memo1.Text) do
begin
if Memo1.Text[i] = ' ' then
Sleep(100);
sleep(75);
Application.ProcessMessages();
while Pause=True do
begin
Application.ProcessMessages();
sleep(1);
end;
if Abort then break;
inc(i);
end;
end;
exports
Synthesis name 'Synthesis';
begin
end.