Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
FTP download
Message
General information
Forum:
Visual Basic
Category:
Internet applications
Title:
Miscellaneous
Thread ID:
00424786
Message ID:
00432389
Views:
16
>I thought if you can see the code, it will be easy to help me out.
>
>This DATABASE.Recordset table has a field("Quantity"). I am looping this table
>and writing to oTable.
>if the quantity in the DATABASE.Recordset.Fields("QUANTITY").Value = 5
>I have to add 5 records to the oTable.
>
> ..snip...
>
> If OrdQuantity > 0 Then
> For RecCount = 1 To OrdQuantity
> oTable.AddNew
> oTable.Fields("ITEM").Value = ItmName
> oTable.Fields("DESC").Value = ItmDESC
> oTable.Fields("QUANTITY").Value = OrdQuantity
> oTable.MoveNext
> Next
> End If
> DATABASE.Recordset.MoveNext
>

Hi Lal,

Where are you updating the recordset? You call oTable.AddNew, populate some fields, but do not update it. You do not need to call oTable.MoveNext at all, as it will not update the data.

Replace the oTable.MoveNext statement with an oTable.Update and you should have it.
Phil
_____________________________
Phil Miles
http://www.philmiles.com
phil@philmiles.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform