calls static function to get path to RO Editor, Also, double-click on RO Value will insert the RO Value
This commit is contained in:
parent
c105823da0
commit
36fd716fed
@ -509,6 +509,11 @@ namespace Volian.Controls.Library
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
private void btnSaveRO_Click(object sender, EventArgs e)
|
private void btnSaveRO_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
SaveRO();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void SaveRO()
|
||||||
{
|
{
|
||||||
if (tbROValue.Text == null || tbROValue.Text == "")
|
if (tbROValue.Text == null || tbROValue.Text == "")
|
||||||
{
|
{
|
||||||
@ -540,9 +545,9 @@ namespace Volian.Controls.Library
|
|||||||
MessageBox.Show("Error occurred finding RO. Contact Volian");
|
MessageBox.Show("Error occurred finding RO. Contact Volian");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
string accPrefix = db.dbiAP.Replace(_Mydvi.DocVersionConfig.RODefaults_graphicsprefix,"IG");
|
string accPrefix = db.dbiAP.Replace(_Mydvi.DocVersionConfig.RODefaults_graphicsprefix, "IG");
|
||||||
accPrefix = accPrefix.Replace(_Mydvi.DocVersionConfig.RODefaults_setpointprefix, "SP");
|
accPrefix = accPrefix.Replace(_Mydvi.DocVersionConfig.RODefaults_setpointprefix, "SP");
|
||||||
// string accPrefix = (roch.type == 8) ? _Mydvi.DocVersionConfig.RODefaults_graphicsprefix : _Mydvi.DocVersionConfig.RODefaults_setpointprefix;
|
// string accPrefix = (roch.type == 8) ? _Mydvi.DocVersionConfig.RODefaults_graphicsprefix : _Mydvi.DocVersionConfig.RODefaults_setpointprefix;
|
||||||
string suffix = roch.roid.Substring(12, 4) == "0041" ? "" : "." + ((char)Convert.ToInt32(roch.roid.Substring(12, 4), 16)).ToString();
|
string suffix = roch.roid.Substring(12, 4) == "0041" ? "" : "." + ((char)Convert.ToInt32(roch.roid.Substring(12, 4), 16)).ToString();
|
||||||
string AccPageID = string.Format("<{0}-{1}{2}>", accPrefix, roch.appid, suffix);// makes <SP1-A.1.B> for example
|
string AccPageID = string.Format("<{0}-{1}{2}>", accPrefix, roch.appid, suffix);// makes <SP1-A.1.B> for example
|
||||||
Console.WriteLine(AccPageID);
|
Console.WriteLine(AccPageID);
|
||||||
@ -763,7 +768,8 @@ namespace Volian.Controls.Library
|
|||||||
MessageBox.Show("Referenced Object Editor not available in the Demo version.", "PROMS Demo Version");
|
MessageBox.Show("Referenced Object Editor not available in the Demo version.", "PROMS Demo Version");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
string roapp = Environment.GetEnvironmentVariable("roapp");
|
//string roapp = Environment.GetEnvironmentVariable("roapp");
|
||||||
|
string roapp = Volian.Base.Library.ExeInfo.GetROEditorPath(); // get the path to the RO Editor Executable
|
||||||
Object obj = tvROFST.SelectedNode.Tag;
|
Object obj = tvROFST.SelectedNode.Tag;
|
||||||
if (obj is ROFSTLookup.rochild)
|
if (obj is ROFSTLookup.rochild)
|
||||||
{
|
{
|
||||||
@ -797,7 +803,8 @@ namespace Volian.Controls.Library
|
|||||||
MessageBox.Show("Referenced Object Editor not available in the Demo version.", "PROMS Demo Version");
|
MessageBox.Show("Referenced Object Editor not available in the Demo version.", "PROMS Demo Version");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
string roapp = Environment.GetEnvironmentVariable("roapp");
|
//string roapp = Environment.GetEnvironmentVariable("roapp");
|
||||||
|
string roapp = Volian.Base.Library.ExeInfo.GetROEditorPath(); // get the path to the RO Editor Executable
|
||||||
Object obj = tvROFST.SelectedNode.Tag;
|
Object obj = tvROFST.SelectedNode.Tag;
|
||||||
if (obj is ROFSTLookup.rochild)
|
if (obj is ROFSTLookup.rochild)
|
||||||
{
|
{
|
||||||
@ -815,8 +822,9 @@ namespace Volian.Controls.Library
|
|||||||
|
|
||||||
private void tvROFST_DoubleClick(object sender, EventArgs e)
|
private void tvROFST_DoubleClick(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
if (tvROFST.SelectedNode == null) return;
|
//if (tvROFST.SelectedNode == null) return;
|
||||||
RunRoEditor();
|
//RunRoEditor();
|
||||||
|
SaveRO();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1564,7 +1564,8 @@ namespace Volian.Controls.Library
|
|||||||
myROID = lt.MyRoUsageInfo.ROID.ToLower();
|
myROID = lt.MyRoUsageInfo.ROID.ToLower();
|
||||||
myRODB = lt.MyRoUsageInfo.MyRODb;
|
myRODB = lt.MyRoUsageInfo.MyRODb;
|
||||||
}
|
}
|
||||||
string roapp = Environment.GetEnvironmentVariable("roapp");
|
//string roapp = Environment.GetEnvironmentVariable("roapp");
|
||||||
|
string roapp = Volian.Base.Library.ExeInfo.GetROEditorPath(); // get the path to the RO Editor Executable
|
||||||
string args = "\"" + myRODB.FolderPath + "\" " + myROID;
|
string args = "\"" + myRODB.FolderPath + "\" " + myROID;
|
||||||
if (!Directory.Exists(myRODB.FolderPath))
|
if (!Directory.Exists(myRODB.FolderPath))
|
||||||
{
|
{
|
||||||
@ -1642,7 +1643,8 @@ namespace Volian.Controls.Library
|
|||||||
MessageBox.Show("Referenced Object Editor not available in the Demo version.", "PROMS Demo Version");
|
MessageBox.Show("Referenced Object Editor not available in the Demo version.", "PROMS Demo Version");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
string roapp = Environment.GetEnvironmentVariable("roapp");
|
//string roapp = Environment.GetEnvironmentVariable("roapp");
|
||||||
|
string roapp = Volian.Base.Library.ExeInfo.GetROEditorPath(); // get the path to the RO Editor Executable
|
||||||
if (roapp == null || roapp == string.Empty)
|
if (roapp == null || roapp == string.Empty)
|
||||||
{
|
{
|
||||||
MessageBox.Show("The 'roapp' environment variable needs to be set to the path of the RO Editor\n\n Ex: C:\\VE-PROMS.NET\\Bin\\roeditor.exe", "Environment Variable Error");
|
MessageBox.Show("The 'roapp' environment variable needs to be set to the path of the RO Editor\n\n Ex: C:\\VE-PROMS.NET\\Bin\\roeditor.exe", "Environment Variable Error");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user