added access to MSWord’s ShowRevisionsAndComments as well as
RevisionView When we generate the PDFs for Word Attachments, we now for Word to print with ShowRevisionsAndComments set to False, and RevisionView set to ViewFinal (instead ViewFinalWithMarkups)
This commit is contained in:
parent
33688179ea
commit
06990b5c13
@ -785,6 +785,16 @@ namespace LBWordLibrary
|
||||
get { return (LBWdViewType)GetProperty("Type"); }
|
||||
set { SetProperty("Type", value); }
|
||||
}
|
||||
public Boolean ShowRevisionsAndComments
|
||||
{
|
||||
get { return (GetProperty("ShowRevisionsAndComments") as Boolean? ?? false); }
|
||||
set { SetProperty("ShowRevisionsAndComments", value); }
|
||||
}
|
||||
public LBWdRevisionsView RevisionsView
|
||||
{
|
||||
get { return (LBWdRevisionsView)GetProperty("RevisionsView"); }
|
||||
set { SetProperty("RevisionsView", value); }
|
||||
}
|
||||
}
|
||||
public enum LBWdColorIndex
|
||||
{
|
||||
@ -899,6 +909,27 @@ namespace LBWordLibrary
|
||||
wdColorWhite = 16777215,
|
||||
wdColorAutomatic = -16777216
|
||||
}
|
||||
public enum LBWdUnderline
|
||||
{
|
||||
wdUnderlineNone = 0,
|
||||
wdUnderlineSingle = 1,
|
||||
wdUnderlineWords = 2,
|
||||
wdUnderlineDouble = 3,
|
||||
wdUnderlineDotted = 4,
|
||||
wdUnderlineThick = 6,
|
||||
wdUnderlineDash = 7,
|
||||
wdUnderlineDotDash = 9,
|
||||
wdUnderlineDotDotDash = 10,
|
||||
wdUnderlineWavy = 11,
|
||||
wdUnderlineDottedHeavy = 20,
|
||||
wdUnderlineDashHeavy = 23,
|
||||
wdUnderlineDotDashHeavy = 25,
|
||||
wdUnderlineDotDotDashHeavy = 26,
|
||||
wdUnderlineWavyHeavy = 27,
|
||||
wdUnderlineDashLong = 39,
|
||||
wdUnderlineWavyDouble = 43,
|
||||
wdUnderlineDashLongHeavy = 55
|
||||
}
|
||||
public partial class LBInlineShape : LBComObject
|
||||
{
|
||||
public LBInlineShape() { }
|
||||
@ -1053,6 +1084,33 @@ namespace LBWordLibrary
|
||||
wdWebView = 6,
|
||||
wdReadingView = 7
|
||||
}
|
||||
public enum LBWdRevisionsView
|
||||
{
|
||||
wdRevisionsViewFinal = 0,
|
||||
wdRevisionsViewOriginal = 1
|
||||
}
|
||||
public enum LBWdRelativeHorizontalPosition
|
||||
{
|
||||
wdRelativeHorizontalPositionMargin = 0,
|
||||
wdRelativeHorizontalPositionPage = 1,
|
||||
wdRelativeHorizontalPositionColumn = 2,
|
||||
wdRelativeHorizontalPositionCharacter = 3,
|
||||
wdRelativeHorizontalPositionLeftMarginArea = 4,
|
||||
wdRelativeHorizontalPositionRightMarginArea = 5,
|
||||
wdRelativeHorizontalPositionInnerMarginArea = 6,
|
||||
wdRelativeHorizontalPositionOuterMarginArea = 7
|
||||
}
|
||||
public enum LBWdRelativeVerticalPosition
|
||||
{
|
||||
wdRelativeVerticalPositionMargin = 0,
|
||||
wdRelativeVerticalPositionPage = 1,
|
||||
wdRelativeVerticalPositionParagraph = 2,
|
||||
wdRelativeVerticalPositionLine = 3,
|
||||
wdRelativeVerticalPositionTopMarginArea = 4,
|
||||
wdRelativeVerticalPositionBottomMarginArea = 5,
|
||||
wdRelativeVerticalPositionInnerMarginArea = 6,
|
||||
wdRelativeVerticalPositionOuterMarginArea = 7
|
||||
}
|
||||
public enum LBWdSaveFormat
|
||||
{
|
||||
wdFormatDocument = 0,
|
||||
@ -1234,47 +1292,4 @@ namespace LBWordLibrary
|
||||
public LBPictureFormat() { }
|
||||
public LBPictureFormat(Object item) : base(item) { }
|
||||
}
|
||||
public enum LBWdRelativeHorizontalPosition
|
||||
{
|
||||
wdRelativeHorizontalPositionMargin = 0,
|
||||
wdRelativeHorizontalPositionPage = 1,
|
||||
wdRelativeHorizontalPositionColumn = 2,
|
||||
wdRelativeHorizontalPositionCharacter = 3,
|
||||
wdRelativeHorizontalPositionLeftMarginArea = 4,
|
||||
wdRelativeHorizontalPositionRightMarginArea = 5,
|
||||
wdRelativeHorizontalPositionInnerMarginArea = 6,
|
||||
wdRelativeHorizontalPositionOuterMarginArea = 7
|
||||
}
|
||||
public enum LBWdRelativeVerticalPosition
|
||||
{
|
||||
wdRelativeVerticalPositionMargin = 0,
|
||||
wdRelativeVerticalPositionPage = 1,
|
||||
wdRelativeVerticalPositionParagraph = 2,
|
||||
wdRelativeVerticalPositionLine = 3,
|
||||
wdRelativeVerticalPositionTopMarginArea = 4,
|
||||
wdRelativeVerticalPositionBottomMarginArea = 5,
|
||||
wdRelativeVerticalPositionInnerMarginArea = 6,
|
||||
wdRelativeVerticalPositionOuterMarginArea = 7
|
||||
}
|
||||
public enum LBWdUnderline
|
||||
{
|
||||
wdUnderlineNone = 0,
|
||||
wdUnderlineSingle = 1,
|
||||
wdUnderlineWords = 2,
|
||||
wdUnderlineDouble = 3,
|
||||
wdUnderlineDotted = 4,
|
||||
wdUnderlineThick = 6,
|
||||
wdUnderlineDash = 7,
|
||||
wdUnderlineDotDash = 9,
|
||||
wdUnderlineDotDotDash = 10,
|
||||
wdUnderlineWavy = 11,
|
||||
wdUnderlineDottedHeavy = 20,
|
||||
wdUnderlineDashHeavy = 23,
|
||||
wdUnderlineDotDashHeavy = 25,
|
||||
wdUnderlineDotDotDashHeavy = 26,
|
||||
wdUnderlineWavyHeavy = 27,
|
||||
wdUnderlineDashLong = 39,
|
||||
wdUnderlineWavyDouble = 43,
|
||||
wdUnderlineDashLongHeavy = 55
|
||||
}
|
||||
}
|
||||
|
@ -796,6 +796,9 @@ namespace VEPROMS.CSLA.Library
|
||||
//sel.Range.Font.Color = (LBWdColor)WordColor(PrintOverride.OverrideTextColor(System.Drawing.Color.Black));
|
||||
sel.Range.Font.Color = (LBWdColor)WordColor(OverrideColor == System.Drawing.Color.Transparent ? System.Drawing.Color.Black : OverrideColor);
|
||||
sect.MSWordPageCount = myDoc.Length;
|
||||
// force Print of MS Word Attachment to Final without revisions and comments
|
||||
myDoc.ActiveWindow.View.ShowRevisionsAndComments = false;
|
||||
myDoc.ActiveWindow.View.RevisionsView = LBWdRevisionsView.wdRevisionsViewFinal;
|
||||
fileName = CreatePDF(fileName, openPdf);
|
||||
MyApp.ActiveDocument.Close(false);
|
||||
if (CloseWordWhenDone)
|
||||
|
Loading…
x
Reference in New Issue
Block a user