I try to set the connection parameters with the following code,
but the password is not set after a call to ApplyLogOnInfo.
What i am doing wrong ??
The call of TestConnectivit y() brings: "Invalid Connection Parameter", but
the values are correct.
// Get the ConnectionInfo Object.
TableLogOnInfo logOnInfo = new TableLogOnInfo( );
logOnInfo = m_document.Data base.Tables[p_table].LogOnInfo;
ConnectionInfo connectionInfo = new ConnectionInfo( );
connectionInfo = logOnInfo.Conne ctionInfo;
// Set the Connection parameters.
connectionInfo. DatabaseName = p_database;
connectionInfo. ServerName = p_server;
connectionInfo. Password = p_password;
connectionInfo. UserID = p_user;
m_document.Data base.Tables[p_table].ApplyLogOnInfo (logOnInfo);
// Test Connection
Table table = m_document.Data base.Tables[p_table];
bool flag = table.TestConne ctivity();
but the password is not set after a call to ApplyLogOnInfo.
What i am doing wrong ??
The call of TestConnectivit y() brings: "Invalid Connection Parameter", but
the values are correct.
// Get the ConnectionInfo Object.
TableLogOnInfo logOnInfo = new TableLogOnInfo( );
logOnInfo = m_document.Data base.Tables[p_table].LogOnInfo;
ConnectionInfo connectionInfo = new ConnectionInfo( );
connectionInfo = logOnInfo.Conne ctionInfo;
// Set the Connection parameters.
connectionInfo. DatabaseName = p_database;
connectionInfo. ServerName = p_server;
connectionInfo. Password = p_password;
connectionInfo. UserID = p_user;
m_document.Data base.Tables[p_table].ApplyLogOnInfo (logOnInfo);
// Test Connection
Table table = m_document.Data base.Tables[p_table];
bool flag = table.TestConne ctivity();
Comment