B2017-138 Add error handling for setting Bottom Margin
Removed debug output
This commit is contained in:
parent
fa68b282b8
commit
537ab3c21c
@ -1057,7 +1057,7 @@ namespace VEPROMS
|
|||||||
if (dti.MyDSOTabPanel != null)
|
if (dti.MyDSOTabPanel != null)
|
||||||
dti.MyDSOTabPanel.CloseDSO();
|
dti.MyDSOTabPanel.CloseDSO();
|
||||||
}
|
}
|
||||||
_MyLog.WarnFormat("frmVEPROMS_FormClosing");
|
//_MyLog.WarnFormat("frmVEPROMS_FormClosing");
|
||||||
if (MyParent == null)
|
if (MyParent == null)
|
||||||
{
|
{
|
||||||
if (MyActivityTimer != null) MyActivityTimer.Dispose();
|
if (MyActivityTimer != null) MyActivityTimer.Dispose();
|
||||||
|
@ -1240,10 +1240,23 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
myDoc.PageSetup.RightMargin = newRight;
|
myDoc.PageSetup.RightMargin = newRight;
|
||||||
|
try // B2017-138 Add error handling for setting Bottom Margin
|
||||||
|
{
|
||||||
myDoc.PageSetup.BottomMargin = newBottom;
|
myDoc.PageSetup.BottomMargin = newBottom;
|
||||||
myDoc.PageSetup.LeftMargin = newLeft;
|
myDoc.PageSetup.LeftMargin = newLeft;
|
||||||
myDoc.PageSetup.TopMargin = newTop;
|
myDoc.PageSetup.TopMargin = newTop;
|
||||||
}
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
if (_MySection != null)
|
||||||
|
{
|
||||||
|
_MyLog.ErrorFormat("<<< ERROR >>> MSWord could not set margins\r\n==>'MSWord could not set margins',{0},'{1}','{2}'"
|
||||||
|
, _MySection.ItemID, _MySection.MyDocVersion.MyFolder.Name, _MySection.ShortPath);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
_MyLog.ErrorFormat("Could not set margins {0}", myDoc.FullName);
|
||||||
|
}
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
|
Loading…
x
Reference in New Issue
Block a user