Click here to Skip to main content
11,718,016 members (80,691 online)
Rate this: bad
Please Sign up or sign in to vote.
See more: Windows VB.NET
Hi all

I wrote the below to and loading the data in listview

          ParentEntry.Path = "WinNT:"
          For Each childEntry In ParentEntry.Children
              Select Case childEntry.SchemaClassName
                  Case "Domain"

                      SubParentEntry.Path = "WinNT://" & childEntry.Name
                      For Each SubChildEntry In SubParentEntry.Children
                          Select Case SubChildEntry.SchemaClassName
                              Case "Computer"
                          End Select
              End Select
      Catch Excep As Exception
          MsgBox("Error While Reading Directories")
          ParentEntry = Nothing
      End Try

now i want to referesh this after a certain interval of time..please tel me how to do..

Thank you
Posted 15-Jan-13 22:51pm

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

chek this link[^]

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
ListBox1.Items.Add("First Item")
ListBox1.Items.Add("Second Item")
ListBox1.Items.Add("Third Item")
ListBox1.Items.Add("Fourth Item")
ListBox1.SelectedIndex = 0
Timer1.Interval = 500
End Sub
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
Dim i As Integer
i = ListBox1.SelectedIndex
i = i + 1
If i > ListBox1.Items.Count - 1 Then i = 0
ListBox1.SelectedIndex = i
End Sub
OneInNineMillion at 17-Jan-13 3:52am
That link seems very helpful. The code doesn't seem to do what's suggested on the other forums though.
Darn ListBoxes, I would just avoid using them lol. Pro approach. Challenge Avoided!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 215
1 F-ES Sitecore 210
2 Maciej Los 140
3 Jochen Arndt 120
4 Andy Lanng 115
0 Sergey Alexandrovich Kryukov 1,649
1 OriginalGriff 535
2 Maciej Los 529
3 Richard MacCutchan 440
4 CHill60 415

Advertise | Privacy | Mobile
Web01 | 2.8.150901.1 | Last Updated 16 Jan 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100