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

C / C++ / MFC

 
GeneralRe: Passing strings from VC to a VB COM dll Pin
ns18-Sep-02 11:28
ns18-Sep-02 11:28 
GeneralRe: Passing strings from VC to a VB COM dll Pin
ns18-Sep-02 11:35
ns18-Sep-02 11:35 
GeneralRe: Passing strings from VC to a VB COM dll Pin
Bart Robeyns18-Sep-02 12:12
Bart Robeyns18-Sep-02 12:12 
GeneralRe: Passing strings from VC to a VB COM dll Pin
ns_18-Sep-02 13:50
sussns_18-Sep-02 13:50 
GeneralRe: Passing strings from VC to a VB COM dll Pin
Anonymous18-Sep-02 21:08
Anonymous18-Sep-02 21:08 
GeneralRe: Passing strings from VC to a VB COM dll Pin
ns19-Sep-02 1:19
ns19-Sep-02 1:19 
GeneralRe: Passing strings from VC to a VB COM dll Pin
Bart Robeyns19-Sep-02 11:21
Bart Robeyns19-Sep-02 11:21 
GeneralFinal question...I hope Pin
ns19-Sep-02 11:37
ns19-Sep-02 11:37 
Great! Thanks. Now the only remaining thing to iron out in this issue is that the VB dll functions argument had to be changed to MyFunc(ByVal as String) or it wouldnt compile. This seems to indicate that I cant pass in a _bstr_t that I want modified by the dll and have the changes persist in the VC - I mean by passing in the _bstr_t by reference. Like if I wanted the VB dll to fill in myBstrString, I'd call it like:

ptr->FillString(&myBstrString)
pls correct me here if I am wrong in calling it like this to get what I want

and in the VB dll

Function FillString(ByRef a as String)

a ="filledByVB"


I'd really appreciate if you can let me know if I'm understanding this pass by reference notion correctly (esp on the VC side - maybe I dont need that & in the ptr call, do I? If the argument was an int or something, I know for sure we'd need to pass in &myInt, and the & would be necessary )

Anyways the time the compiler was unhappy was when the dl had ByRef and I sent in the _bstr_t like this:

ptr->FillString( myBstrString);




Thanks,
ns
GeneralRe: Passing strings from VC to a VB COM dll Pin
Michael Dunn18-Sep-02 12:02
sitebuilderMichael Dunn18-Sep-02 12:02 
GeneralRe: Passing strings from VC to a VB COM dll Pin
ns_18-Sep-02 13:52
sussns_18-Sep-02 13:52 
GeneralRe: Passing strings from VC to a VB COM dll Pin
ns19-Sep-02 1:03
ns19-Sep-02 1:03 
GeneralGUI front end Pin
WhiteLegend18-Sep-02 10:57
WhiteLegend18-Sep-02 10:57 
GeneralRe: GUI front end Pin
Ravi Bhavnani18-Sep-02 11:05
professionalRavi Bhavnani18-Sep-02 11:05 
GeneralRe: GUI front end Pin
xai18-Sep-02 11:19
xai18-Sep-02 11:19 
QuestionWhat path to code in #import? Pin
ns18-Sep-02 10:45
ns18-Sep-02 10:45 
AnswerRe: What path to code in #import? Pin
Michael Dunn18-Sep-02 10:45
sitebuilderMichael Dunn18-Sep-02 10:45 
GeneralRe: What path to code in #import? Pin
ns18-Sep-02 10:55
ns18-Sep-02 10:55 
GeneralRe: What path to code in #import? Pin
Michael Dunn18-Sep-02 11:58
sitebuilderMichael Dunn18-Sep-02 11:58 
GeneralRe: What path to code in #import? Pin
Jon Hulatt18-Sep-02 22:25
Jon Hulatt18-Sep-02 22:25 
GeneralQuestion about CSocket Pin
nachilau18-Sep-02 9:36
nachilau18-Sep-02 9:36 
GeneralRe: Question about CSocket Pin
Daniel Turini18-Sep-02 9:56
Daniel Turini18-Sep-02 9:56 
QuestionHow to make an Incomming connection Pin
Joe O'Connor18-Sep-02 9:02
Joe O'Connor18-Sep-02 9:02 
Questionhow to debug a VB dll called from VC Pin
ns18-Sep-02 8:59
ns18-Sep-02 8:59 
AnswerA little more detail maybe? Pin
Joel Holdsworth18-Sep-02 8:58
Joel Holdsworth18-Sep-02 8:58 
GeneralRe: A little more detail maybe? Pin
ns18-Sep-02 9:05
ns18-Sep-02 9: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.