Click here to Skip to main content
15,914,013 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: PDF Output Pin
BobInNJ28-Oct-08 16:37
BobInNJ28-Oct-08 16:37 
GeneralRe: PDF Output Pin
enhzflep28-Oct-08 17:06
enhzflep28-Oct-08 17:06 
GeneralRe: PDF Output Pin
BobInNJ29-Oct-08 11:02
BobInNJ29-Oct-08 11:02 
GeneralRe: PDF Output Pin
Member 419459329-Oct-08 15:01
Member 419459329-Oct-08 15:01 
AnswerRe: PDF Output Pin
Hamid_RT28-Oct-08 19:20
Hamid_RT28-Oct-08 19:20 
GeneralRe: PDF Output Pin
BobInNJ29-Oct-08 11:03
BobInNJ29-Oct-08 11:03 
GeneralRe: PDF Output Pin
Hamid_RT30-Oct-08 1:24
Hamid_RT30-Oct-08 1:24 
QuestionHow to get String Buffers from a dll within C++ and C# Pin
MarcoNedwig28-Oct-08 12:08
MarcoNedwig28-Oct-08 12:08 
I have a problem using a C++ written Dll using strings to return values.
Could someone give me a hint how to write a dll function to be used in C++ and C#.
At the moment I only found solutions working for C# or C++ but not both. Other language always have memory trash after calling the function, because the "original" variable within the dll is destroyed after call.
I would like to get hints which type to use for implementation within the dll.
I could change all progs, C++, C# and dll. So any solution would be helful to me.

Simple example how it would be simplest, but of course not working:

C++ Prog :
CString ReturnBuffer;
CallDllFunction(ReturnBuffer)

C# Prog :
string ReturnBuffer;
CallDllFunction(ReturnBuffer);

Dll (C++)
void CallDllFunction(CString &ReturnBuffer)
{
CString Test = "Teststring";
ReturnBuffer = Test;
}

Hope someone could help me. Thanks.
AnswerRe: How to get String Buffers from a dll within C++ and C# Pin
Mark Salsbery28-Oct-08 14:26
Mark Salsbery28-Oct-08 14:26 
GeneralRe: How to get String Buffers from a dll within C++ and C# Pin
MarcoNedwig29-Oct-08 6:46
MarcoNedwig29-Oct-08 6:46 
AnswerRe: How to get String Buffers from a dll within C++ and C# Pin
sashoalm29-Oct-08 5:34
sashoalm29-Oct-08 5:34 
Questionhow can i overwrite IDocHostUIHandler::ShowContextMenu() Pin
only_jack28-Oct-08 8:19
only_jack28-Oct-08 8:19 
AnswerRe: how can i overwrite IDocHostUIHandler::ShowContextMenu() Pin
Steve Thresher28-Oct-08 13:52
Steve Thresher28-Oct-08 13:52 
QuestionDownload "content disposition" link with COM object problem Pin
ecosoft128-Oct-08 8:08
ecosoft128-Oct-08 8:08 
QuestionDWM 2 Pin
Sarriss28-Oct-08 6:25
Sarriss28-Oct-08 6:25 
QuestionGetProcessID Pin
fvcker28-Oct-08 2:50
fvcker28-Oct-08 2:50 
AnswerRe: GetProcessID Pin
Roger Stoltz28-Oct-08 2:58
Roger Stoltz28-Oct-08 2:58 
GeneralRe: GetProcessID Pin
fvcker28-Oct-08 6:32
fvcker28-Oct-08 6:32 
QuestionRe: GetProcessID Pin
Roger Stoltz28-Oct-08 6:42
Roger Stoltz28-Oct-08 6:42 
AnswerRe: GetProcessID Pin
fvcker28-Oct-08 6:44
fvcker28-Oct-08 6:44 
QuestionRe: GetProcessID Pin
Roger Stoltz28-Oct-08 6:52
Roger Stoltz28-Oct-08 6:52 
AnswerRe: GetProcessID Pin
fvcker28-Oct-08 7:25
fvcker28-Oct-08 7:25 
QuestionRe: GetProcessID Pin
David Crow28-Oct-08 6:08
David Crow28-Oct-08 6:08 
AnswerRe: GetProcessID Pin
fvcker28-Oct-08 6:43
fvcker28-Oct-08 6:43 
GeneralRe: GetProcessID Pin
David Crow28-Oct-08 7:05
David Crow28-Oct-08 7:05 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.