Fix insert the RO Accessory Page ID into a Word attachment
This commit is contained in:
parent
58486f199d
commit
641dbf945d
@ -419,8 +419,13 @@ namespace Volian.Controls.Library
|
|||||||
DisplayTabItem dti = _TabControl.SelectedDisplayTabItem; //.OpenItem(_ItemInfo); // open the corresponding procedure text
|
DisplayTabItem dti = _TabControl.SelectedDisplayTabItem; //.OpenItem(_ItemInfo); // open the corresponding procedure text
|
||||||
if (dti.MyDSOTabPanel != null) // A Word Document tab is the active tab
|
if (dti.MyDSOTabPanel != null) // A Word Document tab is the active tab
|
||||||
{
|
{
|
||||||
string accPrefix = (roch.type == 8) ? _Mydvi.DocVersionConfig.RODefaults_graphicsprefix : _Mydvi.DocVersionConfig.RODefaults_setpointprefix;
|
ROFSTLookup.rodbi[] dbs = MyROFST.ROFSTLookup.GetRODatabaseList();
|
||||||
|
ROFSTLookup.rodbi db = dbs[int.Parse(roch.roid.Substring(0, 4))-1];
|
||||||
|
string accPrefix = db.dbiAP.Replace(_Mydvi.DocVersionConfig.RODefaults_graphicsprefix,"IG");
|
||||||
|
accPrefix = accPrefix.Replace(_Mydvi.DocVersionConfig.RODefaults_setpointprefix, "SP");
|
||||||
|
// string accPrefix = (roch.type == 8) ? _Mydvi.DocVersionConfig.RODefaults_graphicsprefix : _Mydvi.DocVersionConfig.RODefaults_setpointprefix;
|
||||||
string AccPageID = string.Format("<{0}-{1}>", accPrefix, roch.appid);// makes <SP1-A.1> for example
|
string AccPageID = string.Format("<{0}-{1}>", accPrefix, roch.appid);// makes <SP1-A.1> for example
|
||||||
|
Console.WriteLine(AccPageID);
|
||||||
//string AccPageID = string.Format("{0} <{1}-{2}>", ConvertSymbolsAndStuff(selectedChld.value), accPrefix, roch.appid); // value and accesory ID
|
//string AccPageID = string.Format("{0} <{1}-{2}>", ConvertSymbolsAndStuff(selectedChld.value), accPrefix, roch.appid); // value and accesory ID
|
||||||
//string AccPageID = string.Format("{0} {1}", ConvertSymbolsAndStuff(selectedChld.value), string.Format(@"#Link:ReferencedObject:<NewID> {0} {1}", roch.roid, _MyROFST.MyRODb.RODbID)); // value and link reference
|
//string AccPageID = string.Format("{0} {1}", ConvertSymbolsAndStuff(selectedChld.value), string.Format(@"#Link:ReferencedObject:<NewID> {0} {1}", roch.roid, _MyROFST.MyRODb.RODbID)); // value and link reference
|
||||||
//if (MessageBox.Show(AccPageID,"Place on Windows Clipboard?",MessageBoxButtons.YesNo) == DialogResult.Yes)
|
//if (MessageBox.Show(AccPageID,"Place on Windows Clipboard?",MessageBoxButtons.YesNo) == DialogResult.Yes)
|
||||||
@ -447,6 +452,9 @@ namespace Volian.Controls.Library
|
|||||||
_MyRTB.Focus();
|
_MyRTB.Focus();
|
||||||
}
|
}
|
||||||
_MyRTB.inRoAdd = false;
|
_MyRTB.inRoAdd = false;
|
||||||
|
btnSaveRO.Enabled = btnCancelRO.Enabled = btnPreviewRO.Enabled = false;
|
||||||
|
_SavCurROLink = null;
|
||||||
|
CurROLink = null;
|
||||||
}
|
}
|
||||||
//else // we're in an Word attachment
|
//else // we're in an Word attachment
|
||||||
//{
|
//{
|
||||||
@ -458,9 +466,6 @@ namespace Volian.Controls.Library
|
|||||||
// if (dti.MyDSOTabPanel != null)
|
// if (dti.MyDSOTabPanel != null)
|
||||||
// dti.MyDSOTabPanel.InsertText(AccPageID);
|
// dti.MyDSOTabPanel.InsertText(AccPageID);
|
||||||
//}
|
//}
|
||||||
btnSaveRO.Enabled = btnCancelRO.Enabled = btnPreviewRO.Enabled = false;
|
|
||||||
_SavCurROLink = null;
|
|
||||||
CurROLink = null;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user