Home »» Delphi [Programming]
Thread Profile: Need help with GUI plugin
Need help with GUI plugin
>>I have used class references before across DLLs - my own classes with no
>>VCL components with success.
? I know that even to have Delphi long string types seen across DLL's you have to include sharemem.dll. This is due to the reference counting I believe. Same deal with the classes so I don't understand how you got around it.
>>With out run-time packages, I can uses seperate
>>forms in each DLL and EXE.
? Is this some sort of workaround you came up with? And using run-time packages fixed that?
Dave
doughale (AT) xmission (DOT) com wrote:
Thanks,
I have used class references before across DLLs - my own classes with no
VCL components with success. With out run-time packages, I can uses seperate
forms in each DLL and EXE. With run-time packages, the DLLs and EXE can all
interact with the same form!
Thanks to Rob and David
Doug
Quoting Rob Kennedy <rkennedy (AT) cs (DOT) wisc.edu>:
David Smith wrote:
>You can't pass class references to DLL's. That is a limitation. You have
>to use packages for full interoperability. This means compiling with the
>runtime packages option. That means your product has to make sure all
>packages needed (including Borland's) are on the users system.
>
Class references are meaningful if both the DLL and the EXE are compiled
to use packages.
- 1Answer
- Total
at [2008-5-4 23:07:31]
I'm not exactly shure But I have a guess as to why some things work and
others not -
ShareMem is for Strings - Since strings are part of the language (not a
library as in C) The allocation/deallocation is more dynamic than is
apparent.
If a string is passed to another DLL and operated on - those operations wil
l
free and reallocate the string memory - thus requiring a single allocatoion
pool for all strings.
If an object is only allocated and deallocated (Create/Free) with the same
allocator (within the same pool) ther should not be a problem - if the for
m
exists entirely within a DLL - thinks work with seperate allocation pools f
or
each DLL.
But with GUI objects that form relationships between parents/siblings - the
y
all must come from the same pool - I can't have a parent form from one pool
and a child control from another. Therefore we cannot use staticly link
allocators, we must use a single allocator from a DLL - run-time packages.
This is a guess that comes from observation, if someone has better knowledg
e
or a explaination than I, PLEASE speek up.
Thanks again for you help - Switching to Run-time package were completely
outside my current thinking but it solved all my problems. But now I do hav
e
to ship Borland DLLs - I just have to figure out which ones.
D
Quoting David Smith <djsmith_1998 (AT) yahoo (DOT) com>:
I have used class references before across DLLs - my own classes with n
o
VCL components with success.
? I know that even to have Delphi long string types seen across
DLL's you have to include sharemem.dll. This is due to the reference
counting I believe. Same deal with the classes so I don't understand
how you got around it.
>
>>With out run-time packages, I can uses seperate
forms in each DLL and EXE.
? Is this some sort of workaround you came up with? And using
run-time packages fixed that?
Dave
doughale (AT) xmission (DOT) com wrote:
Thanks,
I have used class references before across DLLs - my own classes with n
o
VCL components with success. With out run-time packages, I can uses seper
ate
forms in each DLL and EXE. With run-time packages, the DLLs and EXE can a
ll
interact with the same form!
Thanks to Rob and David
Doug
>
>
>
>
Quoting Rob Kennedy <rkennedy (AT) cs (DOT) wisc.edu>:
>
>David Smith wrote:
You can't pass class references to DLL's. That is a limitation. You hav
e
to use packages for full interoperability. This means compiling with th
e
runtime packages option. That means your product has to make sure all
packages needed (including Borland's) are on the users system.
>>
>Class references are meaningful if both the DLL and the EXE are compiled
>to use packages.
>>
>--
>Rob
>>
>>
>>
>>
>>
>
>Home page:
>To unsubscribe: delphi-en-unsubscribe (AT) yahoogroups (DOT) com
>Yahoo! Groups Links
>>
>>
>>
>>
>>
>>
>>
>>
>
>
>
>
Home page:
To unsubscribe: delphi-en-unsubscribe (AT) yahoogroups (DOT) com
>
>
>
SPNSRED LINKS
C programming language Computer programming languages Java
programming language The c programming language C programming
language Concept of programming language
YAH! GRUPS LINKS
--
Visit your group "delphi-en" on the web.
To unsubscribe from this group, send an email to:
delphi-en-unsubscribe (AT) yahoogroups (DOT) com
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
--
>
>
>
>
>
Yahoo! Messenger with Voice. Make PC-to-Phone Calls to the US (and
30+ countries) for 2/min or less.
[Non-text portions of this message have been removed]
>
>
>
>
Home page:
To unsubscribe: delphi-en-unsubscribe (AT) yahoogroups (DOT) com
Yahoo! Groups Links
>
>
>
>
>
>
>
Yahoo! Groups Sponsor
You can search right from your browser? It's easy and it's free. See how.
Home page:
To unsubscribe: delphi-en-unsubscribe (AT) yahoogroups (DOT) com
Yahoo! Groups Links
<*To visit your group on the web, go to:
<*To unsubscribe from this group, send an email to:
delphi-en-unsubscribe (AT) yahoogroups (DOT) com
<*Your use of Yahoo! Groups is subject to:
- 1No.
- Answer