개정판 b7b123ba
dev issue #507 : set border file
Change-Id: I36050512de1968cc8867593e25aa97c0b9d7e113
DTI_PID/SPPIDConverter/AutoModeling.cs | ||
---|---|---|
1044 | 1044 |
Log.Write("Fail Create Drawing"); |
1045 | 1045 |
|
1046 | 1046 |
if (newDrawing != null) |
1047 |
{ |
|
1048 |
SetBorderFile(); |
|
1047 | 1049 |
return true; |
1050 |
} |
|
1048 | 1051 |
else |
1049 | 1052 |
return false; |
1050 | 1053 |
} |
1051 | 1054 |
|
1055 |
private void SetBorderFile() |
|
1056 |
{ |
|
1057 |
ETCSetting setting = ETCSetting.GetInstance(); |
|
1058 |
|
|
1059 |
if (!string.IsNullOrEmpty(setting.BorderFilePath) && System.IO.File.Exists(setting.BorderFilePath)) |
|
1060 |
{ |
|
1061 |
foreach (Ingr.RAD2D.SmartFrame2d smartFrame in radApp.ActiveDocument.ActiveSheet.SmartFrames2d) |
|
1062 |
{ |
|
1063 |
if (!string.IsNullOrEmpty(smartFrame.LinkMoniker) && smartFrame.LinkMoniker != setting.BorderFilePath) |
|
1064 |
{ |
|
1065 |
smartFrame.ChangeSource(Ingr.RAD2D.OLEInsertionTypeConstant.igOLELinked, setting.BorderFilePath, true); |
|
1066 |
smartFrame.Update(); |
|
1067 |
} |
|
1068 |
|
|
1069 |
} |
|
1070 |
} |
|
1071 |
} |
|
1072 |
|
|
1052 | 1073 |
/// <summary> |
1053 | 1074 |
/// DrawingName, DrawingNumber를 확인하여 중복이 있으면 _1을 붙이고 +1씩 한다. |
1054 | 1075 |
/// </summary> |
내보내기 Unified diff