|
-
January 24th, 2012, 03:58 PM
#1
[RESOLVED] dll crashing issue
Hi, I have designed a dll to run from excel which prices financial options. It all works fine when I reference the dll on my pc, but If I copy the dll to a shared directory so that others can use it, then it crashed excel all the time..
Is there something I need to specify in the configuration properties in order for it to work on other pc's?
[edit]Just to add this is a win32 app[/edit]
Last edited by jrogers; January 24th, 2012 at 05:58 PM.
-
January 25th, 2012, 12:37 AM
#2
Re: dll crashing issue
You need to post more information.
1. Is it a regular DLL or MFC?
2. Does it access any database, if so, do you share it?
3. What type of interface are you using.
-
January 25th, 2012, 03:48 AM
#3
Re: dll crashing issue
it is a regular dll.. I created a blank WIN32 Consol Application.
I have solved it.
I was using
Code:
extern "C" __declspec(dllexport) double __sdtcall functionname()
but i have now found that if I use
Code:
#define EXPORT comment(linker, "/EXPORT:"__FUNCTION__"="__FUNCDNAME__)
in my header file and then add
Code:
double __stdcall function(double &a)
{
#pragma EXPORT
//rest of code
}
that it not only does not decorate my functions, but It works wherever I install the dll. (I also don't have to use a .def file)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|