2 ADP Questions

  • Thread starter Thread starter T.J. Bernard
  • Start date Start date
T

T.J. Bernard

I have 2 ADP questions, regarding an ADP project I am
working on.

1) I am using a Recordset to count the number of records
found from a stored proc. If the record count is 0 then
the action is stopped. I have created the same coding
process with a Connection Object and a Recordset Object on
one form and it works correctly. On my 2nd form I created
the same code (the recordset does compare => or =<
datetime) but has the same coding concept. I continue to
get the error:

Run-time error '3709':
The connection cannot be used to perform this operation.
It is either closed or invalid in this context.

I can post the code that does work, and does not work to
compare an contrast, but I cannot tell why this code will
work in one form and not another in the same ADP.

2) In my MS Access DB's I would put a text box on the
forms that would display the record count for the record
source of the form. The Text Box property was

="Record " & [CurrentRecord] & " of " & Count(*)

I am not sure how to convert this to work properly in an
ADP project.

Thank you for your time.

T.J.
 
TB> Run-time error '3709':
TB> The connection cannot be used to perform this
TB> operation. It is either closed or invalid in this
TB> context.

Check the scope of the connection object used to execute the s.p. Better yet,
use currentproject.connection, it's always open.


TB> 2) In my MS Access DB's I would put a
TB> text box on
TB> the forms that would display the record count for
TB> the
TB> record source of the form. The Text Box
TB> property was

TB> ="Record " &
TB> [CurrentRecord] & " of " & Count(*)

TB> I am not sure how to convert this to
TB> work properly in an ADP project.

="Record " & [CurrentRecord] & " of " & [RecordsetClone].[RecordCount]


I'm wondering, however, don't you already have it in form's Navigation
Buttons???


Vadim
 
Back
Top