|
-
Feb 27th, 2001, 11:58 AM
#1
Thread Starter
Fanatic Member
I have a data environment (dataenvironmet1) that runs a sql query and posts the results to a data grid. My question is after that query has been ran (command1) how do you close the connection? For example, if I run the query and get the results and then try to run another query it will give me the message
Run Time error 3705
"Operation is not allowed when object is open"
I am supposing that all I have to do is close the connection. I understand how to do when using ADO but I have no clue with a dataenvironment.
Thanks
-
Feb 27th, 2001, 12:09 PM
#2
Hyperactive Member
'PRINT SHIFT REPORTS
With DE1 ' MY DATA ENVIRONMENT
'CLOSE CONNECTION
If .rsdrFindPayroll.State = adStateOpen Then
.rsdrFindPayroll.Close
End If
'SET QUERY PARAMETER
MSHFlexGrid1.LeftCol = 0
'OPEN CONNECTION
.drFindPayroll MSHFlexGrid1.Text
'SHOW PAYROLL REPORT
drPayroll.PrintReport
End With
-
Feb 27th, 2001, 12:46 PM
#3
Thread Starter
Fanatic Member
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|