Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
&
Message
De
16/12/1998 06:07:37
Jody Cairns
OAO Technology Solutions
Moncton, Nouveau-Brunswick, Canada
 
 
À
16/12/1998 02:29:19
Information générale
Forum:
Visual Basic
Catégorie:
Autre
Titre:
Re: &
Divers
Thread ID:
00167929
Message ID:
00167961
Vues:
21
>I want to make simple in my program ....
>Anybody can correct my program please ... ?
> For mSize = 1 To 14
> mstrsize = Right("0" + LTrim(Str(mSize)), 2) ' returns 01 - 14
> mqty = "QTY" & mstrsize ' returns QTY01 - QTY14
> mmSize = Qtylist.Recordset("'" & mqty & "'") ' the problem
> msgbox mmSize ' to show one by one Qty from Qty01 - Qty14
> Next mSize

First, if you want to display your code exactly how it is typed, enclose the code between <pre> and </pre>

Second, in the line

mmSize = Qtylist.Recordset("'" & mqty & "'")

you are sending the Recordset object the string 'QTY01', etc. It appears you want to access a field value from a database table or query. The way you are doing it assumes your recordset has fields names QTY01 up to QTY14.

If that is the case, the line should be:

mmSize = Qtylist.Recordset(mqty)


Does that help?

best,

jody
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform