Connecting Tech Pros Worldwide Forums | Help | Site Map

Not a able to return value from a dll

Venkat
Guest
 
Posts: n/a
#1: Jul 22 '05
Hi,

I got a simple cpp application which calls a dll at runtime.
The application is calling the dll and the dll is also doing the required
thing it suppose to do but
when after dll is done it has to return back to the calling application.
I am having the problem in dll returning back to the calling application.
Infact the application stops once
the dll is called.

Can some one please let me know where i am going wrong.


Sample Code
-------------------
dll

int CIDPDBInstall::IDPInstallCSVFile(const std::string m_CSVFileName)
{
......
......
......
}

Application

{

.......
ret1 = obj->IDPInstallCSVFile(m_CSVFileName);
}


regards,
Venkat








tom_usenet
Guest
 
Posts: n/a
#2: Jul 22 '05

re: Not a able to return value from a dll


On Tue, 13 Jan 2004 17:32:50 +0530, "Venkat" <venkat_kp@yahoo.com>
wrote:
[color=blue]
>Hi,
>
>I got a simple cpp application which calls a dll at runtime.
>The application is calling the dll and the dll is also doing the required
>thing it suppose to do but
>when after dll is done it has to return back to the calling application.
>I am having the problem in dll returning back to the calling application.
>Infact the application stops once
>the dll is called.[/color]
[color=blue]
>int CIDPDBInstall::IDPInstallCSVFile(const std::string m_CSVFileName)
>{
>.....
>.....
>.....
>}
>
>Application
>
>{
>
>......
>ret1 = obj->IDPInstallCSVFile(m_CSVFileName);
>}[/color]

This is not a C++ problem, rather a DLL problem. Ask in a group for
your platform, such as microsoft.public.vc.stl (since string's
destructor is probably causing the problem).

(hint, have you linked both the DLL and the EXE against the
Multithreaded DLL version of the CRT?)

Tom

C++ FAQ: http://www.parashift.com/c++-faq-lite/
C FAQ: http://www.eskimo.com/~scs/C-faq/top.html
Closed Thread