Click here to Skip to main content
15,919,245 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: openDirectory dialog? Pin
David Crow6-Aug-03 5:23
David Crow6-Aug-03 5:23 
AnswerRe: openDirectory dialog? Pin
Chao Zuo5-Aug-03 23:39
Chao Zuo5-Aug-03 23:39 
GeneralLog Window Pin
SLiDeR5-Aug-03 22:38
SLiDeR5-Aug-03 22:38 
GeneralRe: Log Window Pin
Chao Zuo5-Aug-03 23:04
Chao Zuo5-Aug-03 23:04 
GeneralRe: Log Window Pin
SLiDeR5-Aug-03 23:15
SLiDeR5-Aug-03 23:15 
GeneralRe: Log Window Pin
HPSI5-Aug-03 23:24
HPSI5-Aug-03 23:24 
GeneralRe: Log Window Pin
Chao Zuo5-Aug-03 23:56
Chao Zuo5-Aug-03 23:56 
GeneralADODB pointer Pin
_crs_5-Aug-03 22:34
_crs_5-Aug-03 22:34 
hello,
I want to send a pointer from my VB client app. to a VC dll the code is :
for VB
-------

Private Declare Sub GenerateReport Lib "Generator.dll" (ByVal datele As ADODB.Recordset)

Private Sub Command1_Click()
Dim con As ADODB.Connection
Dim rs As ADODB.Recordset

c = "PROVIDER=sqloledb;server=romulus;uid=sa;pwd=951;DataBase=SindServLast"
Set con = New ADODB.Connection
con.Open c
Dim s As String
s = "select * from T_USR_Useri"
Set rs = con.Execute(s)
GenerateReport rs
End Sub

fot VC dll
-----------

void GenerateReport(_RecordsetPtr pRs)
{
pRs->MoveFirst();
CString text;
text=(char*)((_bstr_t)pRs->Fields->GetItem((_variant_t)("usr_LoginName"))->Value);
}

and everything works fine in vc ... the pointer is recived correctly and the text CString is filled ok but after that when my c++ function ends and the execution returns to VB the VB client crushes ... and raise an access violation error ..
why ?
thanks !!!!!
GeneralRe: ADODB pointer Pin
Chao Zuo5-Aug-03 22:46
Chao Zuo5-Aug-03 22:46 
GeneralRe: ADODB pointer Pin
Toni785-Aug-03 22:49
Toni785-Aug-03 22:49 
GeneralRe: ADODB pointer Pin
Chao Zuo5-Aug-03 23:12
Chao Zuo5-Aug-03 23:12 
GeneralRe: ADODB pointer Pin
_crs_5-Aug-03 23:07
_crs_5-Aug-03 23:07 
GeneralConverting hexadecimal to decimal in C++ Pin
Member 1609885-Aug-03 22:15
Member 1609885-Aug-03 22:15 
GeneralRe: Converting hexadecimal to decimal in C++ Pin
Chao Zuo5-Aug-03 22:35
Chao Zuo5-Aug-03 22:35 
GeneralRe: Converting hexadecimal to decimal in C++ Pin
RChin5-Aug-03 22:36
RChin5-Aug-03 22:36 
GeneralRe: Converting hexadecimal to decimal in C++ Pin
Toni785-Aug-03 22:47
Toni785-Aug-03 22:47 
Generala clipboard question Pin
Chao Zuo5-Aug-03 21:44
Chao Zuo5-Aug-03 21:44 
GeneralCBitmapButton Pin
Marissa1825-Aug-03 21:24
Marissa1825-Aug-03 21:24 
GeneralRe: CBitmapButton Pin
Toni785-Aug-03 21:41
Toni785-Aug-03 21:41 
GeneralRe: CBitmapButton Pin
Marissa1825-Aug-03 21:43
Marissa1825-Aug-03 21:43 
GeneralRe: CBitmapButton Pin
Toni785-Aug-03 22:05
Toni785-Aug-03 22:05 
QuestionWhat is wrong in this piece of code... Pin
Exceter5-Aug-03 21:20
Exceter5-Aug-03 21:20 
AnswerRe: What is wrong in this piece of code... Pin
Toni785-Aug-03 21:51
Toni785-Aug-03 21:51 
GeneralRe: What is wrong in this piece of code... Pin
Exceter5-Aug-03 22:23
Exceter5-Aug-03 22:23 
GeneralRe: What is wrong in this piece of code... Pin
Toni785-Aug-03 22:44
Toni785-Aug-03 22:44 

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.