Compare commits
18 Commits
7312330448
...
65c874508e
Author | SHA1 | Date | |
---|---|---|---|
65c874508e | |||
830c84a62e | |||
8b666ed287 | |||
6d5d87f04d | |||
ef3efe2380 | |||
a923a597f3 | |||
e4af381d0c | |||
350b943066 | |||
1cf3a52afa | |||
10821a478b | |||
3a6b1adc47 | |||
ad476d8de4 | |||
a472169c9d | |||
dcc49a10e5 | |||
3ea3c32d06 | |||
25d500c44e | |||
0fa0213eac | |||
314356de36 |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -44,8 +44,9 @@ using System.Runtime.InteropServices;
|
|||||||
// Revision DHH (day - no leading zero, two digit hour - military time
|
// Revision DHH (day - no leading zero, two digit hour - military time
|
||||||
//
|
//
|
||||||
// ********* REMEMBER TO CHECK THE AssemblyConfiguration SETTING (ABOVE) ********
|
// ********* REMEMBER TO CHECK THE AssemblyConfiguration SETTING (ABOVE) ********
|
||||||
[assembly: AssemblyVersion("2.1.2308.2110")]
|
[assembly: AssemblyVersion("2.1.2308.2414")]
|
||||||
[assembly: AssemblyFileVersion("2.1.2308.2110")]
|
[assembly: AssemblyFileVersion("2.1.2308.2414")]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -333,6 +333,25 @@ namespace VEPROMS.CSLA.Library
|
|||||||
OnPropertyChanged("Step_PreferredPagebreak");
|
OnPropertyChanged("Step_PreferredPagebreak");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// C2023-015: Pagination on a sub-step
|
||||||
|
public bool Step_SubStepPagebreak
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
string s = _Xp["Step", "SubStepPagebreak"];
|
||||||
|
|
||||||
|
if (s == string.Empty) return false;
|
||||||
|
if (s == "True") return true;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
set
|
||||||
|
{
|
||||||
|
string s = _Xp["Step", "SubStepPagebreak"];
|
||||||
|
if (value.ToString() == s) return;
|
||||||
|
_Xp["Step", "SubStepPagebreak"] = value.ToString();
|
||||||
|
OnPropertyChanged("Step_SubStepPagebreak");
|
||||||
|
}
|
||||||
|
}
|
||||||
//[Category("Step Attributes")]
|
//[Category("Step Attributes")]
|
||||||
//[DisplayName("Step Change Bar Override")]
|
//[DisplayName("Step Change Bar Override")]
|
||||||
//[RefreshProperties(RefreshProperties.All)]
|
//[RefreshProperties(RefreshProperties.All)]
|
||||||
|
@ -160,6 +160,107 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// B2023-093 This method is called before editing or printing a Word section and will convert it the Word .DOCX format if needed.
|
||||||
|
// Note that the core logic was taken from frmSectionProperties.cs and modified to convert both .RTF and .DOC files
|
||||||
|
// The conversion to DOCX is needs to be done only one time per Word section
|
||||||
|
public static void ConvertWordSectionToDOCX(ItemInfo itmInfo)
|
||||||
|
{
|
||||||
|
// check the Word file extension that is saved in the tblDocuments SQL database table
|
||||||
|
DocumentInfo docInfo = itmInfo.MyContent.MyEntry.MyDocument;
|
||||||
|
if (docInfo.FileExtension.ToUpper() == ".DOCX") return; // already a DOCX - no need to convert
|
||||||
|
FrmPopupStatusMessage pmsg = null;
|
||||||
|
DSOFile myfile = null;
|
||||||
|
LBWordLibrary.LBApplicationClass ap = null;
|
||||||
|
LBWordLibrary.LBDocumentClass doc = null;
|
||||||
|
string orgFilename = null;
|
||||||
|
string filename = null;
|
||||||
|
FileInfo fi = null;
|
||||||
|
FileStream fs = null;
|
||||||
|
SectionInfo msi = null;
|
||||||
|
Section sec = null;
|
||||||
|
SectionConfig cfg = null;
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
// show user a status window of the Word section being converted to DOCX
|
||||||
|
// use the section number (DisplayNumber) unless the length is zero, then use the section title (DisplayText)
|
||||||
|
string statMsg = itmInfo.DisplayNumber;
|
||||||
|
if (statMsg.Length == 0)
|
||||||
|
statMsg = itmInfo.DisplayText;
|
||||||
|
pmsg = new FrmPopupStatusMessage("Converting This Section to Word DOCX", statMsg);
|
||||||
|
pmsg.Show();
|
||||||
|
|
||||||
|
// Get Document as file - it's placed in the user's temporary folder (like we do when we edit a Word section)
|
||||||
|
myfile = new DSOFile(docInfo);
|
||||||
|
|
||||||
|
// Open MSWord App
|
||||||
|
ap = new LBWordLibrary.LBApplicationClass();
|
||||||
|
doc = ap.Documents.Open(myfile.FullName);
|
||||||
|
|
||||||
|
// Older versions of PROMS saved the Word section as either a RTF or the old-style Word DOC file
|
||||||
|
// In either case, we want to convert it to a Word DOCX file
|
||||||
|
// So now create a file name with the .DOCX extension
|
||||||
|
orgFilename = myfile.FullName.ToUpper();
|
||||||
|
filename = orgFilename.Replace(".RTF", ".DOCX").Replace(".DOC", ".DOCX"); // we want to convert either .RTF or .DOC Word sections
|
||||||
|
|
||||||
|
// This calls Word's convert function to convert the opened .DOC or .RTF to DOCX and save it to our new DOCX file name
|
||||||
|
doc.SaveAs(filename, LBWordLibrary.LBWdSaveFormat.wdFormatXMLDocument); // Convert to Word DOCX
|
||||||
|
doc.Close();
|
||||||
|
doc = null;
|
||||||
|
|
||||||
|
// Now read in the new .DOCX file and save the contents to the SQL database
|
||||||
|
fi = new FileInfo(filename);
|
||||||
|
fs = File.Open(filename, FileMode.Open, FileAccess.Read, FileShare.ReadWrite);// B2016-053
|
||||||
|
long len = fs.Length;
|
||||||
|
byte[] ByteArray = new byte[len];
|
||||||
|
int nBytesRead = fs.Read(ByteArray, 0, (int)len);
|
||||||
|
|
||||||
|
bool isLibraryDocument = (docInfo.LibTitle != null && docInfo.LibTitle != "");
|
||||||
|
Document myDoc = null;
|
||||||
|
if (isLibraryDocument)
|
||||||
|
myDoc = Document.Get(docInfo.DocID);
|
||||||
|
else
|
||||||
|
myDoc = Document.MakeDocument(null, ByteArray, docInfo.DocAscii, docInfo.Config, ".DOCX");
|
||||||
|
|
||||||
|
// update the document information in the database
|
||||||
|
msi = itmInfo as SectionInfo;
|
||||||
|
sec = msi.Get();
|
||||||
|
cfg = sec.SectionConfig;
|
||||||
|
if (!isLibraryDocument)
|
||||||
|
cfg.MySection.MyContent.MyEntry.MyDocument = myDoc; // resetting MyDocument will clear the library doc link - so don't do if a library document
|
||||||
|
else
|
||||||
|
cfg.MySection.MyContent.MyEntry.MyDocument.DocContent = ByteArray; // only update .DocContent for library documents
|
||||||
|
cfg.MySection.MyContent.MyEntry.MyDocument.FileExtension = ".DOCX"; // make sure the Word file extension is .DOCX
|
||||||
|
cfg.MySection.MyContent.MyEntry.MyDocument.DTS = fi.LastWriteTimeUtc;
|
||||||
|
cfg.MySection.MyContent.MyEntry.MyDocument.MarkDirty();
|
||||||
|
cfg.MySection.MyContent.MyEntry.Save();
|
||||||
|
|
||||||
|
_MyLog.InfoFormat("Converted Word Section to DOCX - Old ID {0} - New ID {1} - {2}", docInfo.DocID, myDoc.DocID, statMsg); // record in log file (aka error log) that conversion was done
|
||||||
|
// delete the temporary files
|
||||||
|
FileInfo orgFile = new FileInfo(orgFilename);
|
||||||
|
orgFile.Delete();// delete the old temporary Word file (.DOC or .RTF)
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
_MyLog.ErrorFormat("Error converting Word section to DOCX - {0}", ex.Message);
|
||||||
|
_MyLog.ErrorFormat("Error converting Word section to DOCX - ConvertWordSetionToDOXX: ItemID ={0} DOCID={1} LibTitle = {2}", itmInfo, docInfo.DocID, docInfo.LibTitle);
|
||||||
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
if (pmsg != null)
|
||||||
|
pmsg.Close();// close the statue message
|
||||||
|
if (ap != null)
|
||||||
|
ap.Quit(); // close the Word app
|
||||||
|
if (doc != null)
|
||||||
|
doc.Close();
|
||||||
|
if (fs != null)
|
||||||
|
fs.Close();
|
||||||
|
if (fi != null && fi.Exists)
|
||||||
|
fi.Delete();// delete the temporary .DOCX file
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// FixString processes the string returned and changes any symbols (0xF0??) to normal characters
|
/// FixString processes the string returned and changes any symbols (0xF0??) to normal characters
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
72
PROMS/Volian.Base.Library/FrmPopupStatusMessage.Designer.cs
generated
Normal file
72
PROMS/Volian.Base.Library/FrmPopupStatusMessage.Designer.cs
generated
Normal file
@ -0,0 +1,72 @@
|
|||||||
|
|
||||||
|
namespace Volian.Base.Library
|
||||||
|
{
|
||||||
|
partial class FrmPopupStatusMessage
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Required designer variable.
|
||||||
|
/// </summary>
|
||||||
|
private System.ComponentModel.IContainer components = null;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Clean up any resources being used.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||||
|
protected override void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (disposing && (components != null))
|
||||||
|
{
|
||||||
|
components.Dispose();
|
||||||
|
}
|
||||||
|
base.Dispose(disposing);
|
||||||
|
}
|
||||||
|
|
||||||
|
#region Windows Form Designer generated code
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Required method for Designer support - do not modify
|
||||||
|
/// the contents of this method with the code editor.
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeComponent()
|
||||||
|
{
|
||||||
|
this.popMsg = new System.Windows.Forms.Label();
|
||||||
|
this.SuspendLayout();
|
||||||
|
//
|
||||||
|
// popMsg
|
||||||
|
//
|
||||||
|
this.popMsg.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.popMsg.Location = new System.Drawing.Point(13, 13);
|
||||||
|
this.popMsg.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
|
||||||
|
this.popMsg.Name = "popMsg";
|
||||||
|
this.popMsg.Size = new System.Drawing.Size(536, 16);
|
||||||
|
this.popMsg.TabIndex = 0;
|
||||||
|
this.popMsg.Text = "label1";
|
||||||
|
this.popMsg.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
|
||||||
|
this.popMsg.UseWaitCursor = true;
|
||||||
|
//
|
||||||
|
// FrmPopupStatusMessage
|
||||||
|
//
|
||||||
|
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
|
||||||
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||||
|
this.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
|
||||||
|
this.ClientSize = new System.Drawing.Size(562, 38);
|
||||||
|
this.ControlBox = false;
|
||||||
|
this.Controls.Add(this.popMsg);
|
||||||
|
this.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||||
|
this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||||
|
this.MaximizeBox = false;
|
||||||
|
this.MinimizeBox = false;
|
||||||
|
this.Name = "FrmPopupStatusMessage";
|
||||||
|
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||||
|
this.Text = "FrmPopupStatusMessage";
|
||||||
|
this.TopMost = true;
|
||||||
|
this.UseWaitCursor = true;
|
||||||
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
private System.Windows.Forms.Label popMsg;
|
||||||
|
}
|
||||||
|
}
|
28
PROMS/Volian.Base.Library/FrmPopupStatusMessage.cs
Normal file
28
PROMS/Volian.Base.Library/FrmPopupStatusMessage.cs
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
|
namespace Volian.Base.Library
|
||||||
|
{
|
||||||
|
public partial class FrmPopupStatusMessage : Form
|
||||||
|
{
|
||||||
|
// This creates a simple message box consisting of a title and the message
|
||||||
|
// The purpose is to allow the coder to pop up brief status message during the running of a method for a 3rd party.
|
||||||
|
// i.e. this is used when PROMS uses Word to convert to a DOCX file format for PROMS Word sections.
|
||||||
|
// The message is centered in the message box - we can expand on this class if needed
|
||||||
|
// The coder uses the Show method to display the message box and Close to remove it
|
||||||
|
// The user is not prompted for a response.
|
||||||
|
public FrmPopupStatusMessage(string title, string msg)
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
Text = title;
|
||||||
|
popMsg.Text = msg;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
120
PROMS/Volian.Base.Library/FrmPopupStatusMessage.resx
Normal file
120
PROMS/Volian.Base.Library/FrmPopupStatusMessage.resx
Normal file
@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
<xsd:attribute ref="xml:space" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
@ -95,6 +95,12 @@
|
|||||||
<Compile Include="FlagEnumEditor.cs">
|
<Compile Include="FlagEnumEditor.cs">
|
||||||
<SubType>Component</SubType>
|
<SubType>Component</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="FrmPopupStatusMessage.cs">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="FrmPopupStatusMessage.Designer.cs">
|
||||||
|
<DependentUpon>FrmPopupStatusMessage.cs</DependentUpon>
|
||||||
|
</Compile>
|
||||||
<Compile Include="frmRtfEdit.cs">
|
<Compile Include="frmRtfEdit.cs">
|
||||||
<SubType>Form</SubType>
|
<SubType>Form</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
@ -117,6 +123,9 @@
|
|||||||
<Compile Include="VolianTimer.cs" />
|
<Compile Include="VolianTimer.cs" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<EmbeddedResource Include="FrmPopupStatusMessage.resx">
|
||||||
|
<DependentUpon>FrmPopupStatusMessage.cs</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="frmRtfEdit.resx">
|
<EmbeddedResource Include="frmRtfEdit.resx">
|
||||||
<DependentUpon>frmRtfEdit.cs</DependentUpon>
|
<DependentUpon>frmRtfEdit.cs</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
|
@ -655,6 +655,7 @@ namespace Volian.Controls.Library
|
|||||||
}
|
}
|
||||||
else // Otherwise open it in the Word editor
|
else // Otherwise open it in the Word editor
|
||||||
{
|
{
|
||||||
|
Document.ConvertWordSectionToDOCX(myItemInfo); // B2023-093 Convert a Word section to the DOCX Word format if needed before opening it for edit
|
||||||
return OpenDSOTabPage(myItemInfo);
|
return OpenDSOTabPage(myItemInfo);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -827,7 +828,11 @@ namespace Volian.Controls.Library
|
|||||||
private DisplayTabItem FindRemainingTab(Bar myBar)
|
private DisplayTabItem FindRemainingTab(Bar myBar)
|
||||||
{
|
{
|
||||||
// C2023-004: Proms reverts to first tab rather than active tab/save last selected tab is and use to reset to it
|
// C2023-004: Proms reverts to first tab rather than active tab/save last selected tab is and use to reset to it
|
||||||
if (LastSelectedDisplayTabItem != null && !_RemovedDisplayTabItems.Contains(LastSelectedDisplayTabItem))
|
// B2023-078 Added the check for LastSelectedDisplayTabItem is in myBar. This fixes a crash issue where user has as split screen
|
||||||
|
// each with procedure tabs and closes a procedure tab in the split screen that does not currently have focus.
|
||||||
|
// that other screen has its own myBar list which does not contain the LastSelectedDisplayTabItem references.
|
||||||
|
// In that case we want to run through the foreach loop to find a tab in the currently active split screen side
|
||||||
|
if (LastSelectedDisplayTabItem != null && myBar.Items.Contains(LastSelectedDisplayTabItem) && !_RemovedDisplayTabItems.Contains(LastSelectedDisplayTabItem))
|
||||||
return LastSelectedDisplayTabItem;
|
return LastSelectedDisplayTabItem;
|
||||||
foreach (DisplayTabItem itm in myBar.Items)
|
foreach (DisplayTabItem itm in myBar.Items)
|
||||||
{
|
{
|
||||||
|
@ -30,6 +30,7 @@ namespace Volian.Controls.Library
|
|||||||
{
|
{
|
||||||
this.groupPanelPaginate = new DevComponents.DotNetBar.Controls.GroupPanel();
|
this.groupPanelPaginate = new DevComponents.DotNetBar.Controls.GroupPanel();
|
||||||
this.cbPrefPageBreak = new DevComponents.DotNetBar.Controls.CheckBoxX();
|
this.cbPrefPageBreak = new DevComponents.DotNetBar.Controls.CheckBoxX();
|
||||||
|
this.cbSubStepPageBreak = new DevComponents.DotNetBar.Controls.CheckBoxX();
|
||||||
this.cbPageBreak = new DevComponents.DotNetBar.Controls.CheckBoxX();
|
this.cbPageBreak = new DevComponents.DotNetBar.Controls.CheckBoxX();
|
||||||
this.cbCAS = new DevComponents.DotNetBar.Controls.CheckBoxX();
|
this.cbCAS = new DevComponents.DotNetBar.Controls.CheckBoxX();
|
||||||
this.cmbCheckoff = new DevComponents.DotNetBar.Controls.ComboBoxEx();
|
this.cmbCheckoff = new DevComponents.DotNetBar.Controls.ComboBoxEx();
|
||||||
@ -74,6 +75,7 @@ namespace Volian.Controls.Library
|
|||||||
this.groupPanelPaginate.BackColor = System.Drawing.Color.Transparent;
|
this.groupPanelPaginate.BackColor = System.Drawing.Color.Transparent;
|
||||||
this.groupPanelPaginate.CanvasColor = System.Drawing.SystemColors.Control;
|
this.groupPanelPaginate.CanvasColor = System.Drawing.SystemColors.Control;
|
||||||
this.groupPanelPaginate.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.Office2007;
|
this.groupPanelPaginate.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.Office2007;
|
||||||
|
this.groupPanelPaginate.Controls.Add(this.cbSubStepPageBreak);
|
||||||
this.groupPanelPaginate.Controls.Add(this.cbPrefPageBreak);
|
this.groupPanelPaginate.Controls.Add(this.cbPrefPageBreak);
|
||||||
this.groupPanelPaginate.Controls.Add(this.cbPageBreak);
|
this.groupPanelPaginate.Controls.Add(this.cbPageBreak);
|
||||||
this.groupPanelPaginate.DisabledBackColor = System.Drawing.Color.Empty;
|
this.groupPanelPaginate.DisabledBackColor = System.Drawing.Color.Empty;
|
||||||
@ -130,6 +132,23 @@ namespace Volian.Controls.Library
|
|||||||
this.cbPrefPageBreak.Text = "Preferred Page Break (for Sup Info)";
|
this.cbPrefPageBreak.Text = "Preferred Page Break (for Sup Info)";
|
||||||
this.cbPrefPageBreak.CheckedChanged += new System.EventHandler(this.cbPrefPageBreak_CheckedChanged);
|
this.cbPrefPageBreak.CheckedChanged += new System.EventHandler(this.cbPrefPageBreak_CheckedChanged);
|
||||||
//
|
//
|
||||||
|
// cbSubStepPageBreak
|
||||||
|
//
|
||||||
|
this.cbSubStepPageBreak.AutoSize = true;
|
||||||
|
//
|
||||||
|
//
|
||||||
|
//
|
||||||
|
this.cbSubStepPageBreak.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
|
||||||
|
this.cbSubStepPageBreak.Location = new System.Drawing.Point(3, 19);
|
||||||
|
this.cbSubStepPageBreak.Margin = new System.Windows.Forms.Padding(2);
|
||||||
|
this.cbSubStepPageBreak.Name = "cbSubStepPageBreak";
|
||||||
|
this.cbSubStepPageBreak.Size = new System.Drawing.Size(195, 15);
|
||||||
|
this.superTooltipTags.SetSuperTooltip(this.cbSubStepPageBreak, new DevComponents.DotNetBar.SuperTooltipInfo("Page Break for Sub-Steps", "", "When set, starts this step at the top of a page.\r\n\r\nkeyboard command: <Ctrl><Ente" +
|
||||||
|
"r>", null, null, DevComponents.DotNetBar.eTooltipColor.Gray));
|
||||||
|
this.cbSubStepPageBreak.TabIndex = 1;
|
||||||
|
this.cbSubStepPageBreak.Text = "Substep Page Break";
|
||||||
|
this.cbSubStepPageBreak.CheckedChanged += new System.EventHandler(this.cbSubStepPageBreak_CheckedChanged);
|
||||||
|
//
|
||||||
// cbPageBreak
|
// cbPageBreak
|
||||||
//
|
//
|
||||||
this.cbPageBreak.AutoSize = true;
|
this.cbPageBreak.AutoSize = true;
|
||||||
@ -770,6 +789,7 @@ namespace Volian.Controls.Library
|
|||||||
private System.Windows.Forms.TrackBar trBarFS;
|
private System.Windows.Forms.TrackBar trBarFS;
|
||||||
private System.Windows.Forms.Button btnFSrestore;
|
private System.Windows.Forms.Button btnFSrestore;
|
||||||
private DevComponents.DotNetBar.Controls.CheckBoxX cbPrefPageBreak;
|
private DevComponents.DotNetBar.Controls.CheckBoxX cbPrefPageBreak;
|
||||||
|
private DevComponents.DotNetBar.Controls.CheckBoxX cbSubStepPageBreak;
|
||||||
private DevComponents.DotNetBar.Controls.CheckBoxX cbIncludeInTOC;
|
private DevComponents.DotNetBar.Controls.CheckBoxX cbIncludeInTOC;
|
||||||
private DevComponents.DotNetBar.Controls.CheckBoxX cbTCAS;
|
private DevComponents.DotNetBar.Controls.CheckBoxX cbTCAS;
|
||||||
}
|
}
|
||||||
|
@ -110,6 +110,7 @@ namespace Volian.Controls.Library
|
|||||||
cmbCheckoff.Enabled = false;
|
cmbCheckoff.Enabled = false;
|
||||||
cbPageBreak.Enabled = false;
|
cbPageBreak.Enabled = false;
|
||||||
cbPrefPageBreak.Enabled = false;
|
cbPrefPageBreak.Enabled = false;
|
||||||
|
cbSubStepPageBreak.Enabled = false;
|
||||||
cbPlaceKeeper.Enabled = false;
|
cbPlaceKeeper.Enabled = false;
|
||||||
cbPlaceKeeperCont.Enabled = false;
|
cbPlaceKeeperCont.Enabled = false;
|
||||||
cbIncludeInTOC.Enabled = false;
|
cbIncludeInTOC.Enabled = false;
|
||||||
@ -244,10 +245,13 @@ namespace Volian.Controls.Library
|
|||||||
groupPanelFigSize.Style.BackColor = Color.Cornsilk;
|
groupPanelFigSize.Style.BackColor = Color.Cornsilk;
|
||||||
cbPageBreak.Checked = false; // will be set below if HLS & config has it on
|
cbPageBreak.Checked = false; // will be set below if HLS & config has it on
|
||||||
cbPrefPageBreak.Checked = false;
|
cbPrefPageBreak.Checked = false;
|
||||||
|
cbSubStepPageBreak.Checked = false;
|
||||||
cbPlaceKeeper.Checked = false; // will be set below if HLS & config has this set
|
cbPlaceKeeper.Checked = false; // will be set below if HLS & config has this set
|
||||||
cbPlaceKeeperCont.Checked = false; // will be set below if substep & config has this set
|
cbPlaceKeeperCont.Checked = false; // will be set below if substep & config has this set
|
||||||
cbPageBreak.Enabled = CurItemInfo.IsHigh;
|
cbPageBreak.Enabled = CurItemInfo.IsHigh;
|
||||||
cbPrefPageBreak.Visible = cbPrefPageBreak.Enabled = (!CurItemInfo.IsInSupInfo && CurItemInfo.MyDocStyle.SupplementalInformation);
|
cbPrefPageBreak.Visible = cbPrefPageBreak.Enabled = (!CurItemInfo.IsInSupInfo && CurItemInfo.MyDocStyle.SupplementalInformation);
|
||||||
|
// C2023-015: Pagination on a sub-step
|
||||||
|
cbSubStepPageBreak.Visible = cbSubStepPageBreak.Enabled = CurItemInfo.IsSubStep && CurItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.AlarmPagination;
|
||||||
if (!CurItemInfo.IsFigure && !CurItemInfo.IsRtfRaw)
|
if (!CurItemInfo.IsFigure && !CurItemInfo.IsRtfRaw)
|
||||||
{
|
{
|
||||||
cbPlaceKeeper.Enabled = (((SectionConfig)CurItemInfo.ActiveSection.MyConfig).Section_Placekeeper == "Y");
|
cbPlaceKeeper.Enabled = (((SectionConfig)CurItemInfo.ActiveSection.MyConfig).Section_Placekeeper == "Y");
|
||||||
@ -304,6 +308,7 @@ namespace Volian.Controls.Library
|
|||||||
if (CurItemInfo.IsHigh)
|
if (CurItemInfo.IsHigh)
|
||||||
cbPageBreak.Checked = sc.Step_NewManualPagebreak; // High Level Step has a manual page break
|
cbPageBreak.Checked = sc.Step_NewManualPagebreak; // High Level Step has a manual page break
|
||||||
if (cbPrefPageBreak.Enabled) cbPrefPageBreak.Checked = sc.Step_PreferredPagebreak;
|
if (cbPrefPageBreak.Enabled) cbPrefPageBreak.Checked = sc.Step_PreferredPagebreak;
|
||||||
|
if (cbSubStepPageBreak.Enabled) cbSubStepPageBreak.Checked = sc.Step_SubStepPagebreak;
|
||||||
cbPlaceKeeper.Checked = (sc.Step_Placekeeper == "Y"); // step text to be included on PlaceKeeper (Calvert Cliffs)
|
cbPlaceKeeper.Checked = (sc.Step_Placekeeper == "Y"); // step text to be included on PlaceKeeper (Calvert Cliffs)
|
||||||
cbPlaceKeeperCont.Checked = (sc.Step_Placekeeper == "C"); // step is included on Placekeeper and marked as continuous action (Calvert Cliffs)
|
cbPlaceKeeperCont.Checked = (sc.Step_Placekeeper == "C"); // step is included on Placekeeper and marked as continuous action (Calvert Cliffs)
|
||||||
// set the Continuous Action Summary check box to the saved setting in the config or, if nothing in config, set to format flag setting
|
// set the Continuous Action Summary check box to the saved setting in the config or, if nothing in config, set to format flag setting
|
||||||
@ -891,7 +896,17 @@ namespace Volian.Controls.Library
|
|||||||
sc.Step_PreferredPagebreak = cbPrefPageBreak.Checked;
|
sc.Step_PreferredPagebreak = cbPrefPageBreak.Checked;
|
||||||
MyEditItem.ChangeBarForConfigItemChange = true;
|
MyEditItem.ChangeBarForConfigItemChange = true;
|
||||||
}
|
}
|
||||||
|
// C2023-015: Pagination on a sub-step
|
||||||
|
private void cbSubStepPageBreak_CheckedChanged(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (_Initalizing) return;
|
||||||
|
MyEditItem.SaveContents();
|
||||||
|
StepConfig sc = CurItemInfo.MyConfig as StepConfig;
|
||||||
|
if (sc == null) return;
|
||||||
|
MyEditItem.ChangeBarForConfigItemChange = false;
|
||||||
|
sc.Step_SubStepPagebreak = cbSubStepPageBreak.Checked;
|
||||||
|
MyEditItem.ChangeBarForConfigItemChange = true;
|
||||||
|
}
|
||||||
|
|
||||||
//private void txbxAltConActSumText_Leave(object sender, EventArgs e)
|
//private void txbxAltConActSumText_Leave(object sender, EventArgs e)
|
||||||
//{
|
//{
|
||||||
|
@ -99,13 +99,15 @@ namespace Volian.Print.Library
|
|||||||
}
|
}
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
else if (MyItemInfo.MyDocStyle.SupplementalInformation && MyItemInfo.IsStep)
|
// C2023-015: Pagination on a sub-step added. Do the code if supplemental info or if format supports sub-step pagination
|
||||||
|
else if ((MyItemInfo.MyDocStyle.SupplementalInformation || MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.AlarmPagination) && MyItemInfo.IsStep)
|
||||||
{
|
{
|
||||||
// if this is the first caution or note from a substep, if the substep has preferred page break, break at the first caution or note:
|
// if this is the first caution or note from a substep, if the substep has preferred page break, break at the first caution or note:
|
||||||
if ((MyItemInfo.IsCaution || MyItemInfo.IsNote) && MyItemInfo.MyParent.IsSubStep)
|
if ((MyItemInfo.IsCaution || MyItemInfo.IsNote) && MyItemInfo.MyParent.IsSubStep)
|
||||||
{
|
{
|
||||||
StepConfig scs = MyItemInfo.MyParent.MyConfig as StepConfig;
|
StepConfig scs = MyItemInfo.MyParent.MyConfig as StepConfig;
|
||||||
if (MyItemInfo.MyPrevious == null && scs.Step_PreferredPagebreak)
|
// C2023-015: Pagination on a sub-step added on this check
|
||||||
|
if (MyItemInfo.MyPrevious == null && (scs.Step_PreferredPagebreak || scs.Step_SubStepPagebreak))
|
||||||
{
|
{
|
||||||
// B2018-103: The following flags a break within the step. Before returning a '2' (flags break within step), clear it out of the
|
// B2018-103: The following flags a break within the step. Before returning a '2' (flags break within step), clear it out of the
|
||||||
// ParaBreaks. Without the 'RemoveAt', a page break will occur after this step also.
|
// ParaBreaks. Without the 'RemoveAt', a page break will occur after this step also.
|
||||||
@ -120,7 +122,7 @@ namespace Volian.Print.Library
|
|||||||
}
|
}
|
||||||
// Now see if there is a preferred page break on this step.
|
// Now see if there is a preferred page break on this step.
|
||||||
StepConfig sci = MyItemInfo.MyConfig as StepConfig;
|
StepConfig sci = MyItemInfo.MyConfig as StepConfig;
|
||||||
if (sci.Step_PreferredPagebreak)
|
if (sci.Step_PreferredPagebreak || sci.Step_SubStepPagebreak)
|
||||||
{
|
{
|
||||||
if (MyItemInfo.IsHigh) return 1;
|
if (MyItemInfo.IsHigh) return 1;
|
||||||
// if this is the top caution/note return 1 also. Cautions always are first, that is why the check does not need to know if on a
|
// if this is the top caution/note return 1 also. Cautions always are first, that is why the check does not need to know if on a
|
||||||
@ -1472,7 +1474,8 @@ namespace Volian.Print.Library
|
|||||||
// substep with preferred page break (B2017-109)
|
// substep with preferred page break (B2017-109)
|
||||||
private SortedList<float, vlnParagraph> GetMyPreferredBreaks(StepLevelList myList)
|
private SortedList<float, vlnParagraph> GetMyPreferredBreaks(StepLevelList myList)
|
||||||
{
|
{
|
||||||
if (!MyItemInfo.MyDocStyle.SupplementalInformation) return null;
|
// C2023-015: Pagination on a sub-step added. Do the code if supplemental info or if format supports sub-step pagination
|
||||||
|
if (!MyItemInfo.MyDocStyle.SupplementalInformation && !MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.StepSectionLayoutData.AlarmPagination) return null;
|
||||||
SortedList<float, vlnParagraph> sdpara = null;
|
SortedList<float, vlnParagraph> sdpara = null;
|
||||||
foreach (int stepLevel in myList.Keys) // loop thru StepLevels, starting with lowest.
|
foreach (int stepLevel in myList.Keys) // loop thru StepLevels, starting with lowest.
|
||||||
{
|
{
|
||||||
@ -1480,7 +1483,7 @@ namespace Volian.Print.Library
|
|||||||
{
|
{
|
||||||
vlnParagraph myPara = myList[stepLevel][yLocation];
|
vlnParagraph myPara = myList[stepLevel][yLocation];
|
||||||
StepConfig sci = myPara.MyItemInfo.MyConfig as StepConfig;
|
StepConfig sci = myPara.MyItemInfo.MyConfig as StepConfig;
|
||||||
if (sci != null && sci.Step_PreferredPagebreak)
|
if (sci != null && sci.Step_PreferredPagebreak || sci.Step_SubStepPagebreak)
|
||||||
{
|
{
|
||||||
if (sdpara == null) sdpara = new SortedList<float, vlnParagraph>();
|
if (sdpara == null) sdpara = new SortedList<float, vlnParagraph>();
|
||||||
if (myPara.ChildrenAbove != null && myPara.ChildrenAbove.Count > 0) sdpara.Add(-yLocation, myPara.ChildrenAbove[0]);
|
if (myPara.ChildrenAbove != null && myPara.ChildrenAbove.Count > 0) sdpara.Add(-yLocation, myPara.ChildrenAbove[0]);
|
||||||
|
@ -761,6 +761,10 @@ namespace Volian.Print.Library
|
|||||||
int cnt = 0;
|
int cnt = 0;
|
||||||
foreach (SectionInfo mySection in myProcedure.Sections)
|
foreach (SectionInfo mySection in myProcedure.Sections)
|
||||||
{
|
{
|
||||||
|
if (!mySection.MyDocStyle.IsStepSection && !mySection.IsAutoTOCSection)
|
||||||
|
{
|
||||||
|
VEPROMS.CSLA.Library.Document.ConvertWordSectionToDOCX((ItemInfo)mySection); // B2023-093 Convert a Word section to the DOCX Word format if needed before printing
|
||||||
|
}
|
||||||
//C2019-042 Section_IsFoldout checks Section Number, Section Title, and use of check box
|
//C2019-042 Section_IsFoldout checks Section Number, Section Title, and use of check box
|
||||||
if ((myProcedure.ActiveFormat.PlantFormat.FormatData.PrintData.SectionLevelFoldouts && (mySection.MyConfig as SectionConfig).Section_IsFoldout == "Y")
|
if ((myProcedure.ActiveFormat.PlantFormat.FormatData.PrintData.SectionLevelFoldouts && (mySection.MyConfig as SectionConfig).Section_IsFoldout == "Y")
|
||||||
|| (myProcedure.ActiveFormat.PlantFormat.FormatData.PrintData.AlternateFloatingFoldout && (mySection.MyConfig as SectionConfig).Section_IsFoldout == "Y"))
|
|| (myProcedure.ActiveFormat.PlantFormat.FormatData.PrintData.AlternateFloatingFoldout && (mySection.MyConfig as SectionConfig).Section_IsFoldout == "Y"))
|
||||||
|
@ -7098,7 +7098,7 @@ namespace Volian.Print.Library
|
|||||||
//if (paraLoc.MyParagraph.MyItemInfo.MyPrevious == null) // First substep
|
//if (paraLoc.MyParagraph.MyItemInfo.MyPrevious == null) // First substep
|
||||||
level = 0;
|
level = 0;
|
||||||
else
|
else
|
||||||
level = AlarmPagination?3:1; // B2023-088 make it easier to break on a sequential for alarms
|
level = 1; // AlarmPagination?3:1; // B2023-091: backout B2023-088 make it easier to break on a sequential for alarms
|
||||||
}
|
}
|
||||||
else if (AlarmPagination && paraLoc.MyParagraph.MyItemInfo.IsSubStep)
|
else if (AlarmPagination && paraLoc.MyParagraph.MyItemInfo.IsSubStep)
|
||||||
{
|
{
|
||||||
|
1
UpdateBranches.bat
Normal file
1
UpdateBranches.bat
Normal file
@ -0,0 +1 @@
|
|||||||
|
start "" "%PROGRAMFILES%\Git\bin\sh.exe" -c "git fetch -p ; git branch -r | awk '{print $1}' | egrep -v -f /dev/fd/0 <(git branch -vv | grep origin) | awk '{print $1}' | xargs --no-run-if-empty git branch -d;"
|
Loading…
x
Reference in New Issue
Block a user