Have our own DataSoure Provider for report designer.
Have our own DataSoure Provider for report designer.
We are trying to use Stimulsoft report designer in our existing application. we want to use our existing Nhibernate connection in report designer and to execute report as well.So we thought of having our own provider to achieve this.is there a any way of adding our ownProvider (something like StiOledbDataBase). or is there a better solution ?
tnx
chaminda
tnx
chaminda
Have our own DataSoure Provider for report designer.
Hello,
You can create your own data provider (you can see the additional data providers from our site as a sample) or use DataSet and send it to the report.
Thank you.
You can create your own data provider (you can see the additional data providers from our site as a sample) or use DataSet and send it to the report.
Thank you.
Have our own DataSoure Provider for report designer.
i want to execute report with our existing Database Connection (which is use for Nhibernate).without passing the connections string cant we pass CommandObject(which has derived from idbcommand) to report. otherthan creating a StiOledbDataBase or StiSqlDataBase with a connection string.
tnx
chaminda
tnx
chaminda
Have our own DataSoure Provider for report designer.
Hello,
If we understood your problem correctly, you can set all connections to the database in your application, get data and then send them into a report using the RegData() or RegBussinessObject() method.
Thank you.
If we understood your problem correctly, you can set all connections to the database in your application, get data and then send them into a report using the RegData() or RegBussinessObject() method.
Thank you.
Have our own DataSoure Provider for report designer.
tnx for the reply,
what i was trying to do , without executing database commands in our application and send dataset or businessobject to report, we wanted to set command object to the stireport(which has configured with database connection and database command).and then report will execute the command which we have send to stireport and display data.
this is what i want to have in our solution.
chaminda
what i was trying to do , without executing database commands in our application and send dataset or businessobject to report, we wanted to set command object to the stireport(which has configured with database connection and database command).and then report will execute the command which we have send to stireport and display data.
this is what i want to have in our solution.
chaminda
Have our own DataSoure Provider for report designer.
Hello,
You can use the following code.
New connection string:
Add DataSources:
Add Columns:
Add Relations:
Thank you.
You can use the following code.
New connection string:
Code: Select all
report.Dictionary.Databases.Clear();
report.Dictionary.Databases.Add(new Stimulsoft.Report.Dictionary.StiSqlDatabase("Connection", newConnectionString));
Code: Select all
StiSqlSource DS1 = new StiSqlSource("Connection", "DS1", "DS1", "SELECT * FROM DS1", true, false);
report.Dictionary.DataSources.Add(DS1);
Code: Select all
foreach (DataColumn col in dataTableDS1.Columns)
{
DS1.Columns.Add(col.ColumnName, col.DataType);
}
Code: Select all
StiDataRelation dataRelation = new StiDataRelation("MyRelation", parentDS, childDS, new string[] { "Field" }, new string[] { "Field" });
report.Dictionary.RegRelations();
report.Dictionary.Relations.Add(dataRelation);