Create CE Engine error
-
Monday, November 12, 2012 4:51 PM
Trying to instantiate a SQlServerCE engine object such that I can Update a 3.1 SDF to a 3.5 SDF.
Public mSqleng As SqlCeEngine
mSqleng = New SqlCeEngine(DBpath)
DbPath is
"\Program Files\Data\MxHhDev.sdf"
Which points to the older SDF version.
But everytime I try to create a new Engine object in code above I get an error immediately
{"Format of the initialization string does not conform to specification starting at index 0."}
System.ArgumentException: {"Format of the initialization string does not conform to specification starting at index 0."}
InnerException: Nothing
Any idea what I may be doing wrong here?
TIA
HArry
All Replies
-
Monday, November 12, 2012 5:26 PM
Of course the obvious problem was that I was feeding in the path and I needed the entire connection string.
Somedays I am dumb!
Dim
connstring As String =
String.Format("Data Source={0};Password=mexpress", DBFullPath)
mSqleng =
New SqlCeEngine(connstring)
- Marked As Answer by LightStampCode Monday, November 12, 2012 5:26 PM
-
Tuesday, November 13, 2012 10:25 AMModerator


