Welcome to SPN

Register and Join the most happening forum of Sikh community & intellectuals from around the world.

Sign Up Now!

Treeview Control

Discussion in 'Information Technology' started by jtardy, Jul 28, 2006.

  1. jtardy

    jtardy
    Expand Collapse
    Guest

    Hi !

    I am coming up against a difficulty on the control treeviwet, and I
    hope you could help me :
    I would like to do a treeview based on a table "tblTreeview" including
    2 fields [ArticleFab], [ArticleComposant].
    The recordings will be like that :
    ArticleFab______ArticleComposant
    1_______________11
    1_______________12
    1_______________13
    12______________121
    12______________122
    2_______________22
    2_______________23
    22______________221
    ....


    A [ArticleFab] also can be [ArticleComposant] or vice versa. Finally
    the article level 1 ("father"?) would be the one which is in
    [ArticleFab] and not in [ArticleComposant].
    So the Treeview would look like that :

    ¤ 1
    __|
    __->11
    __->12
    _____|
    _____->121
    _____->122
    _->13

    ¤ 2
    __|
    __->22
    _____|
    _____->221
    __->23

    My difficulty comes from the code, I don't know how I can supply the
    treeview...

    Thanks for your help.

    But maybe the structure of the initial table is not very suitable, in
    this case, I am waiting for your advises.

    Thanks to everybody for your help.
     
  2. Loading...

    Similar Threads Forum Date
    How To Control The 5 Thieves? Questions and Answers Apr 7, 2016
    General Controlling Kaam (Lust) Hard Talk Apr 8, 2014
    USA Sikh Americans join Barack Obama in urging lawmakers on Gun Control Breaking News Mar 29, 2013
    Controversial SGPC Takes Control of Live Telecast at Bangla Sahib Hard Talk Feb 7, 2013
    USA Sikhs Join Gun Control Debate. Meet with Vice President Biden Breaking News Jan 16, 2013

  3. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    Dim Tw As Access.control
    Dim Rs AS DAO.Recordset

    set Tw = Me.twTreeView
    Set Rs = CurrentDb.OpenRecordset("SELECT DISTINCT ArticleFab FROM
    tblTreeView", DbOpenSnapshot)
    With Tw.Object
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add , , "f" & Rs.Fields(0).Value, Rs.Fields(0).Value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing

    Set Rs = CurrentDb.OpenRecordset("SELECT ArticleFab,ArticleComposant FROM
    tblTreeView", DbOpenSnapshot)
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add "f" & Rs.Fields(0).Value, 4, "c" & Rs.Fields(1).Value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing
    end With

    Pieter

    "jtardy" <jeremietardy@gmail.com> wrote in message
    news:1153143174.256971.275910@35g2000cwc.googlegroups.com...
    Hi !

    I am coming up against a difficulty on the control treeviwet, and I
    hope you could help me :
    I would like to do a treeview based on a table "tblTreeview" including
    2 fields [ArticleFab], [ArticleComposant].
    The recordings will be like that :
    ArticleFab______ArticleComposant
    1_______________11
    1_______________12
    1_______________13
    12______________121
    12______________122
    2_______________22
    2_______________23
    22______________221
    ....


    A [ArticleFab] also can be [ArticleComposant] or vice versa. Finally
    the article level 1 ("father"?) would be the one which is in
    [ArticleFab] and not in [ArticleComposant].
    So the Treeview would look like that :

    ¤ 1
    __|
    __->11
    __->12
    _____|
    _____->121
    _____->122
    _->13

    ¤ 2
    __|
    __->22
    _____|
    _____->221
    __->23

    My difficulty comes from the code, I don't know how I can supply the
    treeview...

    Thanks for your help.

    But maybe the structure of the initial table is not very suitable, in
    this case, I am waiting for your advises.

    Thanks to everybody for your help.
     
  4. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    Dim Tw As Access.control
    Dim Rs AS DAO.Recordset

    set Tw = Me.twTreeView
    Set Rs = CurrentDb.OpenRecordset("SELECT DISTINCT ArticleFab FROM
    tblTreeView", DbOpenSnapshot)
    With Tw.Object
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add , , "f" & Rs.Fields(0).Value, Rs.Fields(0).Value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing

    Set Rs = CurrentDb.OpenRecordset("SELECT ArticleFab,ArticleComposant FROM
    tblTreeView", DbOpenSnapshot)
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add "f" & Rs.Fields(0).Value, 4, "c" & Rs.Fields(1).Value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing
    end With

    Pieter

    "jtardy" <jeremietardy@gmail.com> wrote in message
    news:1153143174.256971.275910@35g2000cwc.googlegroups.com...
    Hi !

    I am coming up against a difficulty on the control treeviwet, and I
    hope you could help me :
    I would like to do a treeview based on a table "tblTreeview" including
    2 fields [ArticleFab], [ArticleComposant].
    The recordings will be like that :
    ArticleFab______ArticleComposant
    1_______________11
    1_______________12
    1_______________13
    12______________121
    12______________122
    2_______________22
    2_______________23
    22______________221
    ....


    A [ArticleFab] also can be [ArticleComposant] or vice versa. Finally
    the article level 1 ("father"?) would be the one which is in
    [ArticleFab] and not in [ArticleComposant].
    So the Treeview would look like that :

    ¤ 1
    __|
    __->11
    __->12
    _____|
    _____->121
    _____->122
    _->13

    ¤ 2
    __|
    __->22
    _____|
    _____->221
    __->23

    My difficulty comes from the code, I don't know how I can supply the
    treeview...

    Thanks for your help.

    But maybe the structure of the initial table is not very suitable, in
    this case, I am waiting for your advises.

    Thanks to everybody for your help.



    --
    ----------------------------------------
    I am using the free version of SPAMfighter for private users.
    It has removed 4231 spam emails to date.
    Paying users do not have this message in their emails.
    Get the free SPAMfighter here: http://www.spamfighter.com/len
     
  5. jtardy

    jtardy
    Expand Collapse
    Guest

    Hi Pieter, everybody

    Thanks you very much for your help.
    But i've a problem with .twTreeView -> error of compilation, member of
    method or data untraceable ?
    I use Access 97, perhaps i miss some references ?

    Excuse me for my average English

    Bye



    Pieter Wijnen a écrit :

    > Dim Tw As Access.control
    > Dim Rs AS DAO.Recordset
    >
    > set Tw = Me.twTreeView
    > Set Rs = CurrentDb.OpenRecordset("SELECT DISTINCT ArticleFab FROM
    > tblTreeView", DbOpenSnapshot)
    > With Tw.Object
    > VBA.Err.Clear
    > While Not Rs.EOF
    > .Nodes.Add , , "f" & Rs.Fields(0).Value, Rs.Fields(0).Value
    > Rs.MoveNext
    > Wend
    > Rs.Close: Set Rs = Nothing
    >
    > Set Rs = CurrentDb.OpenRecordset("SELECT ArticleFab,ArticleComposant FROM
    > tblTreeView", DbOpenSnapshot)
    > VBA.Err.Clear
    > While Not Rs.EOF
    > .Nodes.Add "f" & Rs.Fields(0).Value, 4, "c" & Rs.Fields(1).Value
    > Rs.MoveNext
    > Wend
    > Rs.Close: Set Rs = Nothing
    > end With
    >
    > Pieter
    >
     
  6. AudreyJeremie@gmail.com

    AudreyJeremie@gmail.com
    Expand Collapse
    Guest

    Sorry i said a mistake. It was just a problem with the object's name !

    But now the Treeview would look like that :
    1
    |___
    |___
    |___
    2
    |___
    |___
    12
    |___
    |___
    22
    |___

    With this table:
    ArticleFab ArticleComposant
    1 11
    1 12
    1 13
    12 121
    12 122
    2 22
    2 23
    22 221

    It's not exactely what i hope ;-)

    Thanks
     
  7. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    my mistake

    Dim Tw As Access.control
    Dim Rs AS DAO.Recordset

    set Tw = Me.twTreeView
    Set Rs = CurrentDb.OpenRecordset("SELECT DISTINCT ArticleFab FROM
    tblTreeView", DbOpenSnapshot)
    With Tw.Object
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add , , "f" & Rs.Fields(0).Value, Rs.Fields(0).Value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing

    Set Rs = CurrentDb.OpenRecordset("SELECT ArticleFab,ArticleComposant FROM
    tblTreeView", DbOpenSnapshot)
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add "f" & Rs.Fields(0).Value, 4, "c" & Rs.Fields(1).Value,
    Rs.Fields(1).Value ' Missed out the display value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing
    end With

    Pieter


    <AudreyJeremie@gmail.com> wrote in message
    news:1153212815.767499.84100@s13g2000cwa.googlegroups.com...
    > Sorry i said a mistake. It was just a problem with the object's name !
    >
    > But now the Treeview would look like that :
    > 1
    > |___
    > |___
    > |___
    > 2
    > |___
    > |___
    > 12
    > |___
    > |___
    > 22
    > |___
    >
    > With this table:
    > ArticleFab ArticleComposant
    > 1 11
    > 1 12
    > 1 13
    > 12 121
    > 12 122
    > 2 22
    > 2 23
    > 22 221
    >
    > It's not exactely what i hope ;-)
    >
    > Thanks
    >
     
  8. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    my mistake

    Dim Tw As Access.control
    Dim Rs AS DAO.Recordset

    set Tw = Me.twTreeView
    Set Rs = CurrentDb.OpenRecordset("SELECT DISTINCT ArticleFab FROM
    tblTreeView", DbOpenSnapshot)
    With Tw.Object
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add , , "f" & Rs.Fields(0).Value, Rs.Fields(0).Value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing

    Set Rs = CurrentDb.OpenRecordset("SELECT ArticleFab,ArticleComposant FROM
    tblTreeView", DbOpenSnapshot)
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add "f" & Rs.Fields(0).Value, 4, "c" & Rs.Fields(1).Value,
    Rs.Fields(1).Value ' Missed out the display value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing
    end With

    Pieter


    <AudreyJeremie@gmail.com> wrote in message
    news:1153212815.767499.84100@s13g2000cwa.googlegroups.com...
    > Sorry i said a mistake. It was just a problem with the object's name !
    >
    > But now the Treeview would look like that :
    > 1
    > |___
    > |___
    > |___
    > 2
    > |___
    > |___
    > 12
    > |___
    > |___
    > 22
    > |___
    >
    > With this table:
    > ArticleFab ArticleComposant
    > 1 11
    > 1 12
    > 1 13
    > 12 121
    > 12 122
    > 2 22
    > 2 23
    > 22 221
    >
    > It's not exactely what i hope ;-)
    >
    > Thanks
    >




    --
    ----------------------------------------
    I am using the free version of SPAMfighter for private users.
    It has removed 4282 spam emails to date.
    Paying users do not have this message in their emails.
    Get the free SPAMfighter here: http://www.spamfighter.com/len
     
  9. jtardy

    jtardy
    Expand Collapse
    Guest

    ok ! with this code the result is now :
    1
    |___ 11
    |___ 12
    |___ 13
    2
    |___ 22
    |___ 23
    12
    |___ 121
    |___ 122
    22
    |___ 221

    but 12 & 22 are not at the level 1, they must be under 12 & 22 like
    that ;-)
    1
    |___ 11
    |___ 12
    |___ 121
    |___ 122
    |___ 13

    2
    |___ 22
    |___ 221
    |___ 23

    so to define the level i use on the first node
    "SELECT DISTINCT tblTreeview1.ArticleFab FROM tblTreeview AS
    tblTreeview1 LEFT JOIN tblTreeview AS tblTreeview2 ON
    tblTreeview1.ArticleFab = tblTreeview2.ArticleComposant WHERE
    (((tblTreeview2.ArticleComposant) Is Null))"
    and i've an error 35601 Element not found on .Nodes.Add "f" &
    Rs.Fields(0).Value, 4, "c" & Rs.Fields(1).Value, Rs.Fields(1).Value on
    the 2nd node

    thank you very much...
     
  10. jtardy

    jtardy
    Expand Collapse
    Guest

    there is another possibility of which I had not thought: one
    [ArtccComposant] can be in several [ArtccFab], therefore in several
    nodes!
    for example if i add the recordset :
    ArticleFab______ArticleComposant
    1______________22

    22 is in 1 & 2 so i've an error : key is not unique in collection !!!

    thanks you very much...
     
  11. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    Try something like

    Dim Tw As Access.control
    Dim Rs AS DAO.Recordset

    set Tw = Me.twTreeView
    Set Rs = CurrentDb.OpenRecordset("SELECT ArticleFab FROM
    tblTreeView WHERE ARTICLEComposant Is Null", DbOpenSnapshot)
    With Tw.Object
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add , , "f" & Rs.Fields(0).Value, Rs.Fields(0).Value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing

    Set Rs = CurrentDb.OpenRecordset("SELECT ArticleFab,ArticleComposant FROM
    tblTreeView Where ArticleComposant Is Not Null ORDER By
    Len(ArticleComposant)", DbOpenSnapshot)
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add "f" & Rs.Fields(0).Value, 4, "c" & Rs.Fields(0).Value &
    Rs.Fields(1).Value, Rs.Fields(1).Value ' Missed out the display value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing
    end With

    Pieter


    "jtardy" <jeremietardy@gmail.com> wrote in message
    news:1153224523.194471.117960@m79g2000cwm.googlegroups.com...
    > there is another possibility of which I had not thought: one
    > [ArtccComposant] can be in several [ArtccFab], therefore in several
    > nodes!
    > for example if i add the recordset :
    > ArticleFab______ArticleComposant
    > 1______________22
    >
    > 22 is in 1 & 2 so i've an error : key is not unique in collection !!!
    >
    > thanks you very much...
    >
     
  12. Pieter Wijnen

    Pieter Wijnen
    Expand Collapse
    Guest

    Try something like

    Dim Tw As Access.control
    Dim Rs AS DAO.Recordset

    set Tw = Me.twTreeView
    Set Rs = CurrentDb.OpenRecordset("SELECT ArticleFab FROM
    tblTreeView WHERE ARTICLEComposant Is Null", DbOpenSnapshot)
    With Tw.Object
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add , , "f" & Rs.Fields(0).Value, Rs.Fields(0).Value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing

    Set Rs = CurrentDb.OpenRecordset("SELECT ArticleFab,ArticleComposant FROM
    tblTreeView Where ArticleComposant Is Not Null ORDER By
    Len(ArticleComposant)", DbOpenSnapshot)
    VBA.Err.Clear
    While Not Rs.EOF
    .Nodes.Add "f" & Rs.Fields(0).Value, 4, "c" & Rs.Fields(0).Value &
    Rs.Fields(1).Value, Rs.Fields(1).Value ' Missed out the display value
    Rs.MoveNext
    Wend
    Rs.Close: Set Rs = Nothing
    end With

    Pieter


    "jtardy" <jeremietardy@gmail.com> wrote in message
    news:1153224523.194471.117960@m79g2000cwm.googlegroups.com...
    > there is another possibility of which I had not thought: one
    > [ArtccComposant] can be in several [ArtccFab], therefore in several
    > nodes!
    > for example if i add the recordset :
    > ArticleFab______ArticleComposant
    > 1______________22
    >
    > 22 is in 1 & 2 so i've an error : key is not unique in collection !!!
    >
    > thanks you very much...
    >




    --
    ----------------------------------------
    I am using the free version of SPAMfighter for private users.
    It has removed 4285 spam emails to date.
    Paying users do not have this message in their emails.
    Get the free SPAMfighter here: http://www.spamfighter.com/len
     
  13. jtardy

    jtardy
    Expand Collapse
    Guest

    thanks pieter

    do you have an idea for my last problem...

    "there is another possibility of which I had not thought: one
    [ArtccComposant] can be in several [ArtccFab], therefore in several
    nodes!
    for example if i add the recordset :
    ArticleFab______ArticleComposant
    1______________22

    22 is in 1 & 2 so i've an error : key is not unique in collection !!!


    thanks you very much... "
     
  14. Douglas J. Steele

    Douglas J. Steele
    Expand Collapse
    Guest

    You have to create a unique key for each node. I typically concatenate the
    various node values together to create the key, so that I'd have A1B22 and
    A2B22 for the two nodes. That lets me easily decompose the trail if I need
    to.

    --
    Doug Steele, Microsoft Access MVP
    http://I.Am/DougSteele
    (no e-mails, please!)


    "jtardy" <jeremietardy@gmail.com> wrote in message
    news:1153305389.253690.305900@m79g2000cwm.googlegroups.com...
    > thanks pieter
    >
    > do you have an idea for my last problem...
    >
    > "there is another possibility of which I had not thought: one
    > [ArtccComposant] can be in several [ArtccFab], therefore in several
    > nodes!
    > for example if i add the recordset :
    > ArticleFab______ArticleComposant
    > 1______________22
    >
    > 22 is in 1 & 2 so i've an error : key is not unique in collection !!!
    >
    >
    > thanks you very much... "
    >
     
  15. jtardy

    jtardy
    Expand Collapse
    Guest

    ok, so you think i've to create an other field in my table with the
    concatenate of the 2 others fields and i'll have a unique key ?
    and after, how i can modify the code to supply the treeview ?

    thank you very much for your help
     
  16. Douglas J. Steele

    Douglas J. Steele
    Expand Collapse
    Guest

    You have to create unique keys for each node. You can do that in a number of
    ways: concatenate a letter with sequential or random numbers, concatenate
    keys from multiple nodes, or whatever works for you.

    Unfortunately, without knowing the actual code you're using, I can't offer
    suggestions on how to modify it.

    --
    Doug Steele, Microsoft Access MVP
    http://I.Am/DougSteele
    (no e-mails, please!)


    "jtardy" <jeremietardy@gmail.com> wrote in message
    news:1153311141.417742.211990@s13g2000cwa.googlegroups.com...
    > ok, so you think i've to create an other field in my table with the
    > concatenate of the 2 others fields and i'll have a unique key ?
    > and after, how i can modify the code to supply the treeview ?
    >
    > thank you very much for your help
    >
     
  17. jtardy

    jtardy
    Expand Collapse
    Guest

    thanks good idea ;-)

    i'm using this code :
    '===============================================================
    Public Sub FillTreeview(Tree As Object, Article_Fab As Long)
    Dim Sql As String
    Dim Rs As DAO.Recordset
    Dim Art_Fab As Long

    If Article_Fab = 0 Then ' premier niveau
    Sql = "SELECT DISTINCT tblTreeview1.ArticleFab FROM tblTreeview AS
    tblTreeview1 LEFT JOIN tblTreeview AS tblTreeview2 ON
    tblTreeview1.ArticleFab = tblTreeview2.ArticleComposant WHERE
    (((tblTreeview2.ArticleComposant) Is Null))"
    Set Rs = CurrentDb.OpenRecordset(Sql, dbOpenSnapshot)

    Do Until Rs.EOF
    Tree.Nodes.Add , , "f" & Rs!ArticleFab, Rs!ArticleFab
    Tree.Nodes("f" & Rs!ArticleFab).EnsureVisible

    FillTreeview Tree, Rs!ArticleFab
    Rs.MoveNext
    Loop

    Else
    Sql = "select * from tblTreeview where [ArticleFab]=" & Article_Fab
    & _
    " order by ArticleComposant;"
    Set Rs = CurrentDb.OpenRecordset(Sql, dbOpenSnapshot)

    Do Until Rs.EOF
    Tree.Nodes.Add "f" & Article_Fab, tvwChild, "f" &
    Rs!ArticleComposant, Rs!ArticleComposant
    Tree.Nodes("f" & Rs!ArticleComposant).EnsureVisible

    FillTreeview Tree, Rs!ArticleComposant
    Rs.MoveNext
    Loop

    End If

    Rs.Close: Set Rs = Nothing

    End Sub
    '===============================================================
    Private Sub Form_Open(Cancel As Integer)
    Dim Tw As Access.Control
    Set Tw = Me.twTreeView
    FillTreeview Tw.Object, 0
    End Sub
    '===============================================================

    The third fields with the concatenation was named [ArticleId].
    The recordset look like this :
    ArticleFab ArticleComposant ArticleId
    1 11 1
    1 12 2
    1 13 3
    12 121 4
    12 122 5
    2 22 6
    2 23 7
    22 221 8

    Thanks
     
  18. Douglas J. Steele

    Douglas J. Steele
    Expand Collapse
    Guest

    Since you're only adding 1 level of children, I think the only change you
    need is to change

    Tree.Nodes.Add "f" & Article_Fab, tvwChild, "f" & Rs!ArticleComposant,
    Rs!ArticleComposant

    to

    Tree.Nodes.Add "f" & Article_Fab, tvwChild, "f" & Article_Fab & "f" &
    Rs!ArticleComposant, Rs!ArticleComposant



    --
    Doug Steele, Microsoft Access MVP
    http://I.Am/DougSteele
    (no e-mails, please!)


    "jtardy" <jeremietardy@gmail.com> wrote in message
    news:1153324411.211203.132580@75g2000cwc.googlegroups.com...
    > thanks good idea ;-)
    >
    > i'm using this code :
    > '===============================================================
    > Public Sub FillTreeview(Tree As Object, Article_Fab As Long)
    > Dim Sql As String
    > Dim Rs As DAO.Recordset
    > Dim Art_Fab As Long
    >
    > If Article_Fab = 0 Then ' premier niveau
    > Sql = "SELECT DISTINCT tblTreeview1.ArticleFab FROM tblTreeview AS
    > tblTreeview1 LEFT JOIN tblTreeview AS tblTreeview2 ON
    > tblTreeview1.ArticleFab = tblTreeview2.ArticleComposant WHERE
    > (((tblTreeview2.ArticleComposant) Is Null))"
    > Set Rs = CurrentDb.OpenRecordset(Sql, dbOpenSnapshot)
    >
    > Do Until Rs.EOF
    > Tree.Nodes.Add , , "f" & Rs!ArticleFab, Rs!ArticleFab
    > Tree.Nodes("f" & Rs!ArticleFab).EnsureVisible
    >
    > FillTreeview Tree, Rs!ArticleFab
    > Rs.MoveNext
    > Loop
    >
    > Else
    > Sql = "select * from tblTreeview where [ArticleFab]=" & Article_Fab
    > & _
    > " order by ArticleComposant;"
    > Set Rs = CurrentDb.OpenRecordset(Sql, dbOpenSnapshot)
    >
    > Do Until Rs.EOF
    > Tree.Nodes.Add "f" & Article_Fab, tvwChild, "f" &
    > Rs!ArticleComposant, Rs!ArticleComposant
    > Tree.Nodes("f" & Rs!ArticleComposant).EnsureVisible
    >
    > FillTreeview Tree, Rs!ArticleComposant
    > Rs.MoveNext
    > Loop
    >
    > End If
    >
    > Rs.Close: Set Rs = Nothing
    >
    > End Sub
    > '===============================================================
    > Private Sub Form_Open(Cancel As Integer)
    > Dim Tw As Access.Control
    > Set Tw = Me.twTreeView
    > FillTreeview Tw.Object, 0
    > End Sub
    > '===============================================================
    >
    > The third fields with the concatenation was named [ArticleId].
    > The recordset look like this :
    > ArticleFab ArticleComposant ArticleId
    > 1 11 1
    > 1 12 2
    > 1 13 3
    > 12 121 4
    > 12 122 5
    > 2 22 6
    > 2 23 7
    > 22 221 8
    >
    > Thanks
    >
     
  19. jtardy

    jtardy
    Expand Collapse
    Guest

Share This Page