Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Object already open ? Can I know before !!

Status
Not open for further replies.

sarah77

Programmer
Jun 4, 2002
36
0
0
US
Program error says "object already open" when it reach the statement :

De.RsPc.Open

De is related to the Data environment
RsPc related to a table

Is there a way to know if RsPc is opened or not such as
( if De.RsPc.Open=True )... any comment ?

(VB6)

Thanks
 
I'm not POSITIVE what you're doing, but if RsPc is an ADO Recordset Object, then..

Code:
If De.RsPc.State = adStateOpen then De.RsPc.Close

--NipsMG s-)

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top