xBrowse Tree with Checkbox

xBrowse Tree with Checkbox

Postby fraxzi » Thu Mar 24, 2011 5:52 am

Dear All,


Anyone has this created Tree with xbrowse with checkbox on tree item?

Kind Regards,
Frances
Kind Regards,
Frances

Fivewin for xHarbour v18.07
xHarbour v1.2.3.x
BCC 7.3 + PellesC8 ( Resource Compiler only)
ADS 10.1 / MariaDB
Crystal Reports 8.5/9.23 DE
xMate v1.15
User avatar
fraxzi
 
Posts: 811
Joined: Tue May 06, 2008 4:28 am
Location: Philippines

Re: xBrowse Tree with Checkbox

Postby nageswaragunupudi » Thu Mar 24, 2011 6:29 am

Using ADD TO oBrw, add a column with appropriate logical expression as DATA and use method oCol:SetCheck()
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10631
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: xBrowse Tree with Checkbox

Postby fraxzi » Thu Mar 24, 2011 6:59 am

nageswaragunupudi wrote:Using ADD TO oBrw, add a column with appropriate logical expression as DATA and use method oCol:SetCheck()



Dear Mr. RAO,


That is what I have right now... I mean the checkbox integrated with oTreeitem... as image?


Kind Regards,
Frances
Kind Regards,
Frances

Fivewin for xHarbour v18.07
xHarbour v1.2.3.x
BCC 7.3 + PellesC8 ( Resource Compiler only)
ADS 10.1 / MariaDB
Crystal Reports 8.5/9.23 DE
xMate v1.15
User avatar
fraxzi
 
Posts: 811
Joined: Tue May 06, 2008 4:28 am
Location: Philippines

Re: xBrowse Tree with Checkbox

Postby nageswaragunupudi » Thu Mar 24, 2011 11:21 am

Do you want it as a bitmap inside the column displaying treeitem:cPrompt ?

In that case, add bmpdata to oBrw:aCols[ 1 ] and add bitmaps to this column
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10631
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: xBrowse Tree with Checkbox

Postby fraxzi » Thu Mar 24, 2011 12:19 pm

nageswaragunupudi wrote:Do you want it as a bitmap inside the column displaying treeitem:cPrompt ?

In that case, add bmpdata to oBrw:aCols[ 1 ] and add bitmaps to this column



Dear Mr. RAO,

Thank you for your reply.. This is my situation..
Here's the screenshoot of what I have right now..

Image

There is bitmap for each tree Item.. can I put another bitmap after the other indicating check/uncheck? then no more :setcheck() on the second column..

Kind Regards,
Frances
Kind Regards,
Frances

Fivewin for xHarbour v18.07
xHarbour v1.2.3.x
BCC 7.3 + PellesC8 ( Resource Compiler only)
ADS 10.1 / MariaDB
Crystal Reports 8.5/9.23 DE
xMate v1.15
User avatar
fraxzi
 
Posts: 811
Joined: Tue May 06, 2008 4:28 am
Location: Philippines

Re: xBrowse Tree with Checkbox

Postby nageswaragunupudi » Thu Mar 24, 2011 2:09 pm

You may need two bitmaps ( selected and unselected ) for the last level. Once you add bitmaps, it is a matter of changing the bBmpData of the first column. You may copy the original codeblock from the settree method and suitably modify it.

Still I personally feel that it may not look good aesthetically. My personal preference would be to insert a separate column before the present first column to show the checkboxes. This would also look similar to Windows 7 selection check boxes.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10631
Joined: Sun Nov 19, 2006 5:22 am
Location: India


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 53 guests