Click here to Skip to main content
15,926,596 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionColumn width problem Pin
paper6710-Aug-07 3:46
paper6710-Aug-07 3:46 
AnswerRe: Column width problem Pin
Jim Crafton10-Aug-07 4:22
Jim Crafton10-Aug-07 4:22 
QuestionToolbar Drop-down Button Width [modified] Pin
T-Mac-Oz10-Aug-07 3:38
T-Mac-Oz10-Aug-07 3:38 
AnswerRe: How To Monitor The File in MFC Pin
David Crow10-Aug-07 3:41
David Crow10-Aug-07 3:41 
QuestionOverriding registry default value's data programmatically Pin
Mushtaque Nizamani10-Aug-07 3:12
Mushtaque Nizamani10-Aug-07 3:12 
AnswerRe: Overriding registry default value's data programmatically Pin
David Crow10-Aug-07 3:21
David Crow10-Aug-07 3:21 
GeneralRe: Overriding registry default value's data programmatically Pin
Mushtaque Nizamani15-Aug-07 19:40
Mushtaque Nizamani15-Aug-07 19:40 
QuestionAccessible Object help Pin
xJorDyx10-Aug-07 2:47
xJorDyx10-Aug-07 2:47 
Hey I'm trying to use the Accessible Object API to find out when an event happens in an IM window, I've got some visual basic code for it but when i try to do this in a console applications it doesn't work. I know its probably something to do with the infinite for loop but i have no idea how else to do this and wait for some events to be printed into the console, heres the code i mainly got from msdn.

<br />
    HWINEVENTHOOK g_hook;<br />
<br />
    void CALLBACK HandleWinEvent(HWINEVENTHOOK hook, DWORD event, HWND hwnd,<br />
                                 LONG idObject, LONG idChild,<br />
                                 DWORD dwEventThread, DWORD dwmsEventTime)<br />
    {<br />
    printf("called\n");<br />
        IAccessible *pAcc = NULL;<br />
        VARIANT varChild;<br />
        HRESULT hr = AccessibleObjectFromEvent(hwnd, idObject, idChild, &pAcc, &varChild); <br />
        if ((hr == S_OK) && (pAcc != NULL))<br />
        {<br />
    char *classname;<br />
    classname = (char*)malloc(15);<br />
    GetClassName(GetParent(hwnd),(LPTSTR)classname,14);<br />
    printf("Classname: %s\n", classname);<br />
    if(strcmp(classname,"IMWindowClass") == 0){<br />
    printf("found\n");<br />
    }<br />
       <br />
        }<br />
    }<br />
<br />
    // Initializes COM and sets up the event hook.<br />
    //<br />
    void InitializeMSAA()<br />
    {<br />
        CoInitialize(NULL);<br />
        g_hook = SetWinEventHook(<br />
            EVENT_SYSTEM_ALERT , EVENT_OBJECT_ACCELERATORCHANGE,  // Range of events<br />
            NULL,                                          // Handle to DLL.<br />
            HandleWinEvent,                                // callback.<br />
            0, 0,              // Process and thread IDs of interest (0 = all)<br />
            WINEVENT_SKIPOWNPROCESS); // Flags.<br />
    }<br />
<br />
    int main(array<System:(Smilie)tring ^> ^args)<br />
    {<br />
    InitializeMSAA();<br />
    printf("init'd\n");<br />
    while(1);<br />
    system("pause");<br />
    return 0;<br />
    }<br />


Any help would be great!Big Grin | :-D
QuestionHow to change colour of TextOut( ) ??? Pin
Neo Andreson10-Aug-07 2:43
Neo Andreson10-Aug-07 2:43 
AnswerRe: How to change colour of TextOut( ) ??? Pin
Hamid_RT10-Aug-07 2:47
Hamid_RT10-Aug-07 2:47 
QuestionDelete cookie from FireFox Pin
veer_in10-Aug-07 2:43
veer_in10-Aug-07 2:43 
AnswerRe: Delete cookie from FireFox Pin
Hamid_RT10-Aug-07 2:53
Hamid_RT10-Aug-07 2:53 
GeneralRe: Delete cookie from FireFox Pin
veer_in10-Aug-07 3:20
veer_in10-Aug-07 3:20 
QuestionRe: Delete cookie from FireFox Pin
David Crow10-Aug-07 3:05
David Crow10-Aug-07 3:05 
AnswerRe: Delete cookie from FireFox Pin
veer_in10-Aug-07 3:25
veer_in10-Aug-07 3:25 
GeneralRe: Delete cookie from FireFox Pin
David Crow10-Aug-07 3:27
David Crow10-Aug-07 3:27 
GeneralRe: Delete cookie from FireFox Pin
veer_in10-Aug-07 3:45
veer_in10-Aug-07 3:45 
GeneralRe: Delete cookie from FireFox Pin
David Crow10-Aug-07 3:54
David Crow10-Aug-07 3:54 
Questionproblem when i try to stop a timer Pin
shja8810-Aug-07 2:12
shja8810-Aug-07 2:12 
QuestionRe: problem when i try to stop a timer Pin
David Crow10-Aug-07 3:06
David Crow10-Aug-07 3:06 
AnswerRe: problem when i try to stop a timer Pin
shja8810-Aug-07 3:29
shja8810-Aug-07 3:29 
GeneralRe: problem when i try to stop a timer Pin
jhwurmbach10-Aug-07 4:03
jhwurmbach10-Aug-07 4:03 
GeneralRe: problem when i try to stop a timer Pin
shja8810-Aug-07 4:08
shja8810-Aug-07 4:08 
GeneralRe: problem when i try to stop a timer Pin
jhwurmbach10-Aug-07 4:17
jhwurmbach10-Aug-07 4:17 
GeneralRe: problem when i try to stop a timer Pin
shja8810-Aug-07 4:28
shja8810-Aug-07 4:28 

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.