loading contacts takes a while (General questions)

by yonko, (4922 days ago)

when it comes to login, it takes some time to load contacts into the Contacts property. Is there any other option to get a complete list of contacts than to guess how many seconds to wait?


.oXMPP.Blocking = .T.
.oXMPP.Connect(.cServer)
lnCount=.oXMPP.Contacts.Count -> returns 0


.oXMPP.Blocking = .T.
.oXMPP.Connect(.cServer)
lnsec=SECONDS()
DO WHILE (SECONDS()-lnsec)<1 && wait 1 second
ENDDO
lnCount=.oXMPP.Contacts.Count -> returns 12, sometimes 11

(on the server is 12 contacts. what if they will be 100?)

locked

Complete thread: