forweefolks
Technical User
I recently replicated a database for the first time. This included of course changing the datatypes of my indices to replicationids. The next thing I see happening is that one of my procedures stops working. In the procedure I first take a form's recordsource, modify it a little and then use to it to count certain aggregate value subsequently displayed on a form. (resorting to this kind of arguably clumsy alternative was forced upon me due to the fact formulas on the form stop working from time to time).
Anyway, why in the heck can't I recover a value from either the query underlying the form or the textbox on the form itself that would contain a replicationid-type transactionid, that i so desperately need. Any suggestions? Help! Anyone?!?
recsourcestring = repsub.Form.RecordSource
recsourcestring = Left(recsourcestring, Len(recsourcestring) - 2)
'recsourcestring = recsourcestring + " where [repayments]![transactionid]=" & (Forms![ExpCreditrepaymentschedule]![TransactionID])
Set recsetrepayments = db.OpenRecordset(recsourcestring, dbOpenDynaset)
If recsetrepayments.RecordCount > 0 Then
recsetrepayments.MoveLast
reccount = recsetrepayments.RecordCount
Else: reccount = 0
End If
If reccount > 0 Then
recsetrepayments.MoveFirst
y = 0
Do Until recsetrepayments.EOF
y = y + recsetrepayments!RepaymentAmount
recsetrepayments.MoveNext
Loop
End If
If 1 = 1 Then
End If
y = Nz
Anyway, why in the heck can't I recover a value from either the query underlying the form or the textbox on the form itself that would contain a replicationid-type transactionid, that i so desperately need. Any suggestions? Help! Anyone?!?
recsourcestring = repsub.Form.RecordSource
recsourcestring = Left(recsourcestring, Len(recsourcestring) - 2)
'recsourcestring = recsourcestring + " where [repayments]![transactionid]=" & (Forms![ExpCreditrepaymentschedule]![TransactionID])
Set recsetrepayments = db.OpenRecordset(recsourcestring, dbOpenDynaset)
If recsetrepayments.RecordCount > 0 Then
recsetrepayments.MoveLast
reccount = recsetrepayments.RecordCount
Else: reccount = 0
End If
If reccount > 0 Then
recsetrepayments.MoveFirst
y = 0
Do Until recsetrepayments.EOF
y = y + recsetrepayments!RepaymentAmount
recsetrepayments.MoveNext
Loop
End If
If 1 = 1 Then
End If
y = Nz