G
gollum_hkt
Hi
I hope someone can help, I have a vb project that was previously
running on a standalone pc accessing an access97 database, I have now
had to modify it to work on multiple networked pcs, I have split the
database so that each pc has the front end in c:\aussie\BarDb97.mdb and
the back end on a mapped drive z:\aussie\BarDb97_be.mdb
The program runs until I try to modify any f the records it gives me
the error Run Time Error 3219 Invalid Operation
this is a sample of the code below:
Private Sub Form_Load()
Label2.Caption = gBinNo
Label4.Caption = gCustomer
Label6.Caption = gWaitress
Label8.Caption = gNextBillNo
Set db = OpenDatabase("c:\Aussie\BarDb97.mdb", False, False,
";pwd=backdoor")
Set rs = db.OpenRecordset("SELECT * FROM ViewBill")
rs.MoveFirst
Label9.Caption = "0"
Do While Not rs.EOF
Label9.Caption = Val(Label9.Caption) + (rs.Fields("Total"))
rs.MoveNext
Loop
Data1.RecordSource = "viewbill"
Data1.Refresh <================== This is where the program
breaks
' MsgBox (Data1.Recordset.Fields("Description"))
ViewBill.Refresh
rs.Close
db.Close
End Sub
What am I doing wrong?
I hope someone can help, I have a vb project that was previously
running on a standalone pc accessing an access97 database, I have now
had to modify it to work on multiple networked pcs, I have split the
database so that each pc has the front end in c:\aussie\BarDb97.mdb and
the back end on a mapped drive z:\aussie\BarDb97_be.mdb
The program runs until I try to modify any f the records it gives me
the error Run Time Error 3219 Invalid Operation
this is a sample of the code below:
Private Sub Form_Load()
Label2.Caption = gBinNo
Label4.Caption = gCustomer
Label6.Caption = gWaitress
Label8.Caption = gNextBillNo
Set db = OpenDatabase("c:\Aussie\BarDb97.mdb", False, False,
";pwd=backdoor")
Set rs = db.OpenRecordset("SELECT * FROM ViewBill")
rs.MoveFirst
Label9.Caption = "0"
Do While Not rs.EOF
Label9.Caption = Val(Label9.Caption) + (rs.Fields("Total"))
rs.MoveNext
Loop
Data1.RecordSource = "viewbill"
Data1.Refresh <================== This is where the program
breaks
' MsgBox (Data1.Recordset.Fields("Description"))
ViewBill.Refresh
rs.Close
db.Close
End Sub
What am I doing wrong?