BoldSignEasily embed eSignatures in your .NET applications. Free sandbox with native SDK available.
{
ConnectionStringBuilder obj = new ConnectionStringBuilder();
DashboardCryptoProvider provider = new DashboardCryptoProvider(EncryptionType.AES);
ConnectionParameters connectionParameter = new ConnectionParameters
{
Url : "", // Pass the web datasource url
UserName: "",
Password: "",
};
ConnectionProviderType connectionType = ConnectionProviderType.WebDataConnector; // Connection type used in the dashboard
OdbcDbmsType odbcType = OdbcDbmsType.None; // ODBC DBMS type, if any
Connection connectionName = new Connection { DataSources = new List<DataSourceConnectionString>() };
connectionName.DataSources.Add(new DataSourceConnectionString
{
Name = "Northwind Traders Sales Analysis", // Nane of the Data Source while designing the Dashboard in the Dashboard Designer
ConnectionString = obj.GenerateConnectionString(connectionParameter, connectionType, odbcType)
});
ViewBag.EncryptedString = provider.DoEncryption(Converter.SerializeObject(connectionName)); // You can pass the encrypted String in the onApplyConnection event API to change the change connection String
} |