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 Tech Support » HTREEITEM from cell Collapse All
Subject Author Date
Offer Har Feb 28, 2008 - 9:13 AM

Dear Support,

I have a cell pointer, and I need to get the HTREEITEM of it.
How can I do it? I only sea a method ItemGetByVisibleRowIndex, but I need ItemGetByRowIndex, not visible row.

Thanks,
Ron.

Offer Har Mar 1, 2008 - 8:29 AM

Dear Support,

This is a major hit to our applications. We are trying to have an object oriented approach in which the cells manage themselves.
Can you please explain what is the benefit of one cell instance appearing in more then one grid? this is something I did not hear before, and I don’t think I used.
Also, assuming that I ask the grid - Give me the HTREEITEM of row X regardless of a specific cell, what is the problem?

Thanks,
Ron.

Technical Support Mar 1, 2008 - 8:21 AM

You cannot get any grid coordinates from a grid cell. You even cannot get a pointer to the grid window from a grid cell because the cell can be displayed in more than one grids or it may be not in the grid at all. The CExtTreeGridWnd::ItemGetByVisibleRowIndex() and CExtTreeGridWnd::ItemGetVisibleIndexOf() methods allow you to perform conversion between a plain row number and a HTREEITEM row handle. It’s not possible to get a plain index for a hidden row and for a row whose parent is collapsed. In these cases CExtTreeGridWnd::ItemGetVisibleIndexOf() returns a negative value.