|
|
dont call that encrypted
Press F1 for help or google it.
Greetings from Germany
|
|
|
|
|
Hello, I am currently working on an MFC project. The project have a treeview and listview similar to the layout of windows registry editor. I was just wondering if any of you guys know how to change the focus wherein if the user click one item in the treeview and then presses the tab key the focus would be changed to the corresponding item in the listview? Please help.
|
|
|
|
|
Try it :
BOOL CLeft(Right)View::PreTranslateMessage(MSG* pMsg)
{
if (WM_KEYDOWN == pMsg->message) {
if (VK_TAB == pMsg->wParam) {
CWnd* pcWnd = YourFunctionToGetRight(Left)View();
if (pcWnd) {
pcWnd->SetFocus();
}
return TRUE;
}
}
return CBaseOfLeft(Right)View::PreTranslateMessage(MSG* pMsg);
}
virtual void BeHappy() = 0;
|
|
|
|
|
I have tried the code above but it slows down the application to the point it no longer populates the treeview, is there any other alternative?
|
|
|
|
|
Of course,
try to implement the reactions on WM_KEYDOWN for the both views
virtual void BeHappy() = 0;
|
|
|
|
|
thanks a lot, it works now.
|
|
|
|
|
Hi,
I have a dos console process communicating with a MFC Win32 program/process
I created a Cevent object passed the synchronization object to Dos console process created Process Table entry (DuplicateHandle)
on the MFC WIN32 end I have a Cdiloag residing in a Cwinthread UI flavor
My question is can the WIndow sdk api call SetEvent (to signal the shared Kernel object event) genarate a message to
the MFC Cdialog thread
thankx
|
|
|
|
|
If i understand your question, you should be able to intercept the event and generate the message yourself.
|
|
|
|
|
I am using the handle operator to get the syncronazation
handle
what is the MSG # WM_USER+ ???
|
|
|
|
|
Thankx the "C" SetEvent can'nt genarate
a WM_USER type message I understand
|
|
|
|
|
yes it should work. You use the HANDLE value of it not the object!!!
You can also use ::PostMessage(HWND,MSG,0,0) API. It works fine because it fits best in the Windows-GUI.
Press F1 for help or google it.
Greetings from Germany
|
|
|
|
|
As i understood, you have two applications
1. Console Application
2. MFC GUI Application( GUI thread derived )
Now you create a CEvent object in console application and duplicate the handle of the event object in MFC GUI.
So that means, you are looking to get the event change in both process, isn't it?
Now you have a doubt that if you call a SetEvent from Console application then whether it will generate a message to MFC thread.
As far as i understood, if u have the same concern then
It is yes, it will signal the wait inside the GUI application. But remember one thing this event is send to all the applications which have the same named event.
Величие не Бога может быть недооценена.
|
|
|
|
|
It was unamed I used DuplicateHandle to create an Entry in console process table
I think the best I can do is signal the event
and then send a message or post to the Cwintnhread UI/CDialog object
thankx
|
|
|
|
|
Fences is a very usefull desktop icon manager.With it,you can create many groups of icons on your desktop so that you can find your icons more easily.I am curious to know how to develop a desktop icon manager like "fences".
The problem is how to create the transparent area that I can drag my icons in.This area seems like a dialog,but I don't know what exactly it is.I have used spy++ to tell what the hell it is,however,I failed,it turns out to be nothing.I don't even know how to start it.
Thank you!
modified on Thursday, April 8, 2010 7:35 AM
|
|
|
|
|
Please pinpoint your problem.
The one explained by you is not a problem, rather you want get the code.
Величие не Бога может быть недооценена.
|
|
|
|
|
Sorry for wasting your time and thank you for your suggestion.My problem is how to create the transparent area that I can drag my icons in.This area seems like a dialog,but I don't know what exactly it is.I have used spy++ to tell what the hell it is,however,I failed,it turns out to be nothing.I don't even know how to get started.
|
|
|
|
|
code yourself. At first you got to identify the features you will need.
extract an icon with
DWORD_PTR dwPtr = ::SHGetFileInfo( buffer, 0/*ignored*/, &m_FileInfo, sizeof( m_FileInfo ),
SHGFI_ICON | SHGFI_SMALLICON | SHGFI_DISPLAYNAME | SHGFI_TYPENAME );//Flags
and display an icon DrawIcon => http://msdn.microsoft.com/en-us/library/ms648064%28VS.85%29.aspx[^]
and so on.
You fin a lot of samples at CP
Press F1 for help or google it.
Greetings from Germany
|
|
|
|
|
Thank you for your advice! I'll have a try.
|
|
|
|
|
Hello everybody !
I'm try to enable the dynamically menu,such as this code :
ListCtrl (Report style)
void CTestDlg::OnRclickList1(NMHDR* pNMHDR, LRESULT* pResult)
{
CString s10,s11,s12;
int nSelRows = m_List1.GetSelectedCount();
if(!nSelRows)
return;
POSITION pos = m_List1.GetFirstSelectedItemPosition();
int i = m_List1.GetNextSelectedItem(pos);
TRACE("First Item %d\n",i);
if (i != -1)
{
s10 = m_List1.GetItemText(i,10);
s11 = m_List1.GetItemText(i,11);
s12 = m_List1.GetItemText(i,12);
LPPOINT lpoint = new tagPOINT;
CMenu *pSubMenu;
CMenu m_Menu;
::GetCursorPos(lpoint);
m_Menu.LoadMenu(IDR_MENU18);
pSubMenu = m_Menu.GetSubMenu(0);
pSubMenu->TrackPopupMenu(TPM_LEFTALIGN,lpoint->x,lpoint->y,this);
if( s11 == "Receive" )
{
pSubMenu->EnableMenuItem(3,MF_BYPOSITION | MF_DISABLED | MF_GRAYED);
}
if( s11 == "UnReceive" )
...
pSubMenu->DestroyMenu();
}
*pResult = 0;
}
I tried but failed. Why cannot disable this sub menu ?
|
|
|
|
|
I'd say, try EnableMenuItem before TrakPopupMenu , not after.
> The problem with computers is that they do what you tell them to do and not what you want them to do. <
> Sometimes you just have to hate coding to do it well. <
|
|
|
|
|
thanks !
|
|
|
|
|
hello Friends
I am updating one of my dll using compiler 64 bit.But i am not able to find 64bit lib files for Quicktimesdk tht I am using as Aditional Libraries,So i ise the same lib but it is giving too many eroors like some variables not found and many more.
Do u have any idea from where i can get 64 bit sdk for QuickTime?
Or Can i run by using same sdk?
THanks
Yogesh
|
|
|
|
|
So,no one having idea of Quick time Sdk for 64 bit?
|
|
|
|
|
What is message/notification/event caused by right-clicking on column header of CListCtrl?
|
|
|
|