예제 #1
0
        public void addCtrls()
        {
            var report = m_editor.getReport();

            cGlobals.addCtrls(report, tv_controls, C_IMG_FOLDER, C_IMG_FORMULA, C_IMG_CONTROL, C_IMG_DATBASE_FIELD);
            lbTitle.Text = "Report definition: " + report.getName();
        }
예제 #2
0
        public void showControls(cEditor editor)
        {
            lv_controls.Items.Clear();

            if (editor != null)
            {
                cGlobals.addCtrls(editor.getReport(), lv_controls, C_CTRL_IMAGE, C_DB_IMAGE);
            }
        }
예제 #3
0
        public void showControlsTree(cEditor editor)
        {
            m_wasDoubleClick = false;
            tv_controls.Nodes.Clear();

            if (editor != null)
            {
                cGlobals.addCtrls(editor.getReport(), tv_controls, C_IMG_FOLDER, C_IMG_FORMULA, C_IMG_CONTROL, C_IMG_DATBASE_FIELD);
            }
        }
예제 #4
0
 private static void setMenu()
 {
     try {
         if (m_editor == null)
         {
             fmain.setMenuAux(false);
             fmain.setBarText("");
             fmain.setStatus("");
         }
         else
         {
             fmain.setMenuAux(true);
             fmain.setDisconnectedReport(m_editor.getReport().getReportDisconnected());
             fmain.setBarText(m_editor.getReport().getName());
             fmain.setStatus(pGetStatus());
         }
     } catch (Exception ex) {
         cError.mngError(ex, "SetMenu", C_MODULE, "");
     }
 }
예제 #5
0
        public void showFields(cEditor editor)
        {
            lv_fields.Items.Clear();

            if (editor != null)
            {
                var connect = editor.getReport().getConnect();
                cGlobals.fillColumns(
                    connect.getDataSource(),
                    connect.getColumns(), lv_fields, C_INDEX, C_FIELDTYPE, false);
            }
        }
예제 #6
0
 private void cmd_search_Click(object sender, EventArgs e)
 {
     if (tx_toSearch.Text.Trim() == "")
     {
         cWindow.msgInfo("You must input some text to search");
     }
     else
     {
         cReport report = m_editor.getReport();
         searchInSections(report.getHeaders(), csObjType.iTypeSec);
         searchInSections(report.getGroupsHeaders(), csObjType.iTypeSecG);
         searchInSections(report.getDetails(), csObjType.iTypeSec);
         searchInSections(report.getGroupsFooters(), csObjType.iTypeSecG);
         searchInSections(report.getFooters(), csObjType.iTypeSec);
     }
 }
예제 #7
0
        public static bool showDbFields(ref string field, ref int fieldType, ref int index, cEditor editor)
        {
            fColumns fc = null;

            try {
                fc = new fColumns();

                fc.clearColumns();

                cReport report = editor.getReport();

                cReportConnect connect = report.getConnect();
                fc.fillColumns(connect.getDataSource(), connect.getColumns(), false);

                for (int _i = 0; _i < report.getConnectsAux().count(); _i++)
                {
                    connect = report.getConnectsAux().item(_i);
                    fc.fillColumns(connect.getDataSource(), connect.getColumns(), true);
                }

                fc.setField(field);
                fc.ShowDialog();

                if (fc.getOk())
                {
                    field     = fc.getField();
                    fieldType = fc.getFieldType();
                    index     = fc.getIndex();

                    return(true);
                }
                else
                {
                    return(false);
                }
            } catch (Exception ex) {
                cError.mngError(ex, "showDbFields", C_MODULE, "");
                return(false);
            }
            finally {
                if (fc != null)
                {
                    fc.Close();
                }
            }
        }
예제 #8
0
 private object getControlOrSection(cEditor editor, string key)
 {
     if (key.Length > 1)
     {
         if (key.Substring(0, 1) == "S")
         {
             return(editor.getSectionOrSectionLineFromKey(key.Substring(1)));
         }
         else
         {
             return(editor.getReport().getControls().item(key));
         }
     }
     else
     {
         return(null);
     }
 }