Page 1 of 1
How to disable some connections type in JS version
Posted: Mon Oct 03, 2022 3:30 pm
by camedinag
Hello I found this code to disable some connections types:
StiServiceContainer services = StiConfig.Services.GetServices(typeof(StiDataAdapterService));
foreach (StiDataAdapterService service in services)
{
Type serviceType = service.GetType();
service.ServiceEnabled = !serviceType.Equals(typeof(StiSqlAdapterService)) && !serviceType.Equals(typeof(StiOleDbAdapterService));
}
How to code this for JS version ??
Thanks
Re: How to disable some connections type in JS version
Posted: Tue Oct 04, 2022 6:48 am
by Lech Kulikowski
Hello,
We need some additional time to investigate the issue, we will let you know about the result.
Thank you.
#8330
Re: How to disable some connections type in JS version
Posted: Tue Oct 04, 2022 9:26 am
by Lech Kulikowski
Hello,
You can use the following code:
Code: Select all
let databases = StiOptions.Services.databases;
databases.clear();
databases.add(new Stimulsoft.Report.Dictionary.StiFirebirdDatabase());
databases.add(new Stimulsoft.Report.Dictionary.StiMySqlDatabase());
databases.add(new Stimulsoft.Report.Dictionary.StiSqlDatabase());
Thank you.
Re: How to disable some connections type in JS version
Posted: Tue Oct 04, 2022 8:01 pm
by camedinag
But in JS don't have a StiOptions class
Re: How to disable some connections type in JS version
Posted: Tue Oct 04, 2022 9:15 pm
by Lech Kulikowski
Hello,
What version are you use?
Please check the last release build version.
Thank you.
Re: How to disable some connections type in JS version
Posted: Tue Oct 04, 2022 9:39 pm
by camedinag
2022.4.1
Re: How to disable some connections type in JS version
Posted: Thu Oct 06, 2022 12:21 pm
by Lech Kulikowski
Hello,
Please send us a sample project that reproduces the issue for analysis.
Thank you.