Click here to Skip to main content
15,925,723 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: How to read japanese string from the string table (.rc file). Pin
sumit.durg19-May-08 2:43
sumit.durg19-May-08 2:43 
GeneralRe: How to read japanese string from the string table (.rc file). Pin
Michael Schubert19-May-08 4:00
Michael Schubert19-May-08 4:00 
GeneralRe: How to read japanese string from the string table (.rc file). Pin
ThatsAlok19-May-08 1:22
ThatsAlok19-May-08 1:22 
QuestionUsing multithreading to log... Pin
pl_kode18-May-08 19:57
pl_kode18-May-08 19:57 
AnswerRe: Using multithreading to log... Pin
Cedric Moonen18-May-08 20:17
Cedric Moonen18-May-08 20:17 
GeneralRe: Using multithreading to log... Pin
pl_kode18-May-08 20:46
pl_kode18-May-08 20:46 
AnswerRe: Using multithreading to log... Pin
pl_kode18-May-08 22:39
pl_kode18-May-08 22:39 
QuestionRe: Using multithreading to log... Pin
Rajkumar R18-May-08 23:22
Rajkumar R18-May-08 23:22 
QuestionRe: Using multithreading to log... Pin
CPallini18-May-08 23:17
mveCPallini18-May-08 23:17 
QuestionRead one struct,write to another struct. Pin
Anu_Bala18-May-08 19:23
Anu_Bala18-May-08 19:23 
AnswerRe: Read one struct,write to another struct. Pin
chandu00418-May-08 19:49
chandu00418-May-08 19:49 
AnswerRe: Read one struct,write to another struct. Pin
Rajkumar R18-May-08 21:08
Rajkumar R18-May-08 21:08 
Question[RESOLVED]Creating Toolbar [modified] Pin
Priya_Sundar18-May-08 18:58
Priya_Sundar18-May-08 18:58 
AnswerRe: Creating Toolbar Pin
ShilpiP18-May-08 19:53
ShilpiP18-May-08 19:53 
AnswerRe: Creating Toolbar Pin
Rajkumar R18-May-08 20:53
Rajkumar R18-May-08 20:53 
General[RESOLVED]: Thanks Pin
Priya_Sundar19-May-08 0:57
Priya_Sundar19-May-08 0:57 
QuestionHow to return COM object? Pin
RYU^^18-May-08 18:13
RYU^^18-May-08 18:13 
Hi,

I tried to return an interface but it gave me this error:
Unable to cast COM object of type 'MyTestLib.MainTestClass' to interface type 'MyTestLib.IMainTest '. This operation failed because the QueryInterface call on the COM component for the interface with IID '{519A413A-2792-4021-847F-B7C205FFE057}' failed due to the following error: No such interface supported (Exception from HRESULT: 0x80004002 (E_NOINTERFACE)).

Any idea why?

Here is my IDL:
import "oaidl.idl";
import "ocidl.idl";

[ object, uuid(EC23249E-2891-4f06-9D6E-77895E74448F) ] interface IAdd : IUnknown
{
    HRESULT     SetFirstNumber(long nX1);
    HRESULT     SetSecondNumber(long nX2);
    HRESULT     DoTheAddition([out,retval] long *pBuffer);
};

[ object, uuid(519A413A-2792-4021-847F-B7C205FFE057) ] interface IMainTest : IUnknown
{
    HRESULT     GetAddObject([out,retval] IAdd **ppObj);
};

[ uuid(AA484B10-6099-4e37-AEE3-8B4ADFBE2815) ] library MyTestLib
{
    importlib("stdole32.tlb");

    [ uuid(82B76786-E89B-4e42-8C50-B7916FEC1ADC) ]
    coclass AddClass
    {
        [default] interface IAdd;
    }

    [ uuid(E76E5E58-F9D9-4570-AEC5-79A72E8E8743) ]
    coclass MainTestClass
    {
        [default] interface IMainTest;
    }
};


Thanks for any help Smile | :)
AnswerRe: How to return COM object? Pin
RYU^^18-May-08 20:15
RYU^^18-May-08 20:15 
Questioninteger value in editbox Pin
Mohanraj D18-May-08 18:12
Mohanraj D18-May-08 18:12 
AnswerRe: integer value in editbox Pin
Hamid_RT18-May-08 18:17
Hamid_RT18-May-08 18:17 
GeneralRe: integer value in editbox Pin
Mohanraj D18-May-08 19:07
Mohanraj D18-May-08 19:07 
GeneralRe: integer value in editbox Pin
Hamid_RT18-May-08 19:17
Hamid_RT18-May-08 19:17 
GeneralRe: integer value in editbox Pin
Mohanraj D18-May-08 19:31
Mohanraj D18-May-08 19:31 
AnswerRe: integer value in editbox Pin
Paresh Chitte18-May-08 19:07
Paresh Chitte18-May-08 19:07 
GeneralRe: integer value in editbox Pin
Mohanraj D18-May-08 19:27
Mohanraj D18-May-08 19: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.