예제 #1
0
        protected void EH_DblClickEditor(object aSender, EventArgs aEArgs)
        {
            CReportItem lItem = getSelectedItem();

            if (lItem is CReportFile)
            {
                CReportFile lRptFile = (CReportFile)lItem;
                RsViewEngine.MainForm.OpenReport(lRptFile.ItemName, lRptFile.ReportFile);
            }
        }
예제 #2
0
        protected void ehOpenNode(object aSender, EventArgs aE)
        {
            foreach (RsListViewItem iItem in ItemList.SelectedItems)
            {
                if (iItem.IsReportFile())
                {
                    CReportFile lFile = iItem.ReportItem as CReportFile;

                    RsViewEngine.MainForm.OpenReport(lFile.ItemName, lFile.ReportFile);
                }
            }
        }
예제 #3
0
        public void DoAddReport()
        {
            XmlNode lThisData = RsViewEngine.Locale.GetFormData(LOCALE_ALIAS);

            RsReportCollection lCurrColl = getSelectedCollection();

            if (lCurrColl == null)
            {
                CRSMessageBox.ShowBox(
                    XmlTools.getXmlNodeByAttrVal("name", NOCOLLECTION_FILE, lThisData).InnerText,
                    RsViewEngine.Locale.GetTagText("error"),
                    MessageBoxButtons.OK,
                    MessageBoxIcon.Exclamation
                    );
            }

            else
            {
                if (lCurrColl is CFavoritesCollection)
                {
                    _dlgAddReport.CollectionName = RsViewEngine.Locale.GetTagText(RsLocalization.TAG_FAVORITES);
                }
                else
                {
                    _dlgAddReport.CollectionName = lCurrColl.CollectionName;
                }
                _dlgAddReport.Modify = false;
                DialogResult lDlgRes = _dlgAddReport.ShowDialog();
                if (lDlgRes == DialogResult.OK)
                {
                    CReportFolder lParent = getCurrentParent();
                    if (lParent == null)
                    {
                        CRSMessageBox.ShowBox(
                            RsViewEngine.Locale.GetTagText("collectionNotSelected"),
                            RsViewEngine.Locale.GetTagText("error"),
                            MessageBoxButtons.OK,
                            MessageBoxIcon.Exclamation);
                        return;
                    }
                    CReportFile lNewFile = new CReportFile(_dlgAddReport.Alias, _dlgAddReport.ReportFile);
                    lNewFile.Parent = lParent;
                    lParent.Collection.ApplyToGUI();
                    lParent.Collection.QuickSave();
                }
            }
        }
예제 #4
0
 public RsCollectionReport(CReportFile aReportFile) : base(aReportFile)
 {
 }