protected override void LoadFromPrimary()
        {
            ReportModel            model = designerLoader.CreateRenderableModel();
            AbstractPreviewCommand cmd   = null;

            switch (model.DataModel)
            {
            case GlobalEnums.PushPullModel.FormSheet: {
                cmd = new AsyncFormsSheetPreviewCommand(model, control);
                break;
            }

            case GlobalEnums.PushPullModel.PullData: {
                cmd = new AsyncPullModelPreviewCommand(model, control);
                break;
            }

            case GlobalEnums.PushPullModel.PushData: {
                cmd = new AsyncPushModelPreviewCommand(model, control);
                break;
            }

            default:
                throw new InvalidReportModelException();
            }
            cmd.Run();
        }
예제 #2
0
        protected override void LoadFromPrimary()
        {
            reportManager = new StandartPreviewManager();
            ReportModel      model = designerLoader.CreateRenderableModel();
            AbstractRenderer rc    = reportManager.CreateRenderer(model);

            if (rc != null)
            {
                previewControl.ShowPreview(rc, GlobalValues.DefaultZoomFactor, true);
            }
        }