Delphi Pages Forums  

Go Back   Delphi Pages Forums > Delphi Forum > General

Lost Password?

Thread Tools Display Modes
Old 02-20-2001, 09:24 PM
eugene_m eugene_m is offline
Junior Member
Join Date: Feb 2001
Posts: 1
Default Printing TTreeView on Quick Report

Can anybody tell me how to print TTreeView on Quick Report.
Thank you

My email
Reply With Quote
Old 02-21-2001, 06:23 AM
Claude Claude is offline
Senior Member
Join Date: Jan 2001
Posts: 178
Default RE: Printing TTreeView on Quick Report

Printing a TTreeView in not something trivial. It can be made of thousand of nodes, each of which possibly having thousand of subnodes, and so on.

What I would recomand is to limit the number of levels to an arbitrary number, let's say 10, so the report width fits into a page. Then, use a Memory Dataset (A good one comes with DevExpress's Quantum Grid but there are some that you can download here and there). This dataset can be comprised of only one Text Field that will content the Node Text property but you may add other fields as well (a Blob field could contain the node bitmap).

While you browse thru each node of the TTreeView, grap the Text property of the Node and use the Level property to add some spaces in front of the Text. So a Level 0 node will have its text stored as "Some Text", a Level 1 node will be " Some Text", a Level 2 node will be " Some Text" and so on.

All there is left to do is to connect the QuickReport to your dataset.
Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump

All times are GMT. The time now is 04:04 PM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2019, vBulletin Solutions, Inc.