當前位置: 首頁>>代碼示例>>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;未經允許,請勿轉載。