My problem,when i started it is continously flickiering..even it does not open properly.
Wats the mistake..what can i do to avoid that?
By commenting any dialog calling code,the other one works perfectly.But i want to display this two dialogs as one in top of screen and other one in left side of screen.
I could not figure out why exactly it is flickering but it seems following points worth considering:
1) pMainFrame->UpdateWindow(); call looks unnecessary.
2) Heap allocations made by using new operator need to be deallocated by using delete operator otherwise results in memory leak.
3) The dialogs need to be explicitly destroyed by calling DestroyWindow() function.
Flickering could be due to a endless try to refresh the dialogs.
In addition to the previous answer I would take a look on the OnPaint, UpdateWindow or similar messages, and on the interactions between one and the other dialog as well (if there are such interactions), the problem could be there.
A updates and try to update B, then B updates and try to update A, so it starts another time and has no end.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
Rating helpfull answers is nice, but saying thanks can be even nicer.
That might work, but it's inherently an unstable solution, mostly because user1 might be or not be the same user as explorer.exe. It's not guaranteed to be the logged on user. It's just whichever process loaded my DLL first.
Wouldn't it be better to use GetCurrentProcess() instead, while my DLL is loaded in user1 process, and then use OpenProcessToken?
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition.
I have an MFC unicode application which needs to access a database which is UTF-8 encoded. Iam accessing the database through direct query excution using ExecuteSQL function.ExecuteSQL functions expects an LPCTSTR which will be be LPCWSTR under _UNICODE , so i need to format the query as UTF-16 and pass to the ExecuteSQL right?, but the DB is UTF-8 encoded.I need to know whether this will cause any problems.?
i am doing an word automation application in vc++. Here i need to create tables, which i have done. Now i need to set the borders for the tables. the tables that are created does not have borders by default.
i did some R&D and created gridlines. But that is not what i wanted. I wanted borders for the tables. Please give me some leads on this