SAMPLE OF A TREEVIEW WITH MDB

SAMPLE OF A TREEVIEW WITH MDB

Postby Silvio » Sat Feb 09, 2008 9:44 pm

TO OPEN A FILE i MADE :

oRs = CREATEOBJECT( "ADODB.Recordset" )
TRY
oRS:Open( "SELECT * FROM CATEGORIE ORDER BY SCATEGORIE", "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=ecom.mdb", 1, 3 )

CATCH oErr
? oErr:Description
RETURN NIL
END TRY


NOW i MUST CREATE A LISTBOX TREEVIEW WITH THIS MAP

sCATEGORIE
-----> CATEGORIE
-----> CATEGORIE
sCATEGORIE
-----> CATEGORIE

HAVE YOU ANY SAMPLE ?
Best Regards, Saludos

Falconi Silvio
User avatar
Silvio
 
Posts: 3107
Joined: Fri Oct 07, 2005 6:28 pm
Location: Teramo,Italy

Postby nageswaragunupudi » Sun Feb 10, 2008 2:43 am

Mr Silvio

There are several ways. I shall post two alternatives. Pl give me some time
Regards

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

Re: SAMPLE OF A TREEVIEW WITH MDB

Postby Enrico Maria Giordano » Sun Feb 10, 2008 8:20 am

Silvio wrote:TO OPEN A FILE i MADE :

oRs = CREATEOBJECT( "ADODB.Recordset" )
TRY
oRS:Open( "SELECT * FROM CATEGORIE ORDER BY SCATEGORIE", "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=ecom.mdb", 1, 3 )

CATCH oErr
? oErr:Description
RETURN NIL
END TRY


NOW i MUST CREATE A LISTBOX TREEVIEW WITH THIS MAP

sCATEGORIE
-----> CATEGORIE
-----> CATEGORIE
sCATEGORIE
-----> CATEGORIE

HAVE YOU ANY SAMPLE ?


You can use TTreeView class.

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8710
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Postby nageswaragunupudi » Sun Feb 10, 2008 9:20 am

Mr Silvio

I sent a small sample to your personal email. Yes it uses TTreeView also as one of the alternatives.

Incidentally there is another way of reading parent - child relationships, which is called DataShaping. I did not include this, because it is more advanced and complex
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10624
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 66 guests

cron