CSReportDll.cReportControls.remove C# (CSharp) Метод

remove() публичный Метод

public remove ( String key ) : void
key String
Результат void
        public void remove(String key)
        {
            try
            {
                item(key).setSectionLine(null);
                if (m_copyColl != null)
                {
                    m_copyColl.remove(item(key).getKey());
                }
                Remove(key);
            }
            catch
            {
            }
        }

Same methods

cReportControls::remove ( int index ) : void

Usage Example

Пример #1
0
        private cReportControls getControlsInZOrder(cReportControls col)
        {
            int i = 0;
            cReportControl ctrl = null;
            cReportControls ctrls = null;

            ctrls = new cReportControls();
            ctrls.setCopyColl(col.getCopyColl());
            ctrls.setTypeSection(col.getTypeSection());
            ctrls.setSectionLine(col.getSectionLine());

            // we load a new collection ordered by zorder
            //
            while (col.count() > 0)
            {
                // we search the lower zorder in this collection
                //
                i = 32767;
                for (int _i = 0; _i < col.count(); _i++)
                {
                    ctrl = col.item(_i);
                    if (ctrl.getLabel().getAspect().getNZOrder() < i)
                    {
                        i = ctrl.getLabel().getAspect().getNZOrder();
                    }
                }

                for (int _i = 0; _i < col.count(); _i++)
                {
                    ctrl = col.item(_i);
                    if (ctrl.getLabel().getAspect().getNZOrder() == i)
                    {
                        col.remove(ctrl.getKey());
                        ctrls.add(ctrl, ctrl.getKey());
                        break;
                    }
                }
                i = i + 1;
            }
            return ctrls;
        }