private void OnLoading(object sender, StiLoadingObjectEventArgs e)
        {
            try
            {
                using (var form = new FrmBuscadorInformes())
                {
                    if (form.ShowDialog() == DialogResult.OK)
                    {
                        informe = form.Informe;
                        //Add data to datastore
                        stiReport = new StiReport();
                        //stiReport.LoadEncryptedReportFromString(informe.Codigo, informe.Guid);
                        stiReport.LoadPackedReportFromString(informe.Codigo);
                        stiReport.Dictionary.Databases.Clear();
                        stiReport.Dictionary.Databases.Add(new StiSqlDatabase("Dym", Ambiente.Conexion.StandardSecurityConnectionString()));
                        // stiReport.sa

                        designer.Report = stiReport;
                    }
                }
            }
            catch (Exception ex)
            {
                Ambiente.Mensaje(ex.ToString());
            }
        }
Example #2
0
        private void OnLoading(object sender, StiLoadingObjectEventArgs e)
        {
            using (var form = new FrmBuscadorInformes())
            {
                if (form.ShowDialog() == DialogResult.OK)
                {
                    informe = form.Informe;
                    //Add data to datastore
                    stiReport = new StiReport();
                    stiReport.LoadEncryptedReportFromString(informe.Codigo, informe.Guid);

                    stiReport.Dictionary.Databases.Clear();
                    stiReport.Dictionary.Databases.Add(new StiSqlDatabase("Dym", @"Data Source=.\SQLEXPRESS;Initial Catalog=Dym;Integrated Security=True;"));

                    designer.Report = stiReport;
                }
            }
        }