Click here to Skip to main content
15,915,076 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Remote Procedure Call. Pin
David Crow19-Aug-08 3:36
David Crow19-Aug-08 3:36 
Questionerror C2011 Pin
vcprog18-Aug-08 19:08
vcprog18-Aug-08 19:08 
AnswerRe: error C2011 Pin
Jijo.Raj18-Aug-08 19:44
Jijo.Raj18-Aug-08 19:44 
GeneralRe: error C2011 Pin
vcprog18-Aug-08 20:06
vcprog18-Aug-08 20:06 
GeneralRe: error C2011 Pin
Jijo.Raj18-Aug-08 21:42
Jijo.Raj18-Aug-08 21:42 
GeneralRe: error C2011 Pin
vcprog18-Aug-08 22:23
vcprog18-Aug-08 22:23 
GeneralRe: error C2011 [modified] Pin
Jijo.Raj18-Aug-08 22:31
Jijo.Raj18-Aug-08 22:31 
QuestionHow to pass variables of type RecordSet from VB ocx to VC++ program??? Pin
savitri18-Aug-08 18:56
savitri18-Aug-08 18:56 
Hello everyone,
I am inserting vb activex control in VC program.In VB ocx program i am passing variables of type recordset from database.when i am inserting this ocx into my VC program those recordset datatypes are converting as LPDISPATCH* type. and my variables of type CRecordset. it is giving error like this:
C:\Program Files\Microsoft Visual Studio\My Projects\RecordSetPgm\RecordSetPgmDlg.cpp(255) : error C2664: 'Processattendacne' : cannot convert parameter 1 from 'class CRecordset' to 'struct IDispatch ** '
No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
VB ocx Code is like this:
void C_UserControl1::Processattendacne(LPDISPATCH* rs, LPDISPATCH* rs1, BOOL* blnprocess)
{
static BYTE parms[] =
VTS_PDISPATCH VTS_PDISPATCH VTS_PBOOL;
InvokeHelper(0x60030000, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
rs, rs1, blnprocess);
}

And VC++ Code is like this:
database.Open(NULL,false,false,sDsn); // Open Clients.MDB
CRecordset recset( &database );
SqlString="SELECT field1 FROM sample";
recset.Open(CRecordset::dynamic,SqlString,CRecordset::readOnly);
CRecordset recset1(&database);
Client= "SELECT field2 FROM sample";
recset1.Open(CRecordset::dynamic,Client,CRecordset::readOnly);
m_UserControl.Processattendacne(recset,recset1,bstr);
database.Close();
please tell me what type of parameters i have to take and how should i declare those please tell me...please Help me out..i am trying this but i am not getting...please give me some suggestions..

Thanks in Advance,
Savitri
AnswerRe: How to pass variables of type RecordSet from VB ocx to VC++ program??? Pin
User 21559718-Aug-08 19:06
User 21559718-Aug-08 19:06 
GeneralRe: How to pass variables of type RecordSet from VB ocx to VC++ program??? Pin
savitri18-Aug-08 19:35
savitri18-Aug-08 19:35 
GeneralRe: How to pass variables of type RecordSet from VB ocx to VC++ program??? Pin
User 21559718-Aug-08 19:53
User 21559718-Aug-08 19:53 
GeneralRe: How to pass variables of type RecordSet from VB ocx to VC++ program??? Pin
savitri18-Aug-08 20:08
savitri18-Aug-08 20:08 
GeneralRe: How to pass variables of type RecordSet from VB ocx to VC++ program??? Pin
User 21559718-Aug-08 20:20
User 21559718-Aug-08 20:20 
GeneralRe: How to pass variables of type RecordSet from VB ocx to VC++ program??? Pin
David Crow19-Aug-08 3:40
David Crow19-Aug-08 3:40 
QuestionUSB Information Pin
NewVC++18-Aug-08 18:39
NewVC++18-Aug-08 18:39 
AnswerRe: USB Information Pin
User 21559718-Aug-08 18:54
User 21559718-Aug-08 18:54 
GeneralRe: USB Information Pin
NewVC++18-Aug-08 19:00
NewVC++18-Aug-08 19:00 
GeneralRe: USB Information Pin
User 21559718-Aug-08 19:47
User 21559718-Aug-08 19:47 
GeneralRe: USB Information Pin
vcprog18-Aug-08 20:09
vcprog18-Aug-08 20:09 
AnswerRe: USB Information Pin
User 21559718-Aug-08 20:27
User 21559718-Aug-08 20:27 
GeneralRe: USB Information Pin
vcprog18-Aug-08 21:02
vcprog18-Aug-08 21:02 
GeneralRe: USB Information Pin
User 21559718-Aug-08 21:58
User 21559718-Aug-08 21:58 
GeneralRe: USB Information Pin
NewVC++19-Aug-08 1:19
NewVC++19-Aug-08 1:19 
AnswerRe: USB Information Pin
Hamid_RT18-Aug-08 20:22
Hamid_RT18-Aug-08 20:22 
AnswerRe: USB Information Pin
vikas amin19-Aug-08 5:27
vikas amin19-Aug-08 5:27 

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.