| | |
saving array of text5(i).text
Please support our Visual Basic 4 / 5 / 6 advertiser: Programming Forums - DaniWeb Sister Site
![]() |
•
•
Join Date: Sep 2006
Posts: 26
Reputation:
Solved Threads: 0
i have a search program that when searched i will make a receipt, a reciept form will be displayed, the
1st item searched will be displayed on text1(0).text and the quantity also will be displayed in text5(0).text
my problem is how to subtract the stock items minus the quantity text5(0).text(its an array of text5(i).text
in frmsearch i have this for a code:
in frmReciept i have this for a code
i want that everytime i add a product in the receipt, the stocks of that particular item will deducted with the quantity purchased
(frmReciept.Text5(i).Text) can anyone help
1st item searched will be displayed on text1(0).text and the quantity also will be displayed in text5(0).text
my problem is how to subtract the stock items minus the quantity text5(0).text(its an array of text5(i).text
in frmsearch i have this for a code:
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
repeat = 1 If Adodc1.Recordset.RecordCount > 0 Then Ono1 = Adodc1.Recordset.Fields("Price") Ono2 = Adodc1.Recordset.Fields("Carmodel") Ono6 = Adodc1.Recordset.Fields("Category") Ono3 = Adodc1.Recordset.Fields("PartNo2") Ono4 = Adodc1.Recordset.Fields("CarApp") Ono5 = Adodc1.Recordset.Fields("Year") stock = Adodc1.Recordset.Fields("Stocks") For i = 0 To 4 If repeat = 1 Then Do While frmReciept.Text4(i).Text = "" And frmReciept.Text6(i).Text = "" frmReciept.Text4(i).Text = Ono2 & " " & Ono6 & " " & Ono3 & " " & Ono4 & " " & Ono5 repeat = 0 frmReciept.Text6(i).Text = Ono1 frmReciept.Text5(i).Text = 1 Loop End If Next i End If frmReciept.Show
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
frmReciept.Adodc3.ConnectionString = "Provider=Microsoft.jet.oledb.4.0;data source=" & App.Path & "\MBMKDbase.mdb" frmReciept.Adodc3.RecordSource = "SELECT * FROM CustDbase" frmReciept.Adodc3.CommandType = adCmdText frmReciept.Adodc3.Refresh If frmReciept.Text4(i).Text <> "" And frmReciept.Text6(i).Text <> "" Then With frmReciept.Adodc3.Recordset .AddNew .Fields("CustName") = frmReciept.Combo6.Text .Fields("InvoiceNo") = frmReciept.Text8.Text .Fields("PONo") = frmReciept.Text10.Text .Fields("Date") = frmReciept.txtDate.Text .Fields("QtY") = frmReciept.Text5(i).Text .Fields("Product") = Label17.Caption & "," & Label18.Caption 'Text4(i).Text .Fields("Price") = frmReciept.Text6(i).Text .Fields("Total") = frmReciept.Text3.Text .Update End With End If
(frmReciept.Text5(i).Text) can anyone help
![]() |
Similar Threads
- Array output (Java)
- Array required, but java.lang.String and java.util.Vector found (Java)
- array required, but java.lang.String found and java.util.Vector found? (Community Introductions)
- filling variable with array from vb code. (HTML and CSS)
- save ARRay elements to a file (C++)
- Homework: filling array from text file (VB.NET)
- Inputting text file data into an array, please help! (C++)
- problem with fstream (C++)
- Saving a file using C++ (C++)
Other Threads in the Visual Basic 4 / 5 / 6 Forum
- Previous Thread: Copy data, but paste with space between rows
- Next Thread: VB and excel solver (runtime errors)
| Thread Tools | Search this Thread |
* 6 429 2007 access activex add age append application basic beginner birth bmp calculator cd cells.find click client code college column component connection connectionproblemusingvb6usingoledb copy creat ctrl+f data database datareport date delete dissertations dissertationthesis dissertationtopic edit error excel excelmacro file filename form hardware header iamthwee image inboxinvb internetfiledownload keypress label listbox listview liveperson login looping machine microsoft movingranges number objectinsert open oracle password prime program prompt range-objects readfile reading record refresh remotesqlserverdatabase report retrieve save search sendbyte sites sort sql sql2008 sqlserver subroutine table tags textbox time urldownloadtofile vb vb6 vb6.0 vba visual visualbasic visualbasic6 web window windows





