Click here to Skip to main content
15,898,588 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Unicode class Pin
ThaSaVa1-Aug-05 1:09
ThaSaVa1-Aug-05 1:09 
Generaldetecting the input from a receiver Pin
Nilegna29-Jul-05 22:56
Nilegna29-Jul-05 22:56 
GeneralMSHTML Editing problem Pin
Scozturk29-Jul-05 22:37
professionalScozturk29-Jul-05 22:37 
GeneralRe: MSHTML Editing problem Pin
Scozturk30-Jul-05 4:08
professionalScozturk30-Jul-05 4:08 
GeneralMixing technologies Pin
pc_dev29-Jul-05 21:22
pc_dev29-Jul-05 21:22 
GeneralRe: Mixing technologies Pin
Scozturk29-Jul-05 22:40
professionalScozturk29-Jul-05 22:40 
GeneralSome problems related to Rich edit and Tree Pin
Aqueel29-Jul-05 21:19
Aqueel29-Jul-05 21:19 
GeneralRe: Some problems related to Rich edit and Tree Pin
Anonymous30-Jul-05 4:36
Anonymous30-Jul-05 4:36 
1) Don't handle NM_CLICK. This only works if you select a tree item
with the mouse. If you use the cursor keys to navigate around the tree,
NM_CLICK does not happen. Use
ON_NOTIFY_REFLECT( TVN_SELCHANGING, OnSelectionChanging)
ON_NOTIFY_REFLECT( TVN_SELCHANGED, OnSelectionChanged)

//this routine is called if tree item is selected.
//Set *pResult to 1 to PREVENT this item from being selected
//Set *pResult to 0 to ALLOW this item from being selected
void CMyTreeView::OnSelectionChanging(NMHDR* pNMHDR, LRESULT* pResult){
NM_TREEVIEW* pTreeView = (NM_TREEVIEW*)pNMHDR;
if(OkayToSelectThisTreeItem(pTreeView)){ //insert your own check
*pResult=0; //item will be selected
}
else{
*pResult=1; //item will not be selected
}
}

//This function is called after a tree item is successfully selected.
//It is also called numerous times when tree branch is
//expanded, collapsed, added or deleted,
//which is why deleting a branch is usually so slow.
//Note: unlike OnSelectionChanging, *pResult is NOT used here
void CMyTreeView::OnSelectionChanged(NMHDR* pNMHDR, LRESULT* pResult){
NM_TREEVIEW* pTV = (NM_TREEVIEW*)pNMHDR;
//figure out which RTF to load
//load the RTF into the window
}

To load the RTF from a file, this is easy.
You can make the RTF a new type of resource.
See http://www.codeproject.com/winhelp/myhelpdialog.asp

GeneralRe: Some problems related to Rich edit and Tree Pin
Anonymous31-Jul-05 8:03
Anonymous31-Jul-05 8:03 
GeneralDialog Position Pin
khlins29-Jul-05 20:49
khlins29-Jul-05 20:49 
GeneralRe: Dialog Position Pin
vishalmore29-Jul-05 21:28
vishalmore29-Jul-05 21:28 
GeneralRe: Dialog Position Pin
khlins30-Jul-05 15:50
khlins30-Jul-05 15:50 
GeneralRe: Dialog Position Pin
ThatsAlok30-Jul-05 4:00
ThatsAlok30-Jul-05 4:00 
Generallinker error Pin
sebinfrancis29-Jul-05 20:11
sebinfrancis29-Jul-05 20:11 
GeneralRe: linker error Pin
sebinfrancis29-Jul-05 23:04
sebinfrancis29-Jul-05 23:04 
GeneralRe: linker error Pin
S. Senthil Kumar29-Jul-05 23:57
S. Senthil Kumar29-Jul-05 23:57 
GeneralSpeech SDK Pin
alex__b29-Jul-05 20:03
professionalalex__b29-Jul-05 20:03 
GeneralRe: Speech SDK Pin
Blake Miller1-Aug-05 8:08
Blake Miller1-Aug-05 8:08 
GeneralRe: Speech SDK Pin
alex__b1-Aug-05 17:52
professionalalex__b1-Aug-05 17:52 
GeneralRe: Speech SDK Pin
Blake Miller2-Aug-05 4:01
Blake Miller2-Aug-05 4:01 
GeneralRe: Speech SDK Pin
alex__b2-Aug-05 4:16
professionalalex__b2-Aug-05 4:16 
GeneralRe: Speech SDK Pin
Blake Miller2-Aug-05 4:34
Blake Miller2-Aug-05 4:34 
GeneralRe: Speech SDK Pin
alex__b2-Aug-05 4:43
professionalalex__b2-Aug-05 4:43 
GeneralEthernet/ network question Pin
Stan the man29-Jul-05 17:27
Stan the man29-Jul-05 17:27 
GeneralRe: Ethernet/ network question Pin
geo_m31-Jul-05 10:12
geo_m31-Jul-05 10:12 

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.