hi mates,
following code works fine in the server machine where sql server exists.
but this doen't run at client machine.
it throws error as "A connection cannot be made. Ensure that the server is running."
help to solve this problem
thanks
Dim msSvr As New Server
Dim db As New Database
Try
If Not msSvr Is System.DBNull.Value ThenmsSvr.Disconnect()
End If
'both connections r not working
msSvr.Connect(
"Provider=MSOLAP.9; datasource=http://server/olap/msmdpump.dll;Initial Catalog=testolap;user id=sa;password=sa;")
msSvr.Connect(
"Provider=SQLNCLI.1;Data Source=esERVER;user id=sa;password=sa;")
If Not db Is System.DBNull.Value Then
db.Dispose()
End Ifdb = msSvr.Databases.Find(
"testdb")db.Process(ProcessType.ProcessFull)
db.Refresh(
True) Catch ex As ExceptionConsole.WriteLine(ex.Message)
Finallydb.Dispose()
msSvr.Disconnect(
True) End Try