当前位置: 首页>>代码示例>>C#>>正文


C# Report.RunGetData方法代码示例

本文整理汇总了C#中fyiReporting.RDL.Report.RunGetData方法的典型用法代码示例。如果您正苦于以下问题:C# Report.RunGetData方法的具体用法?C# Report.RunGetData怎么用?C# Report.RunGetData使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在fyiReporting.RDL.Report的用法示例。


在下文中一共展示了Report.RunGetData方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: LoadReport

        /// <summary>
        /// Loads the report.
        /// </summary>
        /// <param name='filename'>
        /// Filename.
        /// </param>
        /// <param name='parameters'>
        /// Example: parameter1=someValue&parameter2=anotherValue
        /// </param>
        public void LoadReport(Uri filename, string parameters)
        {
            string source;
            System.Collections.Specialized.ListDictionary ld;
            this.parameters = parameters;
            // Any parameters?  e.g.  file1.rdl?orderid=5
            if (parameters.Trim() != "")
            {
                ld = this.GetParmeters(parameters);
            }
            else
            {
                ld = null;
            }

            // Obtain the source
            source = System.IO.File.ReadAllText(filename.AbsolutePath);
            // GetSource is omitted: all it does is read the file.
            // Compile the report
            report = this.GetReport(source);

            // Obtain the data passing any parameters
            report.RunGetData(ld);

            // Render the report in each of the requested types
            string tempFile = System.IO.Path.GetTempFileName();
            ExportReport(report, tempFile, OutputPresentationType.PDF);
            LoadPdf(new Uri(tempFile));
        }
开发者ID:net-haus,项目名称:My-FyiReporting,代码行数:38,代码来源:RdlGtkViewer.cs

示例2: GetPages

        private Pages GetPages(Report report)
        {
            Pages pgs = null;

            ListDictionary ld = GetParameters();		// split parms into dictionary

            try
            {
                report.RunGetData(ld);

                pgs = report.BuildPages();

                if (report.ErrorMaxSeverity > 0)
                {
                    if (_errorMsgs == null)
                    {
                        _errorMsgs = report.ErrorItems;		// keep a copy of the errors
                    }
                    else
                    {
                        foreach (string err in report.ErrorItems)
                        {
                            _errorMsgs.Add(err);
                        }
                    }

                    report.ErrorReset();
                }

            }
            catch (Exception e)
            {
                string msg = e.Message;
            }

            return pgs;
        }
开发者ID:huasonli,项目名称:My-FyiReporting,代码行数:37,代码来源:RdlViewer.cs

示例3: Rebuild

        public void Rebuild()
        {
            _report = this.GetReport(SourceRdl);
            _report.RunGetData(Parameters);
            pages = _report.BuildPages();

            List<ReportArea> tempList = new List<ReportArea>();
            foreach (ReportArea w in this.vboxPages.Children)
            {
                tempList.Add(w);
            }
            foreach (ReportArea w in tempList)
            {
                vboxPages.Remove(w);
            }

            for (int pageCount = 0; pageCount < pages.Count; pageCount++)
            {
                ReportArea area = new ReportArea(this.DefaultBackend);
                area.SetReport(_report, pages[pageCount]);

                vboxPages.PackStart(area, true, true);
            }

            this.Show();

            if (_report.ErrorMaxSeverity > 0)
            {
                // TODO: add error messages back
                //SetErrorMessages(report.ErrorItems);
            }
        }
开发者ID:majorsilence,项目名称:My-FyiReporting,代码行数:32,代码来源:ReportViewer.cs


注:本文中的fyiReporting.RDL.Report.RunGetData方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。