Dear Sir
I have designed a database program. There is a form named as "Purchase Data Entry". I can insert & save data. Now, I want to display the sum of data (in a text box on the same form) along with the previous, for example, previously Computer was 10, now it is 20 after addition. But while doing so, it does display only the first or last or next data.
I have designed a query file from the table which sum the entire Item, say total Computer or total Monitor etc.
Now, if I use the below code, it displays either first or next or last data but not the latest data which has been added/saved in the table.
The code which I have used is as follows:
Dim rst1 As New ADODB.Recordset
DBconnect
If rst1.State = adStateOpen Then rst1.Close
rst1.Open "qrytotalpurchase", cnt, adOpenDynamic, adLockOptimistic
If Not rst1.EOF() Then rst1.MoveNext
Text1.Text = rst1.Fields(0)
I have fallen in trouble. Please help.
If I can't understand my problem, please let me know.
So far I know, there is a option which search whole data by the symbol <> and fetch the specific.
Appreciate, if you would come back soon.
Regards
talorababu