Visual Basic Code , VB.NET Code, VB Code
  Home   :  Code   :  Forums   :  Submit   :  Mailing List   :  About   :  Contact
A1VBCode Forums
Home      Members   Calendar   Who's On
Welcome Guest ( Login | Register )
      

Home » Visual Basic (VB 4/5/6) » General Visual Basic » about my counter and date


about my counter and dateExpand / Collapse
Author
Message
Posted 11/19/2008 9:13:13 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Forum Members
Last Login: 11/24/2008 3:26:09 AM
Posts: 1, Visits: 14
Hi good day to all. I'm a beginner of vb6. Right now I'm doing my first project which is the Sales System of a resto bar. I encounter some errors though this is just a minimal but I'm already stack in this part. This is about my counter as well as displaying the totals sales in descending order. The Code of my counter that I make doesn't work again and also in displaying the total sales in descending order. anybody can help me on this....


-----------------------------------------------------------------
counter

For i = 1 To grd.Rows - 1
With INV
If grd.TextMatrix(i, 0) = INV!ProdCode Then
.Edit
!Quantity = !Quantity + Val(grd.TextMatrix(i, 3))
.Update
Else
.AddNew
!ProdCode = grd.TextMatrix(i, 0)
!ProdName = grd.TextMatrix(i, 2)
!Quantity = grd.TextMatrix(i, 3)
!Date = DTPicker1.Value
.Update
End If
End With
Next i

---------------------------------------------------------------------------------------
Display the Total Sale in descending order

Set SH = Dbase.OpenRecordset("Select * from SalesHeader where iDate <= cDate (' " & CStr(DTPicker1.Value) & " ') and iDate >= cDate(' " & CStr(DTPicker2.Value) & " ')Order by cDate Desc ")

----------------------------------------------------------------------------


Regards

Denine
Post #26283
« Prev Topic | Next Topic »


Reading This TopicExpand / Collapse
Active Users: 1 (1 guest, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: Brian, Peter

PermissionsExpand / Collapse

All times are GMT -5:00, Time now is 3:37pm