Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Do ...
Message
 
À
14/02/1999 22:26:12
Information générale
Forum:
Visual Basic
Catégorie:
Autre
Titre:
Re: Do ...
Divers
Thread ID:
00187577
Message ID:
00187724
Vues:
21
>Actually .. this is a very simple problem .. but I don't understand why .. VB6 give me the error message "No current record" .. can anybody explain to me .. please .. the statement is below :
>
>
>
>Customer.MoveFirst
>With Customer
>Do
> mCustomerCode=!CustomerCode
> While NOT .EOF and mCustomerCode=!CustomerCode
> txtShow.Text = !CustomerCode
> .MoveNext
> Wend
>Loop Until .EOF
>.Close

Put the test condition at the beginning of the loop
With Customer
if not .eof then
.MoveFirst
Do Until .EOF
mCustomerCode=!CustomerCode
While NOT .EOF and mCustomerCode=!CustomerCode
txtShow.Text = !CustomerCode
.MoveNext
Wend
Loop
end if
.Close
Éric Moreau, MCPD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Moer inc.
http://www.emoreau.com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform