超图开发包:SMO_DotNET_810_14127_58257_Bin(SuperMap iObjects .NET 8C(2017)
问题描述:基于上述开发环境搭建两个应用程序,调用下面的测试代码,一个打开工作空间成功,另一个失败,提示问题“数据库连接失败,请检查数据源连接参数”。想咨询出现问题的原因?
测试代码:
WorkspaceConnectionInfo wkspInfo = null;
wkspInfo = new WorkspaceConnectionInfo();
wkspInfo.Type = WorkspaceType.Oracle;
wkspInfo.Server = "ORCL_10.7.1.199";
wkspInfo.User = "TESTNGIS";
wkspInfo.Password = "sa123";
wkspInfo.Name = "workspace_" + "TESTN";
Workspace workspace = new Workspace();
if (!workspace.Open(wkspInfo))
{
MessageBox.Show("打开工作空间失败!");
return;
}