- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Does anyone have an example of a cDEC$ATTRIBUTTES DLLEXPORT statement from a data only module where the exported variables are then used in an external DLL through a USE statement? The CVF documentation mentions that it is possible but I was unable to find an example and can't seem to make it work on my own.
the code in the exporting module is as follows:
MODULE GLOBALCOMMON
...
!DEC$ATTRIBUTES DLLEXPORT :: S,TIME0,TFINAL,DELT,IWARN
...
the code in a subroutine of the other dll is as follows:
SUBROUTINE TYPE571(...)
...
USE GLOBALCOMMON, ONLY:TIME0,TFINAL,DELT
...
I have included the .lib file from the first dll in the second one's project. Any hints as to what I am doing wrong wqould be greatly appreciated.
Thanks in advance,
David
the code in the exporting module is as follows:
MODULE GLOBALCOMMON
...
!DEC$ATTRIBUTES DLLEXPORT :: S,TIME0,TFINAL,DELT,IWARN
...
the code in a subroutine of the other dll is as follows:
SUBROUTINE TYPE571(...)
...
USE GLOBALCOMMON, ONLY:TIME0,TFINAL,DELT
...
I have included the .lib file from the first dll in the second one's project. Any hints as to what I am doing wrong wqould be greatly appreciated.
Thanks in advance,
David
Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What version CVF do you have? This really first started working in 6.6B.
Steve
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I had 6.6A but have remedied that. The errors are a bit different now. When compiling the base dll (from which I want to export the variables) I get link warnings telling me that each of the variables contained in the statement
cDEC$ATTRIBUTES DLLEXPORT :: var1, var2,...
is being imported. The warning text is
LINK : warning LNK4049: locally defined symbol "_GLOBALCOMMON_mp_var1" imported
In the second dll (where I am trying to USE the exported variables) I get the error that the name in ONLY list doesn't exist.
I really appreciate your help on all this.
Cheers,
David
cDEC$ATTRIBUTES DLLEXPORT :: var1, var2,...
is being imported. The warning text is
LINK : warning LNK4049: locally defined symbol "_GLOBALCOMMON_mp_var1" imported
In the second dll (where I am trying to USE the exported variables) I get the error that the name in ONLY list doesn't exist.
I really appreciate your help on all this.
Cheers,
David

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page