Exemple #1
0
        public void InsertDataItem()
        {
            string strTrackType = cXmlDocSectionWell.getTrackTypeByID(this.filePathTemple, sIDcurrentTrack);

            if (strTrackType == TypeTrack.沉积旋回.ToString() || strTrackType == TypeTrack.测井解释.ToString() || strTrackType == TypeTrack.描述.ToString())
            {
                FormSectionAddNewDataItem newItem = new FormSectionAddNewDataItem(this.filePathTemple, sIDcurrentTrack, strTrackType, pDepth.X, pDepth.Y);
                if (newItem.ShowDialog() == DialogResult.OK)
                {
                    userFunctionPointer.DynamicInvoke(0);
                }
            }

            if (strTrackType == TypeTrack.文本道.ToString())
            {
                FormSettingSectionText setText = new FormSettingSectionText(this.filePathTemple, sIDcurrentTrack, strTrackType, pDepth.X, pDepth.Y);
                if (setText.ShowDialog() == DialogResult.OK)
                {
                    userFunctionPointer.DynamicInvoke(0);
                }
            }

            if (strTrackType == TypeTrack.符号.ToString())
            {
                FormSectionAddSymbol newSymbol = new FormSectionAddSymbol(this.filePathTemple, sIDcurrentTrack, pDepth.X, pDepth.Y);
                if (newSymbol.ShowDialog() == DialogResult.OK)
                {
                    userFunctionPointer.DynamicInvoke(0);
                }
            }

            if (strTrackType == TypeTrack.岩性层段.ToString())
            {
                FormSectionAddItemLitho newLitho = new FormSectionAddItemLitho(this.filePathTemple, sIDcurrentTrack, strTrackType, pDepth.X, pDepth.Y);
                if (newLitho.ShowDialog() == DialogResult.OK)
                {
                    userFunctionPointer.DynamicInvoke(0);
                }
            }

            if (strTrackType == TypeTrack.图片道.ToString())
            {
                FormSectionAddImageItem newItemImage = new FormSectionAddImageItem(this.filePathTemple, sIDcurrentTrack, pDepth.X, pDepth.Y);
                if (newItemImage.ShowDialog() == DialogResult.OK)
                {
                    userFunctionPointer.DynamicInvoke(0);
                }
            }
        }
Exemple #2
0
        public void setDataItem()
        {
            bool bSeletctDataItemInSelectTrack = cXmlDocSectionWell.isItemINtrackByID(filePathTemple, sIDcurrentTrack, sIDcurrentItem);

            if (bSeletctDataItemInSelectTrack == false)
            {
                MessageBox.Show("操作数据项不在选择图道内。", "提示");
            }
            else
            {
                string strTrackType = cXmlDocSectionWell.getTrackTypeByID(this.filePathTemple, sIDcurrentTrack);
                if (cProjectManager.ltStrTrackTypeIntervalProperty.IndexOf(strTrackType) >= 0)
                {
                    FormSettingSectionDataItemView setDataItem = new FormSettingSectionDataItemView(this.filePathTemple, this.sIDcurrentItem, strTrackType);
                    if (setDataItem.ShowDialog() == DialogResult.OK)
                    {
                        userFunctionPointer.DynamicInvoke(0);
                    }
                }
                else if (strTrackType == TypeTrack.文本道.ToString())
                {
                    FormSettingSectionText setText = new FormSettingSectionText(this.filePathTemple, this.sIDcurrentItem);
                    if (setText.ShowDialog() == DialogResult.OK)
                    {
                        userFunctionPointer.DynamicInvoke(0);
                    }
                }
                else if (strTrackType == TypeTrack.岩性层段.ToString())
                {
                    FormSectionAddItemLitho setLitho = new FormSectionAddItemLitho(this.filePathTemple, sIDcurrentTrack, this.sIDcurrentItem);
                    if (setLitho.ShowDialog() == DialogResult.OK)
                    {
                        userFunctionPointer.DynamicInvoke(0);
                    }
                }
                else if (strTrackType == TypeTrack.图片道.ToString())
                {
                    FormSectionAddImageItem setImage = new FormSectionAddImageItem(this.filePathTemple, sIDcurrentTrack, this.sIDcurrentItem);
                    if (setImage.ShowDialog() == DialogResult.OK)
                    {
                        userFunctionPointer.DynamicInvoke(0);
                    }
                }
                else if (strTrackType == TypeTrack.符号.ToString())
                {
                    FormSectionAddSymbol newSymbol = new FormSectionAddSymbol(this.filePathTemple, sIDcurrentTrack, this.sIDcurrentItem);
                    if (newSymbol.ShowDialog() == DialogResult.OK)
                    {
                        userFunctionPointer.DynamicInvoke(0);
                    }
                }
                if (strTrackType == TypeTrack.分层.ToString())
                {
                    FormSettingSectionLayer setLayer = new FormSettingSectionLayer(filePathTemple, sIDcurrentTrack, this.sIDcurrentItem);
                    if (setLayer.ShowDialog() == DialogResult.OK)
                    {
                        userFunctionPointer.DynamicInvoke(0);
                    }
                }
            }
        }