Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS General Discussion » ProfUIS Tree Control and enabling the Window Collapse All
Subject Author Date
ven rag May 21, 2006 - 9:20 AM

I a m using Profuis with MFC

Iam using     CExtWFF < CTreeCtrl > m_wndTree ;
also I have added the ImageList
m_wndPNShortcuts.SetImageList( &m_IL, TVSIL_NORMAL );

I have Abort error when I collapse a selected item in the tree .
for example

-TreeParent1(TreeParent1 as the focus)
+item1
+item2
+item3
+TreeParent2

when I try to Colloapse the tree at the focused position ie at "TreeParent1"
I get Abort Retry and Ignore Dialog
When I Ignore the Tree gets Colloapsed and there is no problem.But I get this Abort error in the Tree control Only When I try to Collapse the Tree
at the Selected or Focused Position of the item in the Tree control.
When I remove the ImageList ie "m_wndPNShortcuts.SetImageList( &m_IL, TVSIL_NORMAL )"
I don’t get this error.
I want to place the image with ProfUIS TreeControl.Please u have any Sample code.Actually I have used the treeControl that u have
used in the ProUIS Sample ie PageNavigator.

The Other Problem that I have is that When I Run the program my Window does not have the Focus.
When I click the Window only the Focus gets placed.
How to make my window Active When I run the Program.

Thank u









ven rag May 25, 2006 - 5:21 AM

U r Right.I get Null Value.I checked it out before itself .
But the thing is When I use the Code without ImageList I Don’t get any error.I get the Handle also .But When I use the ImageList I get Error.
U told me that don’t use ImageList.
So How To add a Image to the treectrl.
Can u give a Sample of CTreeCtrl Over which the Profuis tree is placed with the Image.

thank u.

Technical Support May 25, 2006 - 9:15 AM

We told you try to not use the image list and let us know the results on whether the bug still exists. Of course, you should use the image list if you want to see images in your tree control.

ven rag May 22, 2006 - 9:41 AM

Actually I have used the Sample Program in the PageNavigator.
I am using CExtWFF < CTreeCtrl > m_wndTree; and
SetImageList that was used in the PageNavigator.
So "How to set the Image in the TreeControl "without using ImageList.
Can u please Send me a Sample Code for ProfUIS TreeControl .
Actually Iam getting the ERROR
void CTest::OnItemexpandedTree1(NMHDR* pNMHDR, LRESULT* pResult)
{
    NM_TREEVIEW* pNMTreeView = (NM_TREEVIEW*)pNMHDR;
    HTREEITEM nd=pNMTreeView->itemOld.hItem;
    IDData1 * IDs=(IDData1*)m_tree.GetItemData(nd);<------I get error at this point
---
----
}
I want to add images to my tree .How to do that.I have also asked about the Enabling of Window in the Last Post .

Thank u



Technical Support May 24, 2006 - 1:11 PM

We guess, the HTREEITEM nd in your code is simply equal to NULL because the pNMTreeView->itemOld.hItem is also NULL. Of course you can send us your project so we can find out what’s wrong.

Technical Support May 22, 2006 - 8:39 AM

We have used the CExtWFF template class with CTreeCtrl many times without any problems. So we may guess the problem hides somewhere outside these classes. Please try to do some experiments and find out which parts of your project affect this bug. First of all, do not to use the image list in the tree view control. We can also help you by reviewing your project if you send it to us.