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 dencom on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

"Data provider could not be initialized" Error

Status
Not open for further replies.

Aidy680

Technical User
Nov 1, 2006
138
GB
I posted this thread in another forum but not getting much feedback.

Maybe this is a better home....

thread705-1580063

TIA.

 
Maybe the provider you use is not installed on that computer?
What is you connection string?

Borislav Borissov
VFP9 SP2, SQL Server 2000/2005.
 
Not so sure Borislav as it works fine most of the time and only occasionaly do I get this error; usually when I just leave the app open on my screen for a few mins.

Anyway this is the connection string I'm using:

Set cmdParams = New ADODB.Command
cnnParams.CursorLocation = adUseClient
With cmdParams
Set .ActiveConnection = cnnParams
.CommandType = adCmdStoredProc
.CommandText = strProcName
End With

Set rstSourceFile = cmdParams.Execute



 
Apologies for the delay with this. I think this is what you're after:

Provider=SQLOLEDB.1;Persist Security Info=True;Trusted_Connection=Yes;Initial Catalog=somedatabase;Data Source=SQLU10;SERVER=SQLU10
 
Aidy680 said:
when I just leave the app open on my screen for a few mins.
Exactly when are you opening the connection to the database? Is it in a loop, or some event that may be happening numerous times?

I am suspicious that your code is using up all available connections, or something of the kind.
 
I open the connection when I open the SubForm. I also destroy it at the end of the Form_Open event. It isnt in a loop.

I've already tried copying all the objects into a new database, but that hasn't worked.

It does seem to occur when the screen is trying to refrsh/update itself. No code is being executed.
 
Any other thoughts on this at all?!

I've searched the net and haven't been able to find one conclusive answer yet.
 
Just as a follow-up on this, I've tried exporting all the objects into a new database as suggested elsewhere, but that didnt work either.

Getting quite desperate now!!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top