Z*HWh46Cx-+U;YELwC-$2cl`0
z@s^}wzbYjnT1Pff*o%xVJ<&VRQ{go}8a+I`{A}}Icu8{Nteq#VA!BQXhSjmiWm6LC
zoJ-F&92MSN9W9~=YhIoqvEJ7z^$(6!%&Ezg@AXs1T?@2&wp!BLH?;=GtxqU}HuS!%
z;cp#}#F4i=@hGShYHD_c=|8y7lH5uPNM7U?&~^T(W;~z4x9#@Yh@86962_!bDGHmn
z6|y{hj7^o%z5|y=D#9mJy9lKTucuzehB4B+`wufVxj9LwB2ww5kGZcGm8iEQUo=bV
zKnOp+xq_-03_&0O00`?RB$_d_T!1)W6|fR;z{(0(hw1ge3e1^deqLDsbby9+R$x1V
zQAe-{*eE92*D%qOc_T{&>9{jD^!3LoPTF
zz&6L99q^a9!t-&hs-)LNwWZq3$2Aefsi(y)+gBzrL{*J989>tV-4;}i@9x>QYMsi$*8r=j3ibbb(wU}_Rf6m6inWD
z9p7`KV@9ffJQqzi>S`|$GaHNJbWiRo*LZc6Vpkj!pA(>H_r)~-zLsfKQ?o43M}&jkE;xLhiot=##6^f@QOpU$dgdM`nH@?&RdXKx7q5r>Gn
zA4?ieXYp$NE|_>}xdA2Fv1mtpTl!cP{oo5w3_EJ(MuR-LlCy3$>Y;D-9QQyaHj5j0
zIyGD8qQAOmu6nm$k?>|JhHw5MNO1iqukVOP_)Uj$M{V@g;nlO@q=y6HlP{EnYZ-|~
zg5V3_BFhS5-qoy@bAQZQaZswrxazh$FAErGbIBRuZo7@3+G*zeZFV|}<^50aOp(v8>
zZ!v6ph1jI@$U5BSC7OS|krRG8`(Cc6kHAMkq;W#j>G$j!A6bKFBXY2;v5E|C
zF+{Xox`3+9as_9$>9mnI7ku^DqUH<{bzPOe<=2@81{oLd8G_QN4cxZ6`H%H4EP=H6
literal 0
HcmV?d00001
diff --git a/SRC/MESAgent/MESIEW/IEWService/IEWService_TemporaryKey.pfx b/SRC/MESAgent/MESIEW/IEWService/IEWService_TemporaryKey.pfx
new file mode 100644
index 0000000000000000000000000000000000000000..eeffda65b25e3ac6c27d1d15f0d84f4688db89ea
GIT binary patch
literal 1613
zcma)6dow>-gCbfV-Rgn1cxz*1fsz1
zSnJqj62gbD7=%CY48lCdAbi9axVnE$;cns?xDrSgLeC{`{wqsx6N0iBXdT8t?_n~;
zO@GsHaUnea)47)Fxlx}y6y@v2Gtd-`lf+oZG{4C3vO-2gJHx@|%*)D-*2*60yXK|U
z9M5`cU`b1~)~jEe8`s7L_HPA4CS0TUz~oNsJ2=J9$JV5s&F!$;uRAUY6kwh2-@Ib_9p?d^tDGHZ@tw
zu3MdDUQDFaNJZEV2k1EQNZRTSi~Rc%C#MvJ%iE|(UsLGL8Y+RqlX>8#;PAYN@5fEs
zE~u_z$gG}jCD%4KndNqat2V4T@#Wskfq|!WMv~_r&W*{NwwI9J*1Ff;X_uc>YNh*6
zUh)bzn~+bf%t?!1PErXz;aK{E+;WylY_F(nTLz8T&p%+ic(s?C_F(FPOk$Wh%~-mK
zobZ184lr1|r}}{=tZaCTLrW=BY+LK$M)z*!C<(J|nio@4<&EBzBVygL;
zyyAmC*HBctc0gI9a9C#9n*T`oM7L|~405GhAYZwi*%*?}?;TlI-liV2@#1}0049UhZLvSlMjMOU;uQ11)ubbuv{
zwBf8KG&RWUK#e(!_QBBtYW1Mb0Gb(8nnPt2cAO}nN<{DoLr(;u93tBTI}iYT01X6z
zQ0OPYIj{r#1jlveEbxcO9L5nK7;-@n(||XOPkqbU0SdQ1qw#Nam_iV
z?YIXH*tItvJE5jwyIsMa&1^_{XmiU@Aqzm$zgm%
zf~pV>-GBNU2UG*9vynNQYUK@
// 這段程式碼是由工具產生的。
-// 執行階段版本:4.0.30319.42000
+// 執行階段版本:4.0.30319.18051
//
// 對這個檔案所做的變更可能會造成錯誤的行為,而且如果重新產生程式碼,
// 變更將會遺失。
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/Application.myapp b/SRC/MESAgent/MESIEW/IEWService/My Project/Application.myapp
similarity index 91%
rename from SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/Application.myapp
rename to SRC/MESAgent/MESIEW/IEWService/My Project/Application.myapp
index 758895d..602de37 100644
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/Application.myapp
+++ b/SRC/MESAgent/MESIEW/IEWService/My Project/Application.myapp
@@ -5,6 +5,6 @@
0
true
0
- 1
+ 3
true
diff --git a/SRC/MESPlugin/MESPI_BusinessRule/My Project/Resources.resx b/SRC/MESAgent/MESIEW/IEWService/My Project/Resources.resx
similarity index 100%
rename from SRC/MESPlugin/MESPI_BusinessRule/My Project/Resources.resx
rename to SRC/MESAgent/MESIEW/IEWService/My Project/Resources.resx
diff --git a/SRC/MESAgent/MESIEW/IEWService/My Project/Settings.Designer.cs b/SRC/MESAgent/MESIEW/IEWService/My Project/Settings.Designer.cs
new file mode 100644
index 0000000..d25c07a
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/My Project/Settings.Designer.cs
@@ -0,0 +1,101 @@
+// ------------------------------------------------------------------------------
+//
+// 這段程式碼是由工具產生的。
+// 執行階段版本:4.0.30319.42000
+//
+// 對這個檔案所做的變更可能會造成錯誤的行為,而且如果重新產生程式碼,
+// 變更將會遺失。
+//
+// ------------------------------------------------------------------------------
+
+using System.Diagnostics;
+using Microsoft.VisualBasic;
+using Microsoft.VisualBasic.CompilerServices;
+
+
+namespace IEWService.My
+{
+
+ [System.Runtime.CompilerServices.CompilerGenerated()]
+ [System.CodeDom.Compiler.GeneratedCode("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "10.0.0.0")]
+ [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Advanced)]
+ internal sealed partial class MySettings : System.Configuration.ApplicationSettingsBase
+ {
+
+ private static MySettings defaultInstance = (MySettings)Synchronized(new MySettings());
+
+ #region My.Settings 自動儲存功能
+ /* TODO ERROR: Skipped IfDirectiveTrivia
+ #If _MyType = "WindowsForms" Then
+ *//* TODO ERROR: Skipped DisabledTextTrivia
+ Private Shared addedHandler As Boolean
+
+ Private Shared addedHandlerLockObject As New Object
+
+ _
+ Private Shared Sub AutoSaveSettings(ByVal sender As Global.System.Object, ByVal e As Global.System.EventArgs)
+ If My.Application.SaveMySettingsOnExit Then
+ My.Settings.Save()
+ End If
+ End Sub
+ *//* TODO ERROR: Skipped EndIfDirectiveTrivia
+ #End If
+ */
+ #endregion
+
+ public static MySettings Default
+ {
+ get
+ {
+
+ /* TODO ERROR: Skipped IfDirectiveTrivia
+ #If _MyType = "WindowsForms" Then
+ *//* TODO ERROR: Skipped DisabledTextTrivia
+ If Not addedHandler Then
+ SyncLock addedHandlerLockObject
+ If Not addedHandler Then
+ AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings
+ addedHandler = True
+ End If
+ End SyncLock
+ End If
+ *//* TODO ERROR: Skipped EndIfDirectiveTrivia
+ #End If
+ */
+ return defaultInstance;
+ }
+ }
+
+ [System.Configuration.ApplicationScopedSetting()]
+ [DebuggerNonUserCode()]
+ [System.Configuration.SpecialSetting(System.Configuration.SpecialSetting.WebServiceUrl)]
+ [System.Configuration.DefaultSettingValue("http://10.20.88.57/MSFT2/PushService.asmx")]
+ public string MESIEW_wsMCloud_PushService
+ {
+ get
+ {
+ return Conversions.ToString(this["MESIEW_wsMCloud_PushService"]);
+ }
+ }
+ }
+}
+
+namespace IEWService.My
+{
+
+ [HideModuleName()]
+ [DebuggerNonUserCode()]
+ [System.Runtime.CompilerServices.CompilerGenerated()]
+ internal static class MySettingsProperty
+ {
+
+ [System.ComponentModel.Design.HelpKeyword("My.Settings")]
+ internal static MySettings Settings
+ {
+ get
+ {
+ return MySettings.Default;
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/SRC/MESAgent/MESIEW/IEWService/My Project/Settings.settings b/SRC/MESAgent/MESIEW/IEWService/My Project/Settings.settings
new file mode 100644
index 0000000..58e69a1
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/My Project/Settings.settings
@@ -0,0 +1,9 @@
+
+
+
+
+
+ http://10.20.88.57/MSFT2/PushService.asmx
+
+
+
\ No newline at end of file
diff --git a/SRC/MESAgent/MESIEW/IEWService/NLog.config b/SRC/MESAgent/MESIEW/IEWService/NLog.config
new file mode 100644
index 0000000..2b3eadc
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/NLog.config
@@ -0,0 +1,72 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/SRC/MESAgent/MESIEW/IEWService/ProjectInstaller.Designer.cs b/SRC/MESAgent/MESIEW/IEWService/ProjectInstaller.Designer.cs
new file mode 100644
index 0000000..a60cf0a
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/ProjectInstaller.Designer.cs
@@ -0,0 +1,90 @@
+using System.Diagnostics;
+using System.Runtime.CompilerServices;
+
+namespace IEWService
+{
+ [System.ComponentModel.RunInstaller(true)]
+ public partial class ProjectInstaller : System.Configuration.Install.Installer
+ {
+
+ // Installer 覆寫 Dispose 以清除元件清單。
+ [DebuggerNonUserCode()]
+ protected override void Dispose(bool disposing)
+ {
+ try
+ {
+ if (disposing && components != null)
+ {
+ components.Dispose();
+ }
+ }
+ finally
+ {
+ base.Dispose(disposing);
+ }
+ }
+
+ // 為元件設計工具的必要項
+ private System.ComponentModel.IContainer components;
+
+ // 注意: 以下為元件設計工具所需的程序
+ // 您可以使用元件設計工具進行修改。
+ // 請不要使用程式碼編輯器進行修改。
+ [DebuggerStepThrough()]
+ private void InitializeComponent()
+ {
+ _ServiceProcessInstaller1 = new System.ServiceProcess.ServiceProcessInstaller();
+ _ServiceInstaller1 = new System.ServiceProcess.ServiceInstaller();
+ //
+ // ServiceProcessInstaller1
+ //
+ _ServiceProcessInstaller1.Account = System.ServiceProcess.ServiceAccount.LocalSystem;
+ _ServiceProcessInstaller1.Password = null;
+ _ServiceProcessInstaller1.Username = null;
+ //
+ // ServiceInstaller1
+ //
+ _ServiceInstaller1.Description = "MESSeries 智慧預警 Service";
+ _ServiceInstaller1.DisplayName = "MES IEW Service";
+ _ServiceInstaller1.ServiceName = "MES IEW Service";
+ //
+ // ProjectInstaller
+ //
+ Installers.AddRange(new System.Configuration.Install.Installer[] { _ServiceProcessInstaller1, _ServiceInstaller1 });
+
+ }
+ private System.ServiceProcess.ServiceProcessInstaller _ServiceProcessInstaller1;
+
+ internal virtual System.ServiceProcess.ServiceProcessInstaller ServiceProcessInstaller1
+ {
+ [MethodImpl(MethodImplOptions.Synchronized)]
+ get
+ {
+ return _ServiceProcessInstaller1;
+ }
+
+ [MethodImpl(MethodImplOptions.Synchronized)]
+ set
+ {
+ _ServiceProcessInstaller1 = value;
+ }
+ }
+ private System.ServiceProcess.ServiceInstaller _ServiceInstaller1;
+
+ internal virtual System.ServiceProcess.ServiceInstaller ServiceInstaller1
+ {
+ [MethodImpl(MethodImplOptions.Synchronized)]
+ get
+ {
+ return _ServiceInstaller1;
+ }
+
+ [MethodImpl(MethodImplOptions.Synchronized)]
+ set
+ {
+ _ServiceInstaller1 = value;
+ }
+ }
+
+ }
+}
\ No newline at end of file
diff --git a/SRC/MESAgent/MESIEW/IEWService/ProjectInstaller.cs b/SRC/MESAgent/MESIEW/IEWService/ProjectInstaller.cs
new file mode 100644
index 0000000..6927ae8
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/ProjectInstaller.cs
@@ -0,0 +1,19 @@
+
+namespace IEWService
+{
+
+ public partial class ProjectInstaller
+ {
+
+ public ProjectInstaller() : base()
+ {
+
+ // 此為元件設計工具所需的呼叫。
+ InitializeComponent();
+
+ // 在呼叫 InitializeComponent 之後加入初始化程式碼
+
+ }
+
+ }
+}
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/Test/MDI_Panel.resx b/SRC/MESAgent/MESIEW/IEWService/ProjectInstaller.resx
similarity index 92%
rename from SRC/MESWin/SYS4/21670ll/MESWin/Test/MDI_Panel.resx
rename to SRC/MESAgent/MESIEW/IEWService/ProjectInstaller.resx
index 2d7050a..ccc2ebf 100644
--- a/SRC/MESWin/SYS4/21670ll/MESWin/Test/MDI_Panel.resx
+++ b/SRC/MESAgent/MESIEW/IEWService/ProjectInstaller.resx
@@ -117,10 +117,13 @@
System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
- 17, 17
+
+ 17, 60
-
- 254, 17
+
+ 243, 17
+
+
+ False
\ No newline at end of file
diff --git a/SRC/MEStc_SXS/Properties/AssemblyInfo.cs b/SRC/MESAgent/MESIEW/IEWService/Properties/AssemblyInfo.cs
similarity index 86%
rename from SRC/MEStc_SXS/Properties/AssemblyInfo.cs
rename to SRC/MESAgent/MESIEW/IEWService/Properties/AssemblyInfo.cs
index e2bf75b..161f244 100644
--- a/SRC/MEStc_SXS/Properties/AssemblyInfo.cs
+++ b/SRC/MESAgent/MESIEW/IEWService/Properties/AssemblyInfo.cs
@@ -5,8 +5,8 @@ using System.Runtime.InteropServices;
// 組件的一般資訊是由下列的屬性集控制。
// 變更這些屬性的值即可修改組件的相關
// 資訊。
-[assembly: AssemblyTitle("MEStc_ABC.Properties")]
-[assembly: AssemblyDescription("")]
+[assembly: AssemblyTitle("IEWService")]
+[assembly: AssemblyDescription("IEWService for MESSeries")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("iMES Technology Inc.")]
[assembly: AssemblyProduct("MESSeries 6")]
@@ -20,7 +20,7 @@ using System.Runtime.InteropServices;
[assembly: ComVisible(false)]
// 下列 GUID 為專案公開 (Expose) 至 COM 時所要使用的 typelib ID
-[assembly: Guid("00eb00ee-1246-48cf-a0bf-f5203de255f1")]
+[assembly: Guid("7c830bc6-e2bd-4b82-9ff3-ad61fd9004c5")]
// 組件的版本資訊由下列四個值所組成:
//
diff --git a/SRC/MESAgent/MESIEW/IEWService/Uninstall_x64.bat b/SRC/MESAgent/MESIEW/IEWService/Uninstall_x64.bat
new file mode 100644
index 0000000..a4c2932
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/Uninstall_x64.bat
@@ -0,0 +1,4 @@
+%SystemRoot%\Microsoft.NET\Framework64\v4.0.30319\InstallUtil.exe "%~dp0MESIEW.exe" -u
+
+
+Pause
\ No newline at end of file
diff --git a/SRC/MESAgent/MESIEW/IEWService/Uninstall_x86.bat b/SRC/MESAgent/MESIEW/IEWService/Uninstall_x86.bat
new file mode 100644
index 0000000..80e771c
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/Uninstall_x86.bat
@@ -0,0 +1,3 @@
+%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\InstallUtil.exe "%~dp0MESIEW.exe" -u
+
+Pause
\ No newline at end of file
diff --git a/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/PushService.disco b/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/PushService.disco
new file mode 100644
index 0000000..75e2d3f
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/PushService.disco
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/PushService.wsdl b/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/PushService.wsdl
new file mode 100644
index 0000000..34f0745
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/PushService.wsdl
@@ -0,0 +1,345 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/Reference.cs b/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/Reference.cs
new file mode 100644
index 0000000..de5ab92
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/Reference.cs
@@ -0,0 +1,435 @@
+// ------------------------------------------------------------------------------
+//
+// 這段程式碼是由工具產生的。
+// 執行階段版本:4.0.30319.42000
+//
+// 對這個檔案所做的變更可能會造成錯誤的行為,而且如果重新產生程式碼,
+// 變更將會遺失。
+//
+// ------------------------------------------------------------------------------
+
+
+using System;
+using System.ComponentModel;
+using System.Diagnostics;
+using System.Web.Services;
+using System.Web.Services.Protocols;
+using Microsoft.VisualBasic.CompilerServices;
+
+//
+// 原始程式碼已由 Microsoft.VSDesigner 自動產生,版本 4.0.30319.42000。
+//
+namespace IEWService.wsMCloud
+{
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCode("System.Web.Services", "4.6.1055.0")]
+ [DebuggerStepThrough()]
+ [DesignerCategory("code")]
+ [WebServiceBinding(Name = "PushServiceSoap", Namespace = "http://tempuri.org/")]
+ public partial class PushService : SoapHttpClientProtocol
+ {
+
+ private System.Threading.SendOrPostCallback RegistGuestTokenOperationCompleted;
+
+ private System.Threading.SendOrPostCallback RegistPNDeviceOperationCompleted;
+
+ private System.Threading.SendOrPostCallback PushDevicePMGOperationCompleted;
+
+ private System.Threading.SendOrPostCallback UpdateGProgramBgNumberOperationCompleted;
+
+ private System.Threading.SendOrPostCallback PushMessageByTokenOperationCompleted;
+
+ private bool useDefaultCredentialsSetExplicitly;
+
+ ///
+ public PushService() : base()
+ {
+ Url = My.MySettings.Default.MESIEW_wsMCloud_PushService;
+ if (IsLocalFileSystemWebService(Url) == true)
+ {
+ UseDefaultCredentials = true;
+ useDefaultCredentialsSetExplicitly = false;
+ }
+ else
+ {
+ useDefaultCredentialsSetExplicitly = true;
+ }
+ }
+
+ public new string Url
+ {
+ get
+ {
+ return base.Url;
+ }
+ set
+ {
+ if (IsLocalFileSystemWebService(base.Url) == true && useDefaultCredentialsSetExplicitly == false && IsLocalFileSystemWebService(value) == false)
+
+ {
+ base.UseDefaultCredentials = false;
+ }
+ base.Url = value;
+ }
+ }
+
+ public new bool UseDefaultCredentials
+ {
+ get
+ {
+ return base.UseDefaultCredentials;
+ }
+ set
+ {
+ base.UseDefaultCredentials = value;
+ useDefaultCredentialsSetExplicitly = true;
+ }
+ }
+
+ ///
+ public event RegistGuestTokenCompletedEventHandler RegistGuestTokenCompleted;
+
+ ///
+ public event RegistPNDeviceCompletedEventHandler RegistPNDeviceCompleted;
+
+ ///
+ public event PushDevicePMGCompletedEventHandler PushDevicePMGCompleted;
+
+ ///
+ public event UpdateGProgramBgNumberCompletedEventHandler UpdateGProgramBgNumberCompleted;
+
+ ///
+ public event PushMessageByTokenCompletedEventHandler PushMessageByTokenCompleted;
+
+ ///
+ [SoapDocumentMethod("http://tempuri.org/RegistGuestToken", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
+ public string RegistGuestToken(string pKey, string pTransData)
+ {
+ object[] results = Invoke("RegistGuestToken", new object[] { pKey, pTransData });
+ return Conversions.ToString(results[0]);
+ }
+
+ ///
+ public void RegistGuestTokenAsync(string pKey, string pTransData)
+ {
+ RegistGuestTokenAsync(pKey, pTransData, null);
+ }
+
+ ///
+ public void RegistGuestTokenAsync(string pKey, string pTransData, object userState)
+ {
+ if (RegistGuestTokenOperationCompleted == null)
+ {
+ RegistGuestTokenOperationCompleted = OnRegistGuestTokenOperationCompleted;
+ }
+ InvokeAsync("RegistGuestToken", new object[] { pKey, pTransData }, RegistGuestTokenOperationCompleted, userState);
+ }
+
+ private void OnRegistGuestTokenOperationCompleted(object arg)
+ {
+ if (RegistGuestTokenCompleted != null)
+ {
+ InvokeCompletedEventArgs invokeArgs = (InvokeCompletedEventArgs)arg;
+ RegistGuestTokenCompleted?.Invoke(this, new RegistGuestTokenCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [SoapDocumentMethod("http://tempuri.org/RegistPNDevice", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
+ public string RegistPNDevice(string pKey, string pTransData)
+ {
+ object[] results = Invoke("RegistPNDevice", new object[] { pKey, pTransData });
+ return Conversions.ToString(results[0]);
+ }
+
+ ///
+ public void RegistPNDeviceAsync(string pKey, string pTransData)
+ {
+ RegistPNDeviceAsync(pKey, pTransData, null);
+ }
+
+ ///
+ public void RegistPNDeviceAsync(string pKey, string pTransData, object userState)
+ {
+ if (RegistPNDeviceOperationCompleted == null)
+ {
+ RegistPNDeviceOperationCompleted = OnRegistPNDeviceOperationCompleted;
+ }
+ InvokeAsync("RegistPNDevice", new object[] { pKey, pTransData }, RegistPNDeviceOperationCompleted, userState);
+ }
+
+ private void OnRegistPNDeviceOperationCompleted(object arg)
+ {
+ if (RegistPNDeviceCompleted != null)
+ {
+ InvokeCompletedEventArgs invokeArgs = (InvokeCompletedEventArgs)arg;
+ RegistPNDeviceCompleted?.Invoke(this, new RegistPNDeviceCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [SoapDocumentMethod("http://tempuri.org/PushDevicePMG", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
+ public string PushDevicePMG(string pKey, string pPushMsg)
+ {
+ object[] results = Invoke("PushDevicePMG", new object[] { pKey, pPushMsg });
+ return Conversions.ToString(results[0]);
+ }
+
+ ///
+ public void PushDevicePMGAsync(string pKey, string pPushMsg)
+ {
+ PushDevicePMGAsync(pKey, pPushMsg, null);
+ }
+
+ ///
+ public void PushDevicePMGAsync(string pKey, string pPushMsg, object userState)
+ {
+ if (PushDevicePMGOperationCompleted == null)
+ {
+ PushDevicePMGOperationCompleted = OnPushDevicePMGOperationCompleted;
+ }
+ InvokeAsync("PushDevicePMG", new object[] { pKey, pPushMsg }, PushDevicePMGOperationCompleted, userState);
+ }
+
+ private void OnPushDevicePMGOperationCompleted(object arg)
+ {
+ if (PushDevicePMGCompleted != null)
+ {
+ InvokeCompletedEventArgs invokeArgs = (InvokeCompletedEventArgs)arg;
+ PushDevicePMGCompleted?.Invoke(this, new PushDevicePMGCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [SoapDocumentMethod("http://tempuri.org/UpdateGProgramBgNumber", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
+ public string UpdateGProgramBgNumber(string pBgP2M)
+ {
+ object[] results = Invoke("UpdateGProgramBgNumber", new object[] { pBgP2M });
+ return Conversions.ToString(results[0]);
+ }
+
+ ///
+ public void UpdateGProgramBgNumberAsync(string pBgP2M)
+ {
+ UpdateGProgramBgNumberAsync(pBgP2M, null);
+ }
+
+ ///
+ public void UpdateGProgramBgNumberAsync(string pBgP2M, object userState)
+ {
+ if (UpdateGProgramBgNumberOperationCompleted == null)
+ {
+ UpdateGProgramBgNumberOperationCompleted = OnUpdateGProgramBgNumberOperationCompleted;
+ }
+ InvokeAsync("UpdateGProgramBgNumber", new object[] { pBgP2M }, UpdateGProgramBgNumberOperationCompleted, userState);
+ }
+
+ private void OnUpdateGProgramBgNumberOperationCompleted(object arg)
+ {
+ if (UpdateGProgramBgNumberCompleted != null)
+ {
+ InvokeCompletedEventArgs invokeArgs = (InvokeCompletedEventArgs)arg;
+ UpdateGProgramBgNumberCompleted?.Invoke(this, new UpdateGProgramBgNumberCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [SoapDocumentMethod("http://tempuri.org/PushMessageByToken", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
+ public string PushMessageByToken(string pKey, string pPushMsg)
+ {
+ object[] results = Invoke("PushMessageByToken", new object[] { pKey, pPushMsg });
+ return Conversions.ToString(results[0]);
+ }
+
+ ///
+ public void PushMessageByTokenAsync(string pKey, string pPushMsg)
+ {
+ PushMessageByTokenAsync(pKey, pPushMsg, null);
+ }
+
+ ///
+ public void PushMessageByTokenAsync(string pKey, string pPushMsg, object userState)
+ {
+ if (PushMessageByTokenOperationCompleted == null)
+ {
+ PushMessageByTokenOperationCompleted = OnPushMessageByTokenOperationCompleted;
+ }
+ InvokeAsync("PushMessageByToken", new object[] { pKey, pPushMsg }, PushMessageByTokenOperationCompleted, userState);
+ }
+
+ private void OnPushMessageByTokenOperationCompleted(object arg)
+ {
+ if (PushMessageByTokenCompleted != null)
+ {
+ InvokeCompletedEventArgs invokeArgs = (InvokeCompletedEventArgs)arg;
+ PushMessageByTokenCompleted?.Invoke(this, new PushMessageByTokenCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ public new void CancelAsync(object userState)
+ {
+ base.CancelAsync(userState);
+ }
+
+ private bool IsLocalFileSystemWebService(string url)
+ {
+ if (url == null || ReferenceEquals(url, string.Empty))
+ {
+ return false;
+ }
+ var wsUri = new Uri(url);
+ if (wsUri.Port >= 1024 && string.Compare(wsUri.Host, "localHost", StringComparison.OrdinalIgnoreCase) == 0)
+ {
+ return true;
+ }
+ return false;
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCode("System.Web.Services", "4.6.1055.0")]
+ public delegate void RegistGuestTokenCompletedEventHandler(object sender, RegistGuestTokenCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCode("System.Web.Services", "4.6.1055.0")]
+ [DebuggerStepThrough()]
+ [DesignerCategory("code")]
+ public partial class RegistGuestTokenCompletedEventArgs : AsyncCompletedEventArgs
+ {
+
+ private object[] results;
+
+ internal RegistGuestTokenCompletedEventArgs(object[] results, Exception exception, bool cancelled, object userState) : base(exception, cancelled, userState)
+ {
+ this.results = results;
+ }
+
+ ///
+ public string Result
+ {
+ get
+ {
+ RaiseExceptionIfNecessary();
+ return Conversions.ToString(results[0]);
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCode("System.Web.Services", "4.6.1055.0")]
+ public delegate void RegistPNDeviceCompletedEventHandler(object sender, RegistPNDeviceCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCode("System.Web.Services", "4.6.1055.0")]
+ [DebuggerStepThrough()]
+ [DesignerCategory("code")]
+ public partial class RegistPNDeviceCompletedEventArgs : AsyncCompletedEventArgs
+ {
+
+ private object[] results;
+
+ internal RegistPNDeviceCompletedEventArgs(object[] results, Exception exception, bool cancelled, object userState) : base(exception, cancelled, userState)
+ {
+ this.results = results;
+ }
+
+ ///
+ public string Result
+ {
+ get
+ {
+ RaiseExceptionIfNecessary();
+ return Conversions.ToString(results[0]);
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCode("System.Web.Services", "4.6.1055.0")]
+ public delegate void PushDevicePMGCompletedEventHandler(object sender, PushDevicePMGCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCode("System.Web.Services", "4.6.1055.0")]
+ [DebuggerStepThrough()]
+ [DesignerCategory("code")]
+ public partial class PushDevicePMGCompletedEventArgs : AsyncCompletedEventArgs
+ {
+
+ private object[] results;
+
+ internal PushDevicePMGCompletedEventArgs(object[] results, Exception exception, bool cancelled, object userState) : base(exception, cancelled, userState)
+ {
+ this.results = results;
+ }
+
+ ///
+ public string Result
+ {
+ get
+ {
+ RaiseExceptionIfNecessary();
+ return Conversions.ToString(results[0]);
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCode("System.Web.Services", "4.6.1055.0")]
+ public delegate void UpdateGProgramBgNumberCompletedEventHandler(object sender, UpdateGProgramBgNumberCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCode("System.Web.Services", "4.6.1055.0")]
+ [DebuggerStepThrough()]
+ [DesignerCategory("code")]
+ public partial class UpdateGProgramBgNumberCompletedEventArgs : AsyncCompletedEventArgs
+ {
+
+ private object[] results;
+
+ internal UpdateGProgramBgNumberCompletedEventArgs(object[] results, Exception exception, bool cancelled, object userState) : base(exception, cancelled, userState)
+ {
+ this.results = results;
+ }
+
+ ///
+ public string Result
+ {
+ get
+ {
+ RaiseExceptionIfNecessary();
+ return Conversions.ToString(results[0]);
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCode("System.Web.Services", "4.6.1055.0")]
+ public delegate void PushMessageByTokenCompletedEventHandler(object sender, PushMessageByTokenCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCode("System.Web.Services", "4.6.1055.0")]
+ [DebuggerStepThrough()]
+ [DesignerCategory("code")]
+ public partial class PushMessageByTokenCompletedEventArgs : AsyncCompletedEventArgs
+ {
+
+ private object[] results;
+
+ internal PushMessageByTokenCompletedEventArgs(object[] results, Exception exception, bool cancelled, object userState) : base(exception, cancelled, userState)
+ {
+ this.results = results;
+ }
+
+ ///
+ public string Result
+ {
+ get
+ {
+ RaiseExceptionIfNecessary();
+ return Conversions.ToString(results[0]);
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/Reference.map b/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/Reference.map
new file mode 100644
index 0000000..30ac9a5
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/Web References/wsMCloud/Reference.map
@@ -0,0 +1,7 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/SRC/MESAgent/MESIEW/IEWService/app.config b/SRC/MESAgent/MESIEW/IEWService/app.config
new file mode 100644
index 0000000..ca29c91
--- /dev/null
+++ b/SRC/MESAgent/MESIEW/IEWService/app.config
@@ -0,0 +1,50 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ http://10.20.88.57/MSFT2/PushService.asmx
+
+
+
+
diff --git a/SRC/MESPlugin/MESPI_WIP/MESPI_WIP.sln b/SRC/MESAgent/MESIEW/MESIEW.sln
similarity index 55%
rename from SRC/MESPlugin/MESPI_WIP/MESPI_WIP.sln
rename to SRC/MESAgent/MESIEW/MESIEW.sln
index 29ee868..d22e41c 100644
--- a/SRC/MESPlugin/MESPI_WIP/MESPI_WIP.sln
+++ b/SRC/MESAgent/MESIEW/MESIEW.sln
@@ -1,9 +1,9 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14
-VisualStudioVersion = 14.0.25420.1
+VisualStudioVersion = 14.0.25123.0
MinimumVisualStudioVersion = 10.0.40219.1
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MESPI_WIP", "MESPI_WIP.csproj", "{F9051601-B027-0745-17C2-D36A87ABB6A1}"
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "IEWService", "IEWService\IEWService.csproj", "{7538DCCA-4FA2-0BF3-1C07-913D4AE96E95}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -11,22 +11,21 @@ Global
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {F9051601-B027-0745-17C2-D36A87ABB6A1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {F9051601-B027-0745-17C2-D36A87ABB6A1}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {F9051601-B027-0745-17C2-D36A87ABB6A1}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {F9051601-B027-0745-17C2-D36A87ABB6A1}.Release|Any CPU.Build.0 = Release|Any CPU
+ {7538DCCA-4FA2-0BF3-1C07-913D4AE96E95}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {7538DCCA-4FA2-0BF3-1C07-913D4AE96E95}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {7538DCCA-4FA2-0BF3-1C07-913D4AE96E95}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {7538DCCA-4FA2-0BF3-1C07-913D4AE96E95}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(TeamFoundationVersionControl) = preSolution
- SccNumberOfProjects = 1
+ SccNumberOfProjects = 2
SccEnterpriseProvider = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C}
SccTeamFoundationServer = http://tfs.imestech.com:8080/tfs/messeries6
- SccProjectUniqueName0 = MESPI_WIP.csproj
- SccProjectName0 = .
- SccAuxPath0 = http://tfs.imestech.com:8080/tfs/messeries6
SccLocalPath0 = .
- SccProvider0 = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C}
+ SccProjectUniqueName1 = IEWService\\IEWService.vbproj
+ SccProjectName1 = IEWService
+ SccLocalPath1 = IEWService
EndGlobalSection
EndGlobal
diff --git a/SRC/MESPlugin/MESPI_BusinessRule/MESPI_BusinessRule.csproj b/SRC/MESPlugin/MESPI_BusinessRule/MESPI_BusinessRule.csproj
deleted file mode 100644
index ea44882..0000000
--- a/SRC/MESPlugin/MESPI_BusinessRule/MESPI_BusinessRule.csproj
+++ /dev/null
@@ -1,119 +0,0 @@
-
-
-
-
- Debug
- AnyCPU
- {6CD932DD-93B6-0C5E-06F9-47F39C95CB5A}
- Library
- MESPI_BusinessRule
- MESPI_BusinessRule
- 512
- Windows
- v4.6.2
-
- SAK
- SAK
- SAK
- SAK
- $(DefaultItemExcludes);$(ProjectDir)**\*.vb
-
-
- true
- full
- true
- true
- ..\..\MES_S_DLL\plugin\
- ..\..\MES_S_DLL\plugin\MESPI_BusinessRule.xml
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- false
-
-
- pdbonly
- false
- true
- true
- bin\Release\
- bin\Release\
-
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- false
-
-
- On
-
-
- Binary
-
-
- Off
-
-
- On
-
-
- true
-
-
- iMES.snk
-
-
-
-
- False
- ..\..\MES_S_DLL\iMESCIO.dll
- False
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- True
- Application.myapp
-
-
- True
- Settings.settings
- True
-
-
-
-
-
- MyApplicationCodeGenerator
- Application.Designer.cs
-
-
- SettingsSingleFileGenerator
- MESPI_BusinessRule.My
- Settings.Designer.cs
-
-
-
-
-
\ No newline at end of file
diff --git a/SRC/MESPlugin/MESPI_BusinessRule/MESPI_BusinessRule.vssscc b/SRC/MESPlugin/MESPI_BusinessRule/MESPI_BusinessRule.vssscc
deleted file mode 100644
index 6cb031b..0000000
--- a/SRC/MESPlugin/MESPI_BusinessRule/MESPI_BusinessRule.vssscc
+++ /dev/null
@@ -1,10 +0,0 @@
-""
-{
-"FILE_VERSION" = "9237"
-"ENLISTMENT_CHOICE" = "NEVER"
-"PROJECT_FILE_RELATIVE_PATH" = ""
-"NUMBER_OF_EXCLUDED_FILES" = "0"
-"ORIGINAL_PROJECT_FILE_PATH" = ""
-"NUMBER_OF_NESTED_PROJECTS" = "0"
-"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROJECT"
-}
diff --git a/SRC/MESPlugin/MESPI_BusinessRule/My Project/AssemblyInfo.cs b/SRC/MESPlugin/MESPI_BusinessRule/My Project/AssemblyInfo.cs
deleted file mode 100644
index 6648594..0000000
--- a/SRC/MESPlugin/MESPI_BusinessRule/My Project/AssemblyInfo.cs
+++ /dev/null
@@ -1,35 +0,0 @@
-using System;
-using System.Reflection;
-using System.Runtime.InteropServices;
-
-// 組件的一般資訊是由下列的屬性集控制。
-// 變更這些屬性的值即可修改組件的相關
-// 資訊。
-
-// 檢閱組件屬性的值
-
-[assembly: AssemblyTitle("MESPI_BusinessRule")]
-[assembly: AssemblyDescription("")]
-[assembly: AssemblyCompany("")]
-[assembly: AssemblyProduct("MESPI_BusinessRule")]
-[assembly: AssemblyCopyright("Copyright © 2016")]
-[assembly: AssemblyTrademark("")]
-
-[assembly: ComVisible(false)]
-
-// 下列 GUID 為專案公開 (Expose) 至 COM 時所要使用的 typelib ID
-[assembly: Guid("ad5034de-f368-4373-8f98-36aec3edf64e")]
-
-// 組件的版本資訊由下列四個值所組成:
-//
-// 主要版本
-// 次要版本
-// 組建編號
-// 修訂編號
-//
-// 您可以指定所有的值,也可以依照以下的方式,使用 '*' 將組建和修訂編號
-// 指定為預設值:
-//
-
-[assembly: AssemblyVersion("6.0.0.0")]
-[assembly: AssemblyFileVersion("6.0.0.0")]
diff --git a/SRC/MESPlugin/MESPI_BusinessRule/My Project/Settings.Designer.cs b/SRC/MESPlugin/MESPI_BusinessRule/My Project/Settings.Designer.cs
deleted file mode 100644
index 77191f5..0000000
--- a/SRC/MESPlugin/MESPI_BusinessRule/My Project/Settings.Designer.cs
+++ /dev/null
@@ -1,26 +0,0 @@
-//------------------------------------------------------------------------------
-//
-// 這段程式碼是由工具產生的。
-// 執行階段版本:4.0.30319.42000
-//
-// 對這個檔案所做的變更可能會造成錯誤的行為,而且如果重新產生程式碼,
-// 變更將會遺失。
-//
-//------------------------------------------------------------------------------
-
-namespace MESPI_BusinessRule.My {
-
-
- [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
- [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "14.0.0.0")]
- internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
-
- private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
-
- public static Settings Default {
- get {
- return defaultInstance;
- }
- }
- }
-}
diff --git a/SRC/MESPlugin/MESPI_BusinessRule/clsBusinessRule.cs b/SRC/MESPlugin/MESPI_BusinessRule/clsBusinessRule.cs
deleted file mode 100644
index 7ef3087..0000000
--- a/SRC/MESPlugin/MESPI_BusinessRule/clsBusinessRule.cs
+++ /dev/null
@@ -1,16 +0,0 @@
-using iMESCIO.PIO.Plugin;
-using Microsoft.VisualBasic;
-
-namespace MESPI_BusinessRule
-{
-
- public class clsBusinessRule : IBusinessRule
- {
-
- private string funBR_Test(Collection colParameters)
- {
- return "Pass";
- }
-
- }
-}
\ No newline at end of file
diff --git a/SRC/MESPlugin/MESPI_BusinessRule/clsGetFunctionBR.cs b/SRC/MESPlugin/MESPI_BusinessRule/clsGetFunctionBR.cs
deleted file mode 100644
index 435204b..0000000
--- a/SRC/MESPlugin/MESPI_BusinessRule/clsGetFunctionBR.cs
+++ /dev/null
@@ -1,96 +0,0 @@
-using System;
-using System.Data;
-using System.IO;
-using System.Linq;
-using System.Reflection;
-using iMESCIO.PIO.Plugin;
-using Microsoft.VisualBasic;
-using Microsoft.VisualBasic.CompilerServices;
-
-namespace MESPI_BusinessRule
-{
-
- public class clsGetFunctionBR : ICommonPlugin
- {
-
- public string PlugInPoint
- {
- get
- {
- return "wsOP.LoadBRFunctionName";
- }
- }
-
- public object AfterExecut(params object[] Parameters)
- {
-
- string strAppBase = AppDomain.CurrentDomain.BaseDirectory;
- string strFilePath = strAppBase.TrimEnd('\\') + @"\Plugin\BusinessRule";
- Assembly mainAssembly;
- MethodInfo[] MyMethodInfos;
- string strFunction;
- string strResult = "";
-
- try
- {
-
- foreach (string file in Directory.GetFiles(strFilePath))
- {
-
- if (new System.IO.FileInfo(file).Extension.ToUpper() != ".DLL")
- {
- continue;
- }
-
- mainAssembly = Assembly.LoadFrom(file);
-
- foreach (Type item in mainAssembly.GetTypes())
- {
-
- var InterfaceTemp = item.GetInterfaces().Where(x => (x.Name ?? "") == (typeof(IBusinessRule).Name.ToString() ?? "")).FirstOrDefault();
-
- if (InterfaceTemp == null == false)
- {
-
- MyMethodInfos = item.GetMethods(BindingFlags.NonPublic | BindingFlags.Instance);
-
- for (int i = 0, loopTo = MyMethodInfos.Length - 1; i <= loopTo; i++)
- {
-
- strFunction = MyMethodInfos[i].Name;
-
- if (Conversions.ToBoolean(Strings.InStr(strFunction.ToUpper(), "FUNBR")))
- {
- strResult += "" + "FunctionName" + "String" + "" + "" + strFunction + "" + "" + "" + new System.IO.FileInfo(file).Name + "" + "";
- }
-
- }
-
- }
-
- }
-
- }
- }
-
- catch (Exception ex)
- {
- throw;
- }
- finally
- {
- mainAssembly = null;
- MyMethodInfos = null;
- }
-
- return strResult;
-
- }
-
- public object BeforeExecut(ref bool paramIsCancel, params object[] Parameters)
- {
- throw new NotImplementedException();
- }
-
- }
-}
\ No newline at end of file
diff --git a/SRC/MESPlugin/MESPI_WIP/MESPI_WIP.csproj b/SRC/MESPlugin/MESPI_WIP/MESPI_WIP.csproj
deleted file mode 100644
index 5509568..0000000
--- a/SRC/MESPlugin/MESPI_WIP/MESPI_WIP.csproj
+++ /dev/null
@@ -1,124 +0,0 @@
-
-
-
- Debug
- AnyCPU
-
-
-
-
- {F9051601-B027-0745-17C2-D36A87ABB6A1}
- Library
- MESPI_WIP
- MESPI_WIP
- 512
- Windows
- v4.6.2
- SAK
- SAK
- SAK
- SAK
-
- $(DefaultItemExcludes);$(ProjectDir)**\*.vb
-
-
- true
- full
- true
- true
- ..\..\MES_S_DLL\plugin\WIP\
- ..\..\MES_S_DLL\plugin\WIP\MESPI_WIP.xml
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- false
- 0
-
-
- pdbonly
- false
- true
- true
- bin\Release\
- bin\Release\MESPI_WIP.xml
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- false
- 0
-
-
- On
-
-
- Binary
-
-
- Off
-
-
- On
-
-
-
-
- False
- ..\..\MES_S_DLL\iMESException.dll
- True
-
-
- ..\..\MES_S_DLL\iMESLog.dll
-
-
- False
- ..\..\MES_S_DLL\kcPRD.dll
-
-
- ..\..\MES_S_DLL\kcWIP.dll
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- True
- Application.myapp
-
-
- True
- Settings.settings
- True
-
-
-
-
- MyApplicationCodeGenerator
- Application.Designer.cs
-
-
- SettingsSingleFileGenerator
- MESPI_WIP.My
- Settings.Designer.cs
-
-
-
-
-
\ No newline at end of file
diff --git a/SRC/MESPlugin/MESPI_WIP/My Project/Application.Designer.cs b/SRC/MESPlugin/MESPI_WIP/My Project/Application.Designer.cs
deleted file mode 100644
index 299bbe3..0000000
--- a/SRC/MESPlugin/MESPI_WIP/My Project/Application.Designer.cs
+++ /dev/null
@@ -1,11 +0,0 @@
-// ------------------------------------------------------------------------------
-//
-// 這段程式碼是由工具產生的。
-// 執行階段版本:4.0.30319.42000
-//
-// 對這個檔案所做的變更可能會造成錯誤的行為,而且如果重新產生程式碼,
-// 變更將會遺失。
-//
-// ------------------------------------------------------------------------------
-
-
diff --git a/SRC/MESPlugin/MESPI_WIP/My Project/AssemblyInfo.cs b/SRC/MESPlugin/MESPI_WIP/My Project/AssemblyInfo.cs
deleted file mode 100644
index 0d0d221..0000000
--- a/SRC/MESPlugin/MESPI_WIP/My Project/AssemblyInfo.cs
+++ /dev/null
@@ -1,35 +0,0 @@
-using System;
-using System.Reflection;
-using System.Runtime.InteropServices;
-
-// 組件的一般資訊是由下列的屬性集控制。
-// 變更這些屬性的值即可修改組件的相關
-// 資訊。
-
-// 檢閱組件屬性的值
-
-[assembly: AssemblyTitle("MESPI_WIP")]
-[assembly: AssemblyDescription("")]
-[assembly: AssemblyCompany("")]
-[assembly: AssemblyProduct("MESPI_WIP")]
-[assembly: AssemblyCopyright("Copyright © 2018")]
-[assembly: AssemblyTrademark("")]
-
-[assembly: ComVisible(false)]
-
-// 下列 GUID 為專案公開 (Expose) 至 COM 時所要使用的 typelib ID
-[assembly: Guid("438509c2-63aa-45a9-955b-b76a4ad092ac")]
-
-// 組件的版本資訊是由下列四項值構成:
-//
-// 主要版本
-// 次要版本
-// 組建編號
-// 修訂編號
-//
-// 您可以指定所有的值,也可以依照以下的方式,使用 '*' 將組建和修訂編號
-// 指定為預設值:
-//
-
-[assembly: AssemblyVersion("1.0.0.0")]
-[assembly: AssemblyFileVersion("1.0.0.0")]
diff --git a/SRC/MESPlugin/MESPI_WIP/My Project/Settings.settings b/SRC/MESPlugin/MESPI_WIP/My Project/Settings.settings
deleted file mode 100644
index 85b890b..0000000
--- a/SRC/MESPlugin/MESPI_WIP/My Project/Settings.settings
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
-
diff --git a/SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.sln b/SRC/MESWin/BR/BR_L_CI_GEN/BR_L_CI_GEN.sln
similarity index 68%
rename from SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.sln
rename to SRC/MESWin/BR/BR_L_CI_GEN/BR_L_CI_GEN.sln
index 85b1902..0446495 100644
--- a/SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.sln
+++ b/SRC/MESWin/BR/BR_L_CI_GEN/BR_L_CI_GEN.sln
@@ -1,11 +1,14 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14
-VisualStudioVersion = 14.0.25123.0
+VisualStudioVersion = 14.0.25420.1
MinimumVisualStudioVersion = 10.0.40219.1
-Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "ET_Subcontractor", "ET_Subcontractor.vbproj", "{D6EE7B96-F10E-44E2-9731-162B70B4C8DD}"
+Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "BR_L_CI_GEN", "BR_L_CI_GEN.vbproj", "{0FD97C44-56DD-44B2-AA3E-351935F5AC9C}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Test", "..\..\Test\Test.vbproj", "{C4A48E3F-38E4-4E88-A47D-FA5510686E57}"
+ ProjectSection(ProjectDependencies) = postProject
+ {0FD97C44-56DD-44B2-AA3E-351935F5AC9C} = {0FD97C44-56DD-44B2-AA3E-351935F5AC9C}
+ EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -13,10 +16,10 @@ Global
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.ActiveCfg = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.Build.0 = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.ActiveCfg = Release|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.Build.0 = Release|x86
+ {0FD97C44-56DD-44B2-AA3E-351935F5AC9C}.Debug|x86.ActiveCfg = Debug|x86
+ {0FD97C44-56DD-44B2-AA3E-351935F5AC9C}.Debug|x86.Build.0 = Debug|x86
+ {0FD97C44-56DD-44B2-AA3E-351935F5AC9C}.Release|x86.ActiveCfg = Release|x86
+ {0FD97C44-56DD-44B2-AA3E-351935F5AC9C}.Release|x86.Build.0 = Release|x86
{C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.ActiveCfg = Debug|x86
{C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.Build.0 = Debug|x86
{C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Release|x86.ActiveCfg = Release|x86
@@ -29,11 +32,11 @@ Global
SccNumberOfProjects = 3
SccEnterpriseProvider = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C}
SccTeamFoundationServer = http://tfs.imestech.com:8080/tfs/messeries6
- SccProjectUniqueName0 = ET_Subcontractor.vbproj
SccLocalPath0 = .
SccProjectUniqueName1 = ..\\..\\Test\\Test.vbproj
SccProjectName1 = ../../Test
SccLocalPath1 = ..\\..\\Test
+ SccProjectUniqueName2 = BR_L_CI_GEN.vbproj
SccLocalPath2 = .
EndGlobalSection
EndGlobal
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/ET_Subcontractor_21676.vbproj b/SRC/MESWin/BR/BR_L_CI_GEN/BR_L_CI_GEN.vbproj
similarity index 62%
rename from SRC/MESWin/SYS3/ET_Subcontractor_21676/ET_Subcontractor_21676.vbproj
rename to SRC/MESWin/BR/BR_L_CI_GEN/BR_L_CI_GEN.vbproj
index 1b1ea32..1c39ef5 100644
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/ET_Subcontractor_21676.vbproj
+++ b/SRC/MESWin/BR/BR_L_CI_GEN/BR_L_CI_GEN.vbproj
@@ -4,10 +4,10 @@
Debug
x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}
+ {0FD97C44-56DD-44B2-AA3E-351935F5AC9C}
Library
- ET_Subcontractor_21676
- ET_Subcontractor_21676
+ BR_L_CI_GEN
+ BR_L_CI_GEN
512
Windows
v4.6.2
@@ -17,6 +17,28 @@
SAK
SAK
+
+ true
+ full
+ true
+ true
+ ..\..\..\MESClient\
+ BR_L_CI_GEN.xml
+ 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
+ 0
+ false
+
+
+ pdbonly
+ false
+ true
+ true
+ bin\Release\
+ BR_L_CI_GEN.xml
+ 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
+ 0
+ false
+
On
@@ -34,7 +56,7 @@
true
true
..\..\..\MESClient\
- ET_Subcontractor_21676.xml
+ BR_L_CI_GEN.xml
0
42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
full
@@ -45,7 +67,7 @@
true
..\..\..\MESClient\
- ET_Subcontractor_21676.xml
+ BR_L_CI_GEN.xml
true
0
42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
@@ -66,6 +88,11 @@
C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.v19.1.dll
False
+
+ False
+ C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinTabControl.v19.1.dll
+ False
+
False
C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinGrid.v19.1.dll
@@ -86,10 +113,29 @@
C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Shared.v19.1.dll
False
+
+ False
+ ..\..\..\MESClient\COM_ERP.dll
+ False
+
..\..\..\MESClient\COM_Kit.dll
False
+
+ False
+ ..\..\..\MESClient\COM_Search.dll
+ False
+
+
+ False
+ ..\..\..\MESClient\COM_Utility.dll
+ False
+
+
+ ..\..\..\MES_C_DLL\iMESException.dll
+ False
+
..\..\..\MES_C_DLL\iMESExceptionManager.dll
False
@@ -98,17 +144,29 @@
..\..\..\MES_C_DLL\iMESUltraGrid.dll
False
+
+ False
+ ..\..\..\MES_S_DLL\Newtonsoft.Json.dll
+
+
+
+
+ False
+ ..\..\..\MESClient\WP_Kit.dll
+ False
+
+
@@ -121,34 +179,19 @@
+
modConstant.vb
-
- Form
-
-
- Form
-
-
- Form
-
-
- Form
-
-
- Form
-
-
+
Form
True
Application.myapp
- True
True
@@ -160,25 +203,15 @@
Settings.settings
True
+
+ True
+ True
+ Reference.map
+
-
- frmSubcontractor_21676.vb
-
-
- frmSubcontractorContDef_21676.vb
-
-
- frmSubcontractorDef_21676.vb
-
-
- frmSubcontractor.vb
-
-
- frmSubcontractorContDef.vb
-
-
- frmSubcontractorDef.vb
+
+ frmBR_L_CI_GEN.vb
@@ -189,6 +222,7 @@
+
MyApplicationCodeGenerator
@@ -199,8 +233,34 @@
My
Settings.Designer.vb
+
+ MSDiscoCodeGenerator
+ Reference.vb
+
+
+
+
+
+
+
+
+
+
+
+ Dynamic
+ Web References\wsEAI\
+ http://localhost/EAI/wsEAI.asmx
+
+
+
+
+ MySettings
+ BR_L_CI_GEN_localhost_wsEAI
+
+
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ http://localhost/EAI/wsEAI.asmx
+
+
+
+
diff --git a/SRC/MESWin/SYS1/ET_21674/frmTeacherDef.resx b/SRC/MESWin/BR/BR_L_CI_GEN/frmBR_L_CI_GEN.resx
similarity index 94%
rename from SRC/MESWin/SYS1/ET_21674/frmTeacherDef.resx
rename to SRC/MESWin/BR/BR_L_CI_GEN/frmBR_L_CI_GEN.resx
index 1af7de1..46f7a23 100644
--- a/SRC/MESWin/SYS1/ET_21674/frmTeacherDef.resx
+++ b/SRC/MESWin/BR/BR_L_CI_GEN/frmBR_L_CI_GEN.resx
@@ -117,4 +117,10 @@
System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+ 28, 11
+
+
+ 25
+
\ No newline at end of file
diff --git a/SRC/MESWin/BR/BR_L_CI_GEN/frmBR_L_CI_GEN.vb b/SRC/MESWin/BR/BR_L_CI_GEN/frmBR_L_CI_GEN.vb
new file mode 100644
index 0000000..d82d6a5
--- /dev/null
+++ b/SRC/MESWin/BR/BR_L_CI_GEN/frmBR_L_CI_GEN.vb
@@ -0,0 +1,6477 @@
+Imports iMESExceptionManager
+Imports Infragistics.Win.UltraWinGrid
+Imports Infragistics.Win
+Imports System.IO
+Imports Newtonsoft.Json
+Imports Newtonsoft.Json.Linq
+Imports COM_ERP
+
+'''
+''' 修改:2012/06/15,sammi.新增多人加工處理.
+''' 2016/12/26 YF, 增加新制多人加工(btnOperator), 先將舊有的多人加工隱藏(btnMultiUser)
+'''
+Public Class frmBR_L_CI_GEN
+ Inherits System.Windows.Forms.Form
+
+ '//Public Variables
+ Public LotNo As String = defString
+ Public UserId As String = defString
+ Public UserName As String = defString
+
+ Public EquipmentNo As String = defString
+ Public LoadPort As Integer = defInteger
+ Public PrivFunNo As String = defString
+
+ '//Web Service相關變數
+ Dim tmpStringReader As System.IO.StringReader
+ Dim InXml, OutXml, strIdentity, strParameter, XmlData, XmlSchema As String
+
+ '//資料表相關變數
+ Dim dsWIP, dsTemp, dsINV, dsEQP As New DataSet
+ Dim dtKeyIn, dtTmpLoginState, dtTmpMTLLotNo As DataTable
+ Dim drAdd As DataRow
+ Dim tblLotState, tblTAttrib, tblTMaterial, tblAreaEquipment, tblLotLoginState, tblMaterialLotNo,
+ tblTmpMTLLotNo, tblMOMaterialState, tblWIPINVRaw, tblSubstituteMaterial, tblSWRJoinLog,
+ tblMaterialBasis, tblTLotState, tblMaterialProperty, tblOPBasis, tblEQPDispatchState, tblWIPINVSEMI As String
+ '2016-12-19 系統參數資料表
+ Dim dsDefine As New DataSet
+ Dim tblSYSParam As String = ""
+ Dim Execute_eSOP As Integer = 0 '2016-12-14, 是否啟用eSOP(0:false,1:true)
+
+ '//其他共用變數
+ Dim RevLotSerial As String = defString
+ Dim LotSerial As String = defString
+ Dim LogGroupSerial As String = defString
+ Dim RevLotStamp As Long = defInteger
+ Dim PhaseNo As Integer
+ Dim datEventTime As DateTime = Now
+ Dim ugrRow As Infragistics.Win.UltraWinGrid.UltraGridRow
+ Dim blnGetAccessory As Boolean = True
+ Dim drSelE As DataRow()
+ Dim blnChamber As Boolean = False
+ '2019/02/12 Eric 特殊生產需求是否有資料
+ Dim blnShowSWR As Boolean = False
+
+ '20091006 Seam 新增作業工序
+ Dim tblSubOP As String
+
+ '2010/03/08,yumei,iugKeyIn區塊新增清單選擇
+ Dim strDefaultValue As String
+ Dim editor As Infragistics.Win.DateTimeEditor
+
+ ' 2016/08/30 YF, ObjectFile物件
+ Dim ObjectFileHandler As COM_Utility.ObjectFileHandler
+ '2016-12-20 XIANG
+ Dim tblPRDeSOPBasis As String = ""
+ Friend WithEvents chkUpdCheckInTime As CheckBox
+ Friend WithEvents btnSWR As Infragistics.Win.Misc.UltraButton
+ '傳給eSOP,紀錄資料數(ROW欄位)
+ Dim intRow As Integer = 1
+ Dim blnGumMaterialType As Boolean = False
+ Dim aryGumMaterialType As Array
+ Dim dtAllMTLLot As DataTable '所有可用料批資料
+ Dim tblTMaterialLot As String
+ Friend WithEvents lblMaterialNo As Label
+ Friend WithEvents txtMaterialNo As UltraWinEditors.UltraTextEditor
+ Dim blnSelect As Boolean = False
+ Dim blnByEQP As Boolean = False
+ Dim blnCIMTLDBCheck As Boolean = False
+ Dim blnLock As Boolean = False
+
+ Dim ACCMin As Decimal = defInteger
+ Dim ACCMax As Decimal = defInteger
+ Dim ReFrozenFlag As Integer = defInteger
+ Dim ReACCMin As Decimal = defInteger
+ Dim ReACCMax As Decimal = defInteger
+ Dim strTableName, strRaw As String
+
+ Dim vlMaterialLevel As New ValueList
+
+ Dim ckhEQPDispatchRule As String
+
+ ''新设备上料 14278
+ Dim dsOE As New DataSet '資料集:儲存取回之資料?
+ Dim strMOList As String '儲存取回資料表的名稱?
+#Region " Windows Form 設計工具產生的程式碼 "
+
+ Public Sub New()
+ MyBase.New()
+
+ '此呼叫為 Windows Form 設計工具的必要項。
+
+ InitializeComponent()
+
+ '在 InitializeComponent() 呼叫之後加入所有的初始設定
+ ' 2016/08/30 YF, 開另一條執行緒建立會使用到的物件
+ Threading.ThreadPool.QueueUserWorkItem(New Threading.WaitCallback(
+ Sub(pState As Object)
+ ' 呼叫COM_Utility.ObjectFileHandler建構子, 傳入要載入的ObjectID
+ Me.ObjectFileHandler = New COM_Utility.ObjectFileHandler("WP_OperatorLogIn_Lot", "WP_EQPConsumeReset", "WP_EQPCheckQCList", "WP_SWRBasisRead", "WP_MaterialQtyInput_Main")
+ End Sub))
+
+ End Sub
+
+ 'Form 覆寫 Dispose 以清除元件清單。
+
+ Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
+ If disposing Then
+ If Not (components Is Nothing) Then
+ components.Dispose()
+ End If
+ End If
+ MyBase.Dispose(disposing)
+ End Sub
+
+ '為 Windows Form 設計工具的必要項
+ Private components As System.ComponentModel.IContainer
+
+ '注意: 以下為 Windows Form 設計工具所需的程序
+
+ '您可以使用 Windows Form 設計工具進行修改。
+
+ '請勿使用程式碼編輯器來修改這些程序。
+ Friend WithEvents UltraTabPageControl1 As Infragistics.Win.UltraWinTabControl.UltraTabPageControl
+ Friend WithEvents UltraTabPageControl2 As Infragistics.Win.UltraWinTabControl.UltraTabPageControl
+ Friend WithEvents ToolTip1 As System.Windows.Forms.ToolTip
+ Friend WithEvents UltraTabControl1 As Infragistics.Win.UltraWinTabControl.UltraTabControl
+ Friend WithEvents UltraTabSharedControlsPage1 As Infragistics.Win.UltraWinTabControl.UltraTabSharedControlsPage
+ Friend WithEvents utpMaterial As Infragistics.Win.UltraWinTabControl.UltraTabPageControl
+ Friend WithEvents utpSubOP As Infragistics.Win.UltraWinTabControl.UltraTabPageControl
+ Friend WithEvents iugSubOP As iMESUltraGrid.iMESUltraGridControl
+ Friend WithEvents utpEquipment As Infragistics.Win.UltraWinTabControl.UltraTabPageControl
+ Friend WithEvents IMESUltraGrid3 As iMESUltraGrid.iMESUltraGridControl
+ Friend WithEvents SBar1 As System.Windows.Forms.StatusBar
+ Friend WithEvents SBarPanel1 As System.Windows.Forms.StatusBarPanel
+ Friend WithEvents SBarPanel4 As System.Windows.Forms.StatusBarPanel
+ Friend WithEvents SBarPanel2 As System.Windows.Forms.StatusBarPanel
+ Friend WithEvents SBarPanel3 As System.Windows.Forms.StatusBarPanel
+ Friend WithEvents lblOPNo As System.Windows.Forms.Label
+ Friend WithEvents lblLotNo As System.Windows.Forms.Label
+ Friend WithEvents lblSysQty As System.Windows.Forms.Label
+ Friend WithEvents lblCurQty As System.Windows.Forms.Label
+ Friend WithEvents lblEmployeeNo As System.Windows.Forms.Label
+ Friend WithEvents lblShiftNo As System.Windows.Forms.Label
+ Friend WithEvents lblCustomerLotNo As System.Windows.Forms.Label
+ Friend WithEvents lblPriority As System.Windows.Forms.Label
+ Friend WithEvents txtOPNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents txtLotNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents txtCurQty As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents txtCurUnitNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents txtSysQty As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents txtSysUnitNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents txtPriority As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents txtAreaNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents txtEmployeeNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents txtShiftNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents txtCustomerLotNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents iugAttrib As iMESUltraGrid.iMESUltraGridControl
+ Friend WithEvents iugMaterial As iMESUltraGrid.iMESUltraGridControl
+ Friend WithEvents iugEquipment As iMESUltraGrid.iMESUltraGridControl
+ Friend WithEvents btnClose As Infragistics.Win.Misc.UltraButton
+ Friend WithEvents btnConfirm As Infragistics.Win.Misc.UltraButton
+ Friend WithEvents lblEquipmentNo As System.Windows.Forms.Label
+ Friend WithEvents txtEquipmentNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents iugKeyIn As iMESUltraGrid.iMESUltraGridControl
+ Friend WithEvents lblProductNo As System.Windows.Forms.Label
+ Friend WithEvents txtProductNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents lblAreaNo As System.Windows.Forms.Label
+ Friend WithEvents txtOPDescription As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents lblOPDescription As System.Windows.Forms.Label
+ Friend WithEvents lblLotRecord As System.Windows.Forms.Label
+ Friend WithEvents txtLotRecord As System.Windows.Forms.RichTextBox
+ Friend WithEvents txtMONo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents lblMONo As System.Windows.Forms.Label
+ Friend WithEvents gbxLotInfo As System.Windows.Forms.GroupBox
+ Friend WithEvents lblupdcheckintime As System.Windows.Forms.Label
+ Friend WithEvents dtpcheckintime As System.Windows.Forms.DateTimePicker
+ Friend WithEvents btnQCList As Infragistics.Win.Misc.UltraButton
+ Friend WithEvents btnEQPConsumeReset As Infragistics.Win.Misc.UltraButton
+ Friend WithEvents txtOpName As Infragistics.Win.UltraWinEditors.UltraTextEditor
+ Friend WithEvents btnMultiUser As Infragistics.Win.Misc.UltraButton
+ Friend WithEvents lblMaterialLotNo As System.Windows.Forms.Label
+ Friend WithEvents btnOperator As Misc.UltraButton
+ Friend WithEvents txtMaterialLotNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
+
+ Friend WithEvents uegLotInfo As Misc.UltraExpandableGroupBox
+ Friend WithEvents uplEquipment As Misc.UltraPanel
+ Friend WithEvents uplAttrib As Misc.UltraPanel
+ Friend WithEvents UltraExpandableGroupBoxPanel1 As Misc.UltraExpandableGroupBoxPanel
+ Friend WithEvents UltraPanel1 As Misc.UltraPanel
+ Friend WithEvents uplAttrib_Equipment As Misc.UltraPanel
+ Friend WithEvents UltraSplitter1 As Misc.UltraSplitter
+ Friend WithEvents uplMaterial_KeyIn As Misc.UltraPanel
+ Friend WithEvents UltraSplitter2 As Misc.UltraSplitter
+ Friend WithEvents uplMaterial As Misc.UltraPanel
+ Friend WithEvents uplKeyIn As Misc.UltraPanel
+ Friend WithEvents uplAll As Misc.UltraPanel
+ Friend WithEvents uegMaterial_KeyIn2 As Misc.UltraExpandableGroupBox
+ Friend WithEvents UltraExpandableGroupBoxPanel4 As Misc.UltraExpandableGroupBoxPanel
+ Friend WithEvents UltraPanel4 As Misc.UltraPanel
+ Friend WithEvents uegAttrib_Equipment As Misc.UltraExpandableGroupBox
+ Friend WithEvents UltraExpandableGroupBoxPanel2 As Misc.UltraExpandableGroupBoxPanel
+ Friend WithEvents UltraPanel2 As Misc.UltraPanel
+
+ Private Sub InitializeComponent()
+ Me.components = New System.ComponentModel.Container()
+ Dim UltraTab1 As Infragistics.Win.UltraWinTabControl.UltraTab = New Infragistics.Win.UltraWinTabControl.UltraTab()
+ Dim UltraTab4 As Infragistics.Win.UltraWinTabControl.UltraTab = New Infragistics.Win.UltraWinTabControl.UltraTab()
+ Me.utpMaterial = New Infragistics.Win.UltraWinTabControl.UltraTabPageControl()
+ Me.lblMaterialNo = New System.Windows.Forms.Label()
+ Me.txtMaterialNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.lblMaterialLotNo = New System.Windows.Forms.Label()
+ Me.txtMaterialLotNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.iugMaterial = New iMESUltraGrid.iMESUltraGridControl()
+ Me.utpSubOP = New Infragistics.Win.UltraWinTabControl.UltraTabPageControl()
+ Me.iugSubOP = New iMESUltraGrid.iMESUltraGridControl()
+ Me.uegLotInfo = New Infragistics.Win.Misc.UltraExpandableGroupBox()
+ Me.UltraExpandableGroupBoxPanel1 = New Infragistics.Win.Misc.UltraExpandableGroupBoxPanel()
+ Me.UltraPanel1 = New Infragistics.Win.Misc.UltraPanel()
+ Me.gbxLotInfo = New System.Windows.Forms.GroupBox()
+ Me.txtOpName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtOPNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtProductNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtCustomerLotNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtMONo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtShiftNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtEmployeeNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtAreaNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtPriority = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtSysUnitNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtSysQty = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtCurUnitNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtCurQty = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtOPDescription = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.txtLotNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.lblPriority = New System.Windows.Forms.Label()
+ Me.lblMONo = New System.Windows.Forms.Label()
+ Me.lblShiftNo = New System.Windows.Forms.Label()
+ Me.lblOPNo = New System.Windows.Forms.Label()
+ Me.lblAreaNo = New System.Windows.Forms.Label()
+ Me.lblSysQty = New System.Windows.Forms.Label()
+ Me.lblCurQty = New System.Windows.Forms.Label()
+ Me.lblProductNo = New System.Windows.Forms.Label()
+ Me.lblOPDescription = New System.Windows.Forms.Label()
+ Me.lblCustomerLotNo = New System.Windows.Forms.Label()
+ Me.lblEmployeeNo = New System.Windows.Forms.Label()
+ Me.lblLotNo = New System.Windows.Forms.Label()
+ Me.UltraTabPageControl2 = New Infragistics.Win.UltraWinTabControl.UltraTabPageControl()
+ Me.UltraTabPageControl1 = New Infragistics.Win.UltraWinTabControl.UltraTabPageControl()
+ Me.SBar1 = New System.Windows.Forms.StatusBar()
+ Me.SBarPanel1 = New System.Windows.Forms.StatusBarPanel()
+ Me.SBarPanel2 = New System.Windows.Forms.StatusBarPanel()
+ Me.SBarPanel3 = New System.Windows.Forms.StatusBarPanel()
+ Me.SBarPanel4 = New System.Windows.Forms.StatusBarPanel()
+ Me.iugAttrib = New iMESUltraGrid.iMESUltraGridControl()
+ Me.iugEquipment = New iMESUltraGrid.iMESUltraGridControl()
+ Me.btnClose = New Infragistics.Win.Misc.UltraButton()
+ Me.btnConfirm = New Infragistics.Win.Misc.UltraButton()
+ Me.lblEquipmentNo = New System.Windows.Forms.Label()
+ Me.txtEquipmentNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
+ Me.lblLotRecord = New System.Windows.Forms.Label()
+ Me.txtLotRecord = New System.Windows.Forms.RichTextBox()
+ Me.lblupdcheckintime = New System.Windows.Forms.Label()
+ Me.dtpcheckintime = New System.Windows.Forms.DateTimePicker()
+ Me.btnEQPConsumeReset = New Infragistics.Win.Misc.UltraButton()
+ Me.btnQCList = New Infragistics.Win.Misc.UltraButton()
+ Me.ToolTip1 = New System.Windows.Forms.ToolTip(Me.components)
+ Me.utpEquipment = New Infragistics.Win.UltraWinTabControl.UltraTabPageControl()
+ Me.IMESUltraGrid3 = New iMESUltraGrid.iMESUltraGridControl()
+ Me.btnMultiUser = New Infragistics.Win.Misc.UltraButton()
+ Me.btnOperator = New Infragistics.Win.Misc.UltraButton()
+ Me.chkUpdCheckInTime = New System.Windows.Forms.CheckBox()
+ Me.btnSWR = New Infragistics.Win.Misc.UltraButton()
+ Me.uplAttrib = New Infragistics.Win.Misc.UltraPanel()
+ Me.uplEquipment = New Infragistics.Win.Misc.UltraPanel()
+ Me.uplAttrib_Equipment = New Infragistics.Win.Misc.UltraPanel()
+ Me.UltraSplitter1 = New Infragistics.Win.Misc.UltraSplitter()
+ Me.uplMaterial_KeyIn = New Infragistics.Win.Misc.UltraPanel()
+ Me.uplKeyIn = New Infragistics.Win.Misc.UltraPanel()
+ Me.iugKeyIn = New iMESUltraGrid.iMESUltraGridControl()
+ Me.UltraSplitter2 = New Infragistics.Win.Misc.UltraSplitter()
+ Me.uplMaterial = New Infragistics.Win.Misc.UltraPanel()
+ Me.UltraTabControl1 = New Infragistics.Win.UltraWinTabControl.UltraTabControl()
+ Me.UltraTabSharedControlsPage1 = New Infragistics.Win.UltraWinTabControl.UltraTabSharedControlsPage()
+ Me.uplAll = New Infragistics.Win.Misc.UltraPanel()
+ Me.uegMaterial_KeyIn2 = New Infragistics.Win.Misc.UltraExpandableGroupBox()
+ Me.UltraExpandableGroupBoxPanel4 = New Infragistics.Win.Misc.UltraExpandableGroupBoxPanel()
+ Me.UltraPanel4 = New Infragistics.Win.Misc.UltraPanel()
+ Me.uegAttrib_Equipment = New Infragistics.Win.Misc.UltraExpandableGroupBox()
+ Me.UltraExpandableGroupBoxPanel2 = New Infragistics.Win.Misc.UltraExpandableGroupBoxPanel()
+ Me.UltraPanel2 = New Infragistics.Win.Misc.UltraPanel()
+ Me.utpMaterial.SuspendLayout()
+ CType(Me.txtMaterialNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtMaterialLotNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ Me.utpSubOP.SuspendLayout()
+ CType(Me.uegLotInfo, System.ComponentModel.ISupportInitialize).BeginInit()
+ Me.uegLotInfo.SuspendLayout()
+ Me.UltraExpandableGroupBoxPanel1.SuspendLayout()
+ Me.UltraPanel1.ClientArea.SuspendLayout()
+ Me.UltraPanel1.SuspendLayout()
+ Me.gbxLotInfo.SuspendLayout()
+ CType(Me.txtOpName, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtOPNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtProductNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtCustomerLotNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtMONo, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtShiftNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtEmployeeNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtAreaNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtPriority, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtSysUnitNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtSysQty, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtCurUnitNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtCurQty, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtOPDescription, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtLotNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.SBarPanel1, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.SBarPanel2, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.SBarPanel3, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.SBarPanel4, System.ComponentModel.ISupportInitialize).BeginInit()
+ CType(Me.txtEquipmentNo, System.ComponentModel.ISupportInitialize).BeginInit()
+ Me.utpEquipment.SuspendLayout()
+ Me.uplAttrib.ClientArea.SuspendLayout()
+ Me.uplAttrib.SuspendLayout()
+ Me.uplEquipment.ClientArea.SuspendLayout()
+ Me.uplEquipment.SuspendLayout()
+ Me.uplAttrib_Equipment.ClientArea.SuspendLayout()
+ Me.uplAttrib_Equipment.SuspendLayout()
+ Me.uplMaterial_KeyIn.ClientArea.SuspendLayout()
+ Me.uplMaterial_KeyIn.SuspendLayout()
+ Me.uplKeyIn.ClientArea.SuspendLayout()
+ Me.uplKeyIn.SuspendLayout()
+ Me.uplMaterial.ClientArea.SuspendLayout()
+ Me.uplMaterial.SuspendLayout()
+ CType(Me.UltraTabControl1, System.ComponentModel.ISupportInitialize).BeginInit()
+ Me.UltraTabControl1.SuspendLayout()
+ Me.uplAll.ClientArea.SuspendLayout()
+ Me.uplAll.SuspendLayout()
+ CType(Me.uegMaterial_KeyIn2, System.ComponentModel.ISupportInitialize).BeginInit()
+ Me.uegMaterial_KeyIn2.SuspendLayout()
+ Me.UltraExpandableGroupBoxPanel4.SuspendLayout()
+ Me.UltraPanel4.ClientArea.SuspendLayout()
+ Me.UltraPanel4.SuspendLayout()
+ CType(Me.uegAttrib_Equipment, System.ComponentModel.ISupportInitialize).BeginInit()
+ Me.uegAttrib_Equipment.SuspendLayout()
+ Me.UltraExpandableGroupBoxPanel2.SuspendLayout()
+ Me.UltraPanel2.ClientArea.SuspendLayout()
+ Me.UltraPanel2.SuspendLayout()
+ Me.SuspendLayout()
+ '
+ 'utpMaterial
+ '
+ Me.utpMaterial.Controls.Add(Me.lblMaterialNo)
+ Me.utpMaterial.Controls.Add(Me.txtMaterialNo)
+ Me.utpMaterial.Controls.Add(Me.lblMaterialLotNo)
+ Me.utpMaterial.Controls.Add(Me.txtMaterialLotNo)
+ Me.utpMaterial.Controls.Add(Me.iugMaterial)
+ Me.utpMaterial.Location = New System.Drawing.Point(1, 23)
+ Me.utpMaterial.Name = "utpMaterial"
+ Me.utpMaterial.Size = New System.Drawing.Size(511, 187)
+ '
+ 'lblMaterialNo
+ '
+ Me.lblMaterialNo.BackColor = System.Drawing.Color.Transparent
+ Me.lblMaterialNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblMaterialNo.Location = New System.Drawing.Point(7, 11)
+ Me.lblMaterialNo.Name = "lblMaterialNo"
+ Me.lblMaterialNo.Size = New System.Drawing.Size(90, 16)
+ Me.lblMaterialNo.TabIndex = 159
+ Me.lblMaterialNo.Text = "Material No"
+ '
+ 'txtMaterialNo
+ '
+ Me.txtMaterialNo.Location = New System.Drawing.Point(103, 7)
+ Me.txtMaterialNo.Name = "txtMaterialNo"
+ Me.txtMaterialNo.Size = New System.Drawing.Size(132, 22)
+ Me.txtMaterialNo.TabIndex = 158
+ '
+ 'lblMaterialLotNo
+ '
+ Me.lblMaterialLotNo.BackColor = System.Drawing.Color.Transparent
+ Me.lblMaterialLotNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblMaterialLotNo.Location = New System.Drawing.Point(244, 11)
+ Me.lblMaterialLotNo.Name = "lblMaterialLotNo"
+ Me.lblMaterialLotNo.Size = New System.Drawing.Size(90, 16)
+ Me.lblMaterialLotNo.TabIndex = 157
+ Me.lblMaterialLotNo.Text = "Material Lot No"
+ '
+ 'txtMaterialLotNo
+ '
+ Me.txtMaterialLotNo.Location = New System.Drawing.Point(340, 7)
+ Me.txtMaterialLotNo.Name = "txtMaterialLotNo"
+ Me.txtMaterialLotNo.Size = New System.Drawing.Size(132, 22)
+ Me.txtMaterialLotNo.TabIndex = 156
+ '
+ 'iugMaterial
+ '
+ Me.iugMaterial.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
+ Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.iugMaterial.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
+ Me.iugMaterial.GroupBoxPromptText = "Drag a column header here to group by that column."
+ Me.iugMaterial.GroupBoxTextForeColor = System.Drawing.Color.Red
+ Me.iugMaterial.Identity = "IMes"
+ Me.iugMaterial.IdentityForm = ""
+ Me.iugMaterial.LayOutFilePath = ""
+ Me.iugMaterial.Location = New System.Drawing.Point(2, 35)
+ Me.iugMaterial.Name = "iugMaterial"
+ Me.iugMaterial.PrintFitWidthToPages = 0
+ Me.iugMaterial.PrintLandscape = True
+ Me.iugMaterial.PrintPageFooter = ""
+ Me.iugMaterial.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
+ Me.iugMaterial.PrintPageFooterHeight = 20
+ Me.iugMaterial.PrintPageHeader = ""
+ Me.iugMaterial.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
+ Me.iugMaterial.PrintPageHeaderHeight = 20
+ Me.iugMaterial.PrintZoom = 1.0R
+ Me.iugMaterial.Size = New System.Drawing.Size(506, 148)
+ Me.iugMaterial.TabIndex = 108
+ Me.iugMaterial.UserNo = "IMes"
+ '
+ 'utpSubOP
+ '
+ Me.utpSubOP.Controls.Add(Me.iugSubOP)
+ Me.utpSubOP.Location = New System.Drawing.Point(-10000, -10000)
+ Me.utpSubOP.Name = "utpSubOP"
+ Me.utpSubOP.Size = New System.Drawing.Size(511, 187)
+ '
+ 'iugSubOP
+ '
+ Me.iugSubOP.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
+ Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.iugSubOP.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
+ Me.iugSubOP.GroupBoxPromptText = "Drag a column header here to group by that column."
+ Me.iugSubOP.GroupBoxTextForeColor = System.Drawing.Color.Red
+ Me.iugSubOP.Identity = "IMes"
+ Me.iugSubOP.IdentityForm = ""
+ Me.iugSubOP.LayOutFilePath = ""
+ Me.iugSubOP.Location = New System.Drawing.Point(3, 3)
+ Me.iugSubOP.Name = "iugSubOP"
+ Me.iugSubOP.PrintFitWidthToPages = 0
+ Me.iugSubOP.PrintLandscape = True
+ Me.iugSubOP.PrintPageFooter = ""
+ Me.iugSubOP.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
+ Me.iugSubOP.PrintPageFooterHeight = 20
+ Me.iugSubOP.PrintPageHeader = ""
+ Me.iugSubOP.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
+ Me.iugSubOP.PrintPageHeaderHeight = 20
+ Me.iugSubOP.PrintZoom = 1.0R
+ Me.iugSubOP.Size = New System.Drawing.Size(506, 181)
+ Me.iugSubOP.TabIndex = 1
+ Me.iugSubOP.UserNo = "IMes"
+ '
+ 'uegLotInfo
+ '
+ Me.uegLotInfo.Controls.Add(Me.UltraExpandableGroupBoxPanel1)
+ Me.uegLotInfo.Dock = System.Windows.Forms.DockStyle.Top
+ Me.uegLotInfo.ExpandedSize = New System.Drawing.Size(1013, 153)
+ Me.uegLotInfo.Location = New System.Drawing.Point(0, 0)
+ Me.uegLotInfo.Name = "uegLotInfo"
+ Me.uegLotInfo.Size = New System.Drawing.Size(1013, 153)
+ Me.uegLotInfo.TabIndex = 161
+ Me.uegLotInfo.Text = "Lot Information"
+ Me.uegLotInfo.ViewStyle = Infragistics.Win.Misc.GroupBoxViewStyle.Office2003
+ '
+ 'UltraExpandableGroupBoxPanel1
+ '
+ Me.UltraExpandableGroupBoxPanel1.Controls.Add(Me.UltraPanel1)
+ Me.UltraExpandableGroupBoxPanel1.Dock = System.Windows.Forms.DockStyle.Fill
+ Me.UltraExpandableGroupBoxPanel1.Location = New System.Drawing.Point(2, 22)
+ Me.UltraExpandableGroupBoxPanel1.Name = "UltraExpandableGroupBoxPanel1"
+ Me.UltraExpandableGroupBoxPanel1.Size = New System.Drawing.Size(1009, 129)
+ Me.UltraExpandableGroupBoxPanel1.TabIndex = 0
+ '
+ 'UltraPanel1
+ '
+ '
+ 'UltraPanel1.ClientArea
+ '
+ Me.UltraPanel1.ClientArea.Controls.Add(Me.gbxLotInfo)
+ Me.UltraPanel1.Dock = System.Windows.Forms.DockStyle.Fill
+ Me.UltraPanel1.Location = New System.Drawing.Point(0, 0)
+ Me.UltraPanel1.Name = "UltraPanel1"
+ Me.UltraPanel1.Size = New System.Drawing.Size(1009, 129)
+ Me.UltraPanel1.TabIndex = 0
+ '
+ 'gbxLotInfo
+ '
+ Me.gbxLotInfo.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.gbxLotInfo.Controls.Add(Me.txtOpName)
+ Me.gbxLotInfo.Controls.Add(Me.txtOPNo)
+ Me.gbxLotInfo.Controls.Add(Me.txtProductNo)
+ Me.gbxLotInfo.Controls.Add(Me.txtCustomerLotNo)
+ Me.gbxLotInfo.Controls.Add(Me.txtMONo)
+ Me.gbxLotInfo.Controls.Add(Me.txtShiftNo)
+ Me.gbxLotInfo.Controls.Add(Me.txtEmployeeNo)
+ Me.gbxLotInfo.Controls.Add(Me.txtAreaNo)
+ Me.gbxLotInfo.Controls.Add(Me.txtPriority)
+ Me.gbxLotInfo.Controls.Add(Me.txtSysUnitNo)
+ Me.gbxLotInfo.Controls.Add(Me.txtSysQty)
+ Me.gbxLotInfo.Controls.Add(Me.txtCurUnitNo)
+ Me.gbxLotInfo.Controls.Add(Me.txtCurQty)
+ Me.gbxLotInfo.Controls.Add(Me.txtOPDescription)
+ Me.gbxLotInfo.Controls.Add(Me.txtLotNo)
+ Me.gbxLotInfo.Controls.Add(Me.lblPriority)
+ Me.gbxLotInfo.Controls.Add(Me.lblMONo)
+ Me.gbxLotInfo.Controls.Add(Me.lblShiftNo)
+ Me.gbxLotInfo.Controls.Add(Me.lblOPNo)
+ Me.gbxLotInfo.Controls.Add(Me.lblAreaNo)
+ Me.gbxLotInfo.Controls.Add(Me.lblSysQty)
+ Me.gbxLotInfo.Controls.Add(Me.lblCurQty)
+ Me.gbxLotInfo.Controls.Add(Me.lblProductNo)
+ Me.gbxLotInfo.Controls.Add(Me.lblOPDescription)
+ Me.gbxLotInfo.Controls.Add(Me.lblCustomerLotNo)
+ Me.gbxLotInfo.Controls.Add(Me.lblEmployeeNo)
+ Me.gbxLotInfo.Controls.Add(Me.lblLotNo)
+ Me.gbxLotInfo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.gbxLotInfo.Location = New System.Drawing.Point(0, 0)
+ Me.gbxLotInfo.Name = "gbxLotInfo"
+ Me.gbxLotInfo.Size = New System.Drawing.Size(1009, 125)
+ Me.gbxLotInfo.TabIndex = 0
+ Me.gbxLotInfo.TabStop = False
+ '
+ 'txtOpName
+ '
+ Me.txtOpName.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.txtOpName.Location = New System.Drawing.Point(743, 69)
+ Me.txtOpName.Name = "txtOpName"
+ Me.txtOpName.ReadOnly = True
+ Me.txtOpName.Size = New System.Drawing.Size(259, 22)
+ Me.txtOpName.TabIndex = 109
+ '
+ 'txtOPNo
+ '
+ Me.txtOPNo.Location = New System.Drawing.Point(609, 69)
+ Me.txtOPNo.Name = "txtOPNo"
+ Me.txtOPNo.ReadOnly = True
+ Me.txtOPNo.Size = New System.Drawing.Size(137, 22)
+ Me.txtOPNo.TabIndex = 7
+ '
+ 'txtProductNo
+ '
+ Me.txtProductNo.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.txtProductNo.Location = New System.Drawing.Point(609, 42)
+ Me.txtProductNo.Name = "txtProductNo"
+ Me.txtProductNo.ReadOnly = True
+ Me.txtProductNo.Size = New System.Drawing.Size(188, 22)
+ Me.txtProductNo.TabIndex = 13
+ '
+ 'txtCustomerLotNo
+ '
+ Me.txtCustomerLotNo.Location = New System.Drawing.Point(87, 42)
+ Me.txtCustomerLotNo.Name = "txtCustomerLotNo"
+ Me.txtCustomerLotNo.ReadOnly = True
+ Me.txtCustomerLotNo.Size = New System.Drawing.Size(179, 22)
+ Me.txtCustomerLotNo.TabIndex = 8
+ '
+ 'txtMONo
+ '
+ Me.txtMONo.Location = New System.Drawing.Point(341, 42)
+ Me.txtMONo.Name = "txtMONo"
+ Me.txtMONo.ReadOnly = True
+ Me.txtMONo.Size = New System.Drawing.Size(179, 22)
+ Me.txtMONo.TabIndex = 9
+ '
+ 'txtShiftNo
+ '
+ Me.txtShiftNo.Location = New System.Drawing.Point(341, 69)
+ Me.txtShiftNo.Name = "txtShiftNo"
+ Me.txtShiftNo.ReadOnly = True
+ Me.txtShiftNo.Size = New System.Drawing.Size(179, 22)
+ Me.txtShiftNo.TabIndex = 15
+ '
+ 'txtEmployeeNo
+ '
+ Me.txtEmployeeNo.Location = New System.Drawing.Point(87, 69)
+ Me.txtEmployeeNo.Name = "txtEmployeeNo"
+ Me.txtEmployeeNo.ReadOnly = True
+ Me.txtEmployeeNo.Size = New System.Drawing.Size(179, 22)
+ Me.txtEmployeeNo.TabIndex = 12
+ '
+ 'txtAreaNo
+ '
+ Me.txtAreaNo.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.txtAreaNo.Location = New System.Drawing.Point(609, 15)
+ Me.txtAreaNo.Name = "txtAreaNo"
+ Me.txtAreaNo.ReadOnly = True
+ Me.txtAreaNo.Size = New System.Drawing.Size(188, 22)
+ Me.txtAreaNo.TabIndex = 2
+ '
+ 'txtPriority
+ '
+ Me.txtPriority.Location = New System.Drawing.Point(341, 15)
+ Me.txtPriority.Name = "txtPriority"
+ Me.txtPriority.ReadOnly = True
+ Me.txtPriority.Size = New System.Drawing.Size(179, 22)
+ Me.txtPriority.TabIndex = 1
+ '
+ 'txtSysUnitNo
+ '
+ Me.txtSysUnitNo.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.txtSysUnitNo.Location = New System.Drawing.Point(962, 42)
+ Me.txtSysUnitNo.Name = "txtSysUnitNo"
+ Me.txtSysUnitNo.ReadOnly = True
+ Me.txtSysUnitNo.Size = New System.Drawing.Size(40, 22)
+ Me.txtSysUnitNo.TabIndex = 9
+ '
+ 'txtSysQty
+ '
+ Me.txtSysQty.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.txtSysQty.Location = New System.Drawing.Point(860, 42)
+ Me.txtSysQty.Name = "txtSysQty"
+ Me.txtSysQty.ReadOnly = True
+ Me.txtSysQty.Size = New System.Drawing.Size(102, 22)
+ Me.txtSysQty.TabIndex = 8
+ '
+ 'txtCurUnitNo
+ '
+ Me.txtCurUnitNo.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.txtCurUnitNo.Location = New System.Drawing.Point(962, 15)
+ Me.txtCurUnitNo.Name = "txtCurUnitNo"
+ Me.txtCurUnitNo.ReadOnly = True
+ Me.txtCurUnitNo.Size = New System.Drawing.Size(40, 22)
+ Me.txtCurUnitNo.TabIndex = 4
+ '
+ 'txtCurQty
+ '
+ Me.txtCurQty.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.txtCurQty.Location = New System.Drawing.Point(860, 15)
+ Me.txtCurQty.Name = "txtCurQty"
+ Me.txtCurQty.ReadOnly = True
+ Me.txtCurQty.Size = New System.Drawing.Size(102, 22)
+ Me.txtCurQty.TabIndex = 3
+ '
+ 'txtOPDescription
+ '
+ Me.txtOPDescription.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.txtOPDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.txtOPDescription.Location = New System.Drawing.Point(87, 96)
+ Me.txtOPDescription.Name = "txtOPDescription"
+ Me.txtOPDescription.ReadOnly = True
+ Me.txtOPDescription.Size = New System.Drawing.Size(915, 22)
+ Me.txtOPDescription.TabIndex = 10
+ '
+ 'txtLotNo
+ '
+ Me.txtLotNo.Location = New System.Drawing.Point(87, 15)
+ Me.txtLotNo.Name = "txtLotNo"
+ Me.txtLotNo.ReadOnly = True
+ Me.txtLotNo.Size = New System.Drawing.Size(179, 22)
+ Me.txtLotNo.TabIndex = 0
+ '
+ 'lblPriority
+ '
+ Me.lblPriority.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblPriority.Location = New System.Drawing.Point(271, 18)
+ Me.lblPriority.Name = "lblPriority"
+ Me.lblPriority.Size = New System.Drawing.Size(64, 15)
+ Me.lblPriority.TabIndex = 85
+ Me.lblPriority.Text = "Priority"
+ Me.lblPriority.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'lblMONo
+ '
+ Me.lblMONo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblMONo.Location = New System.Drawing.Point(271, 45)
+ Me.lblMONo.Name = "lblMONo"
+ Me.lblMONo.Size = New System.Drawing.Size(64, 15)
+ Me.lblMONo.TabIndex = 83
+ Me.lblMONo.Text = "MONo"
+ Me.lblMONo.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'lblShiftNo
+ '
+ Me.lblShiftNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblShiftNo.Location = New System.Drawing.Point(271, 72)
+ Me.lblShiftNo.Name = "lblShiftNo"
+ Me.lblShiftNo.Size = New System.Drawing.Size(64, 15)
+ Me.lblShiftNo.TabIndex = 79
+ Me.lblShiftNo.Text = "Shift No"
+ Me.lblShiftNo.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'lblOPNo
+ '
+ Me.lblOPNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblOPNo.Location = New System.Drawing.Point(527, 72)
+ Me.lblOPNo.Name = "lblOPNo"
+ Me.lblOPNo.Size = New System.Drawing.Size(75, 15)
+ Me.lblOPNo.TabIndex = 75
+ Me.lblOPNo.Text = "OP No"
+ Me.lblOPNo.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'lblAreaNo
+ '
+ Me.lblAreaNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblAreaNo.Location = New System.Drawing.Point(527, 18)
+ Me.lblAreaNo.Name = "lblAreaNo"
+ Me.lblAreaNo.Size = New System.Drawing.Size(75, 15)
+ Me.lblAreaNo.TabIndex = 71
+ Me.lblAreaNo.Text = "Area No"
+ Me.lblAreaNo.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'lblSysQty
+ '
+ Me.lblSysQty.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.lblSysQty.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblSysQty.Location = New System.Drawing.Point(790, 45)
+ Me.lblSysQty.Name = "lblSysQty"
+ Me.lblSysQty.Size = New System.Drawing.Size(64, 15)
+ Me.lblSysQty.TabIndex = 68
+ Me.lblSysQty.Text = "Sys Qty"
+ Me.lblSysQty.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'lblCurQty
+ '
+ Me.lblCurQty.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.lblCurQty.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblCurQty.Location = New System.Drawing.Point(790, 18)
+ Me.lblCurQty.Name = "lblCurQty"
+ Me.lblCurQty.Size = New System.Drawing.Size(64, 15)
+ Me.lblCurQty.TabIndex = 64
+ Me.lblCurQty.Text = "Cur Qty"
+ Me.lblCurQty.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'lblProductNo
+ '
+ Me.lblProductNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblProductNo.Location = New System.Drawing.Point(527, 45)
+ Me.lblProductNo.Name = "lblProductNo"
+ Me.lblProductNo.Size = New System.Drawing.Size(75, 15)
+ Me.lblProductNo.TabIndex = 107
+ Me.lblProductNo.Text = "Product No"
+ Me.lblProductNo.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'lblOPDescription
+ '
+ Me.lblOPDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblOPDescription.Location = New System.Drawing.Point(3, 97)
+ Me.lblOPDescription.Name = "lblOPDescription"
+ Me.lblOPDescription.Size = New System.Drawing.Size(80, 15)
+ Me.lblOPDescription.TabIndex = 108
+ Me.lblOPDescription.Text = "OP Description"
+ Me.lblOPDescription.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'lblCustomerLotNo
+ '
+ Me.lblCustomerLotNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblCustomerLotNo.Location = New System.Drawing.Point(3, 45)
+ Me.lblCustomerLotNo.Name = "lblCustomerLotNo"
+ Me.lblCustomerLotNo.Size = New System.Drawing.Size(80, 15)
+ Me.lblCustomerLotNo.TabIndex = 81
+ Me.lblCustomerLotNo.Text = "Customer Lot No"
+ Me.lblCustomerLotNo.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'lblEmployeeNo
+ '
+ Me.lblEmployeeNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblEmployeeNo.Location = New System.Drawing.Point(3, 72)
+ Me.lblEmployeeNo.Name = "lblEmployeeNo"
+ Me.lblEmployeeNo.Size = New System.Drawing.Size(80, 15)
+ Me.lblEmployeeNo.TabIndex = 73
+ Me.lblEmployeeNo.Text = "Employee No"
+ Me.lblEmployeeNo.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'lblLotNo
+ '
+ Me.lblLotNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblLotNo.Location = New System.Drawing.Point(3, 18)
+ Me.lblLotNo.Name = "lblLotNo"
+ Me.lblLotNo.Size = New System.Drawing.Size(80, 15)
+ Me.lblLotNo.TabIndex = 62
+ Me.lblLotNo.Text = "Lot No"
+ Me.lblLotNo.TextAlign = System.Drawing.ContentAlignment.MiddleRight
+ '
+ 'UltraTabPageControl2
+ '
+ Me.UltraTabPageControl2.Location = New System.Drawing.Point(-10000, -10000)
+ Me.UltraTabPageControl2.Name = "UltraTabPageControl2"
+ Me.UltraTabPageControl2.Size = New System.Drawing.Size(340, 100)
+ '
+ 'UltraTabPageControl1
+ '
+ Me.UltraTabPageControl1.Location = New System.Drawing.Point(-10000, -10000)
+ Me.UltraTabPageControl1.Name = "UltraTabPageControl1"
+ Me.UltraTabPageControl1.Size = New System.Drawing.Size(340, 100)
+ '
+ 'SBar1
+ '
+ Me.SBar1.Font = New System.Drawing.Font("Times New Roman", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.SBar1.Location = New System.Drawing.Point(0, 707)
+ Me.SBar1.Name = "SBar1"
+ Me.SBar1.Panels.AddRange(New System.Windows.Forms.StatusBarPanel() {Me.SBarPanel1, Me.SBarPanel2, Me.SBarPanel3, Me.SBarPanel4})
+ Me.SBar1.ShowPanels = True
+ Me.SBar1.Size = New System.Drawing.Size(1008, 22)
+ Me.SBar1.TabIndex = 68
+ '
+ 'SBarPanel1
+ '
+ Me.SBarPanel1.Name = "SBarPanel1"
+ '
+ 'SBarPanel2
+ '
+ Me.SBarPanel2.Name = "SBarPanel2"
+ '
+ 'SBarPanel3
+ '
+ Me.SBarPanel3.AutoSize = System.Windows.Forms.StatusBarPanelAutoSize.Spring
+ Me.SBarPanel3.Name = "SBarPanel3"
+ Me.SBarPanel3.Width = 641
+ '
+ 'SBarPanel4
+ '
+ Me.SBarPanel4.Alignment = System.Windows.Forms.HorizontalAlignment.Right
+ Me.SBarPanel4.Name = "SBarPanel4"
+ Me.SBarPanel4.Width = 150
+ '
+ 'iugAttrib
+ '
+ Me.iugAttrib.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
+ Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.iugAttrib.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
+ Me.iugAttrib.GroupBoxPromptText = "Drag a column header here to group by that column."
+ Me.iugAttrib.GroupBoxTextForeColor = System.Drawing.Color.Red
+ Me.iugAttrib.Identity = "IMes"
+ Me.iugAttrib.IdentityForm = ""
+ Me.iugAttrib.LayOutFilePath = ""
+ Me.iugAttrib.Location = New System.Drawing.Point(4, 3)
+ Me.iugAttrib.Name = "iugAttrib"
+ Me.iugAttrib.PrintFitWidthToPages = 0
+ Me.iugAttrib.PrintLandscape = True
+ Me.iugAttrib.PrintPageFooter = ""
+ Me.iugAttrib.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
+ Me.iugAttrib.PrintPageFooterHeight = 20
+ Me.iugAttrib.PrintPageHeader = ""
+ Me.iugAttrib.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
+ Me.iugAttrib.PrintPageHeaderHeight = 20
+ Me.iugAttrib.PrintZoom = 1.0R
+ Me.iugAttrib.Size = New System.Drawing.Size(506, 214)
+ Me.iugAttrib.TabIndex = 105
+ Me.iugAttrib.UserNo = "IMes"
+ '
+ 'iugEquipment
+ '
+ Me.iugEquipment.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
+ Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.iugEquipment.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
+ Me.iugEquipment.GroupBoxPromptText = "Drag a column header here to group by that column."
+ Me.iugEquipment.GroupBoxTextForeColor = System.Drawing.Color.Red
+ Me.iugEquipment.Identity = "IMes"
+ Me.iugEquipment.IdentityForm = ""
+ Me.iugEquipment.LayOutFilePath = ""
+ Me.iugEquipment.Location = New System.Drawing.Point(3, 46)
+ Me.iugEquipment.Name = "iugEquipment"
+ Me.iugEquipment.PrintFitWidthToPages = 0
+ Me.iugEquipment.PrintLandscape = True
+ Me.iugEquipment.PrintPageFooter = ""
+ Me.iugEquipment.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
+ Me.iugEquipment.PrintPageFooterHeight = 20
+ Me.iugEquipment.PrintPageHeader = ""
+ Me.iugEquipment.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
+ Me.iugEquipment.PrintPageHeaderHeight = 20
+ Me.iugEquipment.PrintZoom = 1.0R
+ Me.iugEquipment.Size = New System.Drawing.Size(477, 171)
+ Me.iugEquipment.TabIndex = 107
+ Me.iugEquipment.UserNo = "IMes"
+ '
+ 'btnClose
+ '
+ Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.btnClose.Location = New System.Drawing.Point(925, 673)
+ Me.btnClose.Name = "btnClose"
+ Me.btnClose.Size = New System.Drawing.Size(80, 32)
+ Me.btnClose.TabIndex = 144
+ Me.btnClose.Text = "Close"
+ '
+ 'btnConfirm
+ '
+ Me.btnConfirm.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.btnConfirm.Location = New System.Drawing.Point(839, 673)
+ Me.btnConfirm.Name = "btnConfirm"
+ Me.btnConfirm.Size = New System.Drawing.Size(80, 32)
+ Me.btnConfirm.TabIndex = 143
+ Me.btnConfirm.Text = "Confirm"
+ '
+ 'lblEquipmentNo
+ '
+ Me.lblEquipmentNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblEquipmentNo.Location = New System.Drawing.Point(20, 16)
+ Me.lblEquipmentNo.Name = "lblEquipmentNo"
+ Me.lblEquipmentNo.Size = New System.Drawing.Size(80, 16)
+ Me.lblEquipmentNo.TabIndex = 147
+ Me.lblEquipmentNo.Text = "Equipment No"
+ '
+ 'txtEquipmentNo
+ '
+ Me.txtEquipmentNo.Location = New System.Drawing.Point(106, 12)
+ Me.txtEquipmentNo.Name = "txtEquipmentNo"
+ Me.txtEquipmentNo.Size = New System.Drawing.Size(132, 22)
+ Me.txtEquipmentNo.TabIndex = 17
+ '
+ 'lblLotRecord
+ '
+ Me.lblLotRecord.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
+ Me.lblLotRecord.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblLotRecord.Location = New System.Drawing.Point(16, 634)
+ Me.lblLotRecord.Name = "lblLotRecord"
+ Me.lblLotRecord.Size = New System.Drawing.Size(64, 16)
+ Me.lblLotRecord.TabIndex = 145
+ Me.lblLotRecord.Text = "Lot Record"
+ '
+ 'txtLotRecord
+ '
+ Me.txtLotRecord.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
+ Me.txtLotRecord.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.txtLotRecord.Location = New System.Drawing.Point(88, 634)
+ Me.txtLotRecord.Name = "txtLotRecord"
+ Me.txtLotRecord.Size = New System.Drawing.Size(393, 35)
+ Me.txtLotRecord.TabIndex = 18
+ Me.txtLotRecord.Text = ""
+ '
+ 'lblupdcheckintime
+ '
+ Me.lblupdcheckintime.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
+ Me.lblupdcheckintime.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.lblupdcheckintime.Location = New System.Drawing.Point(8, 683)
+ Me.lblupdcheckintime.Name = "lblupdcheckintime"
+ Me.lblupdcheckintime.Size = New System.Drawing.Size(116, 14)
+ Me.lblupdcheckintime.TabIndex = 62
+ Me.lblupdcheckintime.Text = "Update CheckIn Time"
+ '
+ 'dtpcheckintime
+ '
+ Me.dtpcheckintime.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
+ Me.dtpcheckintime.CustomFormat = "yyyy/MM/dd HH:mm:ss"
+ Me.dtpcheckintime.Format = System.Windows.Forms.DateTimePickerFormat.Custom
+ Me.dtpcheckintime.Location = New System.Drawing.Point(152, 682)
+ Me.dtpcheckintime.Name = "dtpcheckintime"
+ Me.dtpcheckintime.Size = New System.Drawing.Size(128, 21)
+ Me.dtpcheckintime.TabIndex = 151
+ '
+ 'btnEQPConsumeReset
+ '
+ Me.btnEQPConsumeReset.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.btnEQPConsumeReset.Location = New System.Drawing.Point(282, 7)
+ Me.btnEQPConsumeReset.Name = "btnEQPConsumeReset"
+ Me.btnEQPConsumeReset.Size = New System.Drawing.Size(112, 32)
+ Me.btnEQPConsumeReset.TabIndex = 152
+ Me.btnEQPConsumeReset.Text = "EQPConsumeReset"
+ '
+ 'btnQCList
+ '
+ Me.btnQCList.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.btnQCList.Location = New System.Drawing.Point(400, 7)
+ Me.btnQCList.Name = "btnQCList"
+ Me.btnQCList.Size = New System.Drawing.Size(80, 32)
+ Me.btnQCList.TabIndex = 153
+ Me.btnQCList.Text = "QC List"
+ '
+ 'utpEquipment
+ '
+ Me.utpEquipment.Controls.Add(Me.IMESUltraGrid3)
+ Me.utpEquipment.Location = New System.Drawing.Point(-10000, -10000)
+ Me.utpEquipment.Name = "utpEquipment"
+ Me.utpEquipment.Size = New System.Drawing.Size(772, 150)
+ '
+ 'IMESUltraGrid3
+ '
+ Me.IMESUltraGrid3.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.IMESUltraGrid3.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
+ Me.IMESUltraGrid3.GroupBoxPromptText = "Drag a column header here to group by that column."
+ Me.IMESUltraGrid3.GroupBoxTextForeColor = System.Drawing.Color.Red
+ Me.IMESUltraGrid3.Identity = "IMes"
+ Me.IMESUltraGrid3.IdentityForm = ""
+ Me.IMESUltraGrid3.LayOutFilePath = ""
+ Me.IMESUltraGrid3.Location = New System.Drawing.Point(11, 8)
+ Me.IMESUltraGrid3.Name = "IMESUltraGrid3"
+ Me.IMESUltraGrid3.PrintFitWidthToPages = 0
+ Me.IMESUltraGrid3.PrintLandscape = True
+ Me.IMESUltraGrid3.PrintPageFooter = ""
+ Me.IMESUltraGrid3.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
+ Me.IMESUltraGrid3.PrintPageFooterHeight = 20
+ Me.IMESUltraGrid3.PrintPageHeader = ""
+ Me.IMESUltraGrid3.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
+ Me.IMESUltraGrid3.PrintPageHeaderHeight = 20
+ Me.IMESUltraGrid3.PrintZoom = 1.0R
+ Me.IMESUltraGrid3.Size = New System.Drawing.Size(753, 136)
+ Me.IMESUltraGrid3.TabIndex = 0
+ Me.IMESUltraGrid3.UserNo = "IMes"
+ '
+ 'btnMultiUser
+ '
+ Me.btnMultiUser.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
+ Me.btnMultiUser.Location = New System.Drawing.Point(398, 673)
+ Me.btnMultiUser.Name = "btnMultiUser"
+ Me.btnMultiUser.Size = New System.Drawing.Size(80, 32)
+ Me.btnMultiUser.TabIndex = 155
+ Me.btnMultiUser.Text = "Multi User"
+ Me.btnMultiUser.Visible = False
+ '
+ 'btnOperator
+ '
+ Me.btnOperator.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
+ Me.btnOperator.Location = New System.Drawing.Point(315, 673)
+ Me.btnOperator.Name = "btnOperator"
+ Me.btnOperator.Size = New System.Drawing.Size(80, 32)
+ Me.btnOperator.TabIndex = 156
+ Me.btnOperator.Text = "Operator"
+ Me.btnOperator.Visible = False
+ '
+ 'chkUpdCheckInTime
+ '
+ Me.chkUpdCheckInTime.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
+ Me.chkUpdCheckInTime.AutoSize = True
+ Me.chkUpdCheckInTime.Location = New System.Drawing.Point(130, 683)
+ Me.chkUpdCheckInTime.Name = "chkUpdCheckInTime"
+ Me.chkUpdCheckInTime.Size = New System.Drawing.Size(15, 14)
+ Me.chkUpdCheckInTime.TabIndex = 157
+ '
+ 'btnSWR
+ '
+ Me.btnSWR.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.btnSWR.Location = New System.Drawing.Point(753, 673)
+ Me.btnSWR.Name = "btnSWR"
+ Me.btnSWR.Size = New System.Drawing.Size(80, 32)
+ Me.btnSWR.TabIndex = 158
+ Me.btnSWR.Text = "SWR"
+ '
+ 'uplAttrib
+ '
+ '
+ 'uplAttrib.ClientArea
+ '
+ Me.uplAttrib.ClientArea.Controls.Add(Me.iugAttrib)
+ Me.uplAttrib.Dock = System.Windows.Forms.DockStyle.Left
+ Me.uplAttrib.Location = New System.Drawing.Point(0, 0)
+ Me.uplAttrib.Name = "uplAttrib"
+ Me.uplAttrib.Size = New System.Drawing.Size(515, 220)
+ Me.uplAttrib.TabIndex = 0
+ '
+ 'uplEquipment
+ '
+ '
+ 'uplEquipment.ClientArea
+ '
+ Me.uplEquipment.ClientArea.Controls.Add(Me.lblEquipmentNo)
+ Me.uplEquipment.ClientArea.Controls.Add(Me.iugEquipment)
+ Me.uplEquipment.ClientArea.Controls.Add(Me.txtEquipmentNo)
+ Me.uplEquipment.ClientArea.Controls.Add(Me.btnEQPConsumeReset)
+ Me.uplEquipment.ClientArea.Controls.Add(Me.btnQCList)
+ Me.uplEquipment.Dock = System.Windows.Forms.DockStyle.Fill
+ Me.uplEquipment.Location = New System.Drawing.Point(522, 0)
+ Me.uplEquipment.Name = "uplEquipment"
+ Me.uplEquipment.Size = New System.Drawing.Size(487, 220)
+ Me.uplEquipment.TabIndex = 1
+ '
+ 'uplAttrib_Equipment
+ '
+ '
+ 'uplAttrib_Equipment.ClientArea
+ '
+ Me.uplAttrib_Equipment.ClientArea.Controls.Add(Me.uplEquipment)
+ Me.uplAttrib_Equipment.ClientArea.Controls.Add(Me.UltraSplitter1)
+ Me.uplAttrib_Equipment.ClientArea.Controls.Add(Me.uplAttrib)
+ Me.uplAttrib_Equipment.Dock = System.Windows.Forms.DockStyle.Fill
+ Me.uplAttrib_Equipment.Location = New System.Drawing.Point(0, 0)
+ Me.uplAttrib_Equipment.Name = "uplAttrib_Equipment"
+ Me.uplAttrib_Equipment.Size = New System.Drawing.Size(1009, 220)
+ Me.uplAttrib_Equipment.TabIndex = 162
+ '
+ 'UltraSplitter1
+ '
+ Me.UltraSplitter1.Location = New System.Drawing.Point(515, 0)
+ Me.UltraSplitter1.Name = "UltraSplitter1"
+ Me.UltraSplitter1.RestoreExtent = 479
+ Me.UltraSplitter1.Size = New System.Drawing.Size(7, 220)
+ Me.UltraSplitter1.TabIndex = 1
+ '
+ 'uplMaterial_KeyIn
+ '
+ '
+ 'uplMaterial_KeyIn.ClientArea
+ '
+ Me.uplMaterial_KeyIn.ClientArea.Controls.Add(Me.uplKeyIn)
+ Me.uplMaterial_KeyIn.ClientArea.Controls.Add(Me.UltraSplitter2)
+ Me.uplMaterial_KeyIn.ClientArea.Controls.Add(Me.uplMaterial)
+ Me.uplMaterial_KeyIn.Dock = System.Windows.Forms.DockStyle.Fill
+ Me.uplMaterial_KeyIn.Location = New System.Drawing.Point(0, 0)
+ Me.uplMaterial_KeyIn.Name = "uplMaterial_KeyIn"
+ Me.uplMaterial_KeyIn.Size = New System.Drawing.Size(1009, 216)
+ Me.uplMaterial_KeyIn.TabIndex = 0
+ '
+ 'uplKeyIn
+ '
+ '
+ 'uplKeyIn.ClientArea
+ '
+ Me.uplKeyIn.ClientArea.Controls.Add(Me.iugKeyIn)
+ Me.uplKeyIn.Dock = System.Windows.Forms.DockStyle.Fill
+ Me.uplKeyIn.Location = New System.Drawing.Point(522, 0)
+ Me.uplKeyIn.Name = "uplKeyIn"
+ Me.uplKeyIn.Size = New System.Drawing.Size(487, 216)
+ Me.uplKeyIn.TabIndex = 4
+ '
+ 'iugKeyIn
+ '
+ Me.iugKeyIn.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
+ Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.iugKeyIn.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
+ Me.iugKeyIn.GroupBoxPromptText = "Drag a column header here to group by that column."
+ Me.iugKeyIn.GroupBoxTextForeColor = System.Drawing.Color.Red
+ Me.iugKeyIn.Identity = "IMes"
+ Me.iugKeyIn.IdentityForm = ""
+ Me.iugKeyIn.LayOutFilePath = ""
+ Me.iugKeyIn.Location = New System.Drawing.Point(3, 3)
+ Me.iugKeyIn.Name = "iugKeyIn"
+ Me.iugKeyIn.PrintFitWidthToPages = 0
+ Me.iugKeyIn.PrintLandscape = True
+ Me.iugKeyIn.PrintPageFooter = ""
+ Me.iugKeyIn.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
+ Me.iugKeyIn.PrintPageFooterHeight = 20
+ Me.iugKeyIn.PrintPageHeader = ""
+ Me.iugKeyIn.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
+ Me.iugKeyIn.PrintPageHeaderHeight = 20
+ Me.iugKeyIn.PrintZoom = 1.0R
+ Me.iugKeyIn.Size = New System.Drawing.Size(477, 207)
+ Me.iugKeyIn.TabIndex = 150
+ Me.iugKeyIn.UserNo = "IMes"
+ '
+ 'UltraSplitter2
+ '
+ Me.UltraSplitter2.Location = New System.Drawing.Point(515, 0)
+ Me.UltraSplitter2.Name = "UltraSplitter2"
+ Me.UltraSplitter2.RestoreExtent = 479
+ Me.UltraSplitter2.Size = New System.Drawing.Size(7, 216)
+ Me.UltraSplitter2.TabIndex = 3
+ '
+ 'uplMaterial
+ '
+ '
+ 'uplMaterial.ClientArea
+ '
+ Me.uplMaterial.ClientArea.Controls.Add(Me.UltraTabControl1)
+ Me.uplMaterial.Dock = System.Windows.Forms.DockStyle.Left
+ Me.uplMaterial.Location = New System.Drawing.Point(0, 0)
+ Me.uplMaterial.Name = "uplMaterial"
+ Me.uplMaterial.Size = New System.Drawing.Size(515, 216)
+ Me.uplMaterial.TabIndex = 0
+ '
+ 'UltraTabControl1
+ '
+ Me.UltraTabControl1.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
+ Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ Me.UltraTabControl1.Controls.Add(Me.utpMaterial)
+ Me.UltraTabControl1.Controls.Add(Me.UltraTabSharedControlsPage1)
+ Me.UltraTabControl1.Controls.Add(Me.utpSubOP)
+ Me.UltraTabControl1.Location = New System.Drawing.Point(0, 0)
+ Me.UltraTabControl1.Name = "UltraTabControl1"
+ Me.UltraTabControl1.SharedControlsPage = Me.UltraTabSharedControlsPage1
+ Me.UltraTabControl1.Size = New System.Drawing.Size(515, 213)
+ Me.UltraTabControl1.TabIndex = 154
+ Me.UltraTabControl1.TabLayoutStyle = Infragistics.Win.UltraWinTabs.TabLayoutStyle.MultiRowTabsPerRow
+ UltraTab1.FixedWidth = 120
+ UltraTab1.TabPage = Me.utpMaterial
+ UltraTab1.Text = "Material"
+ UltraTab4.TabPage = Me.utpSubOP
+ UltraTab4.Text = "Sub OP"
+ Me.UltraTabControl1.Tabs.AddRange(New Infragistics.Win.UltraWinTabControl.UltraTab() {UltraTab1, UltraTab4})
+ '
+ 'UltraTabSharedControlsPage1
+ '
+ Me.UltraTabSharedControlsPage1.Location = New System.Drawing.Point(-10000, -10000)
+ Me.UltraTabSharedControlsPage1.Name = "UltraTabSharedControlsPage1"
+ Me.UltraTabSharedControlsPage1.Size = New System.Drawing.Size(511, 187)
+ '
+ 'uplAll
+ '
+ Me.uplAll.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
+ Or System.Windows.Forms.AnchorStyles.Left) _
+ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
+ '
+ 'uplAll.ClientArea
+ '
+ Me.uplAll.ClientArea.Controls.Add(Me.uegMaterial_KeyIn2)
+ Me.uplAll.ClientArea.Controls.Add(Me.uegAttrib_Equipment)
+ Me.uplAll.ClientArea.Controls.Add(Me.uegLotInfo)
+ Me.uplAll.Location = New System.Drawing.Point(0, -1)
+ Me.uplAll.Name = "uplAll"
+ Me.uplAll.Size = New System.Drawing.Size(1013, 629)
+ Me.uplAll.TabIndex = 165
+ '
+ 'uegMaterial_KeyIn2
+ '
+ Me.uegMaterial_KeyIn2.Controls.Add(Me.UltraExpandableGroupBoxPanel4)
+ Me.uegMaterial_KeyIn2.Dock = System.Windows.Forms.DockStyle.Fill
+ Me.uegMaterial_KeyIn2.ExpandedSize = New System.Drawing.Size(1013, 236)
+ Me.uegMaterial_KeyIn2.Location = New System.Drawing.Point(0, 393)
+ Me.uegMaterial_KeyIn2.Name = "uegMaterial_KeyIn2"
+ Me.uegMaterial_KeyIn2.Size = New System.Drawing.Size(1013, 236)
+ Me.uegMaterial_KeyIn2.TabIndex = 163
+ Me.uegMaterial_KeyIn2.ViewStyle = Infragistics.Win.Misc.GroupBoxViewStyle.Office2003
+ '
+ 'UltraExpandableGroupBoxPanel4
+ '
+ Me.UltraExpandableGroupBoxPanel4.Controls.Add(Me.UltraPanel4)
+ Me.UltraExpandableGroupBoxPanel4.Dock = System.Windows.Forms.DockStyle.Fill
+ Me.UltraExpandableGroupBoxPanel4.Location = New System.Drawing.Point(2, 18)
+ Me.UltraExpandableGroupBoxPanel4.Name = "UltraExpandableGroupBoxPanel4"
+ Me.UltraExpandableGroupBoxPanel4.Size = New System.Drawing.Size(1009, 216)
+ Me.UltraExpandableGroupBoxPanel4.TabIndex = 0
+ '
+ 'UltraPanel4
+ '
+ '
+ 'UltraPanel4.ClientArea
+ '
+ Me.UltraPanel4.ClientArea.Controls.Add(Me.uplMaterial_KeyIn)
+ Me.UltraPanel4.Dock = System.Windows.Forms.DockStyle.Fill
+ Me.UltraPanel4.Location = New System.Drawing.Point(0, 0)
+ Me.UltraPanel4.Name = "UltraPanel4"
+ Me.UltraPanel4.Size = New System.Drawing.Size(1009, 216)
+ Me.UltraPanel4.TabIndex = 0
+ '
+ 'uegAttrib_Equipment
+ '
+ Me.uegAttrib_Equipment.Controls.Add(Me.UltraExpandableGroupBoxPanel2)
+ Me.uegAttrib_Equipment.Dock = System.Windows.Forms.DockStyle.Top
+ Me.uegAttrib_Equipment.ExpandedSize = New System.Drawing.Size(1013, 240)
+ Me.uegAttrib_Equipment.Location = New System.Drawing.Point(0, 153)
+ Me.uegAttrib_Equipment.Name = "uegAttrib_Equipment"
+ Me.uegAttrib_Equipment.Size = New System.Drawing.Size(1013, 240)
+ Me.uegAttrib_Equipment.TabIndex = 162
+ Me.uegAttrib_Equipment.ViewStyle = Infragistics.Win.Misc.GroupBoxViewStyle.Office2003
+ '
+ 'UltraExpandableGroupBoxPanel2
+ '
+ Me.UltraExpandableGroupBoxPanel2.Controls.Add(Me.UltraPanel2)
+ Me.UltraExpandableGroupBoxPanel2.Dock = System.Windows.Forms.DockStyle.Fill
+ Me.UltraExpandableGroupBoxPanel2.Location = New System.Drawing.Point(2, 18)
+ Me.UltraExpandableGroupBoxPanel2.Name = "UltraExpandableGroupBoxPanel2"
+ Me.UltraExpandableGroupBoxPanel2.Size = New System.Drawing.Size(1009, 220)
+ Me.UltraExpandableGroupBoxPanel2.TabIndex = 0
+ '
+ 'UltraPanel2
+ '
+ '
+ 'UltraPanel2.ClientArea
+ '
+ Me.UltraPanel2.ClientArea.Controls.Add(Me.uplAttrib_Equipment)
+ Me.UltraPanel2.Dock = System.Windows.Forms.DockStyle.Fill
+ Me.UltraPanel2.Location = New System.Drawing.Point(0, 0)
+ Me.UltraPanel2.Name = "UltraPanel2"
+ Me.UltraPanel2.Size = New System.Drawing.Size(1009, 220)
+ Me.UltraPanel2.TabIndex = 0
+ '
+ 'frmBR_L_CI_GEN
+ '
+ Me.AutoScaleBaseSize = New System.Drawing.Size(5, 14)
+ Me.ClientSize = New System.Drawing.Size(1008, 729)
+ Me.Controls.Add(Me.uplAll)
+ Me.Controls.Add(Me.btnSWR)
+ Me.Controls.Add(Me.chkUpdCheckInTime)
+ Me.Controls.Add(Me.btnOperator)
+ Me.Controls.Add(Me.btnMultiUser)
+ Me.Controls.Add(Me.dtpcheckintime)
+ Me.Controls.Add(Me.txtLotRecord)
+ Me.Controls.Add(Me.lblLotRecord)
+ Me.Controls.Add(Me.btnClose)
+ Me.Controls.Add(Me.btnConfirm)
+ Me.Controls.Add(Me.SBar1)
+ Me.Controls.Add(Me.lblupdcheckintime)
+ Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
+ Me.MinimizeBox = False
+ Me.Name = "frmBR_L_CI_GEN"
+ Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
+ Me.Text = "General Check In"
+ Me.utpMaterial.ResumeLayout(False)
+ Me.utpMaterial.PerformLayout()
+ CType(Me.txtMaterialNo, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtMaterialLotNo, System.ComponentModel.ISupportInitialize).EndInit()
+ Me.utpSubOP.ResumeLayout(False)
+ CType(Me.uegLotInfo, System.ComponentModel.ISupportInitialize).EndInit()
+ Me.uegLotInfo.ResumeLayout(False)
+ Me.UltraExpandableGroupBoxPanel1.ResumeLayout(False)
+ Me.UltraPanel1.ClientArea.ResumeLayout(False)
+ Me.UltraPanel1.ResumeLayout(False)
+ Me.gbxLotInfo.ResumeLayout(False)
+ Me.gbxLotInfo.PerformLayout()
+ CType(Me.txtOpName, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtOPNo, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtProductNo, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtCustomerLotNo, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtMONo, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtShiftNo, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtEmployeeNo, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtAreaNo, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtPriority, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtSysUnitNo, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtSysQty, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtCurUnitNo, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtCurQty, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtOPDescription, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtLotNo, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.SBarPanel1, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.SBarPanel2, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.SBarPanel3, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.SBarPanel4, System.ComponentModel.ISupportInitialize).EndInit()
+ CType(Me.txtEquipmentNo, System.ComponentModel.ISupportInitialize).EndInit()
+ Me.utpEquipment.ResumeLayout(False)
+ Me.uplAttrib.ClientArea.ResumeLayout(False)
+ Me.uplAttrib.ResumeLayout(False)
+ Me.uplEquipment.ClientArea.ResumeLayout(False)
+ Me.uplEquipment.ClientArea.PerformLayout()
+ Me.uplEquipment.ResumeLayout(False)
+ Me.uplAttrib_Equipment.ClientArea.ResumeLayout(False)
+ Me.uplAttrib_Equipment.ResumeLayout(False)
+ Me.uplMaterial_KeyIn.ClientArea.ResumeLayout(False)
+ Me.uplMaterial_KeyIn.ResumeLayout(False)
+ Me.uplKeyIn.ClientArea.ResumeLayout(False)
+ Me.uplKeyIn.ResumeLayout(False)
+ Me.uplMaterial.ClientArea.ResumeLayout(False)
+ Me.uplMaterial.ResumeLayout(False)
+ CType(Me.UltraTabControl1, System.ComponentModel.ISupportInitialize).EndInit()
+ Me.UltraTabControl1.ResumeLayout(False)
+ Me.uplAll.ClientArea.ResumeLayout(False)
+ Me.uplAll.ResumeLayout(False)
+ CType(Me.uegMaterial_KeyIn2, System.ComponentModel.ISupportInitialize).EndInit()
+ Me.uegMaterial_KeyIn2.ResumeLayout(False)
+ Me.UltraExpandableGroupBoxPanel4.ResumeLayout(False)
+ Me.UltraPanel4.ClientArea.ResumeLayout(False)
+ Me.UltraPanel4.ResumeLayout(False)
+ CType(Me.uegAttrib_Equipment, System.ComponentModel.ISupportInitialize).EndInit()
+ Me.uegAttrib_Equipment.ResumeLayout(False)
+ Me.UltraExpandableGroupBoxPanel2.ResumeLayout(False)
+ Me.UltraPanel2.ClientArea.ResumeLayout(False)
+ Me.UltraPanel2.ResumeLayout(False)
+ Me.ResumeLayout(False)
+ Me.PerformLayout()
+
+ End Sub
+
+#End Region
+
+ Private Sub frmBR_L_CI_GEN_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
+
+ Cursor.Current = Cursors.WaitCursor
+
+ Dim editorSettings As New Infragistics.Win.UltraWinEditors.DefaultEditorOwnerSettings
+ editorSettings.DataType = GetType(System.DateTime)
+ editorSettings.MaskInput = "yyyy/mm/dd hh:mm:ss"
+ editor = New Infragistics.Win.DateTimeEditor(New Infragistics.Win.UltraWinEditors.DefaultEditorOwner(editorSettings))
+
+ vlMaterialLevel = COM_Utility.ValueListProvider.GetInstance.GetValueList("TBLWIPTEMP_MATERIAL", "MATERIALLEVEL")
+
+ btnConfirm.Enabled = False
+ btnMultiUser.Enabled = False
+
+ '2017/11/06 KunYuan:變更開始加工時間checkbox預設不勾選
+ chkUpdCheckInTime.Checked = False
+
+ If LotNo = defString Or UserId = defString Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%LotNo%] [%or%] [%UserId%] [%CANNOTBEEMPTY%]"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Sub
+ End If
+
+ ' 2016/01/05 YF, 左下角的時間預設為AP SERVER的時間
+ Me.datEventTime = funGetAPServerTime()
+
+ '1.取出生產批資訊 --------------------------------------------------------------------------------------------
+ If funLoadLotState() Then Exit Sub
+
+ If blnByEQP = True Then
+ txtMaterialNo.Enabled = False
+ txtMaterialLotNo.Enabled = False
+ End If
+
+ If dsWIP.Tables(tblLotState).Rows.Count = 0 Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200003", "[%LotNo%]"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Sub
+ End If
+ If funGetShift() Then Exit Sub
+ If funLoadTemp_AttribJoinBasis() Then Exit Sub
+ If funLoadTemp_Material() Then Exit Sub
+
+ txtLotNo.Text = LotNo
+ txtEmployeeNo.Text = UserId
+ Call funLotInfo_Show()
+
+ '2.機台 -------------------------------------------------------------------------------------------------------
+
+ '2023/07/25會議結論, 規格書規畫尚不清晰,此項目註解。
+ '0138119: [6.0.7]recipe配方管理优化派工--配方关联设定, 2023/07/20, 19245
+ 'Dim intAvailable As Integer
+ 'If funGetSysParameter("RMS TYPE") = "0" Then '使用舊版設備配件
+ 'intAvailable = funLoadAvailableEquipment(LotNo)
+ 'Else '使用設備配方
+ ' intAvailable = funLoadAvailableEquipmentInfo(LotNo)
+ 'End If
+
+ 'If intAvailable < 0 Then
+ If funLoadAvailableEquipment(LotNo) < 0 Then
+ Call btnClose_Click(sender, e) '清除trigger OP紀錄
+ Me.Dispose()
+ Exit Sub
+ Else
+ If EquipmentNo = defString Then
+ dsWIP.Tables(tblAreaEquipment).DefaultView.Sort = "EquipmentType, EquipmentNo"
+ Else '有指定機台,要強制使用.
+ Dim drSel As DataRow()
+ drSel = dsWIP.Tables(tblAreaEquipment).Select("EquipmentNo='" & EquipmentNo & "'")
+ If drSel.Length = 0 Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-203072", "[%EquipmentNo%]:" & EquipmentNo & " [%is not in area%]:" & txtAreaNo.Text & "!"), MsgBoxStyle.Exclamation, Me.Text)
+ Call btnClose_Click(sender, e) '清除trigger OP紀錄
+ Me.Dispose()
+ Exit Sub
+ Else
+ If drSel(0)("AllowExecute") = 1 Then '可使用
+
+ drSel(0).BeginEdit()
+ drSel(0)("CheckFlag") = True
+ If LoadPort <> defInteger Then drSel(0)("LoadPort") = LoadPort
+ drSel(0).EndEdit()
+ '強制使用機台,故不提供此功能
+ txtEquipmentNo.Enabled = False
+ Else '不可使用
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-203072", "[%EquipmentNo%]:" & EquipmentNo & " [%is not available%] " & drSel(0)("Description")), MsgBoxStyle.Exclamation, Me.Text)
+ Call btnClose_Click(sender, e) '清除trigger OP紀錄
+ Me.Dispose()
+ Exit Sub
+ End If
+ End If
+ drSel = Nothing
+ End If
+ iugEquipment.iMESUltraGrid.DataSource = dsWIP.Tables(tblAreaEquipment)
+
+ 'Modify on 2008/03/31 By OwenLiu, Auto Focus Assign EquipmentNo
+ If Not EquipmentNo.Equals(defString) Then
+ Dim ugrRow As Infragistics.Win.UltraWinGrid.UltraGridRow
+ ugrRow = FindRecordPosition(iugEquipment, "EquipmentNo", EquipmentNo)
+ If Not ugrRow Is Nothing Then
+ iugEquipment.iMESUltraGrid.ActiveRow = ugrRow
+ End If
+ End If
+
+ '2021/3/18,Ning,點檢表檢查方式已調整, 不需在此帶入點檢類型
+ ' 查詢可用設備,是否有指定點檢表,並將點檢表點檢類型帶入
+ 'Call funQueryEquipmentQCList()
+
+ '20091006 seam
+ Call Me.funLoadSubOP()
+
+ End If
+
+ '3.生產參數 -------------------------------------------------------------------------------------------------------
+ If Not dsWIP.Tables(tblTAttrib) Is Nothing Then
+ '轉換抽樣參數
+ If funGetSampleData() Then Exit Sub
+ dsWIP.Tables(tblTAttrib).DefaultView.RowFilter = "AttribSource <> 0 And AttribSource <> 1 And (AttribPhase = " & PhaseNo & " Or AttribPhase = 99)" 'Source = Not KeyIn, Not Calculate ,Current and All Phase
+ iugAttrib.iMESUltraGrid.DataSource = dsWIP.Tables(tblTAttrib).DefaultView
+ End If
+
+ '4.KeyIn Attrib ----------------------------------------------------------------------------------------------------
+ If Not dsWIP.Tables(tblTAttrib) Is Nothing Then
+ dtKeyIn = New DataTable("KeyIn")
+ dtKeyIn.DefaultView.AllowNew = False
+ dtKeyIn.DefaultView.AllowDelete = False
+ dtKeyIn.DefaultView.AllowEdit = True
+ '建立KeyIn Table的欄位
+ dtKeyIn.Columns.Add("AttribNo", System.Type.GetType("System.String"))
+ dtKeyIn.Columns.Add("AttribName", System.Type.GetType("System.String"))
+ dtKeyIn.Columns.Add("AttribValue", System.Type.GetType("System.String"))
+ dtKeyIn.Columns.Add("AttribSequence", System.Type.GetType("System.Int32"))
+ dtKeyIn.Columns.Add("InputType", System.Type.GetType("System.Int32"))
+ dtKeyIn.Columns.Add("DataType", System.Type.GetType("System.Int32"))
+ dtKeyIn.Columns.Add("ValueType", System.Type.GetType("System.Int32"))
+ dtKeyIn.Columns.Add("QCItemNo", System.Type.GetType("System.String")) '2015-12-18, Joe, Add
+ dtKeyIn.Columns.Add("OrgAttribValue", GetType(String))
+
+ '取出KeyIn Attrib
+ For Each dr As DataRow In dsWIP.Tables(tblTAttrib).Rows
+ '將資料存入KeyIn Table
+ If dr("AttribSource") = 0 AndAlso (dr("AttribPhase") = PhaseNo OrElse dr("AttribPhase") = 99) Then
+ drAdd = dtKeyIn.NewRow()
+ drAdd("AttribNo") = dr("AttribNo")
+ drAdd("AttribName") = dr("AttribName").ToString
+ drAdd("AttribSequence") = dr("AttribSequence")
+ drAdd("AttribValue") = dr("AttribValue")
+ drAdd("InputType") = dr("InputType")
+ drAdd("DataType") = dr("DataType")
+ drAdd("ValueType") = dr("ValueType")
+ drAdd("QCItemNo") = dr("QCItemNo") '2015-12-18, Joe, Add
+ drAdd("OrgAttribValue") = dr("OrgAttribValue") ' 2016/01/27 YF, 未轉換函式的特性值
+ dtKeyIn.Rows.Add(drAdd)
+ End If
+ Next
+
+ iugKeyIn.iMESUltraGrid.DataSource = dtKeyIn.DefaultView
+
+ End If
+
+ '5.物料 -----------------------------------------------------------------------------------------------------------
+ If Not dsWIP.Tables(tblTMaterial) Is Nothing Then
+ '获取当前工单的物料清单 新设备上料14278
+ Call funLoadMOMaterialList(txtMONo.Text, txtOPNo.Text)
+
+ 'Kevin 2013/1/2,加入替代料處理
+ Dim drData As DataRow
+ Dim drSelMaterialNo As DataRow()
+ For i As Integer = dsWIP.Tables(tblTMaterial).Rows.Count - 1 To 0 Step -1
+ '取得用料清單
+ If funLoadSubstituteMaterial_Main(dsWIP.Tables(tblTMaterial).Rows(i)("LotNo"), dsWIP.Tables(tblTMaterial).Rows(i)("MaterialNo"), dsWIP.Tables(tblTMaterial).Rows(i)("UnitNo")) < 0 Then Exit Sub
+ For Each dr As DataRow In dsWIP.Tables(tblSubstituteMaterial).Rows
+ drSelMaterialNo = dsWIP.Tables(tblTMaterial).Select("MaterialNo = '" & dr("MaterialNo") & "' And OrgMaterialNo = '" & dr("OrgMaterialNo") & "'")
+ If drSelMaterialNo.Length = 0 Then
+ drData = dsWIP.Tables(tblTMaterial).NewRow
+ drData("OrgMaterialNo") = dsWIP.Tables(tblTMaterial).Rows(i)("MaterialNo") '紀錄原來的主物料
+ drData("MaterialNo") = dr("MaterialNo")
+ drData("MaterialType") = dr("SubstituteMaterialType")
+ drData("MaterialLevelShow") = dr("SubstituteMaterialLevel")
+ drData("CheckLotNo") = dr("CheckLotNo")
+ drData("PutInPlaceType") = dr("SubstitutePutInPlaceType")
+ drData("StdQty") = dr("SubstituteStdQty")
+ drData("StdUseQty") = Format(dsWIP.Tables(tblLotState).Rows(0)("CurQty") * dr("SubstituteStdQty") * (1 + dsWIP.Tables(tblTMaterial).Rows(i)("DecreaseRate")), "0.######")
+ drData("DecreaseRate") = dsWIP.Tables(tblTMaterial).Rows(i)("DecreaseRate")
+ drData("UnitNo") = dsWIP.Tables(tblTMaterial).Rows(i)("UnitNo")
+ dsWIP.Tables(tblTMaterial).Rows.Add(drData)
+ End If
+ Next
+ Next
+
+ '產生MaterilaLotNo暫存表
+ dtTmpMTLLotNo = New DataTable("TmpMTLLotNo")
+ dtTmpMTLLotNo.Columns.Add("EquipmentNo", System.Type.GetType("System.String"))
+ dtTmpMTLLotNo.Columns.Add("OrgMaterialNo", System.Type.GetType("System.String"))
+ dtTmpMTLLotNo.Columns.Add("MaterialNo", System.Type.GetType("System.String"))
+ dtTmpMTLLotNo.Columns.Add("SUBSTITUTEMATERIALNO", System.Type.GetType("System.String"))
+ dtTmpMTLLotNo.Columns.Add("MaterialLotNo", System.Type.GetType("System.String"))
+ dtTmpMTLLotNo.Columns.Add("Qty", System.Type.GetType("System.Decimal"))
+ dtTmpMTLLotNo.Columns("Qty").DefaultValue = 0
+ dsWIP.Tables.Add(dtTmpMTLLotNo)
+ tblTmpMTLLotNo = "TmpMTLLotNo"
+ dsWIP.Tables(tblTmpMTLLotNo).DefaultView.Sort = "MaterialLotNo"
+
+ 'Data(Relation)
+ Dim parentCol(0) As DataColumn
+ Dim childCol(0) As DataColumn
+ parentCol(0) = dsWIP.Tables(tblTMaterial).Columns("MaterialNo")
+ childCol(0) = dsWIP.Tables(tblTmpMTLLotNo).Columns("OrgMaterialNo")
+ '建立主從關係(RelationName會影響WinForm資料的顯示)
+
+ Dim tmpRe1 As DataRelation
+ tmpRe1 = New DataRelation("MTLLotNo", parentCol, childCol, False)
+ dsWIP.Relations.Add(tmpRe1)
+
+ iugMaterial.iMESUltraGrid.DataSource = dsWIP.Tables(tblTMaterial)
+ iugMaterial.iMESUltraGrid.Rows.ExpandAll(True)
+ End If
+
+ '6.OP Description--------------------------------------------------------------------------------------------------
+ If funGetOPDescription(LotNo) Then Exit Sub
+
+ '多人加上
+ If funMultiUser() < 0 Then Exit Sub
+
+ '7.Initialize
+ Call funInitialize()
+
+ '2019/09/06 Eric 取出系統參數GumMaterialType 哪些物料是屬於固晶膠類
+ Dim strGumMaterialType As String = funLoadParameter("GumMaterialType")
+ blnGumMaterialType = (strGumMaterialType <> "")
+ aryGumMaterialType = If((strGumMaterialType <> ""), Split(strGumMaterialType, ","), {})
+
+ Call funLoadAllMaterialLot()
+
+ '8.語系切換
+ Call ExeChangeResource(Me, gLanguageMode)
+
+ txtEquipmentNo.Focus()
+ btnSWR.Visible = False
+
+ '判斷系統參數EnableSWR_CICO 0:否 1:是
+ Dim strEnableSWR_CICO As String = funLoadParameter("EnableSWR_CICO")
+ If strEnableSWR_CICO = "1" Then '系統參數EnableSWR_CICO為1才需要顯示特殊生產需求
+
+ '2019/02/12 Eric 無資料不顯示SWR視窗
+ Call funLoadSWRJoinLog()
+ If dsWIP.Tables(tblSWRJoinLog).Rows.Count > 0 Then
+
+ blnShowSWR = True
+
+ Dim Parameters As New Dictionary(Of String, Object)
+ Parameters.Add("MONo", txtMONo.Text)
+ Parameters.Add("CustomerLotNo", txtCustomerLotNo.Text)
+ Parameters.Add("OPNo", txtOPNo.Text)
+ Parameters.Add("LotNo", txtLotNo.Text)
+ Parameters.Add("DeviceNo", dsWIP.Tables(tblLotState).Rows(0)("DeviceNo").ToString)
+ Parameters.Add("CustomerNo", dsWIP.Tables(tblLotState).Rows(0)("CustomerNo").ToString)
+ Parameters.Add("LogGroupSerial", dsWIP.Tables(tblLotState).Rows(0)("LogGroupSerial").ToString)
+ Parameters.Add("blnCICo", True)
+ Me.ObjectFileHandler.Execute("WP_SWRBasisRead", Parameters)
+
+ End If
+
+ btnSWR.Visible = True
+
+ End If
+
+ ExeGroupControlPriv(Me, PrivFunNo)
+ Cursor.Current = Cursors.Default
+
+ End Sub
+
+ Private Sub frmBR_L_CI_GEN_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
+
+ txtEquipmentNo.Focus()
+
+ End Sub
+
+ Private Sub frmBR_L_CI_GEN_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
+
+ If Not dsWIP Is Nothing Then dsWIP.Dispose()
+ If Not dtKeyIn Is Nothing Then dtKeyIn.Dispose()
+
+ '2019/12/17 OwenLiu, Mantis:0063698, 修正強制關閉企業邏輯,未正確執行ReverseTriggerOP的問題
+ 'Call ExeReverseTriggerOP(UserId, LotNo, RevLotSerial, RevLotStamp)
+ '2020/3/17,Ning,不啟用Reverse時的ReverseTriggerOP
+ Call ExeReverseTriggerOP_NotUseUndo(UserId, LotNo, RevLotSerial, RevLotStamp)
+ End Sub
+
+
+#Region "Button Events"
+
+ Private Sub btnQCList_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnQCList.Click
+
+ If Not dsWIP.Tables(tblAreaEquipment).Rows.Count > 0 Then
+ Exit Sub
+ End If
+
+ 'Modify on 2008/03/31, By OwenLiu,
+
+ '先取得Actve Row
+ Dim drSel() As DataRow
+ drSel = funGetActiveRows()
+
+ If drSel Is Nothing Then Exit Sub
+
+ '檢查設備是否可使用
+ If drSel(0)("AllowExecute") <> 1 Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-203064", "[%Equipment%]"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Sub
+ End If
+
+ '檢查是否有定義機台點檢表
+ If drSel(0)("QCListNo") Is DBNull.Value Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-203072", "[%QCListNo%]"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Sub
+ End If
+
+ '檢查是否有被勾選
+ If Not drSel(0)("CheckFlag") Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-103010", "[%Please select%] [%Equipment%]"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Sub
+ End If
+
+ '檢查是否已點檢完成
+ If Not drSel(0)("QCFinish") Is DBNull.Value Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-203072", "[%Equipment%] [%FINISHED%]"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Sub
+ End If
+
+ '自動開立點檢務單
+ Call funCheckEQPQCTask(drSel(0)("EquipmentNo"))
+
+ '開始處理設備點檢
+ ' 2016/08/30 YF, 不直接參考改用invoke叫用
+ Me.ObjectFileHandler.Execute(pObjectID:="WP_EQPCheckQCList",
+ pParameters:=Nothing,
+ pArgs:=New Object() {
+ drSel(0)("EquipmentNo"), LotNo, LotSerial, LogGroupSerial})
+
+ End Sub
+
+ Private Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnConfirm.Click
+
+ Dim strResult As String
+
+ Cursor.Current = Cursors.WaitCursor
+
+ '1.基本檢查----------------------------------------------------------------------------------------------------------
+ Dim drSel() As DataRow
+ Dim drSelAcc As DataRow()
+ If dsWIP.Tables(tblAreaEquipment).Rows.Count > 0 Then
+ drSel = dsWIP.Tables(tblAreaEquipment).Select("AllowExecute=1")
+ If drSel.Length = 0 Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-203064", "[%Equipment%]"), MsgBoxStyle.Exclamation, Me.Text)
+ GoTo lblExitProcedure
+ Else
+ drSel = dsWIP.Tables(tblAreaEquipment).Select("CheckFlag=" & True)
+ If drSel.Length = 0 Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-103010", "[%Please select%] [%Equipment%]"), MsgBoxStyle.Exclamation, Me.Text)
+ GoTo lblExitProcedure
+ Else
+ '檢查所有勾選的設備是否完成設備點檢
+ For i As Integer = 0 To drSel.Length - 1
+ '2021/3/17,Ning,87547: [6.0.5] 設備點檢支援可設定頻率_生產批進站設備點檢查核調整
+ Call funCheckEQPQCList(drSel(i)("EquipmentNo"), strResult)
+ If strResult <> "success" Then
+ '有設備未完成點檢
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-103011", "[%EQP QCList OnLine Check%]" & vbCrLf & strResult & vbCrLf & "[%has not been completed%]"), MsgBoxStyle.Exclamation, Me.Text)
+ GoTo lblExitProcedure
+ End If
+ Next
+
+ '2013/12/25,Kevin,有顯示模治具才檢查
+ If Not dsWIP.Tables("AccState") Is Nothing Then
+ '如有設定產品-作業站-模治具,則這些模治具都一定要被選
+ If Not dsWIP.Tables("PRDAccessory") Is Nothing Then
+ If dsWIP.Tables("PRDAccessory").Rows.Count > 0 Then
+ Dim drAccState As DataRow()
+ Dim blnPRDAcc As Boolean = False '是否有產品設定的模治具
+ Dim strAccessoryType As String = ""
+ Dim aryShowAccNo As New ArrayList
+ Dim aryShowAccType As New ArrayList
+ Dim blnAllowExecute As Boolean = True
+ Dim strDesc As String = ""
+
+ For Each dr As DataRow In drSel
+ blnPRDAcc = False
+ strAccessoryType = ""
+ aryShowAccNo.Clear()
+ aryShowAccType.Clear()
+ blnAllowExecute = True
+ strDesc = ""
+
+ drAccState = dsWIP.Tables("AccState").Select("EquipmentNo = '" & dr("EquipmentNo") & "' And Select = True")
+ If drAccState.Length > 0 Then
+ '檢查設備是否都有掛產品指定之模治具,相同類別允許掛多個,但至少要有一個
+ For Each drPRD As DataRow In dsWIP.Tables("PRDAccessory").Rows
+
+ '檢查是否是同個模治具類別
+ If strAccessoryType = drPRD("AccessoryType") Then
+ If blnPRDAcc Then
+ '如果已有產品設定的模治具則跳至下一筆
+ GoTo lblAccCheck
+ End If
+ Else
+ '第一個物料類別不判斷blnPRDAcc
+ If strAccessoryType <> "" Then
+ '不同模治具類別時,如果上個模治具類別沒有符合的資料,則此設備不可用
+ If blnPRDAcc = False Then
+ '只要有一種類別模治具不符合就是False
+ blnAllowExecute = False
+ End If
+ End If
+
+ '記錄此次模治具類別
+ strAccessoryType = drPRD("AccessoryType")
+ End If
+
+ If drPRD("AccessoryNo") = "*" Then
+ '如果模治具編號為*代表只有指定模治具類別
+ For Each drAcc As DataRow In drAccState
+ If drAcc("AccessoryType") = drPRD("AccessoryType") Then
+ '有符合的代表有掛指定的模治具類別
+ blnPRDAcc = True
+ '移除此次加入的類別
+ aryShowAccType.Remove(drPRD("AccessoryType"))
+ '有符合一筆即可
+ GoTo lblAccCheck
+ Else
+ blnPRDAcc = False
+ If Not aryShowAccType.Contains(drPRD("AccessoryType")) Then
+ aryShowAccType.Add(drPRD("AccessoryType"))
+ End If
+ End If
+ Next
+ Else
+ '如果模治具編號不為*代表有指定模治具
+ For Each drAcc As DataRow In drAccState
+ If drAcc("AccessoryType") = drPRD("AccessoryType") AndAlso drAcc("AccessoryNo") = drPRD("AccessoryNo") Then
+ '有符合的代表有掛指定的模治具類別
+ blnPRDAcc = True
+ '移除此次加入的編號
+ aryShowAccNo.Remove(drPRD("AccessoryNo"))
+ '有符合一筆即可
+ Exit For
+ Else
+ blnPRDAcc = False
+ If Not aryShowAccNo.Contains(drPRD("AccessoryNo")) Then
+ aryShowAccNo.Add(drPRD("AccessoryNo"))
+ End If
+ End If
+ Next
+ End If
+lblAccCheck:
+ Next
+
+ '多判斷一次最後一個類別
+ If blnPRDAcc = False Then
+ '只要有一種類別模治具不符合就是False
+ blnAllowExecute = False
+ End If
+
+ If blnAllowExecute = False Then
+ If aryShowAccType.Count > 0 Then
+ strDesc += vbCrLf & "[%AccessoryType%]:"
+ For k As Integer = 0 To aryShowAccType.Count - 1
+ strDesc += aryShowAccType(k) & ","
+ Next
+ strDesc = strDesc.TrimEnd(",")
+ End If
+ If aryShowAccNo.Count > 0 Then
+ strDesc += vbCrLf & "[%AccessoryNo%]:"
+ For k As Integer = 0 To aryShowAccNo.Count - 1
+ strDesc += aryShowAccNo(k) & ","
+ Next
+ strDesc = strDesc.TrimEnd(",")
+ End If
+
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-103010", "[%EquipmentNo%]:" & dr("EquipmentNo") & "[%ISNOTSELECTED%][%Product%][%Setup%][%Accessory%]" & strDesc), MsgBoxStyle.Exclamation, Me.Text)
+ GoTo lblExitProcedure
+ End If
+ Else
+ '設備沒掛模治具就一定沒有掛設定的必需模治具
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-103010", "[%EquipmentNo%]:" & dr("EquipmentNo") & "[%ISNOTSELECTED%][%Accessory%]"), MsgBoxStyle.Exclamation, Me.Text)
+ GoTo lblExitProcedure
+ End If
+ Next
+ End If
+ End If
+ End If
+ End If
+ End If
+ End If
+
+ If funGetSysParameter("CIMTLDBCheck") = "1" Then
+ If dsWIP.Tables(tblTMaterial).Rows.Count > 0 Then
+ If Not funCheckMTL() Then GoTo lblExitProcedure
+ End If
+ End If
+
+ '2023/06/07 ,0135702: [6.0.7] SDD220425_01-03_進站設備派工查核調整,19245
+ Try
+ Dim strEQP As String = ""
+ For Each dr As DataRow In dsWIP.Tables(tblAreaEquipment).Select("CheckFlag=" & True)
+ strEQP += dr("EquipmentNo").ToString() & ","
+ Next
+ If (strEQP <> "") Then
+ strEQP = strEQP.TrimEnd(",")
+ Else
+ strEQP = defString
+ End If
+ Call ChkCIEQPDispatch(strEQP, txtLotNo.Text)
+
+ Dim showMSG As String = ""
+ Dim arrayMsg As New ArrayList
+ If Not IsNothing(dsEQP) Then
+ For i = 0 To dsEQP.Tables.Count - 1
+ If dsEQP.Tables(i).Rows.Count > 0 Then
+ For Each drEQP As DataRow In dsEQP.Tables(i).Rows
+ If drEQP("Result").ToString <> "Success" Then
+ arrayMsg.Add(ChgTranslateName_Content(drEQP("Description").ToString))
+ End If
+ Next
+ End If
+ Next
+ If arrayMsg.Count > 0 Then
+ If funGetSysParameter("LotEQPDispatchLimit") = "1" Then '進站是否卡控生產批派工 參數為1
+ '是否確定執行?
+ For i As Integer = 0 To arrayMsg.Count - 1
+ showMSG += arrayMsg(i).ToString() & vbCrLf
+ Next
+ If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100004", showMSG), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
+ GoTo lblExitProcedure
+ End If
+ Else
+ '進站失敗,失敗原因:不滿足規則xx
+ showMSG = ChgTranslateName_Content("[%CHECK IN FAILED%], [%REASONS FOR FAILURE%]: [%Failure to meet rules%] " & vbCrLf)
+ For i As Integer = 0 To arrayMsg.Count - 1
+ showMSG += arrayMsg(i).ToString() & vbCrLf
+ Next
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Content(showMSG), MsgBoxStyle.Critical, Me.Text)
+ GoTo lblExitProcedure
+ End If
+ End If
+ End If
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Finally
+ End Try
+
+
+ '2020/02/26 Grace Mantis 67753 取得此批號於此作業站上的派工資料
+ Call funLoadWIPEQPDispatchState(LotNo:=LotNo, OPNo:=txtOPNo.Text)
+
+ If Not IsNothing(dsTemp.Tables(tblEQPDispatchState)) Then
+ If dsTemp.Tables(tblEQPDispatchState).Rows.Count > 0 Then
+ Dim aryMsg As New ArrayList
+ Dim strCheckInDate As String = Now.ToString("yyyy/MM/dd") 'Check In 日期
+ If chkUpdCheckInTime.Checked Then strCheckInDate = dtpcheckintime.Value.ToString("yyyy/MM/dd")
+
+ '2020/03/02 Grace Mantis 67753, 68192 檢查所選擇的設備是否有相符的派工資料
+ For Each dr As DataRow In dsWIP.Tables(tblAreaEquipment).Select("CheckFlag=" & True)
+
+ '1. 檢查是否有派工設備
+ Dim drSelEQP As DataRow() = dsTemp.Tables(tblEQPDispatchState).Select("EquipmentNo = '" & dr("EquipmentNo").ToString() & "'")
+ If drSelEQP.Count > 0 Then
+ '1-2. 有派工設備, 檢查派工設備的派工日期是否符合
+ Dim iCount As Integer = 0
+ Dim strDisDate As String = ""
+ For Each dr2 As DataRow In dsTemp.Tables(tblEQPDispatchState).Select("EquipmentNo = '" & dr("EquipmentNo").ToString() & "'", "DispatchOrder")
+ If Convert.ToDateTime(dr2("DispatchDate")).ToString("yyyy/MM/dd") = strCheckInDate Then
+ iCount += 1
+ Exit For
+ Else
+ If strDisDate = "" Then strDisDate = Convert.ToDateTime(dr2("DispatchDate")).ToString("yyyy/MM/dd")
+ End If
+ Next
+
+ If iCount > 0 Then
+ '1-2-1. 派工日期符合, 不顯示訊息
+ Else
+ '1-2-2. 派工日期不符合, 顯示訊息
+ '選擇的設備於[checkin日期]未派工, 設定的派工日期為[DispatchDate]
+ aryMsg.Add(ChgTranslateName_Content("[%EQUIPMENTNO%]:" & dr("EquipmentNo").ToString() & ", [%SelectedEQPAt%]" & strCheckInDate & "[%NoDispatch%], [%ActualDispatchDate%]" & strDisDate))
+ End If
+ '2020/11/05 Mantis:0081316:納標調整,派工順序卡控
+ If dr("DispatchOrder").ToString <> "1" Then
+ aryMsg.Add(ChgTranslateName_Content("[%EQUIPMENTNO%]:" & dr("EquipmentNo").ToString() & ", [%DispatchOrder is not top priority%]"))
+ 'MsgBox(ChgTranslateName_Msg("0000-103010", "[%EquipmentNo%]:" & dr("EquipmentNo") & "[%DispatchOrder is not top priority%]"), MsgBoxStyle.Exclamation, Me.Text)
+ 'GoTo lblExitProcedure
+ End If
+ Else
+ '1-3. 沒有派工設備, 檢查是否有符合的派工日期
+ Dim iCount As Integer = 0
+ Dim strEQPNo As String = ""
+ For Each dr4 As DataRow In dsTemp.Tables(tblEQPDispatchState).Rows
+ If Convert.ToDateTime(dr4("DispatchDate")).ToString("yyyy/MM/dd") = strCheckInDate Then
+ '若派工日期相符的設備資料並未勾選, 才顯示訊息
+ If dsWIP.Tables(tblAreaEquipment).Select("CheckFlag=" & True & " And EquipmentNo = '" & dr4("EquipmentNo") & "'").Count = 0 Then
+ iCount += 1
+ strEQPNo = dr4("EquipmentNo")
+ Exit For
+ End If
+ End If
+ Next
+
+ If iCount > 0 Then
+ '1-3-1. 派工日期符合, 顯示訊息
+ '選擇的設備與派工設備不同
+ aryMsg.Add(ChgTranslateName_Content("[%EQUIPMENTNO%]:" & dr("EquipmentNo").ToString() & ", " & "[%SelectedEQPDispatchNotMatch%]!" & vbCrLf & "[%EQPDispatch%]:" & strEQPNo))
+ Else
+ '1-3-2. 派工日期不符合, 顯示訊息
+ '生產批號於作業站上無任何派工資料
+ aryMsg.Add(ChgTranslateName_Content("[%EQUIPMENTNO%]:" & dr("EquipmentNo").ToString() & ", [%AT%][%OP%]: " & txtOPNo.Text & " [%NoDispatchData%]"))
+ End If
+ End If
+ Next
+
+ '若有錯誤訊息, 一次顯示
+ If aryMsg.Count > 0 Then
+ Dim strMsgMix As String = ""
+ For i As Integer = 0 To aryMsg.Count - 1
+ strMsgMix += aryMsg(i).ToString() & vbCrLf & vbCrLf
+ Next
+ If strMsgMix.Length > 0 Then
+ strMsgMix = strMsgMix & ChgTranslateName_Content("[%Sure2Confirm%]?") '是否確定執行?
+
+ If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100004", strMsgMix), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
+ GoTo lblExitProcedure
+ End If
+ End If
+ End If
+ Else
+ '2020/05/08 Eric 註解派工提示訊息
+ ''是否確定 / 生產批號(" & LotNo & ") 於作業站(" & txtOPNo.Text & ") 上無任何派工資料, 是否確定執行?
+ 'If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100004", "[%LOTNO%](" & LotNo & ") [%AT%][%OP%](" & txtOPNo.Text & ") [%NoDispatchData%], [%Sure2Confirm%]?"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
+ ' GoTo lblExitProcedure
+ 'End If
+ End If
+ Else
+ '2020/05/08 Eric 註解派工提示訊息
+ ''是否確定 / 生產批號(" & LotNo & ") 於作業站(" & txtOPNo.Text & ") 上無任何派工資料, 是否確定執行?
+ 'If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100004", "[%LOTNO%](" & LotNo & ") [%AT%][%OP%](" & txtOPNo.Text & ") [%NoDispatchData%], [%Sure2Confirm%]?"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
+ ' GoTo lblExitProcedure
+ 'End If
+ End If
+
+ Dim strMTLLot As String = ""
+ For Each dr As DataRow In dsWIP.Tables(tblTmpMTLLotNo).Rows
+ strMTLLot += CombineXMLValueTag(CombineXMLValue("materialno", dr("MaterialNo")) &
+ CombineXMLValue("materiallotno", dr("MaterialLotNo")))
+ Next
+
+ '2.格式化資料Attrib-----------------------------------------------------------------------------------------------
+ Dim strAttrib As String = ""
+ Dim strTemp As String
+
+ If Not dsWIP.Tables(tblTAttrib) Is Nothing Then
+ dsWIP.Tables(tblTAttrib).DefaultView.RowFilter = "(AttribPhase = " & PhaseNo & " or AttribPhase = 99) And AttribSource <> 0" 'CurPhase & All的所有Attrib,除了KeyIn
+ For i As Integer = 0 To dsWIP.Tables(tblTAttrib).DefaultView.Count - 1
+ strTemp = CombineXMLValue("attribno", CInput(dsWIP.Tables(tblTAttrib).DefaultView.Item(i)("AttribNo"))) &
+ CombineXMLValue("attribtype", dsWIP.Tables(tblTAttrib).DefaultView.Item(i)("AttribType")) &
+ CombineXMLValue("attribsequence", dsWIP.Tables(tblTAttrib).DefaultView.Item(i)("AttribSequence")) &
+ CombineXMLValue("attribsource", dsWIP.Tables(tblTAttrib).DefaultView.Item(i)("AttribSource")) &
+ CombineXMLValue("attribphase", dsWIP.Tables(tblTAttrib).DefaultView.Item(i)("AttribPhase")) &
+ CombineXMLValue("savetolotpropertyno", CInput(dsWIP.Tables(tblTAttrib).DefaultView.Item(i)("SaveToLotPropertyNo")))
+ If IsDBNull(dsWIP.Tables(tblTAttrib).DefaultView.Item(i)("AttribValue")) Then
+ strTemp += CombineXMLValue("attribvalue", "")
+ Else
+ strTemp += CombineXMLValue("attribvalue", CInput(dsWIP.Tables(tblTAttrib).DefaultView.Item(i)("AttribValue")))
+ End If
+ strAttrib += CombineXMLValueTag(strTemp)
+ Next
+ '還原顯示
+ dsWIP.Tables(tblTAttrib).DefaultView.RowFilter = "AttribSource <> 0 And AttribSource <> 1 And (AttribPhase = " & PhaseNo & " or AttribPhase = 99)" 'Source = Not KeyIn, Not Calculate ,CurPhase and All
+
+ 'Temp:Attrib_KeyIn
+ For i As Integer = 0 To dtKeyIn.Rows.Count - 1
+ If IsDBNull(dtKeyIn.Rows(i)("AttribValue")) = True Then
+ dtKeyIn.Rows(i)("AttribValue") = ""
+ End If
+
+ ''edit by Zoe,2009/03/17:增加DBNull及Trim的比對
+ ''If dtKeyIn.Rows(i)("AttribValue") = "" Then
+ 'R1102001 改由ChkControlRule時才判斷 By Acer 2011/02/21
+ 'If IsDBNull(dtKeyIn.Rows(i)("AttribValue")) OrElse Trim(dtKeyIn.Rows(i)("AttribValue")) = "" OrElse dtKeyIn.Rows(i)("AttribValue") = "" Then
+ ' iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%AttribValue%] of [%AttribNo%]:" & dtKeyIn.Rows(i)("AttribNo") & " is empty!!"), MsgBoxStyle.Exclamation, Me.Text)
+ ' GoTo lblExitProcedure
+ 'End If
+
+ drSel = dsWIP.Tables(tblTAttrib).Select("AttribNo='" & dtKeyIn.Rows(i)("AttribNo") & "'")
+ If drSel.Length = 0 Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-203010", "[%AttribNo%]:" & dtKeyIn.Rows(i)("AttribNo")), MsgBoxStyle.Exclamation, Me.Text)
+ GoTo lblExitProcedure
+ Else
+ strTemp = CombineXMLValue("attribno", CInput(dtKeyIn.Rows(i)("AttribNo"))) &
+ CombineXMLValue("attribtype", drSel(0)("AttribType")) &
+ CombineXMLValue("attribsequence", drSel(0)("AttribSequence")) &
+ CombineXMLValue("attribsource", drSel(0)("AttribSource")) &
+ CombineXMLValue("attribphase", drSel(0)("AttribPhase")) &
+ CombineXMLValue("attribvalue", CInput(dtKeyIn.Rows(i)("AttribValue"))) &
+ CombineXMLValue("savetolotpropertyno", CInput(drSel(0)("SaveToLotPropertyNo")))
+ '2015-12-18, Joe, Add QCItemNo
+ If IsDBNull(drSel(0)("QCItemNo")) Then
+ strTemp += CombineXMLValue("qcitemno", "")
+ Else
+ strTemp += CombineXMLValue("qcitemno", CInput(drSel(0)("QCItemNo")))
+ End If
+ strAttrib += CombineXMLValueTag(strTemp)
+ End If
+ Next
+ End If
+
+ '3.格式化資料Equipment-----------------------------------------------------------------------------------------------
+ Dim strEquipment As String = ""
+
+ '只有一筆
+
+ drSel = dsWIP.Tables(tblAreaEquipment).Select("CheckFlag=" & True)
+ If dsWIP.Tables(tblLotState).Rows(0)("MaterialOption").ToString = "1" AndAlso drSel.Length > 1 Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-103010", "[%MATERIALOPTIONISEQP%], [%Only Support One Equipment To Select%]"), MsgBoxStyle.Exclamation, Me.Text)
+ GoTo lblExitProcedure
+ End If
+
+ 'Modify On 2007/11/30 By OwenLiu, 修正 Equipment 多選後, 仍然只執行第一個設備的Bug
+ For i As Integer = 0 To drSel.Length - 1
+ If IsDBNull(drSel(i)("LoadPort")) Then
+ strEquipment += CombineXMLValueTag(CombineXMLValue("equipmentno", CInput(drSel(i)("EquipmentNo"))))
+ If Not ChkWIPEQPConsume(LotNo, CInt(Me.txtCurQty.Text), UserId, drSel(i)("EquipmentNo").ToString) Then GoTo lblExitProcedure
+ Else
+ If drSel(i)("LoadPort") = -1 Then '代表不選Port.
+ strEquipment += CombineXMLValueTag(CombineXMLValue("equipmentno", CInput(drSel(i)("EquipmentNo"))))
+ If Not ChkWIPEQPConsume(LotNo, CInt(Me.txtCurQty.Text), UserId, drSel(i)("EquipmentNo").ToString) Then GoTo lblExitProcedure
+ Else
+ strEquipment += CombineXMLValueTag(
+ CombineXMLValue("equipmentno", CInput(drSel(i)("EquipmentNo"))) &
+ CombineXMLValue("loadport", drSel(i)("LoadPort")))
+ If Not ChkWIPEQPConsume(LotNo, CInt(Me.txtCurQty.Text), UserId, drSel(i)("EquipmentNo").ToString) Then GoTo lblExitProcedure
+ End If
+ End If
+ Next
+
+ '子設備資料
+ Dim strEquipmentChamber = String.Empty
+ If Not dsWIP.Tables("Chamber") Is Nothing Then
+ drSel = dsWIP.Tables("Chamber").Select("SELECT1 = True")
+ For Each dr As DataRow In drSel
+ strEquipmentChamber += CombineXMLValueTag(
+ CombineXMLValue("equipmentno", CInput(dr("EquipmentNo"))) &
+ CombineXMLValue("belongequipmentno", dr("BelongEquipmentNo")))
+ Next
+ End If
+ '格式化資料Accessory
+ Dim strAccessory As String = ""
+ If Not dsWIP.Tables("AccState") Is Nothing Then
+ drSel = dsWIP.Tables("AccState").Select("Select=" & True)
+ If drSel.Length > 0 Then
+ For Each drAcc As DataRow In drSel
+ strAccessory += CombineXMLValueTag(
+ CombineXMLValue("equipmentno", CInput(drAcc("EquipmentNo"))) &
+ CombineXMLValue("accessoryno", CInput(drAcc("AccessoryNo"))) &
+ CombineXMLValue("accessoryversion", CInput(drAcc("AccessoryVersion"))) &
+ CombineXMLValue("accessorytype", CInput(drAcc("AccessoryType"))) &
+ CombineXMLValue("accumulateqty", drAcc("AccumulateQty")))
+ Next
+ End If
+ End If
+
+ ' 2016/12/27 YF, 取消舊制多人加工
+ '3.多人加工-----------------------------------------------------------------------------------------------
+ 'Dim strLoginState As String = ""
+
+ 'For Each drTmp As DataRow In dtTmpLoginState.Rows
+ ' 'Kevin,2012/12/18,不取client端的時間作CI時間
+ ' If drTmp("CheckInTime").ToString = "" Then
+ ' drTmp("CheckInTime") = defDateTime
+ ' End If
+ ' strLoginState += CombineXMLValueTag(
+ ' CombineXMLValue("userno", CInput(drTmp("UserNo"))) &
+ ' CombineXMLValue("username", CInput(drTmp("UserName"))) &
+ ' CombineXMLValue("checkintime", Format(drTmp("CheckInTime"), "yyyy/MM/dd HH:mm:ss")))
+ 'Next
+
+ '4.檢查是否允許執行-----------------------------------------------------------------------------------------------
+ If ChkLotStamp(LotNo, UserId, dsWIP.Tables(tblLotState).Rows(0)("LotStamp")) < 0 Then GoTo lblExitProcedure
+
+ '5.Control Rule Check --------------------------------------------------------------------------------------------
+ Dim strLinkName, strMSG As String
+ Dim strMailGroupNo As String = ""
+ Dim strRuleNo As String = defString
+ Dim intERFType As Integer = defInteger
+ Dim dsTestValue As DataSet
+ Dim strERFMsg As String
+
+ If ChkControlRule(LotNo, UserId, dsWIP.Tables(tblLotState).Rows(0)("LotStamp"),
+ strAttrib, strLinkName, strMSG, strRuleNo, intERFType, strMailGroupNo, , , , dsTestValue) < 0 Then GoTo lblExitProcedure
+
+ '2015-12-17, Joe, Check SPC Contorl
+ If funChkSPCControl_Var(LotNo, strAttrib, dsTestValue, strLinkName, intERFType, strERFMsg) < 0 Then GoTo lblExitProcedure
+ strERFMsg = ChgTranslateErrorMsg(strERFMsg)
+
+ '若是Hold詢問是否繼續
+ If strLinkName = "HOLD" Then
+ If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100103", "[%Lot%]"), MsgBoxStyle.DefaultButton2 + MsgBoxStyle.YesNo + MsgBoxStyle.Question, "Hold Inquire") = MsgBoxResult.No Then
+ GoTo lblExitProcedure
+ End If
+ End If
+
+ '6.ExecuteCheckIn ------------------------------------------------------------------------------------------------
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", CInput(LotNo), "")
+ strParameter += CombineXMLParameter("linkname", "LinkName", "String", CInput(strLinkName), "")
+ strParameter += CombineXMLParameter("lotstamp", "LotStamp", "Long", dsWIP.Tables(tblLotState).Rows(0)("LotStamp"), "")
+ strParameter += CombineXMLParameter("shiftno", "ShiftNo", "String", CInput(txtShiftNo.Text), "")
+ strParameter += CombineXMLParameter("lotrecord", "LotRecord", "String", CInput(txtLotRecord.Text), "")
+ 'strParameter += CombineXMLParameter("checkintime", "CheckInTime", "String", dtpcheckintime.Value.ToString("yyyy/MM/dd HH:mm:ss"), "") '2017/11/06 mark by KunYuan:移至下方處理
+ strParameter += CombineXMLParameterMultiValue("attrib", "Attrib", "String", strAttrib, "")
+ strParameter += CombineXMLParameterMultiValue("equipment", "Equipment", "String", strEquipment, "")
+ strParameter += CombineXMLParameterMultiValue("equipmentchamber", "EquipmentChamber", "String", strEquipmentChamber, "")
+ strParameter += CombineXMLParameter("ruleno", "RuleNo", "String", CInput(strRuleNo), "") 'Added by Jialing 2011/02/18
+ 'strParameter += CombineXMLParameterMultiValue("loginstate", "LoginState", "String", strLoginState, "") ' 2016/12/27 YF, 取消舊制多人加工
+
+ '2017/11/06 KunYuan:當有勾選『變更開始加工時間』,再傳入CheckInTime
+ If chkUpdCheckInTime.Checked Then
+ strParameter += CombineXMLParameter("checkintime", "CheckInTime", "String", dtpcheckintime.Value.ToString("yyyy/MM/dd HH:mm:ss"), "")
+ End If
+
+ '2013/12/25,Kevin,模治具資料有顯示才傳
+ If blnGetAccessory Then
+ strParameter += CombineXMLParameterMultiValue("accessory", "Accessory", "String", strAccessory, "")
+ End If
+ '2019/09/06 Eric
+ If strMTLLot <> "" Then
+ strParameter += CombineXMLParameterMultiValue("temp_materiallot", "Temp_MaterialLot", "String", strMTLLot, "")
+ End If
+
+
+
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+ Try
+ '2019/06/20 Lena, Mantis: 0058845 [WIP] CI/CO執行時間紀錄
+ '新增參數 LogOn = True, 記錄執行時間.
+ OutXml = InvokeSrv("wsWIP.Exe_CheckIn", InXml, LogOn:=True)
+
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then '找出Exception訊並顯示出來
+ '成功執行完成,避免再按下一次
+ btnConfirm.Enabled = False
+
+ '2017/11/06 KunYuan:變更開始加工時間checkbox預設不勾選
+ chkUpdCheckInTime.Checked = False
+
+ If strLinkName <> "HOLD" And strLinkName <> "WAIT" Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-000001", "[%LotNo%]:" & LotNo & " [%Check In%] [%Successfully%]"), MsgBoxStyle.Information, Me.Text)
+ End If
+ Else
+ If GetExceptionCode(XmlDoc) = "IPQCNO" Then
+ 'ExceptionManager.iMESShowDialog("0000-103021", GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200015", GetExceptionSysMsg(XmlDoc)), MsgBoxStyle.Information, Me.Text)
+ Dim Parameters As New Dictionary(Of String, Object)
+ Parameters.Add("defLotNo", LotNo)
+ Me.ObjectFileHandler.Execute("SC_IPQCForm", Parameters)
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ End If
+ GoTo lblExitProcedure
+ End If
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ GoTo lblExitProcedure
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ GoTo lblExitProcedure
+ Finally
+ End Try
+
+ Me.Close()
+
+ '7.Mail-------------------------------------------------------------------------------------------------------------
+ '以下的執行,不管成功失敗,都讓FormClose,代表此BR已完成
+
+ '2016-12-19 add 取得eSOP參數
+ Execute_eSOP = funGetSysParameter("Execute_eSOP")
+ If Execute_eSOP = 1 Then
+ '讀取eSOP工位及檔案及頁碼
+ Call funLoadPRDeSOP()
+ '顯示作業指導書
+ Call funDisplayProcess()
+ End If
+ If Execute_eSOP = 2 Then
+ '組JSON
+ Dim DataString, ResponsetJson As String
+ Dim strProductNo, strProductVersion As String
+ Try
+ strProductNo = txtProductNo.Text
+ strProductVersion = dsWIP.Tables(tblLotState).Rows(0)("ProductVersion").ToString
+ Dim dic As New Dictionary(Of String, String)
+ dic("userid") = gUserNo
+ dic("languagemode") = gLanguageMode
+ dic("computername") = gComputerName
+ Dim Uri = Newtonsoft.Json.JsonConvert.SerializeObject(dic)
+
+ dic = New Dictionary(Of String, String)
+ dic("produc_no") = strProductNo
+ dic("product_ver") = strProductVersion
+ dic("op_no") = txtOPNo.Text
+ Dim list As New List(Of String)
+ Dim rows As DataRow() = dsWIP.Tables(tblAreaEquipment).Select("CheckFlag=" & True)
+ If rows.Length > 0 Then
+ For Each dr As DataRow In dsWIP.Tables(tblAreaEquipment).Select("CheckFlag=" & True)
+ list.Add(dr("EQUIPMENTTYPE"))
+ Next
+ dic("eqp_type") = String.Join(""",""", list)
+ Else
+ dic("eqp_type") = Nothing
+ End If
+
+ Dim Content = Newtonsoft.Json.JsonConvert.SerializeObject(dic)
+
+ '呼叫EAI GeteSOPInfo_API
+ Using wsEAI As New wsEAI.wsEAI
+ ResponsetJson = wsEAI.GeteSOPInfo_API(Uri, Content)
+ End Using
+
+ '呼叫WP_eSOPList.dll
+ Dim Obj As Newtonsoft.Json.Linq.JObject = Newtonsoft.Json.JsonConvert.DeserializeObject(ResponsetJson)
+ Dim dtResponsetJson As DataTable = JsonConvert.DeserializeObject(Of DataTable)(Obj.Item("ResultJson").ToString)
+ Dim Parameters As New Dictionary(Of String, Object)
+ Parameters.Add("dteSOP", dtResponsetJson)
+ Me.ObjectFileHandler.Execute("WP_eSOPList", Parameters)
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ End Try
+ End If
+
+ If strMailGroupNo <> "" Then
+ Call SendEmailToERFGroup_NoneERF(LotNo, UserId, strMailGroupNo, strMSG,
+ dsWIP.Tables(tblLotState).Rows(0)("OPNo"), dsWIP.Tables(tblLotState).Rows(0)("OPName"), dsWIP.Tables(tblLotState).Rows(0)("BRNo"))
+ End If
+
+
+
+ 'C3:依LinkName決定是否Transfer Lot----------------------------------------------------------------------------------
+ '以下的執行,不管成功失敗,都讓FormClose,代表此BR已完成
+ '若再執行Confirm一次則不正確,同一BR會執行多次
+ '2015-12-21, Joe, 加ERFMsg
+ Call BRTransferLot(LotNo, UserId, strLinkName, intERFType, strRuleNo, , strERFMsg)
+
+
+ gReturnKeyValue = LotNo
+
+
+lblExitProcedure:
+
+ Cursor.Current = Cursors.Default
+ Exit Sub
+
+ End Sub
+
+ Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click
+
+ Cursor.Current = Cursors.WaitCursor
+
+ Try
+ '2019/12/17 OwenLiu, Mantis:0063698, ReverseTriggerOP統一呼叫 WIP_Kit共用函式
+ 'Call ExeReverseTriggerOP(UserId, LotNo, RevLotSerial, RevLotStamp)
+
+ '2020/3/17,Ning,不啟用Reverse時的ReverseTriggerOP
+ '2022/9/19,Ning, 116091: 各BR 在畫面關閉動作執行ReverseTriggerOP,若有執行失敗須把訊息顯示:統一在form_closing時處理
+ 'Call ExeReverseTriggerOP_NotUseUndo(UserId, LotNo, RevLotSerial, RevLotStamp)
+
+ Catch e1 As Exception
+ Finally
+ Me.Close()
+ End Try
+
+ Cursor.Current = Cursors.Default
+
+
+ End Sub
+
+ Private Sub btnEQPConsumeReset_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEQPConsumeReset.Click
+
+ Try
+
+ If Me.iugEquipment.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
+
+ ' 2016/08/30 YF, 不直接參考改用invoke叫用
+ Me.ObjectFileHandler.Execute(pObjectID:="WP_EQPConsumeReset",
+ pParameters:=Nothing,
+ pArgs:=New Object() {
+ Me.iugEquipment.iMESUltraGrid.ActiveRow.Cells("EquipmentNo").Value.ToString})
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ End Try
+
+ End Sub
+
+ Private Sub btnMultiUser_Click(sender As System.Object, e As System.EventArgs) Handles btnMultiUser.Click
+
+ ' 2016/08/30 YF, 不直接參考改用invoke叫用
+ Dim parameters As New Dictionary(Of String, Object)
+ parameters.Add("CallType", 1)
+ parameters.Add("UserID", UserId)
+ parameters.Add("CheckInTime", dtpcheckintime.Value)
+ parameters.Add("drLotInfo", dsWIP.Tables(tblLotState).Rows(0))
+ parameters.Add("dtTmpLoginState", dtTmpLoginState)
+ '2019/10/17 Grace 調整ObjectID
+ Me.ObjectFileHandler.Execute("WP_OperatorLogIn_Lot", parameters)
+
+ dtTmpLoginState = parameters("dtTmpLoginState")
+
+ End Sub
+
+
+#End Region
+
+ Protected Overrides Sub Finalize()
+ MyBase.Finalize()
+ End Sub
+
+#Region "Control Enter,KeyPress"
+
+ Private Sub txtLotNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtLotNo.Enter
+ txtLotNo.SelectAll()
+ End Sub
+ Private Sub txtLotNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtLotNo.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtPriority_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtPriority.Enter
+ txtPriority.SelectAll()
+ End Sub
+ Private Sub txtPriority_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtPriority.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtAreaNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAreaNo.Enter
+ txtAreaNo.SelectAll()
+ End Sub
+ Private Sub txtAreaNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtAreaNo.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtCurQty_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtCurQty.Enter
+ txtCurQty.SelectAll()
+ End Sub
+ Private Sub txtCurQty_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtCurQty.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtCurUnitNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtCurUnitNo.Enter
+ txtCurUnitNo.SelectAll()
+ End Sub
+ Private Sub txtCurUnitNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtCurUnitNo.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtSysQty_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSysQty.Enter
+ txtSysQty.SelectAll()
+ End Sub
+ Private Sub txtSysQty_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSysQty.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtSysUnitNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSysUnitNo.Enter
+ txtSysUnitNo.SelectAll()
+ End Sub
+ Private Sub txtSysUnitNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSysUnitNo.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtOPNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtOPNo.Enter
+ txtOPNo.SelectAll()
+ End Sub
+ Private Sub txtOPNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtOPNo.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtOPDescription_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtOPDescription.Enter
+ txtOPDescription.SelectAll()
+ End Sub
+ Private Sub txtOPDescription_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtOPDescription.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtCustomerLotNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtCustomerLotNo.Enter
+ txtCustomerLotNo.SelectAll()
+ End Sub
+ Private Sub txtCustomerLotNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtCustomerLotNo.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtMONo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtMONo.Enter
+ txtMONo.SelectAll()
+ End Sub
+ Private Sub txtMONo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtMONo.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtEmployeeNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEmployeeNo.Enter
+ txtEmployeeNo.SelectAll()
+ End Sub
+ Private Sub txtEmployeeNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtEmployeeNo.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtShiftNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtShiftNo.Enter
+ txtShiftNo.SelectAll()
+ End Sub
+ Private Sub txtShiftNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtShiftNo.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtLotRecord_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtLotRecord.Enter
+ txtLotRecord.SelectAll()
+ End Sub
+
+ Private Sub txtProductNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtProductNo.Enter
+ txtProductNo.SelectAll()
+ End Sub
+ Private Sub txtProductNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtProductNo.KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub txtMaterialLotNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtMaterialLotNo.Enter
+ txtMaterialLotNo.SelectAll()
+ End Sub
+
+ Private Sub txtMaterialLotNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtMaterialLotNo.KeyPress
+
+ Try
+ If (e.KeyChar = Convert.ToChar(13)) Then
+ funKeyInMaterialLotNo(txtMaterialNo.Text, txtMaterialLotNo.Text)
+ End If
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ End Try
+
+ End Sub
+ Private Sub funKeyInMaterialLotNo(ByVal MaterialNo As String, ByVal MaterialLotNo As String)
+
+ Try
+ '2020/10/29 Grace 請先輸入物料編號
+ If MaterialNo = "" Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(
+ ChgTranslateName_Msg("0000-200005", "[%MaterialNo%]!"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Sub
+ End If
+
+ MaterialLotNo = UCase(MaterialLotNo.Trim)
+ If MaterialLotNo = "" Then Exit Sub
+
+ If dsWIP.Tables(tblTMaterial).Rows.Count = 0 Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(
+ ChgTranslateName_Msg("0000-103019", "[%Do not need to check%]!"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Sub
+ End If
+
+ '相同料批只能加入某一個料,以避免上料錯誤
+ '2020/10/29 Grace 依物料編號取得料批
+ Dim drCheckMTLLotNo() As DataRow = dsWIP.Tables(tblTmpMTLLotNo).Select(
+ "MaterialLotNo ='" & MaterialLotNo & "' And MaterialNo ='" & MaterialNo & "'")
+
+ If drCheckMTLLotNo.Length > 0 Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(
+ ChgTranslateName_Msg("0000-200004", "[%MaterialLotNo%]:" & MaterialLotNo), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Sub
+ End If
+
+ ' 2016/10/19 YF, 依作業站用料選項取出資料
+ Select Case dsWIP.Tables(tblLotState).Rows(0)("MaterialOption").ToString
+ Case "0"
+ ' 發料點(線邊倉或工單)
+ If (Not CheckMaterialByPutinPlace(dsWIP.Tables(tblLotState).Rows(0)("MONo").ToString, MaterialLotNo, MaterialNo)) Then
+ Exit Sub
+ End If
+
+ Case "1"
+ ' 設備
+ 'If (Not CheckMaterialByEquipment(MaterialLotNo, MaterialNo)) Then
+ ' Exit Sub
+ 'End If
+
+ 'Case "2"
+ ' 生產線, 待組裝版再實作
+
+ 'Case "3"
+ ' 工位, 待組裝版再實作
+
+ Case Else
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(
+ ChgTranslateName_Msg("0000-003000", "[%MaterialOption%]:" & dsWIP.Tables(tblLotState).Rows(0)("MaterialOption").ToString &
+ " [%NOT DEFINE%]!"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Sub
+ End Select
+
+ Catch ex As Exception
+ Throw ex
+
+ Finally
+ txtMaterialLotNo.Text = ""
+ txtMaterialNo.Text = ""
+ txtMaterialNo.Focus()
+ End Try
+
+ End Sub
+
+ Private Sub txtMaterialLotNo_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtMaterialLotNo.Leave
+ txtMaterialLotNo.Text = UCase(txtMaterialLotNo.Text)
+ End Sub
+
+#End Region
+
+#Region "Ultra Grid"
+
+ Private Sub iugAttrib_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugAttrib.iMESUltraGrid_InitializeLayOut
+
+ Dim i As Integer
+
+ With e.Layout
+ For i = 0 To dsWIP.Tables(tblTAttrib).Columns.Count - 1
+ Select Case dsWIP.Tables(tblTAttrib).Columns(i).ColumnName.ToUpper
+ Case "ATTRIBNO"
+ With .Bands(tblTAttrib).Columns("AttribNo")
+ .Header.Caption = "AttribNo"
+ .Width = 70
+ .Header.VisiblePosition = 1
+ End With
+ Case "ATTRIBNAME"
+ With .Bands(tblTAttrib).Columns("AttribName")
+ .Header.Caption = "AttribName"
+ .Width = 95
+ .Header.VisiblePosition = 2
+ End With
+ Case "ATTRIBVALUE"
+ With .Bands(tblTAttrib).Columns("AttribValue")
+ .Header.Caption = "AttribValue"
+ .Width = 80
+ .Header.VisiblePosition = 3
+ End With
+ Case "ATTRIBSOURCE"
+ With .Bands(tblTAttrib).Columns("AttribSource")
+ .Header.Caption = "AttribSource"
+ .Width = 65
+ .Header.VisiblePosition = 4
+ .ValueList = iugAttrib.iMESUltraGrid.DisplayLayout.ValueLists("ASource")
+ End With
+ Case Else
+ With .Bands(tblTAttrib).Columns(dsWIP.Tables(tblTAttrib).Columns(i).ColumnName.ToUpper)
+ .Hidden = True
+ End With
+ End Select
+ Next
+
+ End With
+
+ End Sub
+
+ Private Sub iugAttrib_iMESUltraGrid_InitializeRow(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeRowEventArgs) Handles iugAttrib.iMESUltraGrid_InitializeRow
+
+ Dim strAttribValue As String
+ strAttribValue = e.Row.Cells("AttribValue").Value.ToString.Trim
+
+ '\\Server\01A.pdf
+ If Mid(strAttribValue, 1, 2) = "\\" Then
+ e.Row.Cells("AttribValue").Style = ColumnStyle.Button
+ e.Row.Cells("AttribValue").Appearance.BackColor = System.Drawing.Color.Pink
+ End If
+
+ '\\HTTP
+ If Mid(strAttribValue.ToUpper, 1, 4) = "HTTP" Then
+ e.Row.Cells("AttribValue").Style = ColumnStyle.Button
+ e.Row.Cells("AttribValue").Appearance.BackColor = System.Drawing.Color.Pink
+ End If
+ '\\HTTPS
+ If Mid(strAttribValue.ToUpper, 1, 5) = "HTTPS" Then
+ e.Row.Cells("AttribValue").Style = ColumnStyle.Button
+ e.Row.Cells("AttribValue").Appearance.BackColor = System.Drawing.Color.Pink
+ End If
+
+ End Sub
+
+ Private Sub iugAttrib_iMESUltraGrid_ClickCellButton(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.CellEventArgs) Handles iugAttrib.iMESUltraGrid_ClickCellButton
+
+ Cursor.Current = Cursors.WaitCursor
+
+ Dim strFilePath As String
+
+ strFilePath = e.Cell.Row.Cells("AttribValue").Value.ToString.Trim
+
+ If strFilePath = "" Then Exit Sub
+
+ Try
+ Dim objProcess As New Process
+ objProcess.Start(strFilePath)
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ End Try
+
+ Cursor.Current = Cursors.Default
+
+ End Sub
+
+ Private Sub iugMaterial_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugMaterial.iMESUltraGrid_InitializeLayOut
+
+ Dim i As Integer
+
+ With e.Layout
+ For i = 0 To dsWIP.Tables(tblTMaterial).Columns.Count - 1
+ With .Bands(tblTMaterial).Columns(i)
+ .Hidden = True
+ .Header.VisiblePosition = 99
+ End With
+ Next
+ With .Bands(tblTMaterial).Columns("MaterialLevelShow")
+ .Header.Caption = "MaterialLevelShow"
+ .Hidden = False
+ .CalculateAutoResizeWidth(PerformAutoSizeType.VisibleRows, True)
+ .Header.VisiblePosition = 0
+ .ValueList = vlMaterialLevel
+ End With
+ With .Bands(tblTMaterial).Columns("MaterialType")
+ .Header.Caption = "MaterialType"
+ .Width = 30
+ .Hidden = False
+ .Header.VisiblePosition = 1
+ End With
+ With .Bands(tblTMaterial).Columns("MaterialNo")
+ .Header.Caption = "MaterialNo"
+ .Width = 100
+ .Hidden = False
+ .Header.VisiblePosition = 2
+ End With
+ With .Bands(tblTMaterial).Columns("StdUseQty")
+ .Header.Caption = "StdUseQty"
+ .Width = 70
+ .Hidden = False
+ .Header.VisiblePosition = 3
+ .Format = "0.########"
+ .CellAppearance.TextHAlign = Infragistics.Win.HAlign.Right
+ End With
+ With .Bands(tblTMaterial).Columns("UnitNo")
+ .Header.Caption = "UnitNo"
+ .Width = 70
+ .Hidden = False
+ .Header.VisiblePosition = 4
+ End With
+ With .Bands(tblTMaterial).Columns("MTLLotNoSearch")
+ .Header.Caption = ""
+ .Width = 40
+ .Hidden = blnByEQP
+ .Header.VisiblePosition = 5
+ .CellAppearance.TextHAlign = Infragistics.Win.HAlign.Center
+ '20231106,13871,0148577: Online Help優化建議
+ .Tag = New COM_Kit.TagInformation.clsGridColumnTag() With {.UseOnlineHelp = False}
+ .Style = ColumnStyle.Button
+ .CellAppearance.BackColor = System.Drawing.Color.Pink
+ .CellButtonAppearance.BackColor = Color.Pink
+ .CellButtonAppearance.BorderColor3DBase = Color.Pink
+ .CellButtonAppearance.BackGradientStyle = GradientStyle.Rectangular
+ End With
+
+ With .Bands("MTLLotNo").Columns("EquipmentNo")
+ If blnByEQP = True Then
+ .Hidden = False
+ .Width = 40
+ Else
+ .Hidden = True
+ End If
+ End With
+ With .Bands("MTLLotNo").Columns("OrgMaterialNo")
+ .Hidden = True
+ End With
+ With .Bands("MTLLotNo").Columns("MaterialNo")
+ .Hidden = True
+ End With
+ With .Bands("MTLLotNo").Columns("SUBSTITUTEMATERIALNO")
+ .Hidden = False
+ End With
+ With .Bands("MTLLotNo").Columns("MaterialLotNo")
+ .Hidden = False
+ End With
+ With .Bands("MTLLotNo").Columns("Qty")
+ .Hidden = False
+ .Format = "0.########"
+ .Width = 50
+ .CellAppearance.TextHAlign = Infragistics.Win.HAlign.Right
+ End With
+ End With
+
+ End Sub
+
+ Private Sub iugMaterial_iMESUltraGrid_InitializeRow(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeRowEventArgs) Handles iugMaterial.iMESUltraGrid_InitializeRow
+
+ If e.Row.Band.Key = tblTMaterial Then
+ e.Row.Cells("MaterialLevelShow").Appearance.BackColor = System.Drawing.Color.Pink
+ e.Row.Cells("MaterialType").Appearance.BackColor = System.Drawing.Color.Pink
+ e.Row.Cells("MaterialNo").Appearance.BackColor = System.Drawing.Color.Pink
+ e.Row.Cells("StdUseQty").Appearance.BackColor = System.Drawing.Color.Pink
+ e.Row.Cells("UnitNo").Appearance.BackColor = System.Drawing.Color.Pink
+
+ 'e.Row.Cells("MTLLotNoSearch").Style = ColumnStyle.Button
+ 'e.Row.Cells("MTLLotNoSearch").Appearance.BackColor = System.Drawing.Color.Pink
+ 'e.Row.Cells("MTLLotNoSearch").ButtonAppearance.BackColor = Color.Pink
+ 'e.Row.Cells("MTLLotNoSearch").ButtonAppearance.BorderColor3DBase = Color.Pink
+ 'e.Row.Cells("MTLLotNoSearch").ButtonAppearance.BackGradientStyle = GradientStyle.Rectangular
+ e.Row.Cells("MTLLotNoSearch").Value = "..."
+ e.Row.Update()
+ End If
+
+ End Sub
+
+ Private Sub iugMaterial_iMESUltraGrid_ClickCellButton(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.CellEventArgs) Handles iugMaterial.iMESUltraGrid_ClickCellButton
+
+ Dim dvData As DataView
+
+ Try
+ If iugMaterial.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
+
+ Dim MaterialNo As String = iugMaterial.iMESUltraGrid.ActiveRow.Cells("MaterialNo").Value
+ Dim drSel() As DataRow = dsWIP.Tables(tblTMaterial).Select("MaterialNo='" & MaterialNo & "'")
+ If drSel.Length = 0 Then Exit Sub
+
+ Dim dtMLot As DataTable = dsWIP.Tables(tblTmpMTLLotNo).Copy
+ Dim drTMaterial As DataRow = drSel(0)
+ Dim parameters As New Dictionary(Of String, Object) From {
+ {"drMaterial", drTMaterial},
+ {"dtMLot", dtMLot},
+ {"blnCheckIn", True}
+ }
+ Me.ObjectFileHandler.Execute("WP_MaterialQtyInput_Main", parameters)
+
+ drSel = dsWIP.Tables(tblTmpMTLLotNo).Select("OrgMaterialNo='" & MaterialNo & "'")
+ For Each dr In drSel
+ dr.Delete()
+ Next
+ dsWIP.Tables(tblTmpMTLLotNo).AcceptChanges()
+
+ dtMLot = parameters("dtMLot")
+ For Each drMLot As DataRow In dtMLot.Rows
+ drSel = dsWIP.Tables(tblTmpMTLLotNo).Select(
+ "SubstituteMaterialNo='" & drMLot("SubstituteMaterialNo").ToString() & "' And
+ MaterialLotNo='" & drMLot("MaterialLotNo").ToString() & "'")
+ If drSel.Length > 0 Then Continue For
+
+ Dim drAdd As DataRow = dsWIP.Tables(tblTmpMTLLotNo).NewRow
+ For Each dcMLot As DataColumn In dtMLot.Columns
+ drAdd(dcMLot.ColumnName) = drMLot(dcMLot.ColumnName).ToString()
+ Next
+ dsWIP.Tables(tblTmpMTLLotNo).Rows.Add(drAdd)
+ Next
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ End Try
+
+ End Sub
+
+ Private Sub iugEquipment_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugEquipment.iMESUltraGrid_InitializeLayOut
+
+ Dim i As Integer
+
+ Dim colShow As New Collection
+
+ With e.Layout
+ 'Hide all, No Edit
+
+ 'Equipment
+ For i = 0 To dsWIP.Tables(tblAreaEquipment).Columns.Count - 1
+ Select Case dsWIP.Tables(tblAreaEquipment).Columns(i).ColumnName.ToUpper
+ Case "CHECKFLAG"
+ With .Bands(tblAreaEquipment).Columns("CheckFlag")
+ .Width = 50
+ .Header.VisiblePosition = 1
+ .Style = Infragistics.Win.UltraWinGrid.ColumnStyle.CheckBox
+ .CellAppearance.BackColor = System.Drawing.Color.White
+ End With
+ Case "EQUIPMENTNO"
+ With .Bands(tblAreaEquipment).Columns("EquipmentNo")
+ .Width = 100
+ .Header.VisiblePosition = 2
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case "EQUIPMENTNAME"
+ '[Mantis:80651]2020/10/27,Boyi,EquipmentDescription => EquipmentName
+ ' dsWIP.Tables(tblAreaEquipment).Columns("EquipmentName").ColumnName = "EquipmentDescription"
+ With .Bands(tblAreaEquipment).Columns("EquipmentName")
+ .Header.Caption = "EquipmentName"
+ .Width = 150
+ .Header.VisiblePosition = 3
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case "RECIPEGROUP"
+ With .Bands(tblAreaEquipment).Columns("RecipeGroup")
+ .Width = 80
+ .Header.VisiblePosition = 4
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case "RECIPEVERSION"
+ With .Bands(tblAreaEquipment).Columns("RecipeVersion")
+ .Width = 50
+ .Header.VisiblePosition = 5
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case "DESCRIPTION"
+ With .Bands(tblAreaEquipment).Columns("Description")
+ .Width = 100
+ .Header.VisiblePosition = 6
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case "QCLISTNO"
+ With .Bands(tblAreaEquipment).Columns("QCListNo")
+ .Header.VisiblePosition = 7
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case "DISPATCHORDER"
+ With .Bands(tblAreaEquipment).Columns("DispatchOrder")
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ .CellAppearance.TextHAlign = Infragistics.Win.HAlign.Right
+ End With
+ Case "DISPATCHDATE" ''2020/11/05 Steven Mantis:0081316: 手動派工,新增顯示欄位
+ With .Bands(tblAreaEquipment).Columns("DispatchDate")
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ .Format = "yyyy/MM/dd"
+ .Width = 100
+ End With
+ '2023/07/25會議結論, 規格書規畫尚不清晰,此項目註解。
+ 'Case "LOGICALRECIPENAME" '2023/07/20, 0138119: [6.0.7]recipe配方管理优化派工--配方关联设定, 19245
+ ' With .Bands(tblAreaEquipment).Columns("LogicalRecipeName")
+ ' .Width = 80
+ ' .Header.VisiblePosition = 4
+ ' .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ ' .TabStop = False
+ ' End With
+ 'Case "LOGICALRECIPEVERSION" '2023/07/20, 0138119: [6.0.7]recipe配方管理优化派工--配方关联设定, 19245
+ ' With .Bands(tblAreaEquipment).Columns("LogicalRecipeVersion")
+ ' .Width = 100
+ ' .Header.VisiblePosition = 5
+ ' .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ ' .TabStop = False
+ ' End With
+ Case Else
+ With .Bands(tblAreaEquipment).Columns(dsWIP.Tables(tblAreaEquipment).Columns(i).ColumnName.ToUpper)
+ .Hidden = True
+ End With
+ End Select
+ Next
+ 'Chamber
+ If Not dsWIP.Tables("Chamber") Is Nothing Then
+ For i = 0 To dsWIP.Tables("Chamber").Columns.Count - 1
+ Select Case dsWIP.Tables("Chamber").Columns(i).ColumnName.ToUpper
+ Case "SELECT1"
+ With .Bands("Chamber").Columns("SELECT1")
+ .Width = 50
+ .Header.VisiblePosition = 1
+ .Style = Infragistics.Win.UltraWinGrid.ColumnStyle.CheckBox
+ .CellAppearance.BackColor = System.Drawing.Color.White
+ End With
+ Case "EQUIPMENTNO"
+ With .Bands("Chamber").Columns("EQUIPMENTNO")
+ .Width = 100
+ .Header.VisiblePosition = 2
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case "EQUIPMENTNAME"
+ With .Bands("Chamber").Columns("EQUIPMENTNAME")
+ .Header.Caption = "EquipmentName"
+ .Width = 150
+ .Header.VisiblePosition = 3
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case "DESCRIPTION"
+ With .Bands("Chamber").Columns("Description")
+ .Width = 100
+ .Header.VisiblePosition = 4
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case Else
+ With .Bands("Chamber").Columns(dsWIP.Tables("Chamber").Columns(i).ColumnName.ToUpper)
+ .Hidden = True
+ End With
+ End Select
+ Next
+ End If
+ 'For i = 1 To colShow.Count
+ ' .Columns(CStr(colShow(i))).Hidden = False
+ ' .Columns(CStr(colShow(i))).Header.VisiblePosition = i
+ 'Next
+
+ colShow.Add("CHECKFLAG")
+ colShow.Add("EQUIPMENTNO")
+ colShow.Add("EQUIPMENTNAME")
+ colShow.Add("RECIPEGROUP")
+ colShow.Add("RECIPEVERSION")
+ 'colShow.Add("LOGICALRECIPENAME") '2023/07/25會議結論, 規格書規畫尚不清晰,此項目註解。
+ 'colShow.Add("LOGICALRECIPEVERSION")
+ colShow.Add("DESCRIPTION")
+ colShow.Add("QCLISTNO")
+ colShow.Add("DISPATCHDATE")
+ colShow.Add("DISPATCHORDER")
+
+ 'Accessory
+ If Not dsWIP.Tables("AccState") Is Nothing Then
+ For i = 0 To dsWIP.Tables("AccState").Columns.Count - 1
+ Select Case dsWIP.Tables("AccState").Columns(i).ColumnName.ToUpper
+ Case "SELECT"
+ With .Bands("Accessory").Columns("SELECT")
+ .Width = 50
+ .Header.VisiblePosition = 1
+ .Style = Infragistics.Win.UltraWinGrid.ColumnStyle.CheckBox
+ .CellAppearance.BackColor = System.Drawing.Color.White
+ End With
+ Case "ACCESSORYNO"
+ With .Bands("Accessory").Columns("AccessoryNo")
+ .Width = 80
+ .Header.Appearance.BackColor = System.Drawing.Color.Yellow
+ .Header.VisiblePosition = 2
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case "ACCESSORYTYPE"
+ With .Bands("Accessory").Columns("AccessoryType")
+ .Width = 80
+ .Header.Appearance.BackColor = System.Drawing.Color.Yellow
+ .Header.VisiblePosition = 3
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case "STARTTIME"
+ With .Bands("Accessory").Columns("StartTime")
+ .Width = 120
+ .Header.Appearance.BackColor = System.Drawing.Color.Yellow
+ .Header.VisiblePosition = 4
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ .Format = "yyyy/MM/dd HH:mm:ss"
+ End With
+ Case "ACCUMULATEQTY"
+ With .Bands("Accessory").Columns("AccumulateQty")
+ .Width = 80
+ .Header.Appearance.BackColor = System.Drawing.Color.Yellow
+ .Header.VisiblePosition = 5
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .CellAppearance.TextHAlign = Infragistics.Win.HAlign.Right
+ .TabStop = False
+ .Format = "0.######"
+ End With
+ Case "REPAIRCYCLE"
+ With .Bands("Accessory").Columns("RepairCycle")
+ .Width = 80
+ .Header.Appearance.BackColor = System.Drawing.Color.Yellow
+ .Header.VisiblePosition = 6
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .CellAppearance.TextHAlign = Infragistics.Win.HAlign.Right
+ .TabStop = False
+ .Format = "0.######"
+ End With
+ Case Else
+ With .Bands("Accessory").Columns(dsWIP.Tables("AccState").Columns(i).ColumnName.ToUpper)
+ .Hidden = True
+ End With
+ End Select
+ Next
+ End If
+
+ 'Recipe
+ 'Dim vlRecipeType As New ValueList '2023/07/25會議結論, 規格書規畫尚不清晰,此項目註解。
+ 'vlRecipeType = COM_Utility.ValueListProvider.GetInstance.GetValueList("TBLPRDMACHINERECIPEDETAIL", "RECIPETYPE", True)
+
+ If Not dsWIP.Tables("RecipeDetail") Is Nothing Then
+ For i = 0 To dsWIP.Tables("RecipeDetail").Columns.Count - 1
+ Select Case dsWIP.Tables("RecipeDetail").Columns(i).ColumnName.ToUpper
+ Case "RECIPENO"
+ With .Bands("Recipe").Columns("RecipeNo")
+ .Width = 80
+ .Header.Appearance.BackColor = System.Drawing.Color.Yellow
+ .Header.VisiblePosition = 1
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ Case "RECIPEVALUE"
+ With .Bands("Recipe").Columns("RecipeValue")
+ .Width = 100
+ .Header.Appearance.BackColor = System.Drawing.Color.Yellow
+ .Header.VisiblePosition = 2
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .TabStop = False
+ End With
+ '2023/07/25會議結論, 規格書規畫尚不清晰,此項目註解。
+ 'Case "RECIPEPARAMETERNO" '0138119: [6.0.7]recipe配方管理优化派工--配方关联设定, 2023/07/20, 19245
+ ' With .Bands("Recipe").Columns("RecipeParameterNo")
+ ' .Width = 80
+ ' .Header.Appearance.BackColor = System.Drawing.Color.Yellow
+ ' .Header.VisiblePosition = 1
+ ' .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ ' .TabStop = False
+ ' End With
+ 'Case "RECIPETYPE" '0138119: [6.0.7]recipe配方管理优化派工--配方关联设定, 2023/07/21, 19245
+ ' With .Bands("Recipe").Columns("RecipeType")
+ ' .Width = 80
+ ' .Header.Appearance.BackColor = System.Drawing.Color.Yellow
+ ' .Header.VisiblePosition = 2
+ ' .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ ' .TabStop = False
+ ' .ValueList = vlRecipeType
+ 'End With
+
+ Case Else
+ With .Bands("Recipe").Columns(dsWIP.Tables("RecipeDetail").Columns(i).ColumnName.ToUpper)
+ .Hidden = True
+ End With
+ End Select
+ Next
+ End If
+ End With
+
+ 'UltraGrid
+ iugEquipment.iMESUltraGrid.DisplayLayout.Override.AllowUpdate = Infragistics.Win.DefaultableBoolean.True
+ iugEquipment.iMESUltraGrid.Rows.ExpandAll(True)
+
+ End Sub
+
+ Private Sub iugEquipment_iMESUltraGrid_BeforeCellUpdate(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.BeforeCellUpdateEventArgs) Handles iugEquipment.iMESUltraGrid_BeforeCellUpdate
+ Dim drTemp As DataRow()
+ Dim strType As String
+ Dim blnNeedSelect As Boolean
+ '勾選設備後,才自動勾選模治具
+ If e.Cell.Column.Key.ToUpper = "CHECKFLAG" AndAlso e.NewValue = True Then
+ '預設選取每個類別第一個模治具
+ For Each dr As DataRow In dsWIP.Tables(tblAreaEquipment).Select("EquipmentNo = '" & e.Cell.Row.Cells(1).Text & "'")
+ strType = ""
+ blnNeedSelect = True
+ If dr("AllowExecute") = 1 Then '可使用
+ drTemp = dsWIP.Tables("AccState").Select("EquipmentNo = '" & dr("EquipmentNo") & "'")
+ For i = 0 To drTemp.Count - 1
+ If drTemp(i)("Select") = True Then blnNeedSelect = False
+ Next
+ If drTemp.Length > 0 AndAlso blnNeedSelect = True Then
+ '有掛模治具
+ For Each dr1 As DataRow In drTemp
+ If strType = "" Then
+ strType = dr1("AccessoryType")
+ dr1("Select") = True
+ ElseIf strType <> dr1("AccessoryType") Then
+ dr1("Select") = True
+ strType = dr1("AccessoryType")
+ End If
+ Next
+ End If
+ End If
+ Next
+ End If
+ End Sub
+ Private Sub iugEquipment_iMESUltraGrid_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles iugEquipment.iMESUltraGrid_KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub iugEquipment_iMESUltraGrid_InitializeRow(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeRowEventArgs) Handles iugEquipment.iMESUltraGrid_InitializeRow
+
+ If e.Row.Band.Key = tblAreaEquipment Then 'Equipment
+ If e.Row.Cells("AllowExecute").Value = 0 Then '不可使用
+ e.Row.Cells("CheckFlag").Activation = Infragistics.Win.UltraWinGrid.Activation.Disabled
+ e.Row.Cells("CheckFlag").Appearance.BackColor = System.Drawing.Color.Gainsboro
+ ElseIf e.Row.Cells("AllowExecute").Value = 1 Then '可使用
+
+ 'CheckFlag
+ If EquipmentNo = defString Then
+ Else
+ '以機台下貨,關閉勾選介面.
+ e.Row.Cells("CheckFlag").Activation = Infragistics.Win.UltraWinGrid.Activation.Disabled
+ e.Row.Cells("CheckFlag").Appearance.BackColor = System.Drawing.Color.Gainsboro
+ End If
+ End If
+ End If
+ '子設備
+ 'TsungYu 2021/06/09
+ If e.Row.Band.Key = "Chamber" Then 'Equipment
+ If e.Row.Cells("AllowExecute").Value = 0 Then '不可使用
+ e.Row.Cells("Select1").Activation = Infragistics.Win.UltraWinGrid.Activation.Disabled
+ e.Row.Cells("Select1").Appearance.BackColor = System.Drawing.Color.Gainsboro
+ ElseIf e.Row.Cells("AllowExecute").Value = 1 Then '可使用
+ 'CheckFlag
+ If EquipmentNo = defString Then
+ Else
+ e.Row.Cells("Select1").Activation = Infragistics.Win.UltraWinGrid.Activation.Disabled
+ e.Row.Cells("Select1").Appearance.BackColor = System.Drawing.Color.Gainsboro
+ End If
+ End If
+ End If
+ If e.Row.Band.Key.ToUpper = "ACCESSORY" Then '模治具
+ '2014/11/24 Kevin,如果是產品-作業站-模治具所設定的模治具則改變底色
+ If Not dsWIP.Tables("PRDAccessory") Is Nothing Then
+ Dim drSelPRD As DataRow()
+ drSelPRD = dsWIP.Tables("PRDAccessory").Select("AccessoryNo = '" & e.Row.Cells("AccessoryNo").Value & "'")
+ If drSelPRD.Length > 0 Then
+ e.Row.Appearance.BackColor = System.Drawing.Color.Yellow
+ Else
+ '找不到的話再看一次模治具類別
+ drSelPRD = dsWIP.Tables("PRDAccessory").Select("AccessoryType = '" & e.Row.Cells("AccessoryType").Value & "' And AccessoryNo ='*'")
+ If drSelPRD.Length > 0 Then
+ e.Row.Appearance.BackColor = System.Drawing.Color.Yellow
+ End If
+ End If
+ End If
+ End If
+
+ End Sub
+
+
+ Private Sub iugEquipment_iMESUltraGrid_AfterCellUpdate(sender As System.Object, e As Infragistics.Win.UltraWinGrid.CellEventArgs) Handles iugEquipment.iMESUltraGrid_AfterCellUpdate
+
+ '如有點選模製具則將設備自動勾選
+ If e.Cell.Column.Key.ToUpper = "SELECT" AndAlso e.Cell.Row.Cells("SELECT").Value Then
+ drSelE = dsWIP.Tables(tblAreaEquipment).Select("EquipmentNo = '" & e.Cell.Row.Cells("EquipmentNo").Value & "'")
+ For Each dr As DataRow In drSelE
+ dr("CHECKFLAG") = True
+ Next
+ End If
+
+ If e.Cell.Column.Key.ToUpper = "CHECKFLAG" AndAlso e.Cell.Row.Cells("CHECKFLAG").Value = False Then
+ drSelE = dsWIP.Tables("AccState").Select("EquipmentNo = '" & iugEquipment.iMESUltraGrid.ActiveRow.Cells("EquipmentNo").Value & "'")
+ For Each dr As DataRow In drSelE
+ dr("Select") = False
+ Next
+
+ '2021/9/14 Mantis:0099587 當取消勾選設備時,此設備已開立的點檢單應刪除
+ '自動開立點檢務單
+ Call funCheckEQPQCTask(e.Cell.Row.Cells("EquipmentNo").Value, True)
+
+ If blnByEQP = True Then
+ DeleteTmpMTLLotNo(e.Cell.Row.Cells("EquipmentNo").Value)
+ End If
+
+ Else
+ If blnByEQP = True Then
+ Call LoadMaterialByEquipment(e.Cell.Row.Cells("EquipmentNo").Value)
+ End If
+ End If
+
+ If Not dsWIP.Tables("Chamber") Is Nothing Then
+ If dsWIP.Tables("Chamber").Rows.Count > 0 Then
+ '如有點選子設備則將設備自動勾選
+ If e.Cell.Column.Key.ToUpper = "SELECT1" AndAlso e.Cell.Row.Cells("SELECT1").Value Then
+ If Not String.IsNullOrEmpty(e.Cell.Row.Cells("BELONGEQUIPMENTNO").Value.ToString) Then
+ drSelE = dsWIP.Tables(tblAreaEquipment).Select("EquipmentNo = '" & e.Cell.Row.Cells("BelongEquipmentNo").Value & "'")
+ For Each dr As DataRow In drSelE
+ dr("CHECKFLAG") = True
+ Next
+ End If
+ End If
+ '設備取消時子設備的勾選也自動取消
+ If e.Cell.Column.Key.ToUpper = "CHECKFLAG" AndAlso e.Cell.Row.Cells("CHECKFLAG").Value = False Then
+ drSelE = dsWIP.Tables("Chamber").Select("BelongEquipmentNo = '" & iugEquipment.iMESUltraGrid.ActiveRow.Cells("EquipmentNo").Value & "'")
+ For Each dr As DataRow In drSelE
+ dr("SELECT1") = False
+ Next
+ '設備勾選時自動勾選子設備
+ ElseIf e.Cell.Column.Key.ToUpper = "CHECKFLAG" AndAlso e.Cell.Row.Cells("CHECKFLAG").Value Then
+ drSelE = dsWIP.Tables("Chamber").Select("BelongEquipmentNo = '" & iugEquipment.iMESUltraGrid.ActiveRow.Cells("EquipmentNo").Value & "' and AllowExecute = 1")
+ For Each dr As DataRow In drSelE
+ dr("SELECT1") = True
+ Next
+ End If
+ End If
+ End If
+ ' 2016/01/27 YF, 取得設備參數值
+ e.Cell.Row.Update()
+
+ funGetEquipmentRecipe()
+
+
+ End Sub
+
+ Private Sub iugEquipment_iMESUltraGrid_CellChange(sender As Object, e As Infragistics.Win.UltraWinGrid.CellEventArgs) Handles iugEquipment.iMESUltraGrid_CellChange
+ ' CheckFlag被點選時, 可立即將結果異動回DataTable
+ e.Cell.Row.Update()
+ Me.iugEquipment.iMESUltraGrid.ActiveRow = e.Cell.Row
+ End Sub
+
+ Private Sub iugKeyIn_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugKeyIn.iMESUltraGrid_InitializeLayOut
+
+ With e.Layout
+ With .Bands("KeyIn").Columns("AttribNo")
+ .Header.Caption = "AttribNo"
+ .Width = 90
+ .Header.VisiblePosition = 1
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .CellAppearance.BackColor = System.Drawing.Color.Gainsboro
+ .TabStop = False
+ End With
+ With .Bands("KeyIn").Columns("AttribName")
+ .Header.Caption = "AttribName"
+ .Width = 150
+ .Header.VisiblePosition = 2
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .CellAppearance.BackColor = System.Drawing.Color.Gainsboro
+ .TabStop = False
+ End With
+ With .Bands("KeyIn").Columns("AttribValue")
+ .Header.Caption = "AttribValue"
+ .Width = 130
+ .Header.VisiblePosition = 3
+ End With
+ '2015-12-18, Joe, Add
+ With .Bands("KeyIn").Columns("QCItemNo")
+ .Header.Caption = "QCItemNo"
+ .Width = 90
+ .Header.VisiblePosition = 4
+ .CellActivation = Infragistics.Win.UltraWinGrid.Activation.ActivateOnly
+ .CellAppearance.BackColor = System.Drawing.Color.Gainsboro
+ .TabStop = False
+ End With
+ With .Bands("KeyIn").Columns("AttribSequence")
+ .Hidden = True
+ End With
+ With .Bands("KeyIn").Columns("InputType")
+ .Hidden = True
+ End With
+ With .Bands("KeyIn").Columns("DataType")
+ .Hidden = True
+ End With
+ With .Bands("KeyIn").Columns("ValueType")
+ .Hidden = True
+ End With
+
+ .Bands("KeyIn").Columns("OrgAttribValue").Hidden = True ' 2016/01/27 YF
+ End With
+
+ 'UltraGrid
+ iugKeyIn.iMESUltraGrid.DisplayLayout.Override.AllowUpdate = Infragistics.Win.DefaultableBoolean.True
+
+ End Sub
+
+ Private Sub iugKeyIn_iMESUltraGrid_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles iugKeyIn.iMESUltraGrid_KeyPress
+ If e.KeyChar = Convert.ToChar(13) Then
+ SendKeys.Send("{TAB}")
+ End If
+ End Sub
+
+ Private Sub iugKeyIn_iMESUltraGrid_InitializeRow(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeRowEventArgs) Handles iugKeyIn.iMESUltraGrid_InitializeRow
+ Dim strAttribValue As String
+
+ Try
+
+ 'InputType=1 清單選擇
+ If e.Row.Cells("InputType").Value = 1 Then
+ e.Row.Cells("AttribValue").Style = ColumnStyle.Button
+ e.Row.Cells("AttribValue").Appearance.BackColor = System.Drawing.Color.Pink
+ ElseIf e.Row.Cells("DataType").Value = 3 Then
+ e.Row.Cells("AttribValue").Style = ColumnStyle.DateTime
+ e.Row.Cells("AttribValue").Editor = editor
+ e.Row.Cells("AttribValue").Appearance.BackColor = Color.White
+ End If
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ End Try
+
+ End Sub
+
+ Private Sub iugKeyIn_iMESUltraGrid_ClickCellButton(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.CellEventArgs) Handles iugKeyIn.iMESUltraGrid_ClickCellButton
+
+ Dim intValueType As Integer
+
+ Cursor.Current = Cursors.WaitCursor
+
+ Try
+
+ intValueType = iugKeyIn.iMESUltraGrid.ActiveRow.Cells("ValueType").Value
+
+ If intValueType = 3 OrElse intValueType = 1 Then 'Reference System Parameter / Assign Valid Value
+ If Not IsNothing(dsWIP.Tables(strDefaultValue)) Then
+ dsWIP.Tables.Remove(strDefaultValue)
+ End If
+
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = CombineXMLParameter("elementno", "PropertyType", "String", iugKeyIn.iMESUltraGrid.ActiveRow.Cells("AttribNo").Value, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ OutXml = InvokeSrv("wsSYS.LoadElementValue", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ '//取出Data
+ strDefaultValue = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadelementvalue").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadelementvalue").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadelementvalue").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" And XmlData <> "fail" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+
+ Dim fSearch As New frmCOMSearch
+ '如果 PropertyNo 的有效性檢查來自 MESParameter,則取出有效值提供選擇
+ fSearch.dvSearch = dsWIP.Tables(strDefaultValue).DefaultView
+ fSearch.strFindColumnName = dsWIP.Tables(strDefaultValue).Columns(0).ColumnName
+ '20221214,13871,右鍵 儲存設計 需要使用Owner(程式碼由程序建立)
+ fSearch.ShowDialog(Me)
+ fSearch.Dispose()
+
+ If Not drSearch Is Nothing Then
+ If Not IsDBNull(drSearch(0).ToString) Then
+ iugKeyIn.iMESUltraGrid.ActiveRow.Cells("AttribValue").Value = drSearch(0).ToString
+ End If
+ End If
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Sub
+ End If
+
+ End If
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ End Try
+
+ End Sub
+
+ Private Sub iugSubOP_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugSubOP.iMESUltraGrid_InitializeLayOut
+
+ Dim i As Integer
+
+ With e.Layout
+ For i = 0 To dsWIP.Tables(tblSubOP).Columns.Count - 1
+ Select Case dsWIP.Tables(tblSubOP).Columns(i).ColumnName.ToUpper
+ Case "SUBOPSEQUENCE"
+ With .Bands(tblSubOP).Columns("SubOPSequence")
+ .Header.Caption = "SubOPSequence"
+ .Width = 50
+ .Hidden = False
+ .Header.VisiblePosition = 1
+ End With
+ Case "SUBOPNO"
+ With .Bands(tblSubOP).Columns("SubOPNo")
+ .Header.Caption = "SubOPNo"
+ .Width = 80
+ .Header.VisiblePosition = 2
+ End With
+ Case "SUBOPNAME"
+ With .Bands(tblSubOP).Columns("SubOPName")
+ .Header.Caption = "SubOPName"
+ .Width = 180
+ .Header.VisiblePosition = 3
+ End With
+ Case "CREATOR"
+ With .Bands(tblSubOP).Columns("Creator")
+ .Header.Caption = "Creator"
+ .Width = 70
+ .Hidden = True
+ .Header.VisiblePosition = 4
+ End With
+ Case "CREATEDATE"
+ With .Bands(tblSubOP).Columns("CreateDate")
+ .Width = 120
+ .Header.VisiblePosition = 5
+ .Hidden = True
+ .Format = "yyyy/MM/dd HH:mm:ss"
+ End With
+ Case Else
+ With .Bands(tblSubOP).Columns(dsWIP.Tables(tblSubOP).Columns(i).ColumnName.ToUpper)
+ .Hidden = True
+ End With
+ End Select
+ Next
+
+ End With
+
+ End Sub
+
+#End Region
+
+#Region "Equipment"
+
+ Private Sub txtEquipmentNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEquipmentNo.Enter
+ txtEquipmentNo.SelectAll()
+ End Sub
+ Private Sub txtEquipmentNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtEquipmentNo.KeyPress
+
+ Cursor.Current = Cursors.WaitCursor
+
+ '強制使用機台,故不提供此功能
+
+ If EquipmentNo <> defString Then Exit Sub
+
+ If e.KeyChar = Convert.ToChar(13) Then
+ If txtEquipmentNo.Text.Trim <> "" Then
+ Dim drSel() As DataRow
+ Dim strEQPNo As String
+ strEQPNo = txtEquipmentNo.Text.Trim.ToUpper
+ '檢查EquipmentNo是否存在
+ drSel = dsWIP.Tables(tblAreaEquipment).Select("EquipmentNo='" & strEQPNo & "'")
+ If drSel.Length = 0 Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-203072", "[%EquipmentNo%]:" & strEQPNo & " [%is not in area%]:" & txtAreaNo.Text & "!"), MsgBoxStyle.Exclamation, Me.Text)
+ txtEquipmentNo.SelectAll()
+ Exit Sub
+ Else
+ If drSel(0)("AllowExecute") = 1 Then '可使用
+ drSel(0)("CheckFlag") = True
+ If blnByEQP = True Then
+ Call LoadMaterialByEquipment(strEQPNo)
+ End If
+
+ Else '不可使用
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-203072", "[%EquipmentNo%]:" & strEQPNo & " [%is not available%] " & Chr(10) + Chr(13) & drSel(0)("Description")), MsgBoxStyle.Exclamation, Me.Text)
+ txtEquipmentNo.SelectAll()
+ Exit Sub
+ End If
+ End If
+
+ 'Focus
+ Dim ugrRow As Infragistics.Win.UltraWinGrid.UltraGridRow
+ ugrRow = FindRecordPosition(iugEquipment, "EquipmentNo", strEQPNo)
+ If Not ugrRow Is Nothing Then
+ iugEquipment.iMESUltraGrid.ActiveRow = ugrRow
+ iugEquipment.iMESUltraGrid.ActiveRow.Selected = True
+ End If
+
+ txtEquipmentNo.Text = ""
+ txtEquipmentNo.Focus()
+ End If
+ End If
+
+ Cursor.Current = Cursors.Default
+
+ End Sub
+
+
+#End Region
+
+#Region "Load functions"
+
+ Private Function funLoadLotState() As Integer
+
+ funLoadLotState = -1
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", LotNo, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP.LoadLotBasisJoinState", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ '讀取取出資料表之名稱
+ tblLotState = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadlotbasisjoinstate").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadlotbasisjoinstate").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ '取出Data
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadlotbasisjoinstate").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ If dsWIP.Tables(tblLotState).Rows.Count > 0 Then
+ If dsWIP.Tables(tblLotState).Rows(0)("MaterialOption").ToString = "1" Then
+ blnByEQP = True
+ End If
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funLoadLotState = 0
+
+ End Function
+
+ Private Function funLoadTemp_AttribJoinBasis() As Integer
+
+ funLoadTemp_AttribJoinBasis = -1
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", LotNo, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP.LoadTemp_AttribJoinBasis", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ tblTAttrib = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadtemp_attrib").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadtemp_attrib").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadtemp_attrib").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+
+ Call funAddValueList_Attrib()
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funLoadTemp_AttribJoinBasis = 0
+
+
+ End Function
+
+ Private Function funLoadTemp_Material() As Integer
+
+ funLoadTemp_Material = -1
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", LotNo, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP.LoadTemp_Material", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ tblTMaterial = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadtemp_material").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadtemp_material").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadtemp_material").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+
+ '新增OrgMaterialNo,紀錄原來的主物料用
+ Dim colOrgMaterialNo As New DataColumn
+ colOrgMaterialNo.ColumnName = "OrgMaterialNo"
+ colOrgMaterialNo.DataType = System.Type.GetType("System.String")
+ colOrgMaterialNo.DefaultValue = 0
+ colOrgMaterialNo.AllowDBNull = False
+ dsWIP.Tables(tblTMaterial).Columns.Add(colOrgMaterialNo)
+
+ '加入標準用量欄位
+ Dim colStdQty As New DataColumn
+ colStdQty.ColumnName = "StdUseQty"
+ colStdQty.DataType = System.Type.GetType("System.Decimal")
+ colStdQty.DefaultValue = 0
+ colStdQty.AllowDBNull = False
+ dsWIP.Tables(tblTMaterial).Columns.Add(colStdQty)
+
+ '計算標準使用量
+ Dim decCurQty, decStdQty As Decimal
+ Dim i As Integer
+
+ 'Rows(0)一定會有資料.
+ decCurQty = dsWIP.Tables(tblLotState).Rows(0)("CurQty")
+ For i = 0 To dsWIP.Tables(tblTMaterial).Rows.Count - 1
+ decStdQty = decCurQty * dsWIP.Tables(tblTMaterial).Rows(i)("StdQty") * (1 + dsWIP.Tables(tblTMaterial).Rows(i)("DecreaseRate"))
+ dsWIP.Tables(tblTMaterial).Rows(i)("StdUseQty") = Format(decStdQty, "0.######")
+
+ '紀錄原來的主物料
+ dsWIP.Tables(tblTMaterial).Rows(i)("OrgMaterialNo") = dsWIP.Tables(tblTMaterial).Rows(i)("MaterialNo")
+ Next
+
+ dsWIP.Tables(tblTMaterial).Columns("MaterialLevel").ColumnName = "MaterialLevelShow"
+
+ '加入可供使用者點擊搜尋的欄位
+ dsWIP.Tables(tblTMaterial).Columns.Add(New DataColumn("MTLLotNoSearch", System.Type.GetType("System.String")))
+ dsWIP.Tables(tblTMaterial).DefaultView.RowFilter = "MaterialNo = OrgMaterialNo"
+ dsWIP.Tables(tblTMaterial).DefaultView.Sort = "MaterialType,OrgMaterialNo,MaterialNo"
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funLoadTemp_Material = 0
+
+
+ End Function
+
+ Private Function funLoadAvailableEquipment(ByRef LotNo As String) As Integer
+
+ funLoadAvailableEquipment = -1
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", LotNo, "")
+ strParameter += CombineXMLParameter("getrecipe", "GetRecipe", "Boolean", True, "")
+ strParameter += CombineXMLParameter("getaccessory", "GetAccessory", "Boolean", blnGetAccessory, "")
+ strParameter += CombineXMLParameter("multiqclist", "MultiQCList", "Boolean", True, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP.LoadAvailableEquipment_All", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ tblAreaEquipment = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadavailableequipment_all").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadavailableequipment_all").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadavailableequipment_all").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+
+ '2023/12/21,Ning,154124: L_CI_GEN [語系未處理] 挑選設備後,彈窗訊息顯示 LoadPort is full.
+ For Each drEQP As DataRow In dsWIP.Tables(tblAreaEquipment).Rows
+ If drEQP("Description").ToString <> "" Then
+ drEQP("Description") = ChgTranslateName_Content(drEQP("Description"))
+ End If
+ Next
+
+ '加入Check Field
+ Dim colCheckFlag As New DataColumn
+ colCheckFlag.ColumnName = "CheckFlag"
+ colCheckFlag.DataType = System.Type.GetType("System.Boolean")
+ colCheckFlag.DefaultValue = False
+ colCheckFlag.AllowDBNull = False
+ dsWIP.Tables(tblAreaEquipment).Columns.Add(colCheckFlag)
+ '加入LoadPort
+ Dim colPort As New DataColumn
+ colPort.ColumnName = "LoadPort"
+ colPort.DataType = System.Type.GetType("System.String")
+ dsWIP.Tables(tblAreaEquipment).Columns.Add(colPort)
+
+ '加入點檢識別欄位
+ dsWIP.Tables(tblAreaEquipment).Columns.Add(New DataColumn("QCType", System.Type.GetType("System.Decimal")))
+ dsWIP.Tables(tblAreaEquipment).Columns.Add(New DataColumn("QCFinish", System.Type.GetType("System.Decimal")))
+
+ '開放可編輯
+ dsWIP.Tables(tblAreaEquipment).DefaultView.AllowEdit = True
+
+ If Not dsWIP.Tables("Chamber") Is Nothing Then
+ '加入勾選的按鈕
+ Dim colChamberCheckFlag As New DataColumn
+ colChamberCheckFlag.ColumnName = "SELECT1"
+ colChamberCheckFlag.DataType = System.Type.GetType("System.Boolean")
+ colChamberCheckFlag.DefaultValue = False
+ colChamberCheckFlag.AllowDBNull = False
+ dsWIP.Tables("Chamber").Columns.Add(colChamberCheckFlag)
+ dsWIP.Tables(tblAreaEquipment).DefaultView.AllowEdit = True
+ End If
+ 'Kevin 20131223,如有模治具則開放用選取的方式
+ If Not dsWIP.Tables("AccState") Is Nothing Then
+ '加入勾選的按鈕
+ Dim colSelect As New DataColumn
+ colSelect.ColumnName = "Select"
+ colSelect.DataType = System.Type.GetType("System.Boolean")
+ colSelect.DefaultValue = False
+ colSelect.AllowDBNull = False
+ dsWIP.Tables("AccState").Columns.Add(colSelect)
+
+ dsWIP.Tables("AccState").DefaultView.Sort = "AccessoryType,AccessoryNo"
+ Dim strType As String = ""
+ Dim drTemp As DataRow()
+
+ '預設選取每個類別第一個模治具
+ 'For Each dr As DataRow In dsWIP.Tables(tblAreaEquipment).Rows
+ ' strType = ""
+ ' If dr("AllowExecute") = 1 Then '可使用
+ ' drTemp = dsWIP.Tables("AccState").Select("EquipmentNo = '" & dr("EquipmentNo") & "'")
+ ' If drTemp.Length > 0 Then
+ ' '有掛模治具
+ ' For Each dr1 As DataRow In drTemp
+ ' If strType = "" Then
+ ' strType = dr1("AccessoryType")
+ ' dr1("Select") = True
+ ' ElseIf strType <> dr1("AccessoryType") Then
+ ' dr1("Select") = True
+ ' strType = dr1("AccessoryType")
+ ' End If
+ ' Next
+ ' End If
+ ' End If
+ 'Next
+ '2020/02/26 Grace Mantis 67753 取得此批號於此作業站上的派工資料
+ Call funLoadWIPEQPDispatchState(LotNo:=LotNo, OPNo:=txtOPNo.Text)
+ '增加顯示欄位:派工日期、派工順序
+ If dsWIP.Tables(tblAreaEquipment).Columns.Contains("DispatchOrder") Then
+ dsWIP.Tables(tblAreaEquipment).Columns.Remove("DispatchOrder")
+ End If
+ Dim colDispatchDate As New DataColumn
+ colDispatchDate.ColumnName = "DispatchDate"
+ colDispatchDate.DataType = System.Type.GetType("System.DateTime")
+ dsWIP.Tables(tblAreaEquipment).Columns.Add(colDispatchDate)
+ Dim colDispatchOrder As New DataColumn
+ colDispatchOrder.ColumnName = "DispatchOrder"
+ colDispatchOrder.DataType = System.Type.GetType("System.String")
+ dsWIP.Tables(tblAreaEquipment).Columns.Add(colDispatchOrder)
+
+ If Not IsNothing(dsTemp.Tables(tblEQPDispatchState)) Then
+ If dsTemp.Tables(tblEQPDispatchState).Rows.Count > 0 Then
+ Dim strCheckInDate As String = Now.ToString("yyyy/MM/dd") 'Check In 日期
+ '2020/11/05 Steven Mantis:0081316: '增加顯示欄位:派工日期、派工順序
+ For i As Integer = 0 To dsWIP.Tables(tblAreaEquipment).Rows.Count - 1
+ '1. 檢查是否有派工設備
+ Dim drSelEQP As DataRow() = dsTemp.Tables(tblEQPDispatchState).Select("EquipmentNo = '" &
+ dsWIP.Tables(tblAreaEquipment).Rows(i)("EquipmentNo").ToString() & "'And LotNo = '" & txtLotNo.Text & "'And DispatchDate = '" & strCheckInDate & "'")
+ If drSelEQP.Count > 0 Then '優先顯示派工日期為當天
+ dsWIP.Tables(tblAreaEquipment).Rows(i)("DispatchOrder") = drSelEQP(0)("DispatchOrder").ToString
+ If drSelEQP(0)("DispatchDate").ToString <> "" Then
+ dsWIP.Tables(tblAreaEquipment).Rows(i)("DispatchDate") = drSelEQP(0)("DispatchDate")
+ End If
+ Else '如非當天派工日期再顯示
+ Dim drSelEQP2 As DataRow() = dsTemp.Tables(tblEQPDispatchState).Select("EquipmentNo = '" &
+ dsWIP.Tables(tblAreaEquipment).Rows(i)("EquipmentNo").ToString() & "'And LotNo = '" & txtLotNo.Text & "'")
+ If drSelEQP2.Length > 0 Then
+ dsWIP.Tables(tblAreaEquipment).Rows(i)("DispatchOrder") = drSelEQP2(0)("DispatchOrder").ToString
+ If drSelEQP2(0)("DispatchDate").ToString <> "" Then
+ dsWIP.Tables(tblAreaEquipment).Rows(i)("DispatchDate") = drSelEQP2(0)("DispatchDate")
+ End If
+ End If
+ End If
+ Next
+ End If
+ End If
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funLoadAvailableEquipment = 0
+
+
+ End Function
+
+ '2023/07/25會議結論, 規格書規畫尚不清晰,此項目註解。
+ '0138119: [6.0.7]recipe配方管理优化派工--配方关联设定, 2023-07-20, 19245
+ 'Private Function funLoadAvailableEquipmentInfo(ByRef LotNo As String) As Integer
+
+ ' funLoadAvailableEquipmentInfo = -1
+
+ ' '組InXml的字串
+ ' strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ ' strParameter = CombineXMLParameter("lotno", "LotNo", "String", LotNo, "")
+ ' strParameter += CombineXMLParameter("getrecipe", "GetRecipe", "Boolean", True, "")
+ ' strParameter += CombineXMLParameter("getaccessory", "GetAccessory", "Boolean", blnGetAccessory, "")
+ ' strParameter += CombineXMLParameter("multiqclist", "MultiQCList", "Boolean", True, "")
+ ' InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ ' Try
+ ' OutXml = InvokeSrv("wsWIP.LoadAvailableEquipmentInfo", InXml)
+
+ ' Dim XmlDoc As New XmlDocument
+ ' XmlDoc.LoadXml(OutXml)
+ ' If ChkExecutionSuccess(XmlDoc) Then
+ ' tblAreaEquipment = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadavailableequipmentinfo").Item(0).SelectNodes("name").Item(0).InnerXml
+ ' '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ ' XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadavailableequipmentinfo").Item(0).SelectNodes("schema").Item(0).InnerXml
+ ' If XmlSchema <> "" Then
+ ' '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ ' tmpStringReader = New System.IO.StringReader(XmlSchema)
+ ' dsWIP.ReadXmlSchema(tmpStringReader)
+ ' tmpStringReader.Close()
+ ' End If
+ ' XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadavailableequipmentinfo").Item(0).SelectNodes("value").Item(0).InnerXml
+ ' If XmlData <> "" Then
+ ' tmpStringReader = New System.IO.StringReader(XmlData)
+ ' dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ ' tmpStringReader.Close()
+ ' End If
+
+ ' '加入Check Field
+ ' Dim colCheckFlag As New DataColumn
+ ' colCheckFlag.ColumnName = "CheckFlag"
+ ' colCheckFlag.DataType = System.Type.GetType("System.Boolean")
+ ' colCheckFlag.DefaultValue = False
+ ' colCheckFlag.AllowDBNull = False
+ ' dsWIP.Tables(tblAreaEquipment).Columns.Add(colCheckFlag)
+ ' '加入LoadPort
+ ' Dim colPort As New DataColumn
+ ' colPort.ColumnName = "LoadPort"
+ ' colPort.DataType = System.Type.GetType("System.String")
+ ' dsWIP.Tables(tblAreaEquipment).Columns.Add(colPort)
+
+ ' '加入點檢識別欄位
+ ' dsWIP.Tables(tblAreaEquipment).Columns.Add(New DataColumn("QCType", System.Type.GetType("System.Decimal")))
+ ' dsWIP.Tables(tblAreaEquipment).Columns.Add(New DataColumn("QCFinish", System.Type.GetType("System.Decimal")))
+
+ ' '開放可編輯
+ ' dsWIP.Tables(tblAreaEquipment).DefaultView.AllowEdit = True
+
+ ' If Not dsWIP.Tables("Chamber") Is Nothing Then
+ ' '加入勾選的按鈕
+ ' Dim colChamberCheckFlag As New DataColumn
+ ' colChamberCheckFlag.ColumnName = "SELECT1"
+ ' colChamberCheckFlag.DataType = System.Type.GetType("System.Boolean")
+ ' colChamberCheckFlag.DefaultValue = False
+ ' colChamberCheckFlag.AllowDBNull = False
+ ' dsWIP.Tables("Chamber").Columns.Add(colChamberCheckFlag)
+ ' dsWIP.Tables(tblAreaEquipment).DefaultView.AllowEdit = True
+ ' End If
+ ' 'Kevin 20131223,如有模治具則開放用選取的方式
+ ' If Not dsWIP.Tables("AccState") Is Nothing Then
+ ' '加入勾選的按鈕
+ ' Dim colSelect As New DataColumn
+ ' colSelect.ColumnName = "Select"
+ ' colSelect.DataType = System.Type.GetType("System.Boolean")
+ ' colSelect.DefaultValue = False
+ ' colSelect.AllowDBNull = False
+ ' dsWIP.Tables("AccState").Columns.Add(colSelect)
+
+ ' dsWIP.Tables("AccState").DefaultView.Sort = "AccessoryType,AccessoryNo"
+ ' Dim strType As String = ""
+ ' Dim drTemp As DataRow()
+
+ ' '預設選取每個類別第一個模治具
+ ' 'For Each dr As DataRow In dsWIP.Tables(tblAreaEquipment).Rows
+ ' ' strType = ""
+ ' ' If dr("AllowExecute") = 1 Then '可使用
+ ' ' drTemp = dsWIP.Tables("AccState").Select("EquipmentNo = '" & dr("EquipmentNo") & "'")
+ ' ' If drTemp.Length > 0 Then
+ ' ' '有掛模治具
+ ' ' For Each dr1 As DataRow In drTemp
+ ' ' If strType = "" Then
+ ' ' strType = dr1("AccessoryType")
+ ' ' dr1("Select") = True
+ ' ' ElseIf strType <> dr1("AccessoryType") Then
+ ' ' dr1("Select") = True
+ ' ' strType = dr1("AccessoryType")
+ ' ' End If
+ ' ' Next
+ ' ' End If
+ ' ' End If
+ ' 'Next
+ ' '2020/02/26 Grace Mantis 67753 取得此批號於此作業站上的派工資料
+ ' Call funLoadWIPEQPDispatchState(LotNo:=LotNo, OPNo:=txtOPNo.Text)
+ ' '增加顯示欄位:派工日期、派工順序
+ ' If dsWIP.Tables(tblAreaEquipment).Columns.Contains("DispatchOrder") Then
+ ' dsWIP.Tables(tblAreaEquipment).Columns.Remove("DispatchOrder")
+ ' End If
+ ' Dim colDispatchDate As New DataColumn
+ ' colDispatchDate.ColumnName = "DispatchDate"
+ ' colDispatchDate.DataType = System.Type.GetType("System.DateTime")
+ ' dsWIP.Tables(tblAreaEquipment).Columns.Add(colDispatchDate)
+ ' Dim colDispatchOrder As New DataColumn
+ ' colDispatchOrder.ColumnName = "DispatchOrder"
+ ' colDispatchOrder.DataType = System.Type.GetType("System.String")
+ ' dsWIP.Tables(tblAreaEquipment).Columns.Add(colDispatchOrder)
+
+ ' If Not IsNothing(dsTemp.Tables(tblEQPDispatchState)) Then
+ ' If dsTemp.Tables(tblEQPDispatchState).Rows.Count > 0 Then
+ ' Dim strCheckInDate As String = Now.ToString("yyyy/MM/dd") 'Check In 日期
+ ' '2020/11/05 Steven Mantis:0081316: '增加顯示欄位:派工日期、派工順序
+ ' For i As Integer = 0 To dsWIP.Tables(tblAreaEquipment).Rows.Count - 1
+ ' '1. 檢查是否有派工設備
+ ' Dim drSelEQP As DataRow() = dsTemp.Tables(tblEQPDispatchState).Select("EquipmentNo = '" &
+ ' dsWIP.Tables(tblAreaEquipment).Rows(i)("EquipmentNo").ToString() & "'And LotNo = '" & txtLotNo.Text & "'And DispatchDate = '" & strCheckInDate & "'")
+ ' If drSelEQP.Count > 0 Then '優先顯示派工日期為當天
+ ' dsWIP.Tables(tblAreaEquipment).Rows(i)("DispatchOrder") = drSelEQP(0)("DispatchOrder").ToString
+ ' If drSelEQP(0)("DispatchDate").ToString <> "" Then
+ ' dsWIP.Tables(tblAreaEquipment).Rows(i)("DispatchDate") = drSelEQP(0)("DispatchDate")
+ ' End If
+ ' Else '如非當天派工日期再顯示
+ ' Dim drSelEQP2 As DataRow() = dsTemp.Tables(tblEQPDispatchState).Select("EquipmentNo = '" &
+ ' dsWIP.Tables(tblAreaEquipment).Rows(i)("EquipmentNo").ToString() & "'And LotNo = '" & txtLotNo.Text & "'")
+ ' If drSelEQP2.Length > 0 Then
+ ' dsWIP.Tables(tblAreaEquipment).Rows(i)("DispatchOrder") = drSelEQP2(0)("DispatchOrder").ToString
+ ' If drSelEQP2(0)("DispatchDate").ToString <> "" Then
+ ' dsWIP.Tables(tblAreaEquipment).Rows(i)("DispatchDate") = drSelEQP2(0)("DispatchDate")
+ ' End If
+ ' End If
+ ' End If
+ ' Next
+ ' End If
+ ' End If
+ ' End If
+ ' Else
+ ' ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ ' Exit Function
+ ' End If
+
+ ' XmlDoc = Nothing
+
+ ' Catch ex As iMESException.MESException
+ ' ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ ' Exit Function
+ ' Catch ex As Exception
+ ' ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ ' Exit Function
+ ' End Try
+
+ ' funLoadAvailableEquipmentInfo = 0
+
+
+ 'End Function
+
+ Private Function funLoadAvailableEquipment_Chamber(ByRef LotNo As String) As Integer
+
+ funLoadAvailableEquipment_Chamber = -1
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", LotNo, "")
+ strParameter += CombineXMLParameter("getrecipe", "GetRecipe", "Boolean", True, "")
+ strParameter += CombineXMLParameter("getaccessory", "GetAccessory", "Boolean", blnGetAccessory, "")
+ strParameter += CombineXMLParameter("multiqclist", "MultiQCList", "Boolean", True, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ ' 2016 YF, OutXml = wsWIP.LoadAvailableEquipment_All(InXml)
+ OutXml = InvokeSrv("wsWIP.LoadAvailableEquipment_All", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ tblAreaEquipment = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadavailableequipment_all").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadavailableequipment_all").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadavailableequipment_all").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+
+ '加入Check Field
+ Dim colCheckFlag As New DataColumn
+ colCheckFlag.ColumnName = "CheckFlag"
+ colCheckFlag.DataType = System.Type.GetType("System.Boolean")
+ colCheckFlag.DefaultValue = False
+ colCheckFlag.AllowDBNull = False
+ dsWIP.Tables(tblAreaEquipment).Columns.Add(colCheckFlag)
+ '加入LoadPort
+ Dim colPort As New DataColumn
+ colPort.ColumnName = "LoadPort"
+ colPort.DataType = System.Type.GetType("System.String")
+ dsWIP.Tables(tblAreaEquipment).Columns.Add(colPort)
+
+ '加入點檢識別欄位
+ dsWIP.Tables(tblAreaEquipment).Columns.Add(New DataColumn("QCType", System.Type.GetType("System.Decimal")))
+ dsWIP.Tables(tblAreaEquipment).Columns.Add(New DataColumn("QCFinish", System.Type.GetType("System.Decimal")))
+
+ '開放可編輯
+ dsWIP.Tables(tblAreaEquipment).DefaultView.AllowEdit = True
+
+ 'Kevin 20131223,如有模治具則開放用選取的方式
+ If Not dsWIP.Tables("AccState") Is Nothing Then
+ '加入勾選的按鈕
+ Dim colSelect As New DataColumn
+ colSelect.ColumnName = "Select"
+ colSelect.DataType = System.Type.GetType("System.Boolean")
+ colSelect.DefaultValue = False
+ colSelect.AllowDBNull = False
+ dsWIP.Tables("AccState").Columns.Add(colSelect)
+
+ dsWIP.Tables("AccState").DefaultView.Sort = "AccessoryType,AccessoryNo"
+ Dim strType As String = ""
+ Dim drTemp As DataRow()
+
+ '預設選取每個類別第一個模治具
+ 'For Each dr As DataRow In dsWIP.Tables(tblAreaEquipment).Rows
+ ' strType = ""
+ ' If dr("AllowExecute") = 1 Then '可使用
+ ' drTemp = dsWIP.Tables("AccState").Select("EquipmentNo = '" & dr("EquipmentNo") & "'")
+ ' If drTemp.Length > 0 Then
+ ' '有掛模治具
+ ' For Each dr1 As DataRow In drTemp
+ ' If strType = "" Then
+ ' strType = dr1("AccessoryType")
+ ' dr1("Select") = True
+ ' ElseIf strType <> dr1("AccessoryType") Then
+ ' dr1("Select") = True
+ ' strType = dr1("AccessoryType")
+ ' End If
+ ' Next
+ ' End If
+ ' End If
+ 'Next
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funLoadAvailableEquipment_Chamber = 0
+
+
+ End Function
+ Private Function funGetShift() As Integer
+
+ funGetShift = -1
+
+ Dim strShiftNo As String = "N/A"
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("userno", "UserNo", "String", UserId, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsUSR.GetShift", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ '取出ShiftNo
+ If XmlDoc.GetElementsByTagName("shiftno").Item(0).SelectNodes("value").Count > 0 Then
+ strShiftNo = XmlDoc.DocumentElement.GetElementsByTagName("shiftno").Item(0).SelectNodes("value").Item(0).InnerText
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ txtShiftNo.Text = strShiftNo
+
+ funGetShift = 0
+
+ End Function
+
+ Private Function funGetOPDescription(ByRef LotNo As String) As Integer
+
+ funGetOPDescription = -1
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", LotNo, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP.GetLotOPDescription", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ If XmlDoc.GetElementsByTagName("opdescription").Count > 0 Then
+ If XmlDoc.GetElementsByTagName("opdescription").Item(0).SelectNodes("value").Count > 0 Then
+ txtOPDescription.Text = XmlDoc.DocumentElement.GetElementsByTagName("opdescription").Item(0).SelectNodes("value").Item(0).InnerText
+ End If
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funGetOPDescription = 0
+
+ End Function
+
+ Private Function funLoadSubOP() As Integer
+
+ funLoadSubOP = -1
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+
+ '用opreference決定現在要用產品 or Module去抓,2011/04/08,by Sherry
+ If dsWIP.Tables(tblLotState).Rows(0)("OPReference") = 1 Then 'Module
+ strParameter = CombineXMLParameter("productno", "ProductNo", "String", CInput(dsWIP.Tables(tblLotState).Rows(0)("ModuleNo").ToString), "")
+ strParameter += CombineXMLParameter("productversion", "ProductVersion", "String", CInput(dsWIP.Tables(tblLotState).Rows(0)("ModuleVersion").ToString), "")
+ Else 'Product
+ strParameter = CombineXMLParameter("productno", "ProductNo", "String", txtProductNo.Text, "")
+ strParameter += CombineXMLParameter("productversion", "ProductVersion", "String", dsWIP.Tables(tblLotState).Rows(0)("ProductVersion").ToString, "")
+ End If
+ strParameter += CombineXMLParameter("opno", "OPNo", "String", CInput(txtOPNo.Text), "") '將OPNo加上CInput轉換特殊字元,2010/04/08,by yumei
+
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsPRD.LoadPRDOpSubOp", InXml)
+
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ '讀取取出資料表之名稱
+ tblSubOP = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadprdopsubop").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadprdopsubop").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ '取出Data
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadprdopsubop").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+ dsWIP.Tables(tblSubOP).DefaultView.Sort = "SubOPSequence,SubOPNo"
+ iugSubOP.iMESUltraGrid.DataSource = dsWIP.Tables(tblSubOP).DefaultView
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funLoadSubOP = 0
+
+ End Function
+
+ Private Function funLoadLotLoginState() As Integer
+
+ funLoadLotLoginState = -1
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", CInput(LotNo), "")
+ strParameter += CombineXMLParameter("opno", "OPNo", "String", CInput(dsWIP.Tables(tblLotState).Rows(0)("OPNo").ToString), "")
+ strParameter += CombineXMLParameter("userno", "UserNo", "String", CInput(UserId), "")
+ Dim strAdditional As String
+ strAdditional = CombineXMLAdditional(CombineAddXML_Condition("CheckOutTime is null"))
+ strParameter += strAdditional
+
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP.LoadLotLoginState", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ '讀取取出資料表之名稱
+ tblLotLoginState = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadlotloginstate").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadlotloginstate").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ '取出Data
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadlotloginstate").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funLoadLotLoginState = 0
+
+ End Function
+ Private Function funLoadMOMaterialState(ByVal MONo As String,
+ ByVal MaterialLotNo As String,
+ Optional ByVal MaterialNo As String = defString) As Integer
+
+ funLoadMOMaterialState = -1
+
+ Dim XmlDoc As New XmlDocument
+
+ '先判斷DS中是否已有相同名稱的資料表,若有需先remove,否則會有錯誤
+ If Not IsNothing(dsWIP.Tables(tblMOMaterialState)) Then
+ dsWIP.Tables.Remove(tblMOMaterialState)
+ End If
+
+ '組InXml的字串
+
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = CombineXMLParameter("mono", "MONo", "String", CInput(MONo), "")
+ strParameter += CombineXMLParameter("materiallotno", "MaterialLotNo", "String", CInput(MaterialLotNo), "")
+ If MaterialNo <> defString Then
+ strParameter += CombineXMLParameter("materialno", "MaterialNo", "String", CInput(MaterialNo), "")
+ End If
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ ' 2016 YF, Using wsOE As New wsOE.wsOE
+ ' 2016 YF, wsOE.Url = LocalizeWebService(wsOE.Url.ToString)
+ ' 2016 YF, wsOE.EnableDecompression = True
+ ' 2016 YF, OutXml = wsOE.LoadMOMaterialState(InXml)
+ OutXml = InvokeSrv("wsOE.LoadMOMaterialState", InXml)
+
+ ' 2016 YF, End Using
+
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ tblMOMaterialState = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadmomaterialstate").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadmomaterialstate").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadmomaterialstate").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funLoadMOMaterialState = 0
+
+ End Function
+
+ Private Function funLoadWIPInventory_Raw(ByVal MaterialLotNo As String,
+ Optional ByVal MaterialNo As String = defString,
+ Optional ByVal InventoryNo As String = defString) As Integer
+
+ funLoadWIPInventory_Raw = -1
+
+ Dim XmlDoc As New XmlDocument
+
+ '先判斷DS中是否已有相同名稱的資料表,若有需先remove,否則會有錯誤
+ If Not IsNothing(dsWIP.Tables(tblWIPINVRaw)) Then
+ dsWIP.Tables.Remove(tblWIPINVRaw)
+ End If
+
+ '組InXml的字串
+
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = CombineXMLParameter("materiallotno", "MaterialLotNo", "String", CInput(MaterialLotNo), "")
+ '2019/06/17 Shih Kai, Mantis:0058359 多加入條件參數
+ If MaterialNo <> defString Then
+ strParameter += CombineXMLParameter("materialno", "MaterialNo", "String", CInput(MaterialNo), "")
+ End If
+ If InventoryNo <> defString Then
+ strParameter += CombineXMLParameter("inventoryno", "InventoryNo", "String", CInput(InventoryNo), "")
+ End If
+
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsINV.LoadWIPInventory_Raw", InXml)
+
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ tblWIPINVRaw = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadwipinventory_raw").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadwipinventory_raw").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadwipinventory_raw").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funLoadWIPInventory_Raw = 0
+
+ End Function
+
+ Private Function funLoadWIPInventory_SEMI(ByVal LotNo As String,
+ Optional ByVal ProductNo As String = defString,
+ Optional ByVal InventoryNo As String = defString) As Integer
+
+ funLoadWIPInventory_SEMI = -1
+
+ Dim XmlDoc As New XmlDocument
+
+ '先判斷DS中是否已有相同名稱的資料表,若有需先remove,否則會有錯誤
+ If Not IsNothing(dsWIP.Tables(tblWIPINVSEMI)) Then
+ dsWIP.Tables.Remove(tblWIPINVSEMI)
+ End If
+
+ '組InXml的字串
+
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", CInput(LotNo), "")
+ '2019/06/17 Shih Kai, Mantis:0058359 多加入條件參數
+ If ProductNo <> defString Then
+ strParameter += CombineXMLParameter("productno", "ProductNo", "String", CInput(ProductNo), "")
+ End If
+ If InventoryNo <> defString Then
+ strParameter += CombineXMLParameter("inventoryno", "InventoryNo", "String", CInput(InventoryNo), "")
+ End If
+
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP.LoadWIPInventory_SEMI", InXml)
+
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ tblWIPINVSEMI = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadwipinventory_semi").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadwipinventory_semi").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadwipinventory_semi").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funLoadWIPInventory_SEMI = 0
+
+ End Function
+
+ '取出用料清單
+ Private Function funLoadSubstituteMaterial_Main(ByVal LotNo As String, ByVal MaterialNo As String,
+ ByVal UnitNo As String) As Integer
+ funLoadSubstituteMaterial_Main = -1
+
+ Dim XmlDoc As New XmlDocument '處理Xml字串之物件
+ Dim tmpStringReader As System.IO.StringReader '將字串轉換成可讀入DataSet的物件
+ Dim InXml, OutXml, strIdentity, strParameter, XmlData, XmlSchema As String
+
+ '先判斷DS中是否已有相同名稱的資料表,若有需先remove,否則會有錯誤
+ If Not IsNothing(dsWIP.Tables(tblSubstituteMaterial)) Then
+ dsWIP.Tables.Remove(tblSubstituteMaterial)
+ End If
+
+ '組InXml的字串
+
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", CInput(LotNo), "")
+ strParameter += CombineXMLParameter("materialno", "MaterialNo", "String", CInput(MaterialNo), "")
+ strParameter += CombineXMLParameter("unitno", "UnitNo", "String", CInput(UnitNo), "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP.LoadSubstituteMaterial_Main", InXml)
+
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ tblSubstituteMaterial = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadsubstitutematerial_main").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadsubstitutematerial_main").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadsubstitutematerial_main").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Finally
+ XmlDoc = Nothing
+ tmpStringReader = Nothing
+ End Try
+
+ funLoadSubstituteMaterial_Main = 0
+
+ End Function
+
+ '''
+ ''' 2016/10/19 YF, 依設備及工單取出設備上料現況
+ '''
+ '''
+ '''
+ '''
+ ''' 2:原物料線邊倉(RAW) 3:工單存料現況(MO) 4:半成品線邊倉(SEMI)
+ '''
+ Private Function LoadEQPMaterialState(ByRef pTable As DataTable, Optional ByVal pEquipmentNo As String = defString,
+ Optional ByVal pMONo As String = defString, Optional ByVal pMaterialNo As String = defString,
+ Optional ByVal pPutInPlaceType As Integer = 3) As Boolean
+
+ Dim result As Boolean = False
+ Dim XmlDoc As New XmlDocument
+ Dim dsTemp As New DataSet
+
+ Try
+
+ Cursor.Current = Cursors.WaitCursor
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = ""
+
+ If (pEquipmentNo <> defString) Then
+ strParameter += CombineXMLParameter("equipmentno", "EquipmentNo", "String", pEquipmentNo, "")
+ End If
+
+ '不需要工单 新设备上料14278
+ 'If (pMONo <> defString) Then
+ ' strParameter += CombineXMLParameter("mono", "MONo", "String", CInput(pMONo), "")
+ 'End If
+
+ If (pMaterialNo <> defString) Then
+ strParameter += CombineXMLParameter("materialno", "MaterialNo", "String", CInput(pMaterialNo), "")
+ End If
+
+ ' 取出剩餘數量>0
+ Dim strAdditional As String
+ strAdditional = CombineXMLAdditional(CombineAddXML_Condition("Qty > 0"))
+ strParameter += strAdditional
+
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ OutXml = InvokeSrv("wsWIP_Material.LoadWIPEQPMaterialState", InXml)
+
+ XmlDoc.LoadXml(OutXml)
+
+ If ChkExecutionSuccess(XmlDoc) Then
+
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadwipeqpmaterialstate").Item(0).SelectNodes("schema").Item(0).InnerXml
+
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsTemp.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadwipeqpmaterialstate").Item(0).SelectNodes("value").Item(0).InnerXml
+
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsTemp.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+
+ If (dsTemp.Tables.Count > 0) Then
+ pTable = dsTemp.Tables(0).Copy
+ result = True
+ End If
+
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ End If
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Finally
+ XmlDoc = Nothing
+ dsTemp = Nothing
+ Cursor.Current = Cursors.Default
+ End Try
+
+ Return result
+
+ End Function
+
+ '2019/01/18 Eric
+ Private Function funLoadParameter(ByVal ParameterNo As String) As String
+
+ Dim dsPara As New DataSet
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = CombineXMLParameter("parameterno", "ParameterNo", "String", CInput(ParameterNo), "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsSYS.LoadParameter", InXml)
+
+ Dim XmlDoc As New XmlDocument '//處理Xml字串之物件
+ XmlDoc.LoadXml(OutXml)
+ If Not ChkExecutionSuccess(XmlDoc) Then
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ End If
+
+ Dim tblParameter As String = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadparameter").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadparameter").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsPara.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadparameter").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsPara.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+
+ If dsPara.Tables(tblParameter).Rows.Count > 0 Then
+ Return dsPara.Tables(tblParameter).Rows(0)("PARAMETERVALUE").ToString
+ End If
+
+ Return ""
+
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Finally
+ End Try
+
+ End Function
+
+ '2020/10/29 Grace 料批查核,相同料批只能刷一個料號,增加料號刷入
+ Private Sub txtMaterialNo_KeyPress(sender As Object, e As KeyPressEventArgs) Handles txtMaterialNo.KeyPress
+ Try
+ If (e.KeyChar <> Convert.ToChar(13)) Then
+ Exit Sub
+ End If
+ txtMaterialLotNo.Focus()
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ End Try
+ End Sub
+
+
+ Private Sub iugMaterial_Click(sender As Object, e As EventArgs) Handles iugMaterial.Click
+ If iugMaterial.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
+ txtMaterialNo.Text = iugMaterial.iMESUltraGrid.ActiveRow.Cells("MaterialNo").Value
+ End Sub
+
+ Private Function funLoadTemp_LotState() As Integer
+
+ funLoadTemp_LotState = -1
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", CInput(LotNo), "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP.LoadTemp_LotState", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ tblTLotState = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadtemp_lotstate").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadtemp_lotstate").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadtemp_lotstate").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funLoadTemp_LotState = 0
+
+
+ End Function
+
+ '2019/10/17 Grace 查詢作業站資料
+ Private Sub funLoadOPBasis(ByVal OPNo As String)
+
+ If Not IsNothing(dsTemp.Tables(tblOPBasis)) Then
+ dsTemp.Tables.Remove(tblOPBasis)
+ End If
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = CombineXMLParameter("opno", "OPNo", "String", CInput(OPNo), "")
+ '2020/02/07 Grace 增加傳入GetXml_CLOB = false, 避免取回企業邏輯CLOB資料
+ strParameter += CombineXMLParameter("getxml_clob", "GetXML_CLOB", "Boolean", False, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Dim XmlDoc As New XmlDocument
+
+ Try
+ ' 2016 YF, Using wsOP As New wsOP.wsOP
+ ' 2016 YF, wsOP.Url = LocalizeWebService(wsOP.Url.ToString)
+ ' 2016 YF, wsOP.EnableDecompression = True
+ ' 2016 YF, OutXml = wsOP.LoadOPBasis(InXml)
+ OutXml = InvokeSrv("wsOP.LoadOPBasis", InXml)
+
+ ' 2016 YF, End Using
+
+ '利用XmlDoc物件處理ReturnValue
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ '//取出 Tablename
+ tblOPBasis = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadopbasis").Item(0).SelectNodes("name").Item(0).InnerXml
+ '//取出 Table Schma
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadopbasis").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsTemp.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ '//取出Attrib Data
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadopbasis").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsTemp.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Sub
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ End Try
+ End Sub
+
+ '2020/02/26 Grace 查詢設備派工資料
+ Private Sub funLoadWIPEQPDispatchState(Optional ByVal EquipmentNo As String = defString, Optional ByVal LotNo As String = defString,
+ Optional ByVal OPNo As String = defString, Optional ByVal DispatchDate As DateTime = defDateTime)
+
+ If Not IsNothing(dsTemp.Tables(tblEQPDispatchState)) Then
+ dsTemp.Tables.Remove(tblEQPDispatchState)
+ End If
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = ""
+ If EquipmentNo <> defString Then strParameter += CombineXMLParameter("equipmentno", "EquipmentNo", "String", CInput(EquipmentNo), "")
+ If LotNo <> defString Then strParameter += CombineXMLParameter("lotno", "LotNo", "String", CInput(LotNo), "")
+ If OPNo <> defString Then strParameter += CombineXMLParameter("opno", "OPNo", "String", CInput(OPNo), "")
+ If chkUpdCheckInTime.Checked And DispatchDate <> defDateTime Then
+ strParameter += CombineXMLParameter("dispatchdate", "DispatchDate", "String", dtpcheckintime.Value.ToString("yyyy/MM/dd HH:mm:ss"), "")
+ End If
+
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+ Dim XmlDoc As New XmlDocument
+
+ Try
+ ' 2016 YF, Using wsOP As New wsOP.wsOP
+ ' 2016 YF, wsOP.Url = LocalizeWebService(wsOP.Url.ToString)
+ ' 2016 YF, wsOP.EnableDecompression = True
+ ' 2016 YF, OutXml = wsOP.LoadOPBasis(InXml)
+ OutXml = InvokeSrv("wsWIP.LoadWIPEQPDispatchState", InXml)
+
+ ' 2016 YF, End Using
+
+ '利用XmlDoc物件處理ReturnValue
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ '//取出 Tablename
+ tblEQPDispatchState = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadwipeqpdispatchstate").Item(0).SelectNodes("name").Item(0).InnerXml
+ '//取出 Table Schma
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadwipeqpdispatchstate").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsTemp.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ '//取出Attrib Data
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadwipeqpdispatchstate").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsTemp.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Sub
+ End If
+
+ XmlDoc = Nothing
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ End Try
+ End Sub
+
+
+#End Region
+
+#Region "Others"
+
+ Private Function funInitialize()
+
+ iugAttrib.iMESUltraGrid.Text = "Attrib"
+ iugAttrib.iMESUltraGrid.DisplayLayout.GroupByBox.Hidden = True
+ iugAttrib.iMESUltraGrid.ContextMenuStrip.Items.Clear()
+ iugAttrib.iMESUltraGrid.DisplayLayout.Override.CellAppearance.BackColor = Drawing.Color.Gainsboro
+
+ 'iugMaterial.iMESUltraGrid.Text = "Material"
+ iugMaterial.iMESUltraGrid.DisplayLayout.GroupByBox.Hidden = True
+ iugMaterial.iMESUltraGrid.ContextMenuStrip.Items.Clear()
+ iugMaterial.iMESUltraGrid.DisplayLayout.Override.CellAppearance.BackColor = Drawing.Color.Gainsboro
+
+ iugEquipment.iMESUltraGrid.Text = "Equipment"
+ iugEquipment.iMESUltraGrid.DisplayLayout.GroupByBox.Hidden = True
+ iugEquipment.iMESUltraGrid.ContextMenuStrip.Items.Clear()
+ iugEquipment.iMESUltraGrid.UpdateMode = Infragistics.Win.UltraWinGrid.UpdateMode.OnCellChangeOrLostFocus
+ iugEquipment.iMESUltraGrid.DisplayLayout.Override.CellAppearance.BackColor = Drawing.Color.Gainsboro
+
+ '78912: 进站选择模治具时,如该机台领用多套模具,会默认选择第一套而不会选择产品作业站设定绑定使用的的模治具
+ '78879: 若PRD主檔有設定限定模治具,則勾選各類別限定模治具的第一筆,設定為星號亦同,若未設定則不預勾 Edison 2020/10/15
+ '===========================================78879 Start ===========================================
+ If Not dsWIP.Tables("AccState") Is Nothing Then
+ For Each r As DataRow In dsWIP.Tables("AccState").Rows
+ r("Select") = False
+ Next r
+ End If
+
+ If Not dsWIP.Tables("PRDAccessory") Is Nothing AndAlso dsWIP.Tables("PRDAccessory").Rows.Count > 0 AndAlso Not dsWIP.Tables("AccState") Is Nothing Then
+ Dim blnChkACC As Boolean = False
+
+ Dim dtAccType As DataTable = dsWIP.Tables("PRDAccessory").DefaultView.ToTable(True, "AccessoryType")
+ Dim drSelPRDACC() As DataRow
+ Dim drSelAccState() As DataRow
+
+ For Each r As DataRow In dtAccType.Rows
+ drSelPRDACC = dsWIP.Tables("PRDAccessory").Select("AccessoryType = '" & r("AccessoryType") & "'")
+ If drSelPRDACC.Length > 0 Then
+ If drSelPRDACC(0)("AccessoryNo") <> "*" Then
+ drSelAccState = dsWIP.Tables("AccState").Select("AccessoryType = '" & drSelPRDACC(0)("AccessoryType") & "' AND AccessoryNo = '" & drSelPRDACC(0)("AccessoryNo") & "' ")
+ If drSelAccState.Length > 0 Then
+ drSelAccState(0)("Select") = True
+ End If
+ Else
+ drSelAccState = dsWIP.Tables("AccState").Select("AccessoryType = '" & drSelPRDACC(0)("AccessoryType") & "' ")
+ If drSelAccState.Length > 0 Then
+ drSelAccState(0)("Select") = True
+ End If
+ End If
+ End If
+ Next r
+
+ End If
+ '===========================================78879 End ===========================================
+
+ '78913: 【德瑞客户】CI画面放大画面后再缩小画面然后拉伸设备栏位会造成多个设备功能框 Edison 2020/09/24
+ '================================ 78913 Start ================================
+ '防止透過Scroll Bar分割Grid
+ iugEquipment.iMESUltraGrid.DisplayLayout.MaxColScrollRegions = 1
+ iugEquipment.iMESUltraGrid.DisplayLayout.MaxRowScrollRegions = 1
+ '================================ 78913 End ================================
+
+ iugKeyIn.iMESUltraGrid.Text = "Key In"
+ iugKeyIn.iMESUltraGrid.DisplayLayout.GroupByBox.Hidden = True
+ iugKeyIn.iMESUltraGrid.ContextMenuStrip.Items.Clear()
+ iugKeyIn.iMESUltraGrid.UpdateMode = Infragistics.Win.UltraWinGrid.UpdateMode.OnCellChangeOrLostFocus
+ iugKeyIn.iMESUltraGrid.DisplayLayout.MaxColScrollRegions = 1
+ iugKeyIn.iMESUltraGrid.DisplayLayout.MaxRowScrollRegions = 1
+
+ 'iugSubOP.iMESUltraGrid.Text = "Sub OP"
+ iugSubOP.iMESUltraGrid.DisplayLayout.GroupByBox.Hidden = True
+ iugSubOP.iMESUltraGrid.ContextMenuStrip.Items.Clear()
+ iugSubOP.iMESUltraGrid.DisplayLayout.Override.CellAppearance.BackColor = Drawing.Color.Gainsboro
+
+ SBar1.Panels(0).Text = "UserNo:" & UserId
+ SBar1.Panels(3).Text = Format(datEventTime, "yyyy/MM/dd H:mm:ss")
+
+ txtPriority.Appearance.TextHAlign = Infragistics.Win.HAlign.Right
+ txtCurQty.Appearance.TextHAlign = Infragistics.Win.HAlign.Right
+ txtSysQty.Appearance.TextHAlign = Infragistics.Win.HAlign.Right
+ dtpcheckintime.Value = datEventTime
+
+ btnConfirm.Enabled = True
+ 'btnMultiUser.Enabled = True
+
+ '2019/10/17 Grace 依系統參數是否啟動多人加工, 且多人加工模式為生產批, 來決定是否顯示"多人加工"按鈕
+ btnMultiUser.Visible = False
+ btnMultiUser.Enabled = False
+
+ If Val(funGetSysParameter("MultiOperator")) Then
+ Call funLoadOPBasis(txtOPNo.Text)
+ If Not IsNothing(dsTemp.Tables(tblOPBasis)) Then
+ If dsTemp.Tables(tblOPBasis).Rows.Count > 0 Then
+ If dsTemp.Tables(tblOPBasis).Rows(0)("MultiOperatorMode").ToString = "5" Then
+ btnMultiUser.Visible = True
+ btnMultiUser.Enabled = True
+ End If
+ End If
+ End If
+ End If
+
+
+ ' 2016/12/26 YF, 依系統參數是否啟動多人加工來決定是否顯示"作業人員"按鈕
+ Me.btnOperator.Visible = Val(funGetSysParameter("MultiOperator"))
+
+ End Function
+
+ Private Function funLotInfo_Show()
+
+ RevLotSerial = dsWIP.Tables(tblLotState).Rows(0)("LotSerial")
+ RevLotStamp = dsWIP.Tables(tblLotState).Rows(0)("LotStamp")
+ LotSerial = dsWIP.Tables(tblLotState).Rows(0)("LotSerial")
+ LogGroupSerial = dsWIP.Tables(tblLotState).Rows(0)("LogGroupSerial").ToString
+ txtCurQty.Text = Format(dsWIP.Tables(tblLotState).Rows(0)("CurQty"), "0.####")
+ txtCurUnitNo.Text = dsWIP.Tables(tblLotState).Rows(0)("CurUnitNo").ToString
+ txtSysQty.Text = Format(dsWIP.Tables(tblLotState).Rows(0)("SysQty"), "0.####")
+ txtSysUnitNo.Text = dsWIP.Tables(tblLotState).Rows(0)("SysUnitNo").ToString
+ txtOPNo.Text = dsWIP.Tables(tblLotState).Rows(0)("OPNo").ToString
+ txtOpName.Text = dsWIP.Tables(tblLotState).Rows(0)("OPName").ToString
+
+ '2009/05/11 Sophia.Pan R0905002 作業站編號及名稱加上ToolTip
+ ToolTip1.SetToolTip(Me.txtOPNo, dsWIP.Tables(tblLotState).Rows(0)("OPNo").ToString)
+ ToolTip1.SetToolTip(Me.txtOpName, dsWIP.Tables(tblLotState).Rows(0)("OPName").ToString)
+
+ txtAreaNo.Text = dsWIP.Tables(tblLotState).Rows(0)("AreaNo").ToString
+ txtProductNo.Text = dsWIP.Tables(tblLotState).Rows(0)("ProductNo").ToString
+ PhaseNo = dsWIP.Tables(tblLotState).Rows(0)("PhaseNo")
+
+ txtPriority.Text = dsWIP.Tables(tblLotState).Rows(0)("Priority")
+ If dsWIP.Tables(tblLotState).Rows(0)("Priority") = 1 Then
+ txtPriority.BackColor = System.Drawing.Color.Red
+ ElseIf dsWIP.Tables(tblLotState).Rows(0)("Priority") = 2 Then
+ txtPriority.BackColor = System.Drawing.Color.Yellow
+ ElseIf dsWIP.Tables(tblLotState).Rows(0)("Priority") = 3 Then
+ txtPriority.BackColor = System.Drawing.Color.LimeGreen
+ End If
+ txtMONo.Text = dsWIP.Tables(tblLotState).Rows(0)("MONo").ToString
+ txtCustomerLotNo.Text = dsWIP.Tables(tblLotState).Rows(0)("CustomerLotNo").ToString
+
+ End Function
+
+ Private Sub funAddValueList_Attrib()
+
+ iugAttrib.iMESUltraGrid.DisplayLayout.ValueLists.Add("ASource")
+ With iugAttrib.iMESUltraGrid.DisplayLayout.ValueLists("ASource").ValueListItems
+ .Clear()
+ .Add(0, "KeyIn")
+ .Add(1, "Calculate")
+ .Add(2, "System")
+ .Add(3, "Setup")
+ End With
+
+ End Sub
+
+ Private Function funGetSampleData()
+
+ Cursor.Current = Cursors.WaitCursor
+
+ '轉換抽樣參數
+ Dim strAQLType, strAQL, strQCLevel, strTemp As String
+
+ If dsWIP.Tables(tblTAttrib) Is Nothing Then Exit Function
+
+ Dim drSel() As DataRow
+
+ '若已轉換,不再轉
+ drSel = dsWIP.Tables(tblTAttrib).Select("AttribNo = 'SampleQty'")
+ If drSel.Length > 0 Then
+ If Not IsDBNull(drSel(0)("AttribValue")) Then
+ If drSel(0)("AttribValue") <> "" Then
+ Exit Function
+ End If
+ End If
+ End If
+
+ 'AQLType
+ drSel = dsWIP.Tables(tblTAttrib).Select("AttribNo = 'AQLType'")
+ If drSel.Length > 0 Then
+ strAQLType = drSel(0)("AttribValue")
+ Else
+ strAQLType = defString
+ End If
+ 'AQL
+ drSel = dsWIP.Tables(tblTAttrib).Select("AttribNo = 'AQL'")
+ If drSel.Length > 0 Then
+ strAQL = drSel(0)("AttribValue")
+ Else
+ strAQL = defString
+ End If
+ 'QCLevel
+ drSel = dsWIP.Tables(tblTAttrib).Select("AttribNo = 'QCLevel'")
+ If drSel.Length > 0 Then
+ strQCLevel = drSel(0)("AttribValue")
+ Else
+ strQCLevel = defString
+ End If
+
+ drSel = Nothing
+
+ If strAQLType = defString Or strAQL = defString Or strQCLevel = defString Then Exit Function
+
+ '取出抽樣數
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("aqltype", "AQLType", "String", strAQLType, "")
+ strParameter += CombineXMLParameter("qty", "QTY", "Long", dsWIP.Tables(tblLotState).Rows(0)("CurQty"), "")
+ strParameter += CombineXMLParameter("qclevel", "QCLevel", "String", strQCLevel, "")
+ strParameter += CombineXMLParameter("aql", "AQL", "String", strAQL, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+ Try
+ OutXml = InvokeSrv("wsQC.GetAQLQty", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ 'SampleQty
+ If XmlDoc.GetElementsByTagName("sampleqty").Item(0).SelectNodes("value").Count > 0 Then
+ strTemp = XmlDoc.DocumentElement.GetElementsByTagName("sampleqty").Item(0).SelectNodes("value").Item(0).InnerText
+ If IsNumeric(strTemp) Then
+ drSel = dsWIP.Tables(tblTAttrib).Select("AttribNo = 'SampleQty'")
+ If drSel.Length > 0 Then
+ drSel(0).BeginEdit()
+ drSel(0)("AttribValue") = strTemp
+ drSel(0).EndEdit()
+ End If
+ Else
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200011", "[%SampleQty%]"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Function
+ End If
+ End If
+ 'AcceptQty
+ If XmlDoc.GetElementsByTagName("acceptqty").Item(0).SelectNodes("value").Count > 0 Then
+ strTemp = XmlDoc.DocumentElement.GetElementsByTagName("acceptqty").Item(0).SelectNodes("value").Item(0).InnerText
+ If IsNumeric(strTemp) Then
+ drSel = dsWIP.Tables(tblTAttrib).Select("AttribNo = 'AcceptQty'")
+ If drSel.Length > 0 Then
+ drSel(0).BeginEdit()
+ drSel(0)("AttribValue") = strTemp
+ drSel(0).EndEdit()
+ End If
+ Else
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200011", "[%AcceptQty%]"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Function
+ End If
+ End If
+ 'RejectQty
+ If XmlDoc.GetElementsByTagName("rejectqty").Item(0).SelectNodes("value").Count > 0 Then
+ strTemp = XmlDoc.DocumentElement.GetElementsByTagName("rejectqty").Item(0).SelectNodes("value").Item(0).InnerText
+ If IsNumeric(strTemp) Then
+ drSel = dsWIP.Tables(tblTAttrib).Select("AttribNo = 'RejectQty'")
+ If drSel.Length > 0 Then
+ drSel(0).BeginEdit()
+ drSel(0)("AttribValue") = strTemp
+ drSel(0).EndEdit()
+ End If
+ Else
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200011", "[%RejectQty%]"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Function
+ End If
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ Cursor.Current = Cursors.Default
+
+ End Function
+
+ Private Function funGetActiveRows() As DataRow()
+ Dim Rows As DataRow()
+ Dim oRow As Infragistics.Win.UltraWinGrid.UltraGridRow
+ oRow = iugEquipment.iMESUltraGrid.ActiveRow
+
+ If oRow Is Nothing Then
+ Return Nothing
+ End If
+
+ '找出DataSet中在目前游標列的資料列(DataRow)
+
+ Rows = dsWIP.Tables(tblAreaEquipment).Select(
+ "EquipmentNo ='" & Replace(oRow.Cells("EquipmentNo").Value.ToString, "'", "''") & "'")
+
+ If Rows.Length = 0 Then
+ Return Nothing
+ Else
+ Return Rows
+ End If
+ End Function
+
+ Private Function funMultiUser() As Integer
+
+ funMultiUser = -1
+
+ If funLoadLotLoginState() < 0 Then Exit Function
+
+ '產生多人加工暫存表
+ dtTmpLoginState = New DataTable("TmpLoginState")
+ dtTmpLoginState.Columns.Add("UserNo", System.Type.GetType("System.String"))
+ dtTmpLoginState.Columns.Add("UserName", System.Type.GetType("System.String"))
+ dtTmpLoginState.Columns.Add("CheckInTime", System.Type.GetType("System.DateTime"))
+
+ '檢查tblWIPLotLoginState內是否已有本站未登出的資料,若有,則不自動加入.
+ If dsWIP.Tables(tblLotLoginState).Rows.Count = 0 Then
+ drAdd = dtTmpLoginState.NewRow
+ drAdd("UserNo") = UserId
+ drAdd("UserName") = UserName
+ 'Kevin,2012/12/18,不取client端的時間作CI時間
+ 'drAdd("CheckInTime") = datEventTime
+ dtTmpLoginState.Rows.Add(drAdd)
+ End If
+
+ funMultiUser = 0
+
+ End Function
+
+ Private Function funGetSysParameter(ByVal pParameterNo As String) As String
+
+ funGetSysParameter = "0"
+
+ '組InXml的字串
+ strParameter = ""
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = CombineXMLParameter("parameterno", "ParameterNo", "String", CInput(pParameterNo), "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ Dim XmlDoc As New XmlDocument
+
+ OutXml = InvokeSrv("wsSYS.GetParameter", InXml)
+
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ If XmlDoc.DocumentElement.SelectNodes("returnvalue").Count > 0 Then
+ funGetSysParameter = XmlDoc.DocumentElement("returnvalue").InnerXml
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+ End Function
+
+#End Region
+
+#Region "取得設備參數"
+
+ ' 2016/01/27 YF, 取得設備參數值
+ Private Sub funGetEquipmentRecipe()
+
+ Const FUNCTION_NAME As String = "#GETEQPRECIPE"
+
+ Dim strEquipmentNo As String = ""
+ Dim XmlDoc As New XmlDocument
+ Dim SelRows() As DataRow
+
+ Try
+
+ ' 取出勾選的設備編號
+ For Each row As DataRow In dsWIP.Tables(tblAreaEquipment).Select("CheckFlag = " & True, "EquipmentNo")
+ strEquipmentNo += row("EquipmentNo").ToString & ","
+ Next
+
+ If (strEquipmentNo <> "") Then
+ strEquipmentNo = strEquipmentNo.TrimEnd(",")
+ End If
+
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+
+ ' 逐筆判斷特性值的函式是否為#GETEQPRECIPE, 若是則至後端取回參數值
+ For Each row As DataRow In dsWIP.Tables(tblTAttrib).Rows
+
+ If (Microsoft.VisualBasic.Left(row("OrgAttribValue").ToString, FUNCTION_NAME.Length).ToUpper <> FUNCTION_NAME) Then
+ Continue For
+ End If
+
+ ' 沒有挑選設備, 清空#GetEQPRecipe特性值
+ If (strEquipmentNo = "") Then
+ row("AttribValue") = ""
+ Continue For
+ End If
+
+ ' 取回設備參數
+ strParameter = CombineXMLParameter("equipmentno", "EquipmentNo", "String", strEquipmentNo, "")
+ strParameter += CombineXMLParameter("recipescript", "RecipeScript", "String", row("OrgAttribValue").ToString, "")
+
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ OutXml = InvokeSrv("wsWIP.GetEquipmentRecipe", InXml)
+
+ XmlDoc.LoadXml(OutXml)
+
+ If ChkExecutionSuccess(XmlDoc) Then
+ If XmlDoc.GetElementsByTagName("itemvalue").Count > 0 Then
+ If XmlDoc.GetElementsByTagName("itemvalue").Item(0).SelectNodes("value").Count > 0 Then
+ row("AttribValue") = XmlDoc.DocumentElement.GetElementsByTagName("itemvalue").Item(0).SelectNodes("value").Item(0).InnerText
+
+ ' 更新KeyIn的特性值
+ SelRows = dtKeyIn.Select("AttribNo = '" & row("AttribNo") & "'")
+
+ If (SelRows.Length > 0) Then
+ SelRows(0)("AttribValue") = row("AttribValue")
+ End If
+
+ End If
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ End If
+
+ Next
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Finally
+ XmlDoc = Nothing
+ End Try
+
+ End Sub
+
+#End Region
+
+#Region "用料檢查"
+
+ '''
+ ''' 2016/10/19 YF, 投料點用料檢查
+ '''
+ '''
+ Private Function CheckMaterialByPutinPlace(ByVal pMONo As String, ByVal pMaterialLotNo As String, ByVal pMaterialNo As String) As Boolean
+
+ Dim PutinPlace As Integer
+ Dim intInputFlag As Integer = 0
+ Dim strTmpOrgMaterialNo As String = ""
+ Dim strTmpMaterialNo As String = ""
+ Dim strTmpMaterialLotNo As String = ""
+ Dim decQty As Decimal = 0
+ Dim strCheckPlaceMsg As String = ""
+
+
+ '至工單發料區與線邊倉取出輸入的料批
+ If funLoadMOMaterialState(dsWIP.Tables(tblLotState).Rows(0)("MONo").ToString, txtMaterialLotNo.Text) < 0 Then Exit Function
+ If funLoadWIPInventory_Raw(pMaterialLotNo) < 0 Then Exit Function
+ If funLoadWIPInventory_SEMI(pMaterialLotNo) < 0 Then Exit Function
+
+ '檢查是否有符合的物料編號與投料點
+
+ If dsWIP.Tables(tblMOMaterialState).Rows.Count > 0 Then '工單發料區
+
+ For Each drRaw As DataRow In dsWIP.Tables(tblMOMaterialState).Rows
+ '2020/10/30 Grace 先檢查輸入的物料編號, 相符後再往下找物料批號
+ If drRaw("MaterialNo") = pMaterialNo Then
+
+ 'Kevin 2013/1/2,不同主料替代料有可能相同,先檢查游標所選的主物料
+ Dim drSelMTL As DataRow()
+
+ drSelMTL = dsWIP.Tables(tblTMaterial).Select("MaterialNo='" & drRaw("MaterialNo") & "'" &
+ " And OrgMaterialNo ='" & iugMaterial.iMESUltraGrid.ActiveRow.Cells("OrgMaterialNo").Value & "'" &
+ " And PutInPlaceType = 3 ")
+ If drSelMTL.Length > 0 Then
+ If intInputFlag <> 1 Then
+ strTmpOrgMaterialNo = drSelMTL(0)("OrgMaterialNo")
+ strTmpMaterialNo = drRaw("MaterialNo")
+ strTmpMaterialLotNo = drRaw("MaterialLotNo")
+ decQty = drRaw("Qty")
+ End If
+ intInputFlag = 1
+ Else
+ '全部主物料比對
+ For Each dr As DataRow In dsWIP.Tables(tblTMaterial).Rows
+ '檢查物料編號
+ If dr("MaterialNo") = drRaw("MaterialNo") Then
+ '檢查投料點
+ If dr("PutInPlaceType") = 3 Then
+ Dim drSel() As DataRow
+ drSel = dsWIP.Tables(tblTmpMTLLotNo).Select("MaterialNo='" & drRaw("MaterialNo") & "' And MaterialLotNo ='" & drRaw("MaterialLotNo") & "'")
+ If drSel.Length = 0 Then
+ If intInputFlag <> 1 Then
+ strTmpOrgMaterialNo = dr("OrgMaterialNo")
+ strTmpMaterialNo = drRaw("MaterialNo")
+ strTmpMaterialLotNo = drRaw("MaterialLotNo")
+ decQty = drRaw("Qty")
+ End If
+ intInputFlag = 1
+ End If
+ Else
+ strCheckPlaceMsg = "[%MaterialLotNo%]:" & pMaterialLotNo & ",[%MaterialNo%]:" &
+ dr("MaterialNo") & " [%PutInPlace%][%is not%][%MO%] !"
+ End If
+ End If
+ Next
+ End If
+
+ End If
+ Next
+ End If
+
+ If dsWIP.Tables(tblWIPINVRaw).Rows.Count > 0 Then '線邊倉
+
+ For Each drRaw As DataRow In dsWIP.Tables(tblWIPINVRaw).Rows
+
+ '2020/10/30 Grace 先檢查輸入的物料編號, 相符後再往下找物料批號
+ If drRaw("MaterialNo") = pMaterialNo Then
+
+ 'Kevin 2013/1/2,不同主料替代料有可能相同,先檢查游標所選的主物料
+ Dim drSelMTL As DataRow()
+ drSelMTL = dsWIP.Tables(tblTMaterial).Select("MaterialNo='" & drRaw("MaterialNo") & "'" &
+ " And OrgMaterialNo ='" & iugMaterial.iMESUltraGrid.ActiveRow.Cells("OrgMaterialNo").Value & "'" &
+ " And PutInPlaceType = 2 ")
+ If drSelMTL.Length > 0 Then
+ If intInputFlag <> 1 Then
+ strTmpOrgMaterialNo = drSelMTL(0)("OrgMaterialNo")
+ strTmpMaterialNo = drRaw("MaterialNo")
+ strTmpMaterialLotNo = drRaw("MaterialLotNo")
+ decQty = drRaw("Qty")
+ End If
+ intInputFlag = 1
+ Else
+ '全部主物料比對
+ For Each dr As DataRow In dsWIP.Tables(tblTMaterial).Rows
+ '檢查物料編號
+ If dr("MaterialNo") = drRaw("MaterialNo") Then
+ '檢查投料點
+ If dr("PutInPlaceType") = 2 Then
+ Dim drSel() As DataRow
+ drSel = dsWIP.Tables(tblTmpMTLLotNo).Select("MaterialNo='" & drRaw("MaterialNo") & "' And MaterialLotNo ='" & drRaw("MaterialLotNo") & "'")
+ If drSel.Length = 0 Then
+ If intInputFlag <> 1 Then
+ strTmpOrgMaterialNo = dr("OrgMaterialNo")
+ strTmpMaterialNo = drRaw("MaterialNo")
+ strTmpMaterialLotNo = drRaw("MaterialLotNo")
+ decQty = drRaw("Qty")
+ End If
+ intInputFlag = 1
+ End If
+ Else
+ strCheckPlaceMsg = "[%MaterialLotNo%]:" & pMaterialLotNo & ",[%MaterialNo%]:" &
+ dr("MaterialNo") & " [%PutInPlace%][%is not%][%WIP INVENTORY%] !"
+ End If
+ End If
+ Next
+ End If
+
+ End If
+ Next
+ End If
+
+ If dsWIP.Tables(tblWIPINVSEMI).Rows.Count > 0 Then '半成品線邊倉
+
+ For Each drSEMI As DataRow In dsWIP.Tables(tblWIPINVSEMI).Rows
+
+ '2020/10/30 Grace 先檢查輸入的物料編號, 相符後再往下找物料批號
+ If drSEMI("ProductNo") = pMaterialNo Then
+
+ 'Kevin 2013/1/2,不同主料替代料有可能相同,先檢查游標所選的主物料
+ Dim drSelMTL As DataRow()
+ drSelMTL = dsWIP.Tables(tblTMaterial).Select("MaterialNo='" & drSEMI("ProductNo") & "'" &
+ " And OrgMaterialNo ='" & iugMaterial.iMESUltraGrid.ActiveRow.Cells("OrgMaterialNo").Value & "'" &
+ " And PutInPlaceType = 4 ")
+ If drSelMTL.Length > 0 Then
+ If intInputFlag <> 1 Then
+ strTmpOrgMaterialNo = drSelMTL(0)("OrgMaterialNo")
+ strTmpMaterialNo = drSEMI("ProductNo")
+ strTmpMaterialLotNo = drSEMI("LotNo")
+ decQty = drSEMI("Qty")
+ End If
+ intInputFlag = 1
+ Else
+ '全部主物料比對
+ For Each dr As DataRow In dsWIP.Tables(tblTMaterial).Rows
+ '檢查物料編號
+ If dr("MaterialNo") = drSEMI("ProductNo") Then
+ '檢查投料點
+ If dr("PutInPlaceType") = 2 Then
+ Dim drSel() As DataRow
+ drSel = dsWIP.Tables(tblTmpMTLLotNo).Select("MaterialNo='" & drSEMI("ProductNo") & "' And MaterialLotNo ='" & drSEMI("LotNo") & "'")
+ If drSel.Length = 0 Then
+ If intInputFlag <> 1 Then
+ strTmpOrgMaterialNo = dr("OrgMaterialNo")
+ strTmpMaterialNo = drSEMI("ProductNo")
+ strTmpMaterialLotNo = drSEMI("LotNo")
+ decQty = drSEMI("Qty")
+ End If
+ intInputFlag = 1
+ End If
+ Else
+ strCheckPlaceMsg = "[%MaterialLotNo%]:" & pMaterialLotNo & ",[%MaterialNo%]:" &
+ dr("MaterialNo") & " [%PutInPlace%][%is not%][%WIP INVENTORY%] !"
+ End If
+ End If
+ Next
+ End If
+
+ End If
+ Next
+ End If
+
+ If intInputFlag = 1 Then
+
+ '2019/06/18 Shih Kai, Mantis:0058359 ,若物料為指定用料, 則不可使用替代料
+ If funGetSysParameter("CIMTLDBCheck") = "1" Then
+ If dsWIP.Tables(tblTMaterial).Select("MaterialNo = '" & strTmpOrgMaterialNo & "' And Specified = 1").Length > 0 AndAlso
+ strTmpOrgMaterialNo <> strTmpMaterialNo Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-203079", "[%MaterialNo%]:" & strTmpOrgMaterialNo), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Function
+ End If
+ End If
+
+ Dim drAdd As DataRow
+ drAdd = dsWIP.Tables(tblTmpMTLLotNo).NewRow
+ drAdd("OrgMaterialNo") = strTmpOrgMaterialNo
+ drAdd("MaterialNo") = strTmpMaterialNo
+ drAdd("SUBSTITUTEMATERIALNO") = strTmpMaterialNo
+ drAdd("MaterialLotNo") = strTmpMaterialLotNo
+ drAdd("Qty") = decQty
+ dsWIP.Tables(tblTmpMTLLotNo).Rows.Add(drAdd)
+ Else
+ If strCheckPlaceMsg <> "" Then
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200015", strCheckPlaceMsg), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Function
+ Else
+ iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-202104", "[%MaterialLotNo%]!"), MsgBoxStyle.Exclamation, Me.Text)
+ Exit Function
+ End If
+ End If
+
+ '選到新加入的列
+ Dim Vals(1) As Object
+ Dim PmyKey(1) As DataColumn
+ PmyKey(0) = dsWIP.Tables(tblTmpMTLLotNo).Columns("MaterialNo")
+ PmyKey(1) = dsWIP.Tables(tblTmpMTLLotNo).Columns("MaterialLotNo")
+ Vals(0) = strTmpMaterialNo
+ Vals(1) = strTmpMaterialLotNo
+
+ ugrRow = FindRecordPosition_ByMutiCol(iugMaterial, PmyKey, Vals)
+ If Not ugrRow Is Nothing Then
+ iugMaterial.iMESUltraGrid.ActiveRow = ugrRow
+ iugMaterial.iMESUltraGrid.ActiveRow.Selected = True
+ End If
+
+ Return True
+
+ End Function
+
+#End Region
+
+#Region "物料數量檢查"
+
+ Structure MethodNames
+ '''
+ ''' 檢查物料數量
+ '''
+ Const funCheckMTLQuantity = "funCheckMTLQuantity"
+ End Structure
+
+ Private Function funCheckMTL() As Boolean
+
+ For Each row As DataRow In dsWIP.Tables(tblTMaterial).Rows
+ If dsWIP.Tables(tblTmpMTLLotNo).Select("OrgMaterialNo = '" & row("OrgMaterialNo") & "'").Length <= 0 Then
+ ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-203083",
+ row("MaterialNo") & "[%IS NOT ENOUGH%], [%PLEASE%][%EXECUTE%][%MOUNTMATERIAL%]"))
+ Return False
+ End If
+ Next
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("lotno", "LotNo", "String", CInput(LotNo), "")
+ strParameter &= CombineXMLParameter("checkin", "CheckIn", "Boolean", CInput(True), "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP_Material.CheckMTLForBR", InXml, dtTmpMTLLotNo.Copy)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+
+ If Not ChkExecutionSuccess(XmlDoc) Then
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Return False
+ End If
+
+ Dim xmlList As XmlNodeList = XmlDoc.GetElementsByTagName("message")
+ If xmlList.Count > 0 Then
+ xmlList = xmlList(0).SelectNodes("note")
+ If xmlList.Count > 0 Then
+ For Each xmlNode As XmlNode In xmlList
+ If funProcessMessages(xmlNode) = False Then Return False
+ Next
+ End If
+ End If
+
+ Return True
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ End Try
+
+ End Function
+ Private Function funProcessMessages(ByVal xmlNode As XmlNode) As Boolean
+
+ Dim MCode, MType, MMsg As String
+ MCode = xmlNode.SelectNodes("mcode").Item(0).InnerText
+ MType = xmlNode.SelectNodes("mtype").Item(0).InnerText
+ MMsg = xmlNode.SelectNodes("mmsg").Item(0).InnerText
+
+ Dim methodName As String = ""
+ If MMsg.Contains("{") AndAlso MMsg.Contains("}") Then
+ Dim intStart As Int16 = MMsg.IndexOf("{")
+ Dim intEnd As Int16 = MMsg.IndexOf("}")
+ methodName = MMsg.Substring(intStart + 1, intEnd - intStart - 1)
+ MMsg = MMsg.Substring(intEnd + 1, MMsg.Length - intEnd - 1)
+ End If
+
+ Select Case methodName
+ Case MethodNames.funCheckMTLQuantity
+ If ExceptionManager.iMESMsgBoxShowDialog(
+ ChgTranslateName_Msg("0000-100601", MMsg), MsgBoxStyle.YesNo + MsgBoxStyle.Question) = MsgBoxResult.No Then
+ Return False
+ End If
+
+ Case Else
+ ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg(MCode, MMsg), MsgBoxStyle.Exclamation, Me.Text)
+ Return False
+ End Select
+
+ Return True
+
+ End Function
+#End Region
+
+ '取eSOP 工位及作業站 資料
+ Private Function funLoadPRDeSOP() As Integer
+
+ funLoadPRDeSOP = -1
+ If Not IsNothing(dsDefine.Tables(tblPRDeSOPBasis)) Then dsDefine.Tables.Remove(tblPRDeSOPBasis)
+
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = ""
+ strParameter += CombineXMLParameter("productno", "ProductNo", "String", CInput(txtProductNo.Text), "")
+ strParameter += CombineXMLParameter("opno", "OPNo", "String", CInput(txtOPNo.Text), "")
+
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+ Dim XmlDoc As New XmlDocument
+ Try
+ ' 2016 YF, OutXml = wsPRD.LoadPRDeSOPBasis(InXml)
+ OutXml = InvokeSrv("wsPRD.LoadPRDeSOPBasis", InXml)
+
+ '利用XmlDoc物件處理ReturnValue
+ XmlDoc.LoadXml(OutXml)
+
+ If ChkExecutionSuccess(XmlDoc) Then
+ tblPRDeSOPBasis = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadprdesopbasis").Item(0).SelectNodes("name").Item(0).InnerXml
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadprdesopbasis").Item(0).SelectNodes("schema").Item(0).InnerXml
+
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsDefine.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+
+ '取出Data()
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadprdesopbasis").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsDefine.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Finally
+ XmlDoc = Nothing
+
+ End Try
+ funLoadPRDeSOP = 0
+
+ End Function
+ '顯示作業指導書(eSOP) 2016-12-19
+ Private Function funDisplayProcess() As Integer
+ Dim XmlDoc As New XmlDocument()
+ Dim InXml, OutXml As String
+ Dim strTempRecord As String = String.Empty
+ Dim arriveTime As DateTime = DateTime.Now
+ Dim strERP_URL_eSOP As String
+ Dim responseValue, code As String
+
+ Dim strSplitFile() As String
+
+ Try
+ '---- InXml -----
+ Dim InXmlDoc As XmlDocument = New XmlDocument()
+
+ '
+ Dim nodeParam As XmlElement = InXmlDoc.CreateElement("param")
+ nodeParam.SetAttribute("key", "std_data")
+ nodeParam.SetAttribute("type", "xml")
+ InXmlDoc.AppendChild(nodeParam)
+
+ '
+ Dim nodeDataRequest As XmlElement = InXmlDoc.CreateElement("data_request")
+ nodeParam.AppendChild(nodeDataRequest)
+
+ '
+ Dim nodeDataInfo As XmlElement = InXmlDoc.CreateElement("datainfo")
+ nodeDataRequest.AppendChild(nodeDataInfo)
+
+ '
+ Dim nodeParameter As XmlElement = InXmlDoc.CreateElement("parameter")
+ nodeParameter.SetAttribute("key", "sop_display")
+ nodeParameter.SetAttribute("type", "data")
+ nodeDataInfo.AppendChild(nodeParameter)
+
+ '
+ Dim nodeData As XmlElement = InXmlDoc.CreateElement("data")
+ nodeData.SetAttribute("name", "sop_display")
+ nodeParameter.AppendChild(nodeData)
+
+ For Each drData As DataRow In dsDefine.Tables(tblPRDeSOPBasis).Rows
+ If drData("POSITIONNO") = "N/A" Then Continue For
+ 'sop no
+ strSplitFile = Split(drData("SOPFILE"), ".")
+ '顯示作業說明書必傳實體檔案,工位,執行時間
+ '
+ Dim nodeRow As XmlElement = InXmlDoc.CreateElement("row")
+ nodeRow.SetAttribute("seq", intRow)
+ nodeData.AppendChild(nodeRow)
+
+ Dim nodeDField As XmlElement
+ ''sop編號
+ nodeDField = InXmlDoc.CreateElement("field")
+ nodeDField.SetAttribute("name", "sop_no")
+ nodeDField.SetAttribute("type", "string")
+ 'nodeDField.InnerText = strSplitFile(0)
+ nodeDField.InnerText = ""
+ nodeRow.AppendChild(nodeDField)
+ '指定版號: Y:指定 N:不指定
+ nodeDField = InXmlDoc.CreateElement("field")
+ nodeDField.SetAttribute("name", "sop_ver_assign")
+ nodeDField.SetAttribute("type", "string")
+ nodeDField.InnerText = ""
+ nodeRow.AppendChild(nodeDField)
+ '版本
+ nodeDField = InXmlDoc.CreateElement("field")
+ nodeDField.SetAttribute("name", "sop_ver")
+ nodeDField.SetAttribute("type", "string")
+ nodeDField.InnerText = ""
+ nodeRow.AppendChild(nodeDField)
+ '頁數
+ nodeDField = InXmlDoc.CreateElement("field")
+ nodeDField.SetAttribute("name", "sop_page")
+ nodeDField.SetAttribute("type", "string")
+ nodeDField.InnerText = drData("PAGENO")
+ nodeRow.AppendChild(nodeDField)
+ '工位編號
+ nodeDField = InXmlDoc.CreateElement("field")
+ nodeDField.SetAttribute("name", "station_no")
+ nodeDField.SetAttribute("type", "string")
+ nodeDField.InnerText = drData("POSITIONNO")
+ nodeRow.AppendChild(nodeDField)
+ '實體檔名
+ nodeDField = InXmlDoc.CreateElement("field")
+ nodeDField.SetAttribute("name", "sop_file")
+ nodeDField.SetAttribute("type", "string")
+ nodeDField.InnerText = drData("SOPFILE")
+ nodeRow.AppendChild(nodeDField)
+ '傳送時間
+ nodeDField = InXmlDoc.CreateElement("field")
+ nodeDField.SetAttribute("name", "report_datetime")
+ nodeDField.SetAttribute("type", "date")
+ nodeDField.SetAttribute("format", "yyyyMMddHHmmss")
+ nodeDField.InnerText = Now.ToString("yyyyMMddHHmmss")
+ nodeRow.AppendChild(nodeDField)
+ '備註
+ nodeDField = InXmlDoc.CreateElement("field")
+ nodeDField.SetAttribute("name", "remark")
+ nodeDField.SetAttribute("type", "string")
+ nodeDField.InnerText = ""
+ nodeRow.AppendChild(nodeDField)
+ intRow = intRow + 1
+ Next
+ Using obj As New COM_ERP.clsEAI
+ InXml = obj.funGenerateRequestXML(COM_ERP.clsEAI.ERPName.eSOP, InXmlDoc.InnerXml, "sop.display.process", False)
+ strERP_URL_eSOP = obj.getERP_WSURL(COM_ERP.clsEAI.ERPName.eSOP)
+ End Using
+
+ '----- Call Web Service -----
+ Using ws As New COM_ERP.wsESOP.eSOPService
+
+ ws.Url = strERP_URL_eSOP
+ OutXml = ws.sop_display_process(InXml)
+ End Using
+
+ code = "success"
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ code = "fail"
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ code = "fail"
+ Finally
+
+ '紀錄TransactionLog
+ COM_ERP.clsCommon.addTransactionLog_ErrorCode(InXml, OutXml, arriveTime.ToString("yyyyMMddHHmmssss"), "WIP", "station.get", My.Computer.Name,
+ gUserNo, arriveTime.ToString("yyyy/MM/dd HH:mm:ss"), code, "", "station.get", LogClass:="WIP")
+ End Try
+ End Function
+
+#Region "作業人員"
+
+ '''
+ ''' 2016/12/26 YF, 顯示作業人員現況資訊
+ '''
+ '''
+ '''
+ Private Sub btnOperator_Click(sender As Object, e As EventArgs) Handles btnOperator.Click
+
+ Dim parameters As Dictionary(Of String, Object)
+ Dim EquipmentNo As String = ""
+
+ Try
+
+ parameters = New Dictionary(Of String, Object)
+
+ With dsWIP.Tables(tblLotState).Rows(0)
+
+ Select Case .Item("MultiOperatorMode").ToString
+ Case "0"
+ ' 作業站
+ parameters.Add("OPNo", .Item("OPNo").ToString)
+ Case "1"
+ ' 區域
+ parameters.Add("AreaNo", .Item("AreaNo").ToString)
+ Case "2"
+ ' 設備
+ For Each row As DataRow In dsWIP.Tables(tblAreaEquipment).Select("CheckFlag = True")
+ EquipmentNo += row("EquipmentNo") & ","
+ Next
+
+ If (EquipmentNo = "") Then
+ Throw New iMESException.MESException("0000-103010", "[%PLEASE SELECT%] [%EQUIPMENT%]!")
+ End If
+
+ EquipmentNo = EquipmentNo.TrimEnd(",")
+ parameters.Add("EquipmentNo", EquipmentNo)
+ Case "5" 'Mantis 63873: 增加判斷多人加工模式為生產批, 並傳入資料
+ ' 生產批
+ parameters.Add("LotNo", .Item("LotNo").ToString)
+ Case Else
+ Throw New iMESException.MESException("0000-003000", "[%MultiOperatorMode%]:" & .Item("MultiOperatorMode").ToString & " [%NOT DEFINE%]!")
+ End Select
+
+ End With
+
+ parameters.Add("EnableSignOut", False)
+ Me.ObjectFileHandler.Execute(pObjectID:="WP_OperatorOnline", pParameters:=parameters)
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ End Try
+
+ End Sub
+
+#End Region
+
+ '2019/01/18 Eric 特殊生產需求顯示
+ Private Sub btnSWR_Click(sender As System.Object, e As System.EventArgs) Handles btnSWR.Click
+ '2019/02/12 Eric 加入判斷有無資料
+ If blnShowSWR = True Then
+
+ Dim Parameters As New Dictionary(Of String, Object)
+ Parameters.Add("MONo", txtMONo.Text)
+ Parameters.Add("CustomerLotNo", txtCustomerLotNo.Text)
+ Parameters.Add("OPNo", txtOPNo.Text)
+ Parameters.Add("LotNo", txtLotNo.Text)
+ Parameters.Add("DeviceNo", dsWIP.Tables(tblLotState).Rows(0)("DeviceNo").ToString)
+ Parameters.Add("CustomerNo", dsWIP.Tables(tblLotState).Rows(0)("CustomerNo").ToString)
+ Parameters.Add("LogGroupSerial", dsWIP.Tables(tblLotState).Rows(0)("LogGroupSerial").ToString)
+ Parameters.Add("blnCICo", False)
+ Me.ObjectFileHandler.Execute("WP_SWRBasisRead", Parameters)
+
+ btnSWR.Visible = True
+
+ End If
+
+ End Sub
+
+ '2019/02/12 Eric
+ Private Sub funLoadSWRJoinLog()
+
+ Cursor.Current = Cursors.WaitCursor
+
+
+ If Not IsNothing(dsWIP.Tables(tblSWRJoinLog)) Then
+ dsWIP.Tables.Remove(tblSWRJoinLog)
+ End If
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = CombineXMLParameter("loggroupserial", "LogGroupSerial", "String", CInput(dsWIP.Tables(tblLotState).Rows(0)("LogGroupSerial").ToString), "")
+ strParameter += CombineXMLParameter("customerno", "CustomerNo", "String", CInput(dsWIP.Tables(tblLotState).Rows(0)("CustomerNo").ToString), "")
+ strParameter += CombineXMLParameter("lotno", "LotNo", "String", CInput(txtLotNo.Text), "")
+ strParameter += CombineXMLParameter("deviceno", "DeviceNo", "String", CInput(dsWIP.Tables(tblLotState).Rows(0)("DeviceNo").ToString), "")
+ strParameter += CombineXMLParameter("opno", "OPNo", "String", CInput(txtOPNo.Text), "")
+ strParameter += CombineXMLParameter("customerlotno", "CustomerLotNo", "String", CInput(txtCustomerLotNo.Text), "")
+ strParameter += CombineXMLParameter("mono", "MONo", "String", CInput(txtMONo.Text), "")
+ strParameter += CombineXMLParameter("status", "Status", "Integer", 2, "")
+
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+
+ OutXml = InvokeSrv("wsWIP.LoadSWRBasisJoinLog", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ tblSWRJoinLog = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadswrbasisjoinlog").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadswrbasisjoinlog").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsWIP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ '取出Data
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadswrbasisjoinlog").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsWIP.ReadXml(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Sub
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ End Try
+
+ Cursor.Current = Cursors.Default
+
+ End Sub
+
+ Private Sub funLoadAllMaterialLot()
+
+ Dim drAdd As DataRow
+ Dim drSel As DataRow()
+ Dim defNullDate As Date = CDate("9999/12/31") '製造日期或保存期限為Null時, 填入9999/12/31, 以防步Null錯誤, 因Null表示不受管控, 可以較後使用, 故填入較大的值
+
+ dtAllMTLLot = New DataTable("AllMTLLot")
+ dtAllMTLLot.Columns.Add("MaterialNo", System.Type.GetType("System.String")) '主料號
+ dtAllMTLLot.Columns.Add("MaterialLotNo", System.Type.GetType("System.String"))
+ dtAllMTLLot.Columns.Add("Qty", System.Type.GetType("System.Decimal"))
+ dtAllMTLLot.Columns.Add("MFGDate", System.Type.GetType("System.DateTime"))
+ dtAllMTLLot.Columns.Add("ExpireDate", System.Type.GetType("System.DateTime"))
+ dtAllMTLLot.Columns.Add("InputDate", System.Type.GetType("System.DateTime"))
+
+ dtAllMTLLot.Columns.Add("SubstituteMaterialNo", System.Type.GetType("System.String")) '新增一替代料欄位,2010/03/26,by yumei, 實際用料的料號
+ dtAllMTLLot.Columns.Add("SubstituteMaterialLevel", System.Type.GetType("System.Int16")) '新增一替代料位階欄位,2013/01/08,by Kevin
+ dtAllMTLLot.Columns.Add("SubstituteMaterialType", System.Type.GetType("System.String")) '新增一替代料類型欄位,2013/01/08,by Kevin
+ dtAllMTLLot.Columns.Add("SubstituteStdQty", System.Type.GetType("System.Decimal")) '新增一替代料標準用量欄位,2013/01/08,by Kevin
+ dtAllMTLLot.Columns.Add("CheckLotNo", System.Type.GetType("System.Int16")) '新增一替代料是否檢查批號欄位,2013/01/08,by Kevin
+
+ dtAllMTLLot.Columns.Add("SeqNo", System.Type.GetType("System.Int16")) '記錄同料號間各料批應被使用的次序
+ dtAllMTLLot.Columns.Add("blnExpireDate", System.Type.GetType("System.Boolean")) '紀錄是否有超過有效期限 有:True 沒有:False
+
+ Select Case dsWIP.Tables(tblLotState).Rows(0)("MaterialOption").ToString
+
+ Case "0" ' 發料點(線邊倉或工單)
+ '將Temp_Material中各主料所有可用料批全數取出, 存入dtAllMTLLot中
+ For Each drMTL As DataRow In dsWIP.Tables(tblTMaterial).Rows
+ If drMTL("LOTNO").ToString <> "" Then
+ Call funLoadSubstituteMaterial_Main(LotNo, drMTL("MaterialNo"), drMTL("UnitNo"))
+ For Each drMTLLot As DataRow In dsWIP.Tables(tblSubstituteMaterial).Rows
+ drAdd = dtAllMTLLot.NewRow
+ drAdd("MaterialNo") = drMTL("MaterialNo") 'BOM的主料號
+ drAdd("MaterialLotNo") = drMTLLot("MaterialLotNo")
+ drAdd("Qty") = drMTLLot("Qty")
+ 'drAdd("MFGDate") = drMTLLot("ManufactureDate")
+ 'drAdd("ExpireDate") = drMTLLot("ExpireDate")
+ If drMTLLot("ManufactureDate").ToString = "" Then
+ drAdd("MFGDate") = defNullDate
+ Else
+ drAdd("MFGDate") = drMTLLot("ManufactureDate")
+ End If
+ If drMTLLot("ExpireDate").ToString = "" Then
+ drAdd("ExpireDate") = defNullDate
+ Else
+ drAdd("ExpireDate") = drMTLLot("ExpireDate")
+ End If
+ If drMTLLot("InputDate").ToString = "" Then
+ drAdd("InputDate") = defNullDate
+ Else
+ drAdd("InputDate") = drMTLLot("InputDate")
+ End If
+
+ drAdd("SubstituteMaterialNo") = drMTLLot("MaterialNo") '實際料號, 有可能與主料號同也有可能是替代料號
+ drAdd("SubstituteMaterialLevel") = drMTLLot("SubstituteMaterialLevel")
+ drAdd("SubstituteMaterialType") = drMTLLot("SubstituteMaterialType")
+ drAdd("SubstituteStdQty") = drMTLLot("SubstituteStdQty")
+ drAdd("CheckLotNo") = drMTLLot("CheckLotNo")
+ dtAllMTLLot.Rows.Add(drAdd)
+ Next
+ End If
+ Next
+
+ '計算同一料號各料批的使用次序
+ Dim dvAllMTLLot, dvTemp As DataView
+ Dim dtTemp As DataTable
+ For Each drMTL As DataRow In dsWIP.Tables(tblTMaterial).Rows
+ If drMTL("LOTNO").ToString <> "" Then
+ 'drSel = dtAllMTLLot.Select("MaterialNo = '" & drMTL("MaterialNo") & "'", "MFGDate, ExpireDate, InputDate")
+ 'For idx As Integer = 0 To drSel.Length - 1
+ ' drSel(idx)("SeqNo") = idx + 1
+ 'Next
+ dvAllMTLLot = New DataView(dtAllMTLLot)
+ dvAllMTLLot.RowFilter = "MaterialNo = '" & drMTL("MaterialNo") & "'"
+ dtTemp = dvAllMTLLot.ToTable(True, {"MFGDate", "ExpireDate", "InputDate"}) '對製造日期,有效日期,入庫日做Distinct篩選
+ dvTemp = dtTemp.DefaultView
+ dvTemp.Sort = "MFGDate, ExpireDate, InputDate"
+ '當MFGDate, ExpireDate, InputDate皆相同時, 需給予相同的SeqNo, 故以Distinct的三個日期下去跑Loop
+ For idx As Integer = 0 To dvTemp.Count - 1
+ drSel = dtAllMTLLot.Select("MaterialNo = '" & drMTL("MaterialNo") & "'" &
+ "And MFGDate = #" & Format(dvTemp(idx)("MFGDate"), "yyyy/MM/dd HH:mm:ss") & "#" &
+ " And ExpireDate = #" & Format(dvTemp(idx)("ExpireDate"), "yyyy/MM/dd HH:mm:ss") & "#" &
+ " And InputDate = #" & Format(dvTemp(idx)("InputDate"), "yyyy/MM/dd HH:mm:ss") & "#")
+ For j As Integer = 0 To drSel.Length - 1
+ drSel(j)("SeqNo") = idx + 1
+ If Now > CDate(drSel(j)("EXPIREDATE")) Then '判定是否超過有效期限
+ drSel(j)("blnExpireDate") = True
+ Else
+ drSel(j)("blnExpireDate") = False
+ End If
+ Next
+ Next
+ End If
+ Next
+
+ End Select
+
+ End Sub
+
+#Region "CheckEQPQCList"
+
+ Private Function funCheckEQPQCList(ByVal EquipmentNo As String, ByRef CheckResult As String) As Integer
+
+ funCheckEQPQCList = -1
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("equipmentno", "EquipmentNo", "String", CInput(EquipmentNo), "")
+ strParameter += CombineXMLParameter("lotno", "LotNo", "String", CInput(LotNo), "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP.CheckEQPQCList", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ '取出CheckResult
+ If XmlDoc.GetElementsByTagName("checkresult").Item(0).SelectNodes("value").Count > 0 Then
+ CheckResult = XmlDoc.DocumentElement.GetElementsByTagName("checkresult").Item(0).SelectNodes("value").Item(0).InnerText
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funCheckEQPQCList = 0
+
+ End Function
+
+ Private Function funCheckEQPQCTask(ByVal EquipmentNo As String, Optional ByVal CancelUpdate As Boolean = False) As Integer
+
+ funCheckEQPQCTask = -1
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, UserId, Now)
+ strParameter = CombineXMLParameter("equipmentno", "EquipmentNo", "String", CInput(EquipmentNo), "")
+ strParameter += CombineXMLParameter("lotno", "LotNo", "String", CInput(LotNo), "")
+ strParameter += CombineXMLParameter("cancelupdate", "CancelUpdate", "Boolean", CancelUpdate, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ OutXml = InvokeSrv("wsWIP.CheckEQPQCTask", InXml)
+
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Function
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Function
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Function
+ End Try
+
+ funCheckEQPQCTask = 0
+
+ End Function
+
+#End Region
+
+
+#Region "ChkCIEQPDispatch"
+ ''2023/05/29 ,0135702: [6.0.7] SDD220425_01-03_進站設備派工查核調整,19245
+ Private Sub ChkCIEQPDispatch(ByVal EquipmentNo As String, ByVal LotNo As String, Optional OpNo As String = defString)
+
+ If Not IsNothing(dsEQP) Then
+ dsEQP.Clear()
+ dsEQP.Dispose()
+ End If
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = CombineXMLParameter("equipmentno", "EquipmentNo", "String", CInput(EquipmentNo), "")
+ strParameter += CombineXMLParameter("lotno", "LotNo", "String", CInput(LotNo), "")
+
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Dim XmlDoc As New XmlDocument
+ Try
+ OutXml = InvokeSrv("wsWIP.ChkCIEQPDispatch", InXml)
+
+ '利用XmlDoc物件處理ReturnValue
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ ckhEQPDispatchRule = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("chkcieqpdispatch").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("chkcieqpdispatch").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsEQP.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ '取出Data
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("chkcieqpdispatch").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsEQP.ReadXml(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Sub
+ End If
+
+ XmlDoc = Nothing
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ Exit Sub
+ End Try
+ End Sub
+
+#End Region
+ Private Sub DeleteTmpMTLLotNo(ByVal EquipmentNo As String)
+
+ Dim drSelTmpMTL As DataRow() = dsWIP.Tables(tblTmpMTLLotNo).Select("EquipmentNo = '" & EquipmentNo & "'")
+ For i As Integer = drSelTmpMTL.Count - 1 To 0 Step -1
+ drSelTmpMTL(i).Delete()
+ Next
+ dsWIP.Tables(tblTmpMTLLotNo).AcceptChanges()
+
+ End Sub
+ Private Sub LoadMaterialByEquipment(ByVal EquipmentNo As String)
+
+ Try
+ DeleteTmpMTLLotNo(EquipmentNo)
+
+ Dim MONo As String = dsWIP.Tables(tblLotState).Rows(0)("MONo").ToString
+ Dim OrgMaterialNo As String
+ ' 依設備及工單取出設備上料現況
+ Dim dtMaterialState As DataTable
+ If (Not LoadEQPMaterialState(dtMaterialState, EquipmentNo, MONo)) Then
+ Exit Sub
+ End If
+
+ ' 寫入暫存表
+ For Each r As DataRowView In dtMaterialState.DefaultView
+ 'Dim drSel() As DataRow = dsWIP.Tables(tblTMaterial).Select("MaterialNo = '" & r("MaterialNo") & "' ")
+ '物料表中的materialno是* 改成InputMaterialNo 14278
+ Dim drSel() As DataRow = dsWIP.Tables(tblTMaterial).Select("MaterialNo = '" & r("InputMaterialNo") & "' ")
+ If drSel.Length > 0 Then
+ '根据实际用料 投料点 和检查料批 找到用料清单的数据 原物料--------
+ Dim drSel1() As DataRow = dsOE.Tables(strMOList).Select("SubstituteMaterialNo='" & r("InputMaterialNo").ToString & "' and PutInPlaceType='" & drSel(0)("PutInPlaceType") & "' AND CheckLotNo='" & drSel(0)("CHECKLOTNO") & "'")
+ If drSel1.Length > 0 Then
+ OrgMaterialNo = drSel1(0)("MATERIALNO").ToString()
+ End If
+ ''----------------------
+ If drSel(0)("PutInPlaceType") = 3 Then
+ If r("MONO").ToString.ToUpper = MONo.ToUpper Then
+ Dim drAdd As DataRow = dsWIP.Tables(tblTmpMTLLotNo).NewRow
+ drAdd("EquipmentNo") = r("EquipmentNo")
+ 'drAdd("OrgMaterialNo") = r("MaterialNo").ToString 'Me.iugMaterial.iMESUltraGrid.ActiveRow.Cells("MaterialNo").Value
+ drAdd("OrgMaterialNo") = OrgMaterialNo 'Me.iugMaterial.iMESUltraGrid.ActiveRow.Cells("MaterialNo").Value
+ drAdd("SUBSTITUTEMATERIALNO") = r("InputMaterialNo").ToString
+ drAdd("MaterialNo") = r("InputMaterialNo").ToString 'Me.iugMaterial.iMESUltraGrid.ActiveRow.Cells("MaterialNo").Value
+ drAdd("MaterialLotNo") = r("MaterialLotNo").ToString 'pMaterialLotNo
+ drAdd("Qty") = r("Qty")
+ dsWIP.Tables(tblTmpMTLLotNo).Rows.Add(drAdd)
+ End If
+ ElseIf drSel(0)("PutInPlaceType") = 2 OrElse drSel(0)("PutInPlaceType") = 4 Then
+ If r("MONO").ToString.ToUpper = "N/A" Then
+ Dim drAdd As DataRow = dsWIP.Tables(tblTmpMTLLotNo).NewRow
+ drAdd("EquipmentNo") = r("EquipmentNo")
+ 'drAdd("OrgMaterialNo") = r("MaterialNo").ToString 'Me.iugMaterial.iMESUltraGrid.ActiveRow.Cells("MaterialNo").Value
+ drAdd("OrgMaterialNo") = OrgMaterialNo 'Me.iugMaterial.iMESUltraGrid.ActiveRow.Cells("MaterialNo").Value
+ drAdd("SUBSTITUTEMATERIALNO") = r("InputMaterialNo").ToString
+ drAdd("MaterialNo") = r("InputMaterialNo").ToString 'Me.iugMaterial.iMESUltraGrid.ActiveRow.Cells("MaterialNo").Value
+ drAdd("MaterialLotNo") = r("MaterialLotNo").ToString 'pMaterialLotNo
+ drAdd("Qty") = r("Qty")
+ dsWIP.Tables(tblTmpMTLLotNo).Rows.Add(drAdd)
+ End If
+ End If
+ End If
+ Next
+
+ Catch ex As iMESException.MESException
+ ExceptionManager.iMESShowDialog(ex.ErrorCode, ex.Message, ex.StackTrace)
+ Catch ex As Exception
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+ End Try
+
+ End Sub
+
+ Private Sub uegMaterial_KeyIn2_ExpandedStateChanged(sender As Object, e As EventArgs) Handles uegMaterial_KeyIn2.ExpandedStateChanged, uegAttrib_Equipment.ExpandedStateChanged
+
+ If uegMaterial_KeyIn2.Expanded Then
+
+ If uegAttrib_Equipment.Expanded Then
+ uegMaterial_KeyIn2.Size = New System.Drawing.Size(uegMaterial_KeyIn2.Width, (uplAll.Height - uegLotInfo.Height) / 2 - 10)
+ uegAttrib_Equipment.Size = New System.Drawing.Size(uegAttrib_Equipment.Width, (uplAll.Height - uegLotInfo.Height) / 2 - 10)
+ End If
+
+ Else
+
+ If uegAttrib_Equipment.Expanded Then
+ uegAttrib_Equipment.Size = New System.Drawing.Size(uegAttrib_Equipment.Width, uplAll.Height - uegLotInfo.Height - 20)
+ End If
+
+ End If
+
+ End Sub
+#Region "'//^_^ADD BY H-14278 2023-12-29 新设备上料"
+ '''
+ ''' 获取工单用料清单
+ '''
+ '''
+ '''
+ Private Sub funLoadMOMaterialList(ByVal MONo As String, ByVal OPNo As String) '//取出MO MaterialList資料
+
+
+ Dim i, j As Integer
+
+ If Not IsNothing(dsOE.Tables(strMOList)) Then '修正用料清單多次查詢重複計算問題
+ dsOE.Tables.Remove(strMOList)
+ End If
+
+ '組InXml的字串
+ strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
+ strParameter = CombineXMLParameter("mono", "MONo", "String", MONo.ToUpper, "")
+ strParameter += CombineXMLParameter("opno", "OPNo", "String", OPNo.ToUpper, "")
+ InXml = CombineXMLRequest(strIdentity, strParameter)
+
+ Try
+ ' 2016 YF, OutXml = wsOE.LoadMOMaterialListJoinMOBasis(InXml)
+ OutXml = InvokeSrv("wsOE.LoadMOMaterialListJoinMOBasis", InXml)
+
+ '利用XmlDoc物件處理ReturnValue
+ Dim XmlDoc As New XmlDocument
+ XmlDoc.LoadXml(OutXml)
+ If ChkExecutionSuccess(XmlDoc) Then
+ '讀取取出資料表之名稱
+
+ strMOList = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadmomateriallistjoinmobasis").Item(0).SelectNodes("name").Item(0).InnerXml
+ '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
+ XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadmomateriallistjoinmobasis").Item(0).SelectNodes("schema").Item(0).InnerXml
+ If XmlSchema <> "" Then
+ '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
+ tmpStringReader = New System.IO.StringReader(XmlSchema)
+ dsOE.ReadXmlSchema(tmpStringReader)
+ tmpStringReader.Close()
+ End If
+ '取出Data
+ XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadmomateriallistjoinmobasis").Item(0).SelectNodes("value").Item(0).InnerXml
+ If XmlData <> "" Then
+ tmpStringReader = New System.IO.StringReader(XmlData)
+ dsOE.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
+ tmpStringReader.Close()
+ End If
+
+ XmlDoc = Nothing
+ Else
+ ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
+ Exit Sub
+ End If
+
+ Catch ex As Exception
+ 'MsgBox("Unexpected Error. Load MO Material List Failed," & e1.Message, MsgBoxStyle.Exclamation)
+ ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
+
+ Finally
+ tmpStringReader = Nothing
+ End Try
+
+ End Sub
+
+#End Region
+
+End Class
diff --git a/SRC/MESPlugin/MESPI_BusinessRule/iMES.snk b/SRC/MESWin/BR/BR_L_CI_GEN/iMES.snk
similarity index 100%
rename from SRC/MESPlugin/MESPI_BusinessRule/iMES.snk
rename to SRC/MESWin/BR/BR_L_CI_GEN/iMES.snk
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/ET_Subcontractor.sln b/SRC/MESWin/BR/BR_L_CO_GEN/BR_L_CO_GEN.sln
similarity index 68%
rename from SRC/MESWin/SYS3/ET_TESTDATA21676/ET_Subcontractor.sln
rename to SRC/MESWin/BR/BR_L_CO_GEN/BR_L_CO_GEN.sln
index 85b1902..6cd5641 100644
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/ET_Subcontractor.sln
+++ b/SRC/MESWin/BR/BR_L_CO_GEN/BR_L_CO_GEN.sln
@@ -1,11 +1,14 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14
-VisualStudioVersion = 14.0.25123.0
+VisualStudioVersion = 14.0.25420.1
MinimumVisualStudioVersion = 10.0.40219.1
-Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "ET_Subcontractor", "ET_Subcontractor.vbproj", "{D6EE7B96-F10E-44E2-9731-162B70B4C8DD}"
+Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "BR_L_CO_GEN", "BR_L_CO_GEN.vbproj", "{380C6B38-FB64-49BE-A9A8-5E49015ADFD2}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Test", "..\..\Test\Test.vbproj", "{C4A48E3F-38E4-4E88-A47D-FA5510686E57}"
+ ProjectSection(ProjectDependencies) = postProject
+ {380C6B38-FB64-49BE-A9A8-5E49015ADFD2} = {380C6B38-FB64-49BE-A9A8-5E49015ADFD2}
+ EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -13,10 +16,10 @@ Global
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.ActiveCfg = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.Build.0 = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.ActiveCfg = Release|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.Build.0 = Release|x86
+ {380C6B38-FB64-49BE-A9A8-5E49015ADFD2}.Debug|x86.ActiveCfg = Debug|x86
+ {380C6B38-FB64-49BE-A9A8-5E49015ADFD2}.Debug|x86.Build.0 = Debug|x86
+ {380C6B38-FB64-49BE-A9A8-5E49015ADFD2}.Release|x86.ActiveCfg = Release|x86
+ {380C6B38-FB64-49BE-A9A8-5E49015ADFD2}.Release|x86.Build.0 = Release|x86
{C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.ActiveCfg = Debug|x86
{C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.Build.0 = Debug|x86
{C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Release|x86.ActiveCfg = Release|x86
@@ -29,11 +32,11 @@ Global
SccNumberOfProjects = 3
SccEnterpriseProvider = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C}
SccTeamFoundationServer = http://tfs.imestech.com:8080/tfs/messeries6
- SccProjectUniqueName0 = ET_Subcontractor.vbproj
SccLocalPath0 = .
SccProjectUniqueName1 = ..\\..\\Test\\Test.vbproj
SccProjectName1 = ../../Test
SccLocalPath1 = ..\\..\\Test
+ SccProjectUniqueName2 = BR_L_CO_GEN.vbproj
SccLocalPath2 = .
EndGlobalSection
EndGlobal
diff --git a/SRC/MESWin/SYS6/21695韦海桑/frontend/ET_Subcontractor/ET_Subcontractor.vbproj b/SRC/MESWin/BR/BR_L_CO_GEN/BR_L_CO_GEN.vbproj
similarity index 69%
rename from SRC/MESWin/SYS6/21695韦海桑/frontend/ET_Subcontractor/ET_Subcontractor.vbproj
rename to SRC/MESWin/BR/BR_L_CO_GEN/BR_L_CO_GEN.vbproj
index 74144a4..c4c85fc 100644
--- a/SRC/MESWin/SYS6/21695韦海桑/frontend/ET_Subcontractor/ET_Subcontractor.vbproj
+++ b/SRC/MESWin/BR/BR_L_CO_GEN/BR_L_CO_GEN.vbproj
@@ -4,10 +4,10 @@
Debug
x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}
+ {380C6B38-FB64-49BE-A9A8-5E49015ADFD2}
Library
- ET_Subcontractor_21695
- ET_Subcontractor_21695
+ BR_L_CO_GEN
+ BR_L_CO_GEN
512
Windows
v4.6.2
@@ -17,6 +17,28 @@
SAK
SAK
+
+ true
+ full
+ true
+ true
+ ..\..\..\MESClient\
+ BR_L_CO_GEN.xml
+ 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
+ 0
+ false
+
+
+ pdbonly
+ false
+ true
+ true
+ bin\Release\
+ BR_L_CO_GEN.xml
+ 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
+ 0
+ false
+
On
@@ -34,7 +56,7 @@
true
true
..\..\..\MESClient\
- ET_Subcontractor_21695.xml
+ BR_L_CO_GEN.xml
0
42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
full
@@ -45,7 +67,7 @@
true
..\..\..\MESClient\
- ET_Subcontractor_21695.xml
+ BR_L_CO_GEN.xml
true
0
42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
@@ -60,10 +82,12 @@
iMES.snk
-
- false
-
+
+ False
+ ..\..\..\MES_C_DLL\iMESWizards.dll
+ False
+
False
C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.v19.1.dll
@@ -89,10 +113,29 @@
C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Shared.v19.1.dll
False
+
+ False
+ ..\..\..\MESClient\COM_ERP.dll
+ False
+
..\..\..\MESClient\COM_Kit.dll
False
+
+ False
+ ..\..\..\MESClient\COM_Search.dll
+ False
+
+
+ False
+ ..\..\..\MESClient\COM_Utility.dll
+ False
+
+
+ ..\..\..\MES_C_DLL\iMESException.dll
+ False
+
..\..\..\MES_C_DLL\iMESExceptionManager.dll
False
@@ -104,14 +147,24 @@
+
+
+
+
+
+ False
+ ..\..\..\MESClient\WP_Kit.dll
+ False
+
+
@@ -124,25 +177,22 @@
+
modConstant.vb
-
+
Form
-
- Form
-
-
+
Form
True
Application.myapp
- True
True
@@ -156,14 +206,11 @@
-
- frmSubcontractor.vb
+
+ frmBinStateAdjust .vb
-
- frmSubcontractorContDef.vb
-
-
- frmSubcontractorDef.vb
+
+ frmBR_L_CO_GEN.vb
@@ -185,6 +232,9 @@
Settings.Designer.vb
+
+
+
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/ENT/ET_Subcontractor/My Project/Settings.Designer.vb b/SRC/MESWin/ENT/ET_Subcontractor/My Project/Settings.Designer.vb
deleted file mode 100644
index aa098f6..0000000
--- a/SRC/MESWin/ENT/ET_Subcontractor/My Project/Settings.Designer.vb
+++ /dev/null
@@ -1,76 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 這段程式碼是由工具產生的。
-' 執行階段版本:4.0.30319.42000
-'
-' 對這個檔案所做的變更可能會造成錯誤的行為,而且如果重新產生程式碼,
-' 變更將會遺失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-
-Namespace My
-
- _
- Partial Friend NotInheritable Class MySettings
- Inherits Global.System.Configuration.ApplicationSettingsBase
-
- Private Shared defaultInstance As MySettings = CType(Global.System.Configuration.ApplicationSettingsBase.Synchronized(New MySettings()),MySettings)
-
-#Region "My.Settings 自動儲存功能"
-#If _MyType = "WindowsForms" Then
- Private Shared addedHandler As Boolean
-
- Private Shared addedHandlerLockObject As New Object
-
- _
- Private Shared Sub AutoSaveSettings(ByVal sender As Global.System.Object, ByVal e As Global.System.EventArgs)
- If My.Application.SaveMySettingsOnExit Then
- My.Settings.Save()
- End If
- End Sub
-#End If
-#End Region
-
- Public Shared ReadOnly Property [Default]() As MySettings
- Get
-
-#If _MyType = "WindowsForms" Then
- If Not addedHandler Then
- SyncLock addedHandlerLockObject
- If Not addedHandler Then
- AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings
- addedHandler = True
- End If
- End SyncLock
- End If
-#End If
- Return defaultInstance
- End Get
- End Property
- End Class
-End Namespace
-
-Namespace My
-
- _
- Friend Module MySettingsProperty
-
- _
-
- Friend ReadOnly Property Settings() As Global.ET_Subcontractor.My.MySettings
- Get
- Return Global.ET_Subcontractor.My.MySettings.Default
-
-
- End Get
- End Property
- End Module
-End Namespace
diff --git a/SRC/MESWin/ENT/ET_Subcontractor/frmSubcontractor.vb b/SRC/MESWin/ENT/ET_Subcontractor/frmSubcontractor.vb
deleted file mode 100644
index d2a3050..0000000
--- a/SRC/MESWin/ENT/ET_Subcontractor/frmSubcontractor.vb
+++ /dev/null
@@ -1,1142 +0,0 @@
-Imports iMESExceptionManager
-
-Imports Infragistics.Win
-Imports Infragistics.Win.UltraWinGrid
-Public Class frmSubcontractor
-
- Inherits COM_Kit.frmBasisTemplat
-
- Public PrivFunNo As String = defString
-
- '//WS相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT '宣告Web Service物件?
- Dim tmpStringReader As System.IO.StringReader '將字串轉換成可讀入DataSet的物件
- Dim XmlData As String '儲存取回之資料
- Dim XmlSchema As String '儲存取回之資料結構
- Dim InXml As String '儲存呼叫Web Service的傳入參數(Request字串)
- Dim OutXml As String '儲存Web Service的傳回值(Response字串)
- Dim strIdentity As String '儲存Identity XML字串?
- Dim strParameter As String '儲存Parameter XML字串
-
- '//資料表相關變數
-
- Dim dsENT As New DataSet '資料集:儲存取回之資料?
-
- Dim tblENTSubcontractor As String '儲存取回資料表的名稱(master)?
- Dim tblENTSubcontractorCont As String '明細資料表名稱(detail)
- Dim strFilter As String 'Filter string及列印的過濾條件
-
- '//其他共用變數
- Dim SubcontractorNo As String 'for Gird to Focus
- Dim ContactorName As String 'for DetailGrid to Focus
- Dim ugrRow As Infragistics.Win.UltraWinGrid.UltraGridRow
- Friend WithEvents btnAdd As Misc.UltraButton
- Friend WithEvents btnEdit As Misc.UltraButton
- Friend WithEvents btnDel As Misc.UltraButton
- Friend WithEvents btnCopy As Misc.UltraButton
- Friend WithEvents btnApprove As Misc.UltraButton
- Friend WithEvents iugSubcontractor As iMESUltraGrid.iMESUltraGridControl
- Dim i As Integer
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.Container
- Friend WithEvents iugDetail As iMESUltraGrid.iMESUltraGridControl
- Friend WithEvents btnClose As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnEMail As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDCopy As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDDel As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDEdit As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDAdd As Infragistics.Win.Misc.UltraButton
- Private Sub InitializeComponent()
- Me.btnClose = New Infragistics.Win.Misc.UltraButton()
- Me.btnEMail = New Infragistics.Win.Misc.UltraButton()
- Me.btnDCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnDDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnDEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDAdd = New Infragistics.Win.Misc.UltraButton()
- Me.iugDetail = New iMESUltraGrid.iMESUltraGridControl()
- Me.btnAdd = New Infragistics.Win.Misc.UltraButton()
- Me.btnEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnApprove = New Infragistics.Win.Misc.UltraButton()
- Me.iugSubcontractor = New iMESUltraGrid.iMESUltraGridControl()
- Me.SuspendLayout()
- '
- 'btnClose
- '
- Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnClose.Location = New System.Drawing.Point(912, 552)
- Me.btnClose.Name = "btnClose"
- Me.btnClose.Size = New System.Drawing.Size(88, 32)
- Me.btnClose.TabIndex = 18
- Me.btnClose.Text = "Close (&X)"
- '
- 'btnEMail
- '
- Me.btnEMail.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEMail.Location = New System.Drawing.Point(912, 429)
- Me.btnEMail.Name = "btnEMail"
- Me.btnEMail.Size = New System.Drawing.Size(88, 32)
- Me.btnEMail.TabIndex = 17
- Me.btnEMail.Text = "Mail"
- '
- 'btnDCopy
- '
- Me.btnDCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDCopy.Location = New System.Drawing.Point(912, 389)
- Me.btnDCopy.Name = "btnDCopy"
- Me.btnDCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnDCopy.TabIndex = 16
- Me.btnDCopy.Text = "Copy"
- '
- 'btnDDel
- '
- Me.btnDDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDDel.Location = New System.Drawing.Point(912, 349)
- Me.btnDDel.Name = "btnDDel"
- Me.btnDDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDDel.TabIndex = 15
- Me.btnDDel.Text = "DEL"
- '
- 'btnDEdit
- '
- Me.btnDEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDEdit.Location = New System.Drawing.Point(912, 309)
- Me.btnDEdit.Name = "btnDEdit"
- Me.btnDEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnDEdit.TabIndex = 14
- Me.btnDEdit.Text = "EDIT"
- '
- 'btnDAdd
- '
- Me.btnDAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDAdd.Location = New System.Drawing.Point(912, 269)
- Me.btnDAdd.Name = "btnDAdd"
- Me.btnDAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnDAdd.TabIndex = 13
- Me.btnDAdd.Text = "ADD"
- '
- 'iugDetail
- '
- Me.iugDetail.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugDetail.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugDetail.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugDetail.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugDetail.Identity = "IMes"
- Me.iugDetail.IdentityForm = ""
- Me.iugDetail.LayOutFilePath = ""
- Me.iugDetail.Location = New System.Drawing.Point(12, 270)
- Me.iugDetail.Name = "iugDetail"
- Me.iugDetail.PrintFitWidthToPages = 0
- Me.iugDetail.PrintLandscape = True
- Me.iugDetail.PrintPageFooter = ""
- Me.iugDetail.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageFooterHeight = 20
- Me.iugDetail.PrintPageHeader = ""
- Me.iugDetail.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageHeaderHeight = 20
- Me.iugDetail.PrintZoom = 1.0R
- Me.iugDetail.Size = New System.Drawing.Size(894, 314)
- Me.iugDetail.TabIndex = 12
- Me.iugDetail.UserNo = "IMes"
- '
- 'btnAdd
- '
- Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnAdd.Location = New System.Drawing.Point(912, 53)
- Me.btnAdd.Name = "btnAdd"
- Me.btnAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnAdd.TabIndex = 20
- Me.btnAdd.Text = "Add(&A)"
- '
- 'btnEdit
- '
- Me.btnEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEdit.Location = New System.Drawing.Point(912, 93)
- Me.btnEdit.Name = "btnEdit"
- Me.btnEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnEdit.TabIndex = 21
- Me.btnEdit.Text = "Edit(&E)"
- '
- 'btnDel
- '
- Me.btnDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDel.Location = New System.Drawing.Point(912, 133)
- Me.btnDel.Name = "btnDel"
- Me.btnDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDel.TabIndex = 22
- Me.btnDel.Text = "Del(&D)"
- '
- 'btnCopy
- '
- Me.btnCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnCopy.Location = New System.Drawing.Point(912, 173)
- Me.btnCopy.Name = "btnCopy"
- Me.btnCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnCopy.TabIndex = 23
- Me.btnCopy.Text = "Copy(&C)"
- '
- 'btnApprove
- '
- Me.btnApprove.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnApprove.Location = New System.Drawing.Point(912, 213)
- Me.btnApprove.Name = "btnApprove"
- Me.btnApprove.Size = New System.Drawing.Size(88, 32)
- Me.btnApprove.TabIndex = 24
- Me.btnApprove.Text = "Approve(&Y)"
- '
- 'iugSubcontractor
- '
- Me.iugSubcontractor.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugSubcontractor.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugSubcontractor.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugSubcontractor.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugSubcontractor.Identity = "IMes"
- Me.iugSubcontractor.IdentityForm = ""
- Me.iugSubcontractor.LayOutFilePath = ""
- Me.iugSubcontractor.Location = New System.Drawing.Point(12, 53)
- Me.iugSubcontractor.Name = "iugSubcontractor"
- Me.iugSubcontractor.PrintFitWidthToPages = 0
- Me.iugSubcontractor.PrintLandscape = True
- Me.iugSubcontractor.PrintPageFooter = ""
- Me.iugSubcontractor.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageFooterHeight = 20
- Me.iugSubcontractor.PrintPageHeader = ""
- Me.iugSubcontractor.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageHeaderHeight = 20
- Me.iugSubcontractor.PrintZoom = 1.0R
- Me.iugSubcontractor.Size = New System.Drawing.Size(894, 192)
- Me.iugSubcontractor.TabIndex = 25
- Me.iugSubcontractor.UserNo = "IMes"
- '
- 'frmSubcontractor
- '
- Me.ClientSize = New System.Drawing.Size(1008, 591)
- Me.Controls.Add(Me.btnClose)
- Me.Controls.Add(Me.btnApprove)
- Me.Controls.Add(Me.btnEMail)
- Me.Controls.Add(Me.btnDCopy)
- Me.Controls.Add(Me.btnCopy)
- Me.Controls.Add(Me.btnDDel)
- Me.Controls.Add(Me.iugSubcontractor)
- Me.Controls.Add(Me.btnDEdit)
- Me.Controls.Add(Me.btnAdd)
- Me.Controls.Add(Me.btnDAdd)
- Me.Controls.Add(Me.btnDel)
- Me.Controls.Add(Me.iugDetail)
- Me.Controls.Add(Me.btnEdit)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractor"
- Me.Text = "ENT Subcontractor & Contactor"
- Me.WindowState = System.Windows.Forms.FormWindowState.Maximized
- Me.Controls.SetChildIndex(Me.btnEdit, 0)
- Me.Controls.SetChildIndex(Me.iugDetail, 0)
- Me.Controls.SetChildIndex(Me.btnDel, 0)
- Me.Controls.SetChildIndex(Me.btnDAdd, 0)
- Me.Controls.SetChildIndex(Me.btnAdd, 0)
- Me.Controls.SetChildIndex(Me.btnDEdit, 0)
- Me.Controls.SetChildIndex(Me.iugSubcontractor, 0)
- Me.Controls.SetChildIndex(Me.btnDDel, 0)
- Me.Controls.SetChildIndex(Me.btnCopy, 0)
- Me.Controls.SetChildIndex(Me.btnDCopy, 0)
- Me.Controls.SetChildIndex(Me.btnEMail, 0)
- Me.Controls.SetChildIndex(Me.btnApprove, 0)
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractor_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- Call funiMESUltraGridIni() 'Grid初始設定
-
- '//取出資料
- Call funLoadSubcontractor()
-
- SetIssueState(Issue.Unfrozen) '預設在Unforzen上
- SetSearchFieldName(New String() {"SubcontractorNo", "SubcontractorNaME"}) '設置搜尋欄位
-
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractor_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- If Not dsENT Is Nothing Then dsENT.Dispose()
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
- Protected Overrides Sub rdoIssue_CheckedChanged(sender As Object, e As EventArgs)
- If IsNothing(dsENT) Then Exit Sub
-
- Select Case GetIssueState()
- Case Issue.Unfrozen
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=0"
- Case Issue.Pending
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=1"
- Case Issue.Active
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=2"
- Case Issue.Unused
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=-1"
- End Select
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
- Call funShowActiveDetail()
- End Sub
-
- Protected Overrides Sub Finalize()
- MyBase.Finalize()
- End Sub
-
- Private Sub btnAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAdd.Click
-
- Dim fSubcontractorDef As New frmSubcontractorDef
-
- fSubcontractorDef.DefMode = 0
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End Sub
-
- Private Sub btnEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEdit.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'")
-
- '核准狀態為"Unfrozen"者才可修改
-
- If Rows(0).Item("IssueState") <> 0 Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-202202", "[%NOT ALLOWED TO EDIT%]"), MsgBoxStyle.Exclamation, Me.Text)
- Exit Sub
- End If
-
- Dim fSubcontractorDef As New frmSubcontractorDef
- fSubcontractorDef.DefMode = 1
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDel.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Or intIssueState = -1 Or intIssueState = 2 Then '狀態為Unforzen或Unused時直接刪除
-
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", CInput(intIssueState), "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOWED TO delete%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCopy.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorDef As New frmSubcontractorDef
- fSubcontractorDef.DefMode = 2
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnApprove_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnApprove.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100002", "[%ARE YOU SURE TO APPROVE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Then
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo").Value.ToString), "")
- strParameter += CombineXMLParameter("issuestate", "IssueState", "String", intIssueState, "")
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.ApproveSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.ApproveSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.ApproveSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Approve failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOW TO APPROVE%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDAdd.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
-
- 'Dim Rows As DataRow()
- Dim fSubcontractorContDef As New frmSubcontractorContDef
-
- fSubcontractorContDef.DefMode = 0
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- End If
- End Sub
-
- Private Sub btnDEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDEdit.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmSubcontractorContDef
- fSubcontractorContDef.DefMode = 1
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnDDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDDel.Click
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
-
- Cursor.Current = Cursors.WaitCursor
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugDetail.iMESUltraGrid.Selected.Rows.Count - 1
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("ContactorName", "ContactorName", "String", CInput(Me.iugDetail.iMESUltraGrid.Selected.Rows(i).Cells("ContactorName").Value.ToString), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractorCont", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
-
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDCopy.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmSubcontractorContDef
- fSubcontractorContDef.DefMode = 2
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEMail.Click
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
- Dim proMail As New System.Diagnostics.Process
- Dim strAccount As String
-
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- strAccount = "mailto:" & Rows(0).Item("EMail").ToString
- proMail.Start(strAccount)
-
- End If
-
- End Sub
-
- Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnQuery_Click(sender As Object, e As EventArgs)
- Cursor.Current = Cursors.WaitCursor
-
- funLoadSubcontractor()
-
- Cursor.Current = Cursors.Default
- End Sub
-
-#Region "Ultra Grid"
-
- Private Sub iugSubcontractor_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugSubcontractor.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo")
- .Header.Caption = "SubcontractorNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("SubcontractorName")
- .Header.Caption = "SubcontractorName"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("IssueState")
- .Header.Caption = "IssueState"
- .Width = 114
- .Hidden = True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 7
- End With
- With .Bands(0).Columns("AGE")
- .Header.Caption = "AGE"
- .Width = 150
- .Hidden = False
- .Header.VisiblePosition = 8
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
- Private Sub iugSubcontractor_iMESUltraGrid_AfterRowActivate(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles iugSubcontractor.iMESUltraGrid_AfterRowActivate
-
- 'IsGroupByRow不做任何處理
- If Not iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
- Else
- Exit Sub
- End If
-
- End Sub
-
- Private Sub iugDetail_iMESUltraGrid_InitializeLayOut(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugDetail.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo")
- .Header.Caption = "SubcontractorNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("ContactorName")
- .Header.Caption = "ContactorName"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("TelNo")
- .Header.Caption = "TelNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("FaxNo")
- .Header.Caption = "FaxNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("Title")
- .Header.Caption = "Title"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("Address")
- .Header.Caption = "Address"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("EMail")
- .Header.Caption = "EMail"
- .Width = 150
- .Hidden = False
- .CellAppearance.ForeColor = System.Drawing.Color.Blue
- .CellAppearance.FontData.Underline = DefaultableBoolean.True
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 200
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 7
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 8
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 9
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 10
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 11
- End With
- With .Bands(0).Columns("AGE")
- .Header.Caption = "AGE"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 12
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
-#End Region
-
-#Region "Load Function"
-
- '//取出tblENTSubcontractor 外包商資料
-
- Private Sub funLoadSubcontractor()
-
- '先判斷是否dataset中已有ENTSubcontractor之datatable,若有,需先remove否則會有錯誤
- If Not IsNothing(dsENT.Tables(tblENTSubcontractor)) Then
- dsENT.Tables.Remove(tblENTSubcontractor)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- '加上IssueState要求取出所有資料
- strParameter = CombineXMLParameter("issuestate", "IssueState", "Integer", defInteger, "")
- '加上查詢條件 cboSearchFieldName,txtSearchFieldValue
- strParameter += CombineXMLQueryCondition()
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.LoadSubcontractor", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
-
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractor = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractor").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
-
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractor").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractor").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- strFilter = ""
- Select Case GetIssueState()
- Case Issue.Unfrozen
- strFilter = FilterByInteger(strFilter, "IssueState", 0)
- Case Issue.Pending
- strFilter = FilterByInteger(strFilter, "IssueState", 1)
- Case Issue.Active
- strFilter = FilterByInteger(strFilter, "IssueState", 2)
- Case Issue.Unused
- strFilter = FilterByInteger(strFilter, "IssueState", -1)
- End Select
-
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = strFilter
- dsENT.Tables(tblENTSubcontractor).DefaultView.Sort = "SubcontractorNo"
-
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit Sub
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- '//取出tblENTSubcontractorCont聯絡人資料
-
- Private Sub funLoadSubcontractorCont(ByRef SubcontractorNo As String)
-
- If Not IsNothing(dsENT.Tables(tblENTSubcontractorCont)) Then
- dsENT.Tables.Remove(tblENTSubcontractorCont)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", SubcontractorNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.LoadSubcontractorCont", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractorCont = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractorcont").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- Me.iugDetail.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractorCont).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Cont Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- Private Sub funShowActiveDetail()
-
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.DataSource = Nothing
- Else
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
- End If
-
- End Sub
-
- Private Sub funiMESUltraGridIni()
-
- 'iugSubcontractor 初始設定
- With Me.iugSubcontractor.iMESUltraGrid
- .Text = ""
- .DisplayLayout.GroupByBox.Hidden = True
- .DisplayLayout.UseFixedHeaders = False
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugSubcontractor.UserNo = gUserNo
-
- 'iugDetail 初始設定
- With Me.iugDetail.iMESUltraGrid.DisplayLayout
- .GroupByBox.Hidden = True
- .Override.ExpansionIndicator = ShowExpansionIndicator.Default
- .ViewStyle = ViewStyle.SingleBand
- .RowConnectorStyle = RowConnectorStyle.Default
-
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugDetail.UserNo = gUserNo
-
- End Sub
-
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/ENT/ET_Subcontractor/frmSubcontractorContDef.vb b/SRC/MESWin/ENT/ET_Subcontractor/frmSubcontractorContDef.vb
deleted file mode 100644
index 4ccbafa..0000000
--- a/SRC/MESWin/ENT/ET_Subcontractor/frmSubcontractorContDef.vb
+++ /dev/null
@@ -1,751 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorContDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
-
- Public SubcontractorNo As String = defString
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
-
- Friend WithEvents UltraTextEditor1 As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents dll21671 As Label
-
- Friend WithEvents lblAge As Label
- Friend WithEvents txtAge As Infragistics.Win.UltraWinEditors.UltraTextEditor
-
-
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblAddress As System.Windows.Forms.Label
- Friend WithEvents lblEMail As System.Windows.Forms.Label
- Friend WithEvents lblTitle As System.Windows.Forms.Label
- Friend WithEvents lblFaxNo As System.Windows.Forms.Label
- Friend WithEvents lblTelNo As System.Windows.Forms.Label
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblContactorName As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorContData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtContactorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtFaxNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTelNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtEMail As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTitle As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtAddress As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorContData = New System.Windows.Forms.GroupBox()
- Me.txtAddress = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtEMail = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTitle = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtFaxNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblAddress = New System.Windows.Forms.Label()
- Me.lblEMail = New System.Windows.Forms.Label()
- Me.lblTitle = New System.Windows.Forms.Label()
- Me.lblFaxNo = New System.Windows.Forms.Label()
- Me.lblTelNo = New System.Windows.Forms.Label()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblContactorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtContactorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTelNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
-
-
- Me.dll21671 = New System.Windows.Forms.Label()
- Me.UltraTextEditor1 = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
-
- Me.txtAge = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
-
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorContData.SuspendLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).BeginInit()
-
-
- CType(Me.UltraTextEditor1, System.ComponentModel.ISupportInitialize).BeginInit()
-
- CType(Me.txtAge, System.ComponentModel.ISupportInitialize).BeginInit()
-
-
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 322)
- Me.gbxBasisData.Size = New System.Drawing.Size(472, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(396, 401)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(208, 401)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(302, 401)
- '
- 'gbxSubcontractorContData
- '
- Me.gbxSubcontractorContData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
-
-
- Me.gbxSubcontractorContData.Controls.Add(Me.UltraTextEditor1)
- Me.gbxSubcontractorContData.Controls.Add(Me.dll21671)
-
- Me.gbxSubcontractorContData.Controls.Add(Me.txtAge)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblAge)
-
-
- Me.gbxSubcontractorContData.Controls.Add(Me.txtAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTelNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTelNo)
- Me.gbxSubcontractorContData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorContData.Location = New System.Drawing.Point(15, 8)
- Me.gbxSubcontractorContData.Name = "gbxSubcontractorContData"
- Me.gbxSubcontractorContData.Size = New System.Drawing.Size(469, 306)
- Me.gbxSubcontractorContData.TabIndex = 0
- Me.gbxSubcontractorContData.TabStop = False
- Me.gbxSubcontractorContData.Text = "ENT Subcontractor Contactor Data"
- '
- 'txtAddress
- '
- Me.txtAddress.Location = New System.Drawing.Point(116, 152)
- Me.txtAddress.Name = "txtAddress"
- Me.txtAddress.Size = New System.Drawing.Size(336, 26)
- Me.txtAddress.TabIndex = 13
- '
- 'txtEMail
- '
- Me.txtEMail.Location = New System.Drawing.Point(320, 120)
- Me.txtEMail.Name = "txtEMail"
- Me.txtEMail.Size = New System.Drawing.Size(136, 26)
- Me.txtEMail.TabIndex = 11
- '
- 'txtTitle
- '
- Me.txtTitle.Location = New System.Drawing.Point(120, 120)
- Me.txtTitle.Name = "txtTitle"
- Me.txtTitle.Size = New System.Drawing.Size(114, 26)
- Me.txtTitle.TabIndex = 9
- '
- 'txtFaxNo
- '
- Me.txtFaxNo.Location = New System.Drawing.Point(320, 88)
- Me.txtFaxNo.Name = "txtFaxNo"
- Me.txtFaxNo.Size = New System.Drawing.Size(136, 26)
- Me.txtFaxNo.TabIndex = 7
- '
- 'lblAddress
- '
- Me.lblAddress.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblAddress.Location = New System.Drawing.Point(24, 154)
- Me.lblAddress.Name = "lblAddress"
- Me.lblAddress.Size = New System.Drawing.Size(86, 14)
- Me.lblAddress.TabIndex = 12
- Me.lblAddress.Text = "Address"
- Me.lblAddress.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblEMail
- '
- Me.lblEMail.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblEMail.Location = New System.Drawing.Point(248, 123)
- Me.lblEMail.Name = "lblEMail"
- Me.lblEMail.Size = New System.Drawing.Size(64, 14)
- Me.lblEMail.TabIndex = 10
- Me.lblEMail.Text = "EMail"
- Me.lblEMail.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTitle
- '
- Me.lblTitle.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTitle.Location = New System.Drawing.Point(24, 121)
- Me.lblTitle.Name = "lblTitle"
- Me.lblTitle.Size = New System.Drawing.Size(86, 14)
- Me.lblTitle.TabIndex = 8
- Me.lblTitle.Text = "Title"
- Me.lblTitle.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblFaxNo
- '
- Me.lblFaxNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblFaxNo.Location = New System.Drawing.Point(248, 90)
- Me.lblFaxNo.Name = "lblFaxNo"
- Me.lblFaxNo.Size = New System.Drawing.Size(64, 14)
- Me.lblFaxNo.TabIndex = 6
- Me.lblFaxNo.Text = "FaxNo"
- Me.lblFaxNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTelNo
- '
- Me.lblTelNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTelNo.Location = New System.Drawing.Point(24, 90)
- Me.lblTelNo.Name = "lblTelNo"
- Me.lblTelNo.Size = New System.Drawing.Size(86, 14)
- Me.lblTelNo.TabIndex = 4
- Me.lblTelNo.Text = "TelNo"
- Me.lblTelNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(116, 190)
- Me.txtDescription.Name = "txtDescription"
-
- Me.txtDescription.Size = New System.Drawing.Size(336, 108)
-
-
- Me.txtDescription.Size = New System.Drawing.Size(316, 36)
-
- Me.txtDescription.Size = New System.Drawing.Size(336, 21)
-
-
- Me.txtDescription.TabIndex = 15
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(24, 186)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(86, 14)
- Me.lblDescription.TabIndex = 14
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(14, 29)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 14)
- Me.lblSubcontractorNo.TabIndex = 0
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblContactorName
- '
- Me.lblContactorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblContactorName.Location = New System.Drawing.Point(24, 59)
- Me.lblContactorName.Name = "lblContactorName"
- Me.lblContactorName.Size = New System.Drawing.Size(86, 14)
- Me.lblContactorName.TabIndex = 2
- Me.lblContactorName.Text = "Contactor Name"
- Me.lblContactorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(120, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.ReadOnly = True
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(114, 26)
- Me.txtSubcontractorNo.TabIndex = 1
- Me.txtSubcontractorNo.TabStop = False
- '
- 'txtContactorName
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Appearance = Appearance1
- Me.txtContactorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Location = New System.Drawing.Point(120, 56)
- Me.txtContactorName.Name = "txtContactorName"
- Me.txtContactorName.Size = New System.Drawing.Size(160, 26)
- Me.txtContactorName.TabIndex = 3
- '
- 'txtTelNo
- '
- Me.txtTelNo.Location = New System.Drawing.Point(120, 88)
- Me.txtTelNo.Name = "txtTelNo"
- Me.txtTelNo.Size = New System.Drawing.Size(114, 26)
- Me.txtTelNo.TabIndex = 5
- '
-
-
- 'dll21671
- '
- Me.dll21671.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.dll21671.Location = New System.Drawing.Point(14, 236)
- Me.dll21671.Name = "dll21671"
- Me.dll21671.Size = New System.Drawing.Size(86, 14)
- Me.dll21671.TabIndex = 16
- Me.dll21671.Text = "AGE"
- Me.dll21671.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'UltraTextEditor1
- '
- Me.UltraTextEditor1.Location = New System.Drawing.Point(116, 232)
- Me.UltraTextEditor1.Name = "UltraTextEditor1"
- Me.UltraTextEditor1.Size = New System.Drawing.Size(114, 26)
- Me.UltraTextEditor1.TabIndex = 17
-
- 'txtAge
- '
- Me.txtAge.Location = New System.Drawing.Point(120, 222)
- Me.txtAge.Name = "txtAge"
- Me.txtAge.Size = New System.Drawing.Size(336, 22)
- Me.txtAge.TabIndex = 17
-
- '
-
- 'frmSubcontractorContDef
- '
- Me.ClientSize = New System.Drawing.Size(496, 446)
- Me.Controls.Add(Me.gbxSubcontractorContData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorContDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Contactor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorContData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorContData.ResumeLayout(False)
- Me.gbxSubcontractorContData.PerformLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).EndInit()
-
-
- CType(Me.UltraTextEditor1, System.ComponentModel.ISupportInitialize).EndInit()
-
- CType(Me.txtAge, System.ComponentModel.ISupportInitialize).EndInit()
-
-
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorContDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據()
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
- If DefMode = 0 Or DefMode = 2 Then
- SetCreateDate(Now)
- SetCreator(gUserNo)
- End If
- If Not EditDataRow Is Nothing Then '修改 or Copy
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtContactorName.Text = EditDataRow.Item("ContactorName").ToString
- txtTelNo.Text = EditDataRow.Item("TelNo").ToString
- txtFaxNo.Text = EditDataRow.Item("FaxNo").ToString
- txtTitle.Text = EditDataRow.Item("Title").ToString
- txtAddress.Text = EditDataRow.Item("Address").ToString
- txtEMail.Text = EditDataRow.Item("EMail").ToString
-
-
- dll21671.Text = EditDataRow.Item("AGE").ToString
-
- txtAge.Text = EditDataRow.Item("Age").ToString
-
-
- 'txtDescription是RichTextBox(Control, 因為TextBox無法正常顯示多行換行的資料)
- txtDescription.Text = EditDataRow.Item("Description").ToString
- If DefMode = 1 Then
- If (Not IsDBNull(EditDataRow("Creator"))) Then
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetCreator(EditDataRow.Item("Creator").ToString)
- End If
- End If
- End If
-
- If DefMode = 0 Then 'Add
- txtSubcontractorNo.Text = SubcontractorNo
- SetCreateDate(Now)
- SetCreator(gUserNo)
- ElseIf DefMode = 1 Then 'Edit
- txtContactorName.ReadOnly = True
- SetReviseDate(Now)
- SetReviser(gUserNo)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorContDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
-
- txtEMail.Text = ""
- btnApplyEnabled = False
- Cursor.Current = Cursors.Default
-
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtContactorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Click
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Enter
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtContactorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtContactorName_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Leave
- If txtContactorName.Text <> "" And txtEMail.Text = "" Then
- txtEMail.Text = txtContactorName.Text & "@"
- End If
- txtContactorName.Text = UCase(txtContactorName.Text)
- End Sub
-
- Private Sub txtContactorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTelNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Click
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Enter
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTelNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTelNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtFaxNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Click
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Enter
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtFaxNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtFaxNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTitle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Click
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Enter
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTitle.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTitle_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Click
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Enter
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtEMail.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtEMail_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtAddress_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Click
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Enter
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtAddress.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtAddress_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtDescription.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查()
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
- If txtContactorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%ContactorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtContactorName.Focus()
- Exit Function
- End If
-
- '******************************************************************************
- '2.寫回資料庫()
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("contactorname", "ContactorName", "String", CInput(txtContactorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("telno", "TelNo", "String", txtTelNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("faxno", "FaxNo", "String", txtFaxNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("title", "Title", "String", CInput(txtTitle.Text), "")
- strParameter = strParameter & CombineXMLParameter("address", "Address", "String", CInput(txtAddress.Text), "")
- strParameter = strParameter & CombineXMLParameter("email", "EMail", "String", CInput(txtEMail.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
- strParameter = strParameter & CombineXMLParameter("AGE", "AGE", "String", CInput(dll21671.Text), "")
-
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.AddSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.AddSubcontractorCont", InXml)
-
- Else 'Edit
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.EditSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.EditSubcontractorCont", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtContactorName.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Contactor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-#End Region
-
-
- Private Sub frmSubcontractorContDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
-
-
- Private Sub UltraTextEditor1_ValueChanged(sender As Object, e As EventArgs) Handles UltraTextEditor1.ValueChanged
-
- End Sub
-
- Private Sub DD_Click(sender As Object, e As EventArgs) Handles dll21671.Click
-
- End Sub
-
-
-
-End Class
-
diff --git a/SRC/MESWin/ENT/ET_Subcontractor/frmSubcontractorDef.vb b/SRC/MESWin/ENT/ET_Subcontractor/frmSubcontractorDef.vb
deleted file mode 100644
index e7662bc..0000000
--- a/SRC/MESWin/ENT/ET_Subcontractor/frmSubcontractorDef.vb
+++ /dev/null
@@ -1,476 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
-
-
- Friend WithEvents RichTextBox1 As RichTextBox
- Friend WithEvents dll21671_01 As Label
-
- Friend WithEvents txtAge As RichTextBox
- Friend WithEvents lblAge As Label
-
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorName As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtSubcontractorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance2 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorData = New System.Windows.Forms.GroupBox()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblSubcontractorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtSubcontractorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.dll21671_01 = New System.Windows.Forms.Label()
- Me.RichTextBox1 = New System.Windows.Forms.RichTextBox()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorData.SuspendLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 185)
- Me.gbxBasisData.Size = New System.Drawing.Size(479, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(403, 264)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(215, 264)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(309, 264)
- '
- 'gbxSubcontractorData
- '
- Me.gbxSubcontractorData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
-
-
- Me.gbxSubcontractorData.Controls.Add(Me.RichTextBox1)
- Me.gbxSubcontractorData.Controls.Add(Me.dll21671_01)
-
- Me.gbxSubcontractorData.Controls.Add(Me.txtAge)
- Me.gbxSubcontractorData.Controls.Add(Me.lblAge)
-
-
- Me.gbxSubcontractorData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorName)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorName)
- Me.gbxSubcontractorData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorData.Location = New System.Drawing.Point(12, 8)
- Me.gbxSubcontractorData.Name = "gbxSubcontractorData"
- Me.gbxSubcontractorData.Size = New System.Drawing.Size(479, 169)
- Me.gbxSubcontractorData.TabIndex = 7
- Me.gbxSubcontractorData.TabStop = False
- Me.gbxSubcontractorData.Text = "Subcontractor Data"
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(128, 86)
- Me.txtDescription.Name = "txtDescription"
-
-
- Me.txtDescription.Size = New System.Drawing.Size(316, 33)
-
- Me.txtDescription.Size = New System.Drawing.Size(334, 24)
-
-
- Me.txtDescription.TabIndex = 2
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(56, 88)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(64, 14)
- Me.lblDescription.TabIndex = 13
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(24, 24)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 32)
- Me.lblSubcontractorNo.TabIndex = 5
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorName
- '
- Me.lblSubcontractorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorName.Location = New System.Drawing.Point(8, 56)
- Me.lblSubcontractorName.Name = "lblSubcontractorName"
- Me.lblSubcontractorName.Size = New System.Drawing.Size(112, 32)
- Me.lblSubcontractorName.TabIndex = 9
- Me.lblSubcontractorName.Text = "Subcontractor Name"
- Me.lblSubcontractorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Appearance = Appearance1
- Me.txtSubcontractorNo.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(128, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(152, 26)
- Me.txtSubcontractorNo.TabIndex = 0
- '
- 'txtSubcontractorName
- '
- Appearance2.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Appearance = Appearance2
- Me.txtSubcontractorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Location = New System.Drawing.Point(128, 55)
- Me.txtSubcontractorName.Name = "txtSubcontractorName"
- Me.txtSubcontractorName.Size = New System.Drawing.Size(334, 26)
- Me.txtSubcontractorName.TabIndex = 1
- '
- 'dll21671_01
- '
- Me.dll21671_01.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.dll21671_01.Location = New System.Drawing.Point(56, 128)
- Me.dll21671_01.Name = "dll21671_01"
- Me.dll21671_01.Size = New System.Drawing.Size(64, 14)
- Me.dll21671_01.TabIndex = 14
- Me.dll21671_01.Text = "AGE"
- Me.dll21671_01.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'RichTextBox1
- '
- Me.RichTextBox1.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.RichTextBox1.Location = New System.Drawing.Point(128, 125)
- Me.RichTextBox1.Name = "RichTextBox1"
- Me.RichTextBox1.Size = New System.Drawing.Size(120, 33)
- Me.RichTextBox1.TabIndex = 15
- Me.RichTextBox1.Text = ""
- '
- 'frmSubcontractorDef
- '
- Me.ClientSize = New System.Drawing.Size(503, 309)
- Me.Controls.Add(Me.gbxSubcontractorData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorData.ResumeLayout(False)
- Me.gbxSubcontractorData.PerformLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- If Not EditDataRow Is Nothing Then
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtSubcontractorName.Text = EditDataRow.Item("SubcontractorName").ToString
- 'txtDescription是RichTextBox Control,因為TextBox無法正常顯示多行換行的資料
- txtDescription.Text = EditDataRow.Item("Description").ToString
-
-
- dll21671_01.Text = EditDataRow.Item("AGE").ToString
-
- txtAge.Text = EditDataRow.Item("Age").ToString
-
- End If
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- SetCreator(gUserNo)
- SetCreateDate(Now)
- ElseIf DefMode = 1 Then 'Edit
- txtSubcontractorNo.ReadOnly = True
- SetCreator(EditDataRow.Item("Creator").ToString)
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetReviser(gUserNo)
- SetReviseDate(Now)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
-
- End If
-
- Cursor.Current = Cursors.Default
- btnApplyEnabled = False
-
- End Sub
-
- Private Sub frmSubcontractorDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Leave
- txtSubcontractorNo.Text = UCase(txtSubcontractorNo.Text)
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtSubcontractorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Click
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Enter
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
-
- If txtSubcontractorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorName.Focus()
- Exit Function
- End If
-
- '2.
- '******************************************************************************
- '寫回資料庫
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("subcontractorname", "SubcontractorName", "String", CInput(txtSubcontractorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
- strParameter = strParameter & CombineXMLParameter("AGE", "AGE", "String", dll21671_01.Text, "")
-
- strParameter = strParameter & CombineXMLParameter("age", "Age", "String", txtAge.Text, "")
-
-
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter = strParameter & CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("createdate", "CreateDate", "DateTime", Format(Now, "yyyy/MM/dd HH:mm:ss"), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.AddSubcontractor(InXml)
- OutXml = InvokeSrv("wsENT.AddSubcontractor", InXml)
-
- Else
- '修改
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", EditDataRow.Item("IssueState").ToString, "")
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.EditSubcontractor(InXml)
- OutXml = InvokeSrv("wsENT.EditSubcontractor", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtSubcontractorNo.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.vbproj b/SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.vbproj
deleted file mode 100644
index fc8e9ea..0000000
--- a/SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.vbproj
+++ /dev/null
@@ -1,207 +0,0 @@
-
-
-
-
- Debug
- x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}
- Library
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/ET_Subcontractor.vbproj
- ET_Subcontractor_21691
- ET_Subcontractor_21691
-========
- ET_Teacher_M
- ET_Teacher_M
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.vbproj
- 512
- Windows
- v4.6.2
-
- SAK
- SAK
- SAK
- SAK
-
-
- On
-
-
- Binary
-
-
- Off
-
-
- On
-
-
- true
- true
- true
- ..\..\..\MESClient\
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/ET_Subcontractor.vbproj
- ET_Subcontractor_21691.xml
-========
- ET_Teacher_M.xml
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.vbproj
- 0
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- full
- x86
- MinimumRecommendedRules.ruleset
- false
-
-
- true
- ..\..\..\MESClient\
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/ET_Subcontractor.vbproj
- ET_Subcontractor_21691.xml
-========
- ET_Teacher_M.xml
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.vbproj
- true
- 0
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- pdbonly
- x86
- MinimumRecommendedRules.ruleset
- false
-
-
- true
-
-
- iMES.snk
-
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinGrid.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinEditors.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.Misc.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Shared.v19.1.dll
- False
-
-
- ..\..\..\MESClient\COM_Kit.dll
- False
-
-
- ..\..\..\MES_C_DLL\iMESExceptionManager.dll
- False
-
-
- ..\..\..\MES_C_DLL\iMESUltraGrid.dll
- False
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- modConstant.vb
-
-
- Form
-
-
- Form
-
-
- Form
-
-
-
- True
- Application.myapp
- True
-
-
- True
- True
- Resources.resx
-
-
- True
- Settings.settings
- True
-
-
-
-
- frmSubcontractor.vb
-
-
- frmTeacherContDef.vb
-
-
- frmTeacherDef.vb
-
-
-
- VbMyResourcesResXFileCodeGenerator
- Resources.Designer.vb
- My.Resources
- Designer
-
-
-
-
-
- MyApplicationCodeGenerator
- Application.Designer.vb
-
-
- SettingsSingleFileGenerator
- My
- Settings.Designer.vb
-
-
-
-
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.vbproj.user b/SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.vbproj.user
deleted file mode 100644
index 9fe4e52..0000000
--- a/SRC/MESWin/SYS1/ET_21674/ET_Subcontractor.vbproj.user
+++ /dev/null
@@ -1,6 +0,0 @@
-
-
-
- D:\Program Files\work\IIS\607.4\MESsc\SClientSource\
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS1/ET_21674/My Project/Application.Designer.vb b/SRC/MESWin/SYS1/ET_21674/My Project/Application.Designer.vb
deleted file mode 100644
index 537244b..0000000
--- a/SRC/MESWin/SYS1/ET_21674/My Project/Application.Designer.vb
+++ /dev/null
@@ -1,13 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
diff --git a/SRC/MESWin/SYS1/ET_21674/My Project/AssemblyInfo.vb b/SRC/MESWin/SYS1/ET_21674/My Project/AssemblyInfo.vb
deleted file mode 100644
index b0cdd98..0000000
--- a/SRC/MESWin/SYS1/ET_21674/My Project/AssemblyInfo.vb
+++ /dev/null
@@ -1,35 +0,0 @@
-Imports System
-Imports System.Reflection
-Imports System.Runtime.InteropServices
-
-' 組件的一般資訊是由下列的屬性集控制。
-' 變更這些屬性的值即可修改組件的相關
-' 資訊。
-
-' 檢閱組件屬性的值
-
-
-
-
-
-
-
-
-
-
-'下列 GUID 為專案公開 (Expose) 至 COM 時所要使用的 typelib ID
-
-
-' 組件的版本資訊由下列四個值所組成:
-'
-' 主要版本
-' 次要版本
-' 組建編號
-' 修訂編號
-'
-' 您可以指定所有的值,也可以依照以下的方式,使用 '*' 將組建和修訂編號
-' 指定為預設值:
-'
-
-
-
diff --git a/SRC/MESWin/SYS1/ET_21674/My Project/BuildIncrementVersionInfo.vb b/SRC/MESWin/SYS1/ET_21674/My Project/BuildIncrementVersionInfo.vb
deleted file mode 100644
index d2f2e21..0000000
--- a/SRC/MESWin/SYS1/ET_21674/My Project/BuildIncrementVersionInfo.vb
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/SRC/MESWin/SYS1/ET_21674/My Project/Resources.Designer.vb b/SRC/MESWin/SYS1/ET_21674/My Project/Resources.Designer.vb
deleted file mode 100644
index 688b951..0000000
--- a/SRC/MESWin/SYS1/ET_21674/My Project/Resources.Designer.vb
+++ /dev/null
@@ -1,67 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-Imports System
-
-Namespace My.Resources
-
- '此类是由 StronglyTypedResourceBuilder
- '类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
- '若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen
- '(以 /str 作为命令选项),或重新生成 VS 项目。
- '''
- ''' 一个强类型的资源类,用于查找本地化的字符串等。
- '''
- _
- Friend Module Resources
-
- Private resourceMan As Global.System.Resources.ResourceManager
-
- Private resourceCulture As Global.System.Globalization.CultureInfo
-
- '''
- ''' 返回此类使用的缓存的 ResourceManager 实例。
- '''
- _
- Friend ReadOnly Property ResourceManager() As Global.System.Resources.ResourceManager
- Get
- If Object.ReferenceEquals(resourceMan, Nothing) Then
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/My Project/Resources.Designer.vb
- Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("ET_Subcontractor_21691.Resources", GetType(Resources).Assembly)
-========
- Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("ET_Teacher_M.Resources", GetType(Resources).Assembly)
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/My Project/Resources.Designer.vb
- resourceMan = temp
- End If
- Return resourceMan
- End Get
- End Property
-
- '''
- ''' 重写当前线程的 CurrentUICulture 属性,对
- ''' 使用此强类型资源类的所有资源查找执行重写。
- '''
- _
- Friend Property Culture() As Global.System.Globalization.CultureInfo
- Get
- Return resourceCulture
- End Get
- Set
- resourceCulture = value
- End Set
- End Property
- End Module
-End Namespace
diff --git a/SRC/MESWin/SYS1/ET_21674/My Project/Settings.Designer.vb b/SRC/MESWin/SYS1/ET_21674/My Project/Settings.Designer.vb
deleted file mode 100644
index 2ac46e7..0000000
--- a/SRC/MESWin/SYS1/ET_21674/My Project/Settings.Designer.vb
+++ /dev/null
@@ -1,79 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-
-Namespace My
-
- _
- Partial Friend NotInheritable Class MySettings
- Inherits Global.System.Configuration.ApplicationSettingsBase
-
- Private Shared defaultInstance As MySettings = CType(Global.System.Configuration.ApplicationSettingsBase.Synchronized(New MySettings()),MySettings)
-
-#Region "My.Settings 自动保存功能"
-#If _MyType = "WindowsForms" Then
- Private Shared addedHandler As Boolean
-
- Private Shared addedHandlerLockObject As New Object
-
- _
- Private Shared Sub AutoSaveSettings(sender As Global.System.Object, e As Global.System.EventArgs)
- If My.Application.SaveMySettingsOnExit Then
- My.Settings.Save()
- End If
- End Sub
-#End If
-#End Region
-
- Public Shared ReadOnly Property [Default]() As MySettings
- Get
-
-#If _MyType = "WindowsForms" Then
- If Not addedHandler Then
- SyncLock addedHandlerLockObject
- If Not addedHandler Then
- AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings
- addedHandler = True
- End If
- End SyncLock
- End If
-#End If
- Return defaultInstance
- End Get
- End Property
- End Class
-End Namespace
-
-Namespace My
-
- _
- Friend Module MySettingsProperty
-
- _
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/My Project/Settings.Designer.vb
- Friend ReadOnly Property Settings() As Global.ET_Subcontractor_21691.My.MySettings
- Get
- Return Global.ET_Subcontractor_21691.My.MySettings.Default
-========
- Friend ReadOnly Property Settings() As Global.ET_Teacher_M.My.MySettings
- Get
- Return Global.ET_Teacher_M.My.MySettings.Default
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/My Project/Settings.Designer.vb
- End Get
- End Property
- End Module
-End Namespace
diff --git a/SRC/MESWin/SYS1/ET_21674/My Project/Settings.settings b/SRC/MESWin/SYS1/ET_21674/My Project/Settings.settings
deleted file mode 100644
index 85b890b..0000000
--- a/SRC/MESWin/SYS1/ET_21674/My Project/Settings.settings
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
-
diff --git a/SRC/MESWin/SYS1/ET_21674/My Project/licenses.licx b/SRC/MESWin/SYS1/ET_21674/My Project/licenses.licx
deleted file mode 100644
index e3f40e2..0000000
--- a/SRC/MESWin/SYS1/ET_21674/My Project/licenses.licx
+++ /dev/null
@@ -1,7 +0,0 @@
-Infragistics.Win.Misc.UltraButton, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraRadioButton, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraComboEditor, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraGroupBox, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraTextEditor, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraLabel, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraPanel, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
diff --git a/SRC/MESWin/SYS1/ET_21674/frmSubcontractor.vb b/SRC/MESWin/SYS1/ET_21674/frmSubcontractor.vb
deleted file mode 100644
index 50ea352..0000000
--- a/SRC/MESWin/SYS1/ET_21674/frmSubcontractor.vb
+++ /dev/null
@@ -1,1133 +0,0 @@
-Imports iMESExceptionManager
-
-Imports Infragistics.Win
-Imports Infragistics.Win.UltraWinGrid
-Public Class frmTeacher
-
- Inherits COM_Kit.frmBasisTemplat
-
- Public PrivFunNo As String = defString
-
- '//WS相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT '宣告Web Service物件?
- Dim tmpStringReader As System.IO.StringReader '將字串轉換成可讀入DataSet的物件
- Dim XmlData As String '儲存取回之資料
- Dim XmlSchema As String '儲存取回之資料結構
- Dim InXml As String '儲存呼叫Web Service的傳入參數(Request字串)
- Dim OutXml As String '儲存Web Service的傳回值(Response字串)
- Dim strIdentity As String '儲存Identity XML字串?
- Dim strParameter As String '儲存Parameter XML字串
-
- '//資料表相關變數
-
- Dim dsENT As New DataSet '資料集:儲存取回之資料?
-
- Dim AA_21674TEACHER As String '儲存取回資料表的名稱(master)?
- Dim AA_21674TeacherCont As String '明細資料表名稱(detail)
- Dim strFilter As String 'Filter string及列印的過濾條件
-
- '//其他共用變數
- Dim TeacherNo As String 'for Gird to Focus
- Dim ContactorName As String 'for DetailGrid to Focus
- Dim ugrRow As Infragistics.Win.UltraWinGrid.UltraGridRow
- Friend WithEvents btnAdd As Misc.UltraButton
- Friend WithEvents btnEdit As Misc.UltraButton
- Friend WithEvents btnDel As Misc.UltraButton
- Friend WithEvents btnCopy As Misc.UltraButton
- Friend WithEvents btnApprove As Misc.UltraButton
- Friend WithEvents iugTeacher As iMESUltraGrid.iMESUltraGridControl
- Dim i As Integer
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.Container
- Friend WithEvents iugDetail As iMESUltraGrid.iMESUltraGridControl
- Friend WithEvents btnClose As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnEMail As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDCopy As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDDel As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDEdit As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDAdd As Infragistics.Win.Misc.UltraButton
- Private Sub InitializeComponent()
- Me.btnClose = New Infragistics.Win.Misc.UltraButton()
- Me.btnEMail = New Infragistics.Win.Misc.UltraButton()
- Me.btnDCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnDDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnDEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDAdd = New Infragistics.Win.Misc.UltraButton()
- Me.iugDetail = New iMESUltraGrid.iMESUltraGridControl()
- Me.btnAdd = New Infragistics.Win.Misc.UltraButton()
- Me.btnEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnApprove = New Infragistics.Win.Misc.UltraButton()
- Me.iugTeacher = New iMESUltraGrid.iMESUltraGridControl()
- Me.SuspendLayout()
- '
- 'btnClose
- '
- Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnClose.Location = New System.Drawing.Point(912, 552)
- Me.btnClose.Name = "btnClose"
- Me.btnClose.Size = New System.Drawing.Size(88, 32)
- Me.btnClose.TabIndex = 18
- Me.btnClose.Text = "Close (&X)"
- '
- 'btnEMail
- '
- Me.btnEMail.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEMail.Location = New System.Drawing.Point(912, 429)
- Me.btnEMail.Name = "btnEMail"
- Me.btnEMail.Size = New System.Drawing.Size(88, 32)
- Me.btnEMail.TabIndex = 17
- Me.btnEMail.Text = "Mail"
- '
- 'btnDCopy
- '
- Me.btnDCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDCopy.Location = New System.Drawing.Point(912, 389)
- Me.btnDCopy.Name = "btnDCopy"
- Me.btnDCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnDCopy.TabIndex = 16
- Me.btnDCopy.Text = "Copy"
- '
- 'btnDDel
- '
- Me.btnDDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDDel.Location = New System.Drawing.Point(912, 349)
- Me.btnDDel.Name = "btnDDel"
- Me.btnDDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDDel.TabIndex = 15
- Me.btnDDel.Text = "DEL"
- '
- 'btnDEdit
- '
- Me.btnDEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDEdit.Location = New System.Drawing.Point(912, 309)
- Me.btnDEdit.Name = "btnDEdit"
- Me.btnDEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnDEdit.TabIndex = 14
- Me.btnDEdit.Text = "EDIT"
- '
- 'btnDAdd
- '
- Me.btnDAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDAdd.Location = New System.Drawing.Point(912, 269)
- Me.btnDAdd.Name = "btnDAdd"
- Me.btnDAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnDAdd.TabIndex = 13
- Me.btnDAdd.Text = "ADD"
- '
- 'iugDetail
- '
- Me.iugDetail.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugDetail.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugDetail.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugDetail.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugDetail.Identity = "IMes"
- Me.iugDetail.IdentityForm = ""
- Me.iugDetail.LayOutFilePath = ""
- Me.iugDetail.Location = New System.Drawing.Point(12, 270)
- Me.iugDetail.Name = "iugDetail"
- Me.iugDetail.PrintFitWidthToPages = 0
- Me.iugDetail.PrintLandscape = True
- Me.iugDetail.PrintPageFooter = ""
- Me.iugDetail.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageFooterHeight = 20
- Me.iugDetail.PrintPageHeader = ""
- Me.iugDetail.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageHeaderHeight = 20
- Me.iugDetail.PrintZoom = 1.0R
- Me.iugDetail.Size = New System.Drawing.Size(894, 314)
- Me.iugDetail.TabIndex = 12
- Me.iugDetail.UserNo = "IMes"
- '
- 'btnAdd
- '
- Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnAdd.Location = New System.Drawing.Point(912, 53)
- Me.btnAdd.Name = "btnAdd"
- Me.btnAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnAdd.TabIndex = 20
- Me.btnAdd.Text = "Add(&A)"
- '
- 'btnEdit
- '
- Me.btnEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEdit.Location = New System.Drawing.Point(912, 93)
- Me.btnEdit.Name = "btnEdit"
- Me.btnEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnEdit.TabIndex = 21
- Me.btnEdit.Text = "Edit(&E)"
- '
- 'btnDel
- '
- Me.btnDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDel.Location = New System.Drawing.Point(912, 133)
- Me.btnDel.Name = "btnDel"
- Me.btnDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDel.TabIndex = 22
- Me.btnDel.Text = "Del(&D)"
- '
- 'btnCopy
- '
- Me.btnCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnCopy.Location = New System.Drawing.Point(912, 173)
- Me.btnCopy.Name = "btnCopy"
- Me.btnCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnCopy.TabIndex = 23
- Me.btnCopy.Text = "Copy(&C)"
- '
- 'btnApprove
- '
- Me.btnApprove.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnApprove.Location = New System.Drawing.Point(912, 213)
- Me.btnApprove.Name = "btnApprove"
- Me.btnApprove.Size = New System.Drawing.Size(88, 32)
- Me.btnApprove.TabIndex = 24
- Me.btnApprove.Text = "Approve(&Y)"
- '
- 'iugTeacher
- '
- Me.iugTeacher.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugTeacher.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugTeacher.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugTeacher.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugTeacher.Identity = "IMes"
- Me.iugTeacher.IdentityForm = ""
- Me.iugTeacher.LayOutFilePath = ""
- Me.iugTeacher.Location = New System.Drawing.Point(12, 53)
- Me.iugTeacher.Name = "iugTeacher"
- Me.iugTeacher.PrintFitWidthToPages = 0
- Me.iugTeacher.PrintLandscape = True
- Me.iugTeacher.PrintPageFooter = ""
- Me.iugTeacher.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugTeacher.PrintPageFooterHeight = 20
- Me.iugTeacher.PrintPageHeader = ""
- Me.iugTeacher.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugTeacher.PrintPageHeaderHeight = 20
- Me.iugTeacher.PrintZoom = 1.0R
- Me.iugTeacher.Size = New System.Drawing.Size(894, 192)
- Me.iugTeacher.TabIndex = 25
- Me.iugTeacher.UserNo = "IMes"
- '
- 'frmTeacher
- '
- Me.ClientSize = New System.Drawing.Size(1008, 591)
- Me.Controls.Add(Me.btnClose)
- Me.Controls.Add(Me.btnApprove)
- Me.Controls.Add(Me.btnEMail)
- Me.Controls.Add(Me.btnDCopy)
- Me.Controls.Add(Me.btnCopy)
- Me.Controls.Add(Me.btnDDel)
- Me.Controls.Add(Me.iugTeacher)
- Me.Controls.Add(Me.btnDEdit)
- Me.Controls.Add(Me.btnAdd)
- Me.Controls.Add(Me.btnDAdd)
- Me.Controls.Add(Me.btnDel)
- Me.Controls.Add(Me.iugDetail)
- Me.Controls.Add(Me.btnEdit)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmTeacher"
- Me.Text = "ENT Teacher"
- Me.WindowState = System.Windows.Forms.FormWindowState.Maximized
- Me.Controls.SetChildIndex(Me.btnEdit, 0)
- Me.Controls.SetChildIndex(Me.iugDetail, 0)
- Me.Controls.SetChildIndex(Me.btnDel, 0)
- Me.Controls.SetChildIndex(Me.btnDAdd, 0)
- Me.Controls.SetChildIndex(Me.btnAdd, 0)
- Me.Controls.SetChildIndex(Me.btnDEdit, 0)
- Me.Controls.SetChildIndex(Me.iugTeacher, 0)
- Me.Controls.SetChildIndex(Me.btnDDel, 0)
- Me.Controls.SetChildIndex(Me.btnCopy, 0)
- Me.Controls.SetChildIndex(Me.btnDCopy, 0)
- Me.Controls.SetChildIndex(Me.btnEMail, 0)
- Me.Controls.SetChildIndex(Me.btnApprove, 0)
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractor_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- Call funiMESUltraGridIni() 'Grid初始設定
-
- '//取出資料
- Call funLoadTeacher()
-
- SetIssueState(Issue.Unfrozen) '預設在Unforzen上
- SetSearchFieldName(New String() {"TeacherNo", "TeacherNaME"}) '設置搜尋欄位
-
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractor_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- If Not dsENT Is Nothing Then dsENT.Dispose()
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
- Protected Overrides Sub rdoIssue_CheckedChanged(sender As Object, e As EventArgs)
- If IsNothing(dsENT) Then Exit Sub
-
- Select Case GetIssueState()
- Case Issue.Unfrozen
- dsENT.Tables(AA_21674TEACHER).DefaultView.RowFilter = "IssueState=0"
- Case Issue.Pending
- dsENT.Tables(AA_21674TEACHER).DefaultView.RowFilter = "IssueState=1"
- Case Issue.Active
- dsENT.Tables(AA_21674TEACHER).DefaultView.RowFilter = "IssueState=2"
- Case Issue.Unused
- dsENT.Tables(AA_21674TEACHER).DefaultView.RowFilter = "IssueState=-1"
- End Select
- Me.iugTeacher.iMESUltraGrid.DataSource = dsENT.Tables(AA_21674TEACHER).DefaultView
- Call funShowActiveDetail()
- End Sub
-
- Protected Overrides Sub Finalize()
- MyBase.Finalize()
- End Sub
-
- Private Sub btnAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAdd.Click
-
- Dim frmTeacherDef As New frmTeacherDef
-
- frmTeacherDef.DefMode = 0
- frmTeacherDef.ShowDialog(Me)
- frmTeacherDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- TeacherNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadTeacher()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugTeacher, "TeacherNo", TeacherNo)
- If Not ugrRow Is Nothing Then
- Me.iugTeacher.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugTeacher.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End Sub
-
- Private Sub btnEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEdit.Click
-
-
-
- If Not Me.iugTeacher.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugTeacher.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(AA_21674TEACHER).Select("TeacherNo = '" _
- & Replace(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString, "'", "''") & "'")
-
- '核准狀態為"Unfrozen"者才可修改
-
- If Rows(0).Item("IssueState") <> 0 Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-202202", "[%NOT ALLOWED TO EDIT%]"), MsgBoxStyle.Exclamation, Me.Text)
- Exit Sub
- End If
-
- Dim fTeacherDef As New frmTeacherDef
- fTeacherDef.DefMode = 1
- fTeacherDef.EditDataRow = Rows(0)
- fTeacherDef.ShowDialog(Me)
- fTeacherDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- TeacherNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadTeacher()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugTeacher, "TeacherNo", TeacherNo)
- If Not ugrRow Is Nothing Then
- Me.iugTeacher.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugTeacher.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDel.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugTeacher.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugTeacher.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugTeacher.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugTeacher.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugTeacher.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugTeacher.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugTeacher.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugTeacher.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Or intIssueState = -1 Or intIssueState = 2 Then '狀態為Unforzen或Unused時直接刪除
-
- strParameter = CombineXMLParameter("TeacherNo", "TeacherNo", "String", CInput(Me.iugTeacher.iMESUltraGrid.Selected.Rows(i).Cells("TeacherNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", CInput(intIssueState), "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugTeacher.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT_21674.DelTeacher", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOWED TO delete%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadTeacher()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCopy.Click
-
-
-
- If Not Me.iugTeacher.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugTeacher.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(AA_21674TEACHER).Select("TeacherNo = '" _
- & Replace(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorDef As New frmTeacherDef
- fSubcontractorDef.DefMode = 2
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- TeacherNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadTeacher()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugTeacher, "TeacherNo", TeacherNo)
- If Not ugrRow Is Nothing Then
- Me.iugTeacher.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugTeacher.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnApprove_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnApprove.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugTeacher.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugTeacher.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugTeacher.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugTeacher.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugTeacher.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugTeacher.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100002", "[%ARE YOU SURE TO APPROVE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugTeacher.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugTeacher.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Then
- strParameter = CombineXMLParameter("teacherno", "TeacherNo", "String", CInput(Me.iugTeacher.iMESUltraGrid.Selected.Rows(i).Cells("TeacherNo").Value.ToString), "")
- strParameter += CombineXMLParameter("issuestate", "IssueState", "String", intIssueState, "")
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugTeacher.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.ApproveSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.ApproveSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT_21674.ApproveTeacher", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Approve failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOW TO APPROVE%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadTeacher()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDAdd.Click
-
- If Not Me.iugTeacher.iMESUltraGrid.ActiveRow Is Nothing Then
-
- 'Dim Rows As DataRow()
- Dim fSubcontractorContDef As New frmTeacherContDef
-
- 'fSubcontractorContDef.DefMode = 0
- ' fSubcontractorContDef.TeacherNo = Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadTeacherCont(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- End If
- End Sub
-
- Private Sub btnDEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDEdit.Click
-
- If Not Me.iugTeacher.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugTeacher.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(AA_21674TeacherCont).Select("TeacherNo = '" _
- & Replace(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmTeacherContDef
- fSubcontractorContDef.DefMode = 1
- fSubcontractorContDef.EditDataRow = Rows(0)
- 'fSubcontractorContDef.TeacherNo = Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadTeacherCont(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnDDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDDel.Click
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
-
- Cursor.Current = Cursors.WaitCursor
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugDetail.iMESUltraGrid.Selected.Rows.Count - 1
- strParameter = CombineXMLParameter("TeacherNo", "TeacherNo", "String", CInput(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("ContactorName", "ContactorName", "String", CInput(Me.iugDetail.iMESUltraGrid.Selected.Rows(i).Cells("ContactorName").Value.ToString), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractorCont", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
-
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then Call funLoadTeacherCont(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString)
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDCopy.Click
-
- If Not Me.iugTeacher.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugTeacher.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(AA_21674TeacherCont).Select("TeacherNo = '" _
- & Replace(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmTeacherContDef
- fSubcontractorContDef.DefMode = 2
- fSubcontractorContDef.EditDataRow = Rows(0)
- 'fSubcontractorContDef.TeacherNo = Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadTeacherCont(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEMail.Click
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
- Dim proMail As New System.Diagnostics.Process
- Dim strAccount As String
-
- Rows = dsENT.Tables(AA_21674TeacherCont).Select("TeacherNo = '" _
- & Replace(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- strAccount = "mailto:" & Rows(0).Item("EMail").ToString
- proMail.Start(strAccount)
-
- End If
-
- End Sub
-
- Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnQuery_Click(sender As Object, e As EventArgs)
- Cursor.Current = Cursors.WaitCursor
-
- funLoadTeacher()
-
- Cursor.Current = Cursors.Default
- End Sub
-
-#Region "Ultra Grid"
-
- Private Sub iugSubcontractor_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugTeacher.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("TeacherNo")
- .Header.Caption = "TeacherNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("TeacherName")
- .Header.Caption = "TeacherName"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("IssueState")
- .Header.Caption = "IssueState"
- .Width = 114
- .Hidden = True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 7
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
- Private Sub iugSubcontractor_iMESUltraGrid_AfterRowActivate(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles iugTeacher.iMESUltraGrid_AfterRowActivate
-
- 'IsGroupByRow不做任何處理
- If Not iugTeacher.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Call funLoadTeacherCont(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString)
- Else
- Exit Sub
- End If
-
- End Sub
-
- Private Sub iugDetail_iMESUltraGrid_InitializeLayOut(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugDetail.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("TeacherNo")
- .Header.Caption = "TeacherNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("TeacherContName")
- .Header.Caption = "TeacherContName"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("TelNo")
- .Header.Caption = "TelNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("FaxNo")
- .Header.Caption = "FaxNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("Title")
- .Header.Caption = "Title"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("Address")
- .Header.Caption = "Address"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("EMail")
- .Header.Caption = "EMail"
- .Width = 150
- .Hidden = False
- .CellAppearance.ForeColor = System.Drawing.Color.Blue
- .CellAppearance.FontData.Underline = DefaultableBoolean.True
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 200
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 7
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 8
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 9
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 10
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 11
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
-#End Region
-
-#Region "Load Function"
-
- '//取出tblENTSubcontractor 外包商資料
-
- Private Sub funLoadTeacher()
-
- '先判斷是否dataset中已有ENTSubcontractor之datatable,若有,需先remove否則會有錯誤
- If Not IsNothing(dsENT.Tables(AA_21674TEACHER)) Then
- dsENT.Tables.Remove(AA_21674TEACHER)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- '加上IssueState要求取出所有資料
- strParameter = CombineXMLParameter("issuestate", "IssueState", "Integer", defInteger, "")
- '加上查詢條件 cboSearchFieldName,txtSearchFieldValue
- strParameter += CombineXMLQueryCondition()
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadTeacher(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadTeacher", InXml)
- OutXml = InvokeSrv("SXS.wsENT_21674.LoadTeacher", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
-
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- AA_21674TEACHER = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("LoadTeacher").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
-
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("LoadTeacher").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("LoadTeacher").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- strFilter = ""
- Select Case GetIssueState()
- Case Issue.Unfrozen
- strFilter = FilterByInteger(strFilter, "IssueState", 0)
- Case Issue.Pending
- strFilter = FilterByInteger(strFilter, "IssueState", 1)
- Case Issue.Active
- strFilter = FilterByInteger(strFilter, "IssueState", 2)
- Case Issue.Unused
- strFilter = FilterByInteger(strFilter, "IssueState", -1)
- End Select
-
- dsENT.Tables(AA_21674TEACHER).DefaultView.RowFilter = strFilter
- dsENT.Tables(AA_21674TEACHER).DefaultView.Sort = "TeacherNo"
-
- Me.iugTeacher.iMESUltraGrid.DataSource = dsENT.Tables(AA_21674TEACHER).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit Sub
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- '//取出AA_21674TeacherCont聯絡人資料
-
- Private Sub funLoadTeacherCont(ByRef TeacherNo As String)
-
- If Not IsNothing(dsENT.Tables(AA_21674TeacherCont)) Then
- dsENT.Tables.Remove(AA_21674TeacherCont)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("teacherno", "TeacherNo", "String", TeacherNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadTeacherCont(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadTeacherCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT_21674.LoadTeacherCont", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- AA_21674TeacherCont = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("LoadTeachercont").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("LoadTeachercont").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("LoadTeachercont").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- Me.iugDetail.iMESUltraGrid.DataSource = dsENT.Tables(AA_21674TeacherCont).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Cont Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- Private Sub funShowActiveDetail()
-
- If Me.iugTeacher.iMESUltraGrid.ActiveRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.DataSource = Nothing
- Else
- Call funLoadTeacherCont(Me.iugTeacher.iMESUltraGrid.ActiveRow.Cells("TeacherNo").Value.ToString)
- End If
-
- End Sub
-
- Private Sub funiMESUltraGridIni()
-
- 'iugTeacher 初始設定
- With Me.iugTeacher.iMESUltraGrid
- .Text = ""
- .DisplayLayout.GroupByBox.Hidden = True
- .DisplayLayout.UseFixedHeaders = False
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugTeacher.UserNo = gUserNo
-
- 'iugDetail 初始設定
- With Me.iugDetail.iMESUltraGrid.DisplayLayout
- .GroupByBox.Hidden = True
- .Override.ExpansionIndicator = ShowExpansionIndicator.Default
- .ViewStyle = ViewStyle.SingleBand
- .RowConnectorStyle = RowConnectorStyle.Default
-
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugDetail.UserNo = gUserNo
-
- End Sub
-
- Private Sub iugTeacher_Load(sender As Object, e As EventArgs) Handles iugTeacher.Load
-
- End Sub
-
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS1/ET_21674/frmSubcontractorContDef.vb b/SRC/MESWin/SYS1/ET_21674/frmSubcontractorContDef.vb
deleted file mode 100644
index c489735..0000000
--- a/SRC/MESWin/SYS1/ET_21674/frmSubcontractorContDef.vb
+++ /dev/null
@@ -1,656 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorContDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
-
- Public SubcontractorNo As String = defString
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblAddress As System.Windows.Forms.Label
- Friend WithEvents lblEMail As System.Windows.Forms.Label
- Friend WithEvents lblTitle As System.Windows.Forms.Label
- Friend WithEvents lblFaxNo As System.Windows.Forms.Label
- Friend WithEvents lblTelNo As System.Windows.Forms.Label
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblContactorName As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorContData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtContactorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtFaxNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTelNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtEMail As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTitle As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtAddress As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorContData = New System.Windows.Forms.GroupBox()
- Me.txtAddress = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtEMail = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTitle = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtFaxNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblAddress = New System.Windows.Forms.Label()
- Me.lblEMail = New System.Windows.Forms.Label()
- Me.lblTitle = New System.Windows.Forms.Label()
- Me.lblFaxNo = New System.Windows.Forms.Label()
- Me.lblTelNo = New System.Windows.Forms.Label()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblContactorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtContactorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTelNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorContData.SuspendLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 322)
- Me.gbxBasisData.Size = New System.Drawing.Size(472, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(396, 401)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(208, 401)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(302, 401)
- '
- 'gbxSubcontractorContData
- '
- Me.gbxSubcontractorContData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTelNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTelNo)
- Me.gbxSubcontractorContData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorContData.Location = New System.Drawing.Point(15, 8)
- Me.gbxSubcontractorContData.Name = "gbxSubcontractorContData"
- Me.gbxSubcontractorContData.Size = New System.Drawing.Size(469, 306)
- Me.gbxSubcontractorContData.TabIndex = 0
- Me.gbxSubcontractorContData.TabStop = False
- Me.gbxSubcontractorContData.Text = "ENT Subcontractor Contactor Data"
- '
- 'txtAddress
- '
- Me.txtAddress.Location = New System.Drawing.Point(120, 152)
- Me.txtAddress.Name = "txtAddress"
- Me.txtAddress.Size = New System.Drawing.Size(336, 22)
- Me.txtAddress.TabIndex = 13
- '
- 'txtEMail
- '
- Me.txtEMail.Location = New System.Drawing.Point(320, 120)
- Me.txtEMail.Name = "txtEMail"
- Me.txtEMail.Size = New System.Drawing.Size(136, 22)
- Me.txtEMail.TabIndex = 11
- '
- 'txtTitle
- '
- Me.txtTitle.Location = New System.Drawing.Point(120, 120)
- Me.txtTitle.Name = "txtTitle"
- Me.txtTitle.Size = New System.Drawing.Size(114, 22)
- Me.txtTitle.TabIndex = 9
- '
- 'txtFaxNo
- '
- Me.txtFaxNo.Location = New System.Drawing.Point(320, 88)
- Me.txtFaxNo.Name = "txtFaxNo"
- Me.txtFaxNo.Size = New System.Drawing.Size(136, 22)
- Me.txtFaxNo.TabIndex = 7
- '
- 'lblAddress
- '
- Me.lblAddress.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblAddress.Location = New System.Drawing.Point(24, 154)
- Me.lblAddress.Name = "lblAddress"
- Me.lblAddress.Size = New System.Drawing.Size(86, 14)
- Me.lblAddress.TabIndex = 12
- Me.lblAddress.Text = "Address"
- Me.lblAddress.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblEMail
- '
- Me.lblEMail.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblEMail.Location = New System.Drawing.Point(248, 123)
- Me.lblEMail.Name = "lblEMail"
- Me.lblEMail.Size = New System.Drawing.Size(64, 14)
- Me.lblEMail.TabIndex = 10
- Me.lblEMail.Text = "EMail"
- Me.lblEMail.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTitle
- '
- Me.lblTitle.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTitle.Location = New System.Drawing.Point(24, 121)
- Me.lblTitle.Name = "lblTitle"
- Me.lblTitle.Size = New System.Drawing.Size(86, 14)
- Me.lblTitle.TabIndex = 8
- Me.lblTitle.Text = "Title"
- Me.lblTitle.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblFaxNo
- '
- Me.lblFaxNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblFaxNo.Location = New System.Drawing.Point(248, 90)
- Me.lblFaxNo.Name = "lblFaxNo"
- Me.lblFaxNo.Size = New System.Drawing.Size(64, 14)
- Me.lblFaxNo.TabIndex = 6
- Me.lblFaxNo.Text = "FaxNo"
- Me.lblFaxNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTelNo
- '
- Me.lblTelNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTelNo.Location = New System.Drawing.Point(24, 90)
- Me.lblTelNo.Name = "lblTelNo"
- Me.lblTelNo.Size = New System.Drawing.Size(86, 14)
- Me.lblTelNo.TabIndex = 4
- Me.lblTelNo.Text = "TelNo"
- Me.lblTelNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(120, 184)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(336, 108)
- Me.txtDescription.TabIndex = 15
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(24, 186)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(86, 14)
- Me.lblDescription.TabIndex = 14
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(14, 29)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 14)
- Me.lblSubcontractorNo.TabIndex = 0
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblContactorName
- '
- Me.lblContactorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblContactorName.Location = New System.Drawing.Point(24, 59)
- Me.lblContactorName.Name = "lblContactorName"
- Me.lblContactorName.Size = New System.Drawing.Size(86, 14)
- Me.lblContactorName.TabIndex = 2
- Me.lblContactorName.Text = "Contactor Name"
- Me.lblContactorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(120, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.ReadOnly = True
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(114, 22)
- Me.txtSubcontractorNo.TabIndex = 1
- Me.txtSubcontractorNo.TabStop = False
- '
- 'txtContactorName
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Appearance = Appearance1
- Me.txtContactorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Location = New System.Drawing.Point(120, 56)
- Me.txtContactorName.Name = "txtContactorName"
- Me.txtContactorName.Size = New System.Drawing.Size(160, 22)
- Me.txtContactorName.TabIndex = 3
- '
- 'txtTelNo
- '
- Me.txtTelNo.Location = New System.Drawing.Point(120, 88)
- Me.txtTelNo.Name = "txtTelNo"
- Me.txtTelNo.Size = New System.Drawing.Size(114, 22)
- Me.txtTelNo.TabIndex = 5
- '
- 'frmSubcontractorContDef
- '
- Me.ClientSize = New System.Drawing.Size(496, 446)
- Me.Controls.Add(Me.gbxSubcontractorContData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorContDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Contactor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorContData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorContData.ResumeLayout(False)
- Me.gbxSubcontractorContData.PerformLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorContDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據()
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
- If DefMode = 0 Or DefMode = 2 Then
- SetCreateDate(Now)
- SetCreator(gUserNo)
- End If
- If Not EditDataRow Is Nothing Then '修改 or Copy
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtContactorName.Text = EditDataRow.Item("ContactorName").ToString
- txtTelNo.Text = EditDataRow.Item("TelNo").ToString
- txtFaxNo.Text = EditDataRow.Item("FaxNo").ToString
- txtTitle.Text = EditDataRow.Item("Title").ToString
- txtAddress.Text = EditDataRow.Item("Address").ToString
- txtEMail.Text = EditDataRow.Item("EMail").ToString
- 'txtDescription是RichTextBox(Control, 因為TextBox無法正常顯示多行換行的資料)
- txtDescription.Text = EditDataRow.Item("Description").ToString
- If DefMode = 1 Then
- If (Not IsDBNull(EditDataRow("Creator"))) Then
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetCreator(EditDataRow.Item("Creator").ToString)
- End If
- End If
- End If
-
- If DefMode = 0 Then 'Add
- txtSubcontractorNo.Text = SubcontractorNo
- SetCreateDate(Now)
- SetCreator(gUserNo)
- ElseIf DefMode = 1 Then 'Edit
- txtContactorName.ReadOnly = True
- SetReviseDate(Now)
- SetReviser(gUserNo)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorContDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
-
- txtEMail.Text = ""
- btnApplyEnabled = False
- Cursor.Current = Cursors.Default
-
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtContactorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Click
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Enter
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtContactorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtContactorName_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Leave
- If txtContactorName.Text <> "" And txtEMail.Text = "" Then
- txtEMail.Text = txtContactorName.Text & "@"
- End If
- txtContactorName.Text = UCase(txtContactorName.Text)
- End Sub
-
- Private Sub txtContactorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTelNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Click
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Enter
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTelNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTelNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtFaxNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Click
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Enter
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtFaxNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtFaxNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTitle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Click
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Enter
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTitle.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTitle_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Click
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Enter
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtEMail.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtEMail_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtAddress_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Click
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Enter
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtAddress.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtAddress_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtDescription.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查()
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
- If txtContactorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%ContactorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtContactorName.Focus()
- Exit Function
- End If
-
- '******************************************************************************
- '2.寫回資料庫()
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("contactorname", "ContactorName", "String", CInput(txtContactorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("telno", "TelNo", "String", txtTelNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("faxno", "FaxNo", "String", txtFaxNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("title", "Title", "String", CInput(txtTitle.Text), "")
- strParameter = strParameter & CombineXMLParameter("address", "Address", "String", CInput(txtAddress.Text), "")
- strParameter = strParameter & CombineXMLParameter("email", "EMail", "String", CInput(txtEMail.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.AddSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.AddSubcontractorCont", InXml)
-
- Else 'Edit
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.EditSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.EditSubcontractorCont", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtContactorName.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Contactor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-#End Region
-
-
- Private Sub frmSubcontractorContDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-End Class
-
diff --git a/SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.resx b/SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb b/SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
deleted file mode 100644
index 4a55ecf..0000000
--- a/SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
+++ /dev/null
@@ -1,526 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/frmSubcontractorDef.vb
- Friend WithEvents lblTelNo As Label
- Friend WithEvents txtTelNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents lblEMail As Label
- Friend WithEvents txtEMail As Infragistics.Win.UltraWinEditors.UltraTextEditor
-========
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorName As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtSubcontractorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance2 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorData = New System.Windows.Forms.GroupBox()
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/frmSubcontractorDef.vb
- Me.txtEMail = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblEMail = New System.Windows.Forms.Label()
- Me.txtTelNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblTelNo = New System.Windows.Forms.Label()
-========
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblSubcontractorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtSubcontractorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorData.SuspendLayout()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/frmSubcontractorDef.vb
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 211)
-========
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 185)
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
- Me.gbxBasisData.Size = New System.Drawing.Size(479, 70)
- '
- 'btnApply
- '
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/frmSubcontractorDef.vb
- Me.btnApply.Location = New System.Drawing.Point(403, 290)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(215, 290)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(309, 290)
-========
- Me.btnApply.Location = New System.Drawing.Point(403, 264)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(215, 264)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(309, 264)
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
- '
- 'gbxSubcontractorData
- '
- Me.gbxSubcontractorData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/frmSubcontractorDef.vb
- Me.gbxSubcontractorData.Controls.Add(Me.txtEMail)
- Me.gbxSubcontractorData.Controls.Add(Me.lblEMail)
- Me.gbxSubcontractorData.Controls.Add(Me.txtTelNo)
- Me.gbxSubcontractorData.Controls.Add(Me.lblTelNo)
-========
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
- Me.gbxSubcontractorData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorName)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorName)
- Me.gbxSubcontractorData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorData.Location = New System.Drawing.Point(12, 8)
- Me.gbxSubcontractorData.Name = "gbxSubcontractorData"
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/frmSubcontractorDef.vb
- Me.gbxSubcontractorData.Size = New System.Drawing.Size(479, 195)
-========
- Me.gbxSubcontractorData.Size = New System.Drawing.Size(479, 169)
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
- Me.gbxSubcontractorData.TabIndex = 7
- Me.gbxSubcontractorData.TabStop = False
- Me.gbxSubcontractorData.Text = "Subcontractor Data"
- '
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/frmSubcontractorDef.vb
- 'txtEMail
- '
- Me.txtEMail.Location = New System.Drawing.Point(326, 83)
- Me.txtEMail.Name = "txtEMail"
- Me.txtEMail.Size = New System.Drawing.Size(136, 22)
- Me.txtEMail.TabIndex = 17
- '
- 'lblEMail
- '
- Me.lblEMail.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblEMail.Location = New System.Drawing.Point(256, 83)
- Me.lblEMail.Name = "lblEMail"
- Me.lblEMail.Size = New System.Drawing.Size(64, 14)
- Me.lblEMail.TabIndex = 16
- Me.lblEMail.Text = "EMail"
- Me.lblEMail.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtTelNo
- '
- Me.txtTelNo.Location = New System.Drawing.Point(128, 83)
- Me.txtTelNo.Name = "txtTelNo"
- Me.txtTelNo.Size = New System.Drawing.Size(114, 22)
- Me.txtTelNo.TabIndex = 15
- '
- 'lblTelNo
- '
- Me.lblTelNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTelNo.Location = New System.Drawing.Point(34, 83)
- Me.lblTelNo.Name = "lblTelNo"
- Me.lblTelNo.Size = New System.Drawing.Size(86, 14)
- Me.lblTelNo.TabIndex = 14
- Me.lblTelNo.Text = "TelNo"
- Me.lblTelNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
-========
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(128, 111)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(334, 67)
- Me.txtDescription.TabIndex = 2
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(58, 114)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(64, 14)
- Me.lblDescription.TabIndex = 13
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(24, 24)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 32)
- Me.lblSubcontractorNo.TabIndex = 5
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorName
- '
- Me.lblSubcontractorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorName.Location = New System.Drawing.Point(8, 56)
- Me.lblSubcontractorName.Name = "lblSubcontractorName"
- Me.lblSubcontractorName.Size = New System.Drawing.Size(112, 32)
- Me.lblSubcontractorName.TabIndex = 9
- Me.lblSubcontractorName.Text = "Subcontractor Name"
- Me.lblSubcontractorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Appearance = Appearance1
- Me.txtSubcontractorNo.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(128, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(152, 22)
- Me.txtSubcontractorNo.TabIndex = 0
- '
- 'txtSubcontractorName
- '
- Appearance2.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Appearance = Appearance2
- Me.txtSubcontractorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Location = New System.Drawing.Point(128, 55)
- Me.txtSubcontractorName.Name = "txtSubcontractorName"
- Me.txtSubcontractorName.Size = New System.Drawing.Size(334, 22)
- Me.txtSubcontractorName.TabIndex = 1
- '
- 'frmSubcontractorDef
- '
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/frmSubcontractorDef.vb
- Me.ClientSize = New System.Drawing.Size(503, 335)
-========
- Me.ClientSize = New System.Drawing.Size(503, 309)
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
- Me.Controls.Add(Me.gbxSubcontractorData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorData.ResumeLayout(False)
- Me.gbxSubcontractorData.PerformLayout()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- If Not EditDataRow Is Nothing Then
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtSubcontractorName.Text = EditDataRow.Item("SubcontractorName").ToString
- 'txtDescription是RichTextBox Control,因為TextBox無法正常顯示多行換行的資料
- txtTelNo.Text = EditDataRow.Item("TelNo").ToString
- txtEMail.Text = EditDataRow.Item("EMail").ToString
- txtDescription.Text = EditDataRow.Item("Description").ToString
- End If
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- SetCreator(gUserNo)
- SetCreateDate(Now)
- ElseIf DefMode = 1 Then 'Edit
- txtSubcontractorNo.ReadOnly = True
- SetCreator(EditDataRow.Item("Creator").ToString)
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetReviser(gUserNo)
- SetReviseDate(Now)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
-
- End If
-
- Cursor.Current = Cursors.Default
- btnApplyEnabled = False
-
- End Sub
-
- Private Sub frmSubcontractorDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Leave
- txtSubcontractorNo.Text = UCase(txtSubcontractorNo.Text)
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtSubcontractorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Click
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Enter
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
-
- If txtSubcontractorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorName.Focus()
- Exit Function
- End If
-
- '2.
- '******************************************************************************
- '寫回資料庫
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("subcontractorname", "SubcontractorName", "String", CInput(txtSubcontractorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("telno", "TelNo", "String", CInput(txtTelNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("email", "EMail", "String", CInput(txtEMail.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter = strParameter & CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("createdate", "CreateDate", "DateTime", Format(Now, "yyyy/MM/dd HH:mm:ss"), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.AddSubcontractor(InXml)
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/frmSubcontractorDef.vb
- OutXml = InvokeSrv("SXS.wsENT.AddSubcontractor", InXml)
-========
- OutXml = InvokeSrv("wsENT.AddSubcontractor", InXml)
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
-
- Else
- '修改
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", EditDataRow.Item("IssueState").ToString, "")
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.EditSubcontractor(InXml)
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/frmSubcontractorDef.vb
- OutXml = InvokeSrv("SXS.wsENT.EditSubcontractor", InXml)
-========
- OutXml = InvokeSrv("wsENT.EditSubcontractor", InXml)
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtSubcontractorNo.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-
-<<<<<<<< HEAD:SRC/MESWin/SYS4/21691/frmSubcontractorDef.vb
- Private Sub lblTelNo_Click(sender As Object, e As EventArgs) Handles lblTelNo.Click
-
- End Sub
-
-========
->>>>>>>> dc359766c3664933829094578fcef17205eebc35:SRC/MESWin/SYS1/ET_21674/frmSubcontractorDef.vb
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS1/ET_21674/frmTeacherContDef.resx b/SRC/MESWin/SYS1/ET_21674/frmTeacherContDef.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS1/ET_21674/frmTeacherContDef.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS1/ET_21674/frmTeacherContDef.vb b/SRC/MESWin/SYS1/ET_21674/frmTeacherContDef.vb
deleted file mode 100644
index 0f7590a..0000000
--- a/SRC/MESWin/SYS1/ET_21674/frmTeacherContDef.vb
+++ /dev/null
@@ -1,656 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmTeacherContDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
-
- Public SubcontractorNo As String = defString
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblAddress As System.Windows.Forms.Label
- Friend WithEvents lblEMail As System.Windows.Forms.Label
- Friend WithEvents lblTitle As System.Windows.Forms.Label
- Friend WithEvents lblFaxNo As System.Windows.Forms.Label
- Friend WithEvents lblTelNo As System.Windows.Forms.Label
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblTeacherContName As System.Windows.Forms.Label
- Friend WithEvents lblTeacherNo As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorContData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtContactorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtFaxNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTelNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtEMail As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTitle As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtAddress As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorContData = New System.Windows.Forms.GroupBox()
- Me.txtAddress = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtEMail = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTitle = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtFaxNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblAddress = New System.Windows.Forms.Label()
- Me.lblEMail = New System.Windows.Forms.Label()
- Me.lblTitle = New System.Windows.Forms.Label()
- Me.lblFaxNo = New System.Windows.Forms.Label()
- Me.lblTelNo = New System.Windows.Forms.Label()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblTeacherNo = New System.Windows.Forms.Label()
- Me.lblTeacherContName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtContactorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTelNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorContData.SuspendLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 322)
- Me.gbxBasisData.Size = New System.Drawing.Size(472, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(396, 401)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(208, 401)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(302, 401)
- '
- 'gbxSubcontractorContData
- '
- Me.gbxSubcontractorContData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTelNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTeacherNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTeacherContName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTelNo)
- Me.gbxSubcontractorContData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorContData.Location = New System.Drawing.Point(15, 8)
- Me.gbxSubcontractorContData.Name = "gbxSubcontractorContData"
- Me.gbxSubcontractorContData.Size = New System.Drawing.Size(469, 306)
- Me.gbxSubcontractorContData.TabIndex = 0
- Me.gbxSubcontractorContData.TabStop = False
- Me.gbxSubcontractorContData.Text = "ENT Subcontractor Contactor Data"
- '
- 'txtAddress
- '
- Me.txtAddress.Location = New System.Drawing.Point(120, 152)
- Me.txtAddress.Name = "txtAddress"
- Me.txtAddress.Size = New System.Drawing.Size(336, 22)
- Me.txtAddress.TabIndex = 13
- '
- 'txtEMail
- '
- Me.txtEMail.Location = New System.Drawing.Point(320, 120)
- Me.txtEMail.Name = "txtEMail"
- Me.txtEMail.Size = New System.Drawing.Size(136, 22)
- Me.txtEMail.TabIndex = 11
- '
- 'txtTitle
- '
- Me.txtTitle.Location = New System.Drawing.Point(120, 120)
- Me.txtTitle.Name = "txtTitle"
- Me.txtTitle.Size = New System.Drawing.Size(114, 22)
- Me.txtTitle.TabIndex = 9
- '
- 'txtFaxNo
- '
- Me.txtFaxNo.Location = New System.Drawing.Point(320, 88)
- Me.txtFaxNo.Name = "txtFaxNo"
- Me.txtFaxNo.Size = New System.Drawing.Size(136, 22)
- Me.txtFaxNo.TabIndex = 7
- '
- 'lblAddress
- '
- Me.lblAddress.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblAddress.Location = New System.Drawing.Point(24, 154)
- Me.lblAddress.Name = "lblAddress"
- Me.lblAddress.Size = New System.Drawing.Size(86, 14)
- Me.lblAddress.TabIndex = 12
- Me.lblAddress.Text = "Address"
- Me.lblAddress.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblEMail
- '
- Me.lblEMail.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblEMail.Location = New System.Drawing.Point(248, 123)
- Me.lblEMail.Name = "lblEMail"
- Me.lblEMail.Size = New System.Drawing.Size(64, 14)
- Me.lblEMail.TabIndex = 10
- Me.lblEMail.Text = "EMail"
- Me.lblEMail.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTitle
- '
- Me.lblTitle.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTitle.Location = New System.Drawing.Point(24, 121)
- Me.lblTitle.Name = "lblTitle"
- Me.lblTitle.Size = New System.Drawing.Size(86, 14)
- Me.lblTitle.TabIndex = 8
- Me.lblTitle.Text = "Title"
- Me.lblTitle.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblFaxNo
- '
- Me.lblFaxNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblFaxNo.Location = New System.Drawing.Point(248, 90)
- Me.lblFaxNo.Name = "lblFaxNo"
- Me.lblFaxNo.Size = New System.Drawing.Size(64, 14)
- Me.lblFaxNo.TabIndex = 6
- Me.lblFaxNo.Text = "FaxNo"
- Me.lblFaxNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTelNo
- '
- Me.lblTelNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTelNo.Location = New System.Drawing.Point(24, 90)
- Me.lblTelNo.Name = "lblTelNo"
- Me.lblTelNo.Size = New System.Drawing.Size(86, 14)
- Me.lblTelNo.TabIndex = 4
- Me.lblTelNo.Text = "TelNo"
- Me.lblTelNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(120, 184)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(336, 108)
- Me.txtDescription.TabIndex = 15
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(24, 186)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(86, 14)
- Me.lblDescription.TabIndex = 14
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTeacherNo
- '
- Me.lblTeacherNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTeacherNo.Location = New System.Drawing.Point(14, 29)
- Me.lblTeacherNo.Name = "lblTeacherNo"
- Me.lblTeacherNo.Size = New System.Drawing.Size(96, 14)
- Me.lblTeacherNo.TabIndex = 0
- Me.lblTeacherNo.Text = "Teacher No"
- Me.lblTeacherNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTeacherContName
- '
- Me.lblTeacherContName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTeacherContName.Location = New System.Drawing.Point(24, 59)
- Me.lblTeacherContName.Name = "lblTeacherContName"
- Me.lblTeacherContName.Size = New System.Drawing.Size(86, 14)
- Me.lblTeacherContName.TabIndex = 2
- Me.lblTeacherContName.Text = "TeacherCont Name"
- Me.lblTeacherContName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(120, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.ReadOnly = True
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(114, 22)
- Me.txtSubcontractorNo.TabIndex = 1
- Me.txtSubcontractorNo.TabStop = False
- '
- 'txtContactorName
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Appearance = Appearance1
- Me.txtContactorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Location = New System.Drawing.Point(120, 56)
- Me.txtContactorName.Name = "txtContactorName"
- Me.txtContactorName.Size = New System.Drawing.Size(160, 22)
- Me.txtContactorName.TabIndex = 3
- '
- 'txtTelNo
- '
- Me.txtTelNo.Location = New System.Drawing.Point(120, 88)
- Me.txtTelNo.Name = "txtTelNo"
- Me.txtTelNo.Size = New System.Drawing.Size(114, 22)
- Me.txtTelNo.TabIndex = 5
- '
- 'frmTeacherContDef
- '
- Me.ClientSize = New System.Drawing.Size(496, 446)
- Me.Controls.Add(Me.gbxSubcontractorContData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmTeacherContDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Contactor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorContData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorContData.ResumeLayout(False)
- Me.gbxSubcontractorContData.PerformLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorContDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據()
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
- If DefMode = 0 Or DefMode = 2 Then
- SetCreateDate(Now)
- SetCreator(gUserNo)
- End If
- If Not EditDataRow Is Nothing Then '修改 or Copy
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtContactorName.Text = EditDataRow.Item("ContactorName").ToString
- txtTelNo.Text = EditDataRow.Item("TelNo").ToString
- txtFaxNo.Text = EditDataRow.Item("FaxNo").ToString
- txtTitle.Text = EditDataRow.Item("Title").ToString
- txtAddress.Text = EditDataRow.Item("Address").ToString
- txtEMail.Text = EditDataRow.Item("EMail").ToString
- 'txtDescription是RichTextBox(Control, 因為TextBox無法正常顯示多行換行的資料)
- txtDescription.Text = EditDataRow.Item("Description").ToString
- If DefMode = 1 Then
- If (Not IsDBNull(EditDataRow("Creator"))) Then
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetCreator(EditDataRow.Item("Creator").ToString)
- End If
- End If
- End If
-
- If DefMode = 0 Then 'Add
- txtSubcontractorNo.Text = SubcontractorNo
- SetCreateDate(Now)
- SetCreator(gUserNo)
- ElseIf DefMode = 1 Then 'Edit
- txtContactorName.ReadOnly = True
- SetReviseDate(Now)
- SetReviser(gUserNo)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorContDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
-
- txtEMail.Text = ""
- btnApplyEnabled = False
- Cursor.Current = Cursors.Default
-
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtContactorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Click
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Enter
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtContactorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtContactorName_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Leave
- If txtContactorName.Text <> "" And txtEMail.Text = "" Then
- txtEMail.Text = txtContactorName.Text & "@"
- End If
- txtContactorName.Text = UCase(txtContactorName.Text)
- End Sub
-
- Private Sub txtContactorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTelNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Click
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Enter
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTelNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTelNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtFaxNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Click
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Enter
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtFaxNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtFaxNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTitle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Click
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Enter
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTitle.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTitle_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Click
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Enter
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtEMail.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtEMail_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtAddress_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Click
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Enter
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtAddress.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtAddress_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtDescription.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查()
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
- If txtContactorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%ContactorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtContactorName.Focus()
- Exit Function
- End If
-
- '******************************************************************************
- '2.寫回資料庫()
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("contactorname", "ContactorName", "String", CInput(txtContactorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("telno", "TelNo", "String", txtTelNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("faxno", "FaxNo", "String", txtFaxNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("title", "Title", "String", CInput(txtTitle.Text), "")
- strParameter = strParameter & CombineXMLParameter("address", "Address", "String", CInput(txtAddress.Text), "")
- strParameter = strParameter & CombineXMLParameter("email", "EMail", "String", CInput(txtEMail.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.AddSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.AddSubcontractorCont", InXml)
-
- Else 'Edit
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.EditSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.EditSubcontractorCont", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtContactorName.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Contactor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-#End Region
-
-
- Private Sub frmSubcontractorContDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-End Class
-
diff --git a/SRC/MESWin/SYS1/ET_21674/frmTeacherDef.vb b/SRC/MESWin/SYS1/ET_21674/frmTeacherDef.vb
deleted file mode 100644
index 114d58d..0000000
--- a/SRC/MESWin/SYS1/ET_21674/frmTeacherDef.vb
+++ /dev/null
@@ -1,433 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmTeacherDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblTeacherNo As System.Windows.Forms.Label
- Friend WithEvents lblTeacherName As System.Windows.Forms.Label
- Friend WithEvents gbxTeacherData As System.Windows.Forms.GroupBox
- Friend WithEvents txtTeacherNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTeacherName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance2 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxTeacherData = New System.Windows.Forms.GroupBox()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblTeacherNo = New System.Windows.Forms.Label()
- Me.lblTeacherName = New System.Windows.Forms.Label()
- Me.txtTeacherNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTeacherName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxTeacherData.SuspendLayout()
- CType(Me.txtTeacherNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTeacherName, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 185)
- Me.gbxBasisData.Size = New System.Drawing.Size(479, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(403, 264)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(215, 264)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(309, 264)
- '
- 'gbxTeacherData
- '
- Me.gbxTeacherData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxTeacherData.Controls.Add(Me.txtDescription)
- Me.gbxTeacherData.Controls.Add(Me.lblDescription)
- Me.gbxTeacherData.Controls.Add(Me.lblTeacherNo)
- Me.gbxTeacherData.Controls.Add(Me.lblTeacherName)
- Me.gbxTeacherData.Controls.Add(Me.txtTeacherNo)
- Me.gbxTeacherData.Controls.Add(Me.txtTeacherName)
- Me.gbxTeacherData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxTeacherData.Location = New System.Drawing.Point(12, 8)
- Me.gbxTeacherData.Name = "gbxTeacherData"
- Me.gbxTeacherData.Size = New System.Drawing.Size(479, 169)
- Me.gbxTeacherData.TabIndex = 7
- Me.gbxTeacherData.TabStop = False
- Me.gbxTeacherData.Text = "Teacher Data"
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(128, 86)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(334, 67)
- Me.txtDescription.TabIndex = 2
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(56, 88)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(64, 14)
- Me.lblDescription.TabIndex = 13
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTeacherNo
- '
- Me.lblTeacherNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTeacherNo.Location = New System.Drawing.Point(24, 24)
- Me.lblTeacherNo.Name = "lblTeacherNo"
- Me.lblTeacherNo.Size = New System.Drawing.Size(96, 32)
- Me.lblTeacherNo.TabIndex = 5
- Me.lblTeacherNo.Text = "Teacher No"
- Me.lblTeacherNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTeacherName
- '
- Me.lblTeacherName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTeacherName.Location = New System.Drawing.Point(8, 56)
- Me.lblTeacherName.Name = "lblTeacherName"
- Me.lblTeacherName.Size = New System.Drawing.Size(112, 32)
- Me.lblTeacherName.TabIndex = 9
- Me.lblTeacherName.Text = "Teacher Name"
- Me.lblTeacherName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtTeacherNo
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtTeacherNo.Appearance = Appearance1
- Me.txtTeacherNo.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtTeacherNo.Location = New System.Drawing.Point(128, 24)
- Me.txtTeacherNo.Name = "txtTeacherNo"
- Me.txtTeacherNo.Size = New System.Drawing.Size(152, 22)
- Me.txtTeacherNo.TabIndex = 0
- '
- 'txtTeacherName
- '
- Appearance2.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtTeacherName.Appearance = Appearance2
- Me.txtTeacherName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtTeacherName.Location = New System.Drawing.Point(128, 55)
- Me.txtTeacherName.Name = "txtTeacherName"
- Me.txtTeacherName.Size = New System.Drawing.Size(334, 22)
- Me.txtTeacherName.TabIndex = 1
- '
- 'frmTeacherDef
- '
- Me.ClientSize = New System.Drawing.Size(503, 309)
- Me.Controls.Add(Me.gbxTeacherData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmTeacherDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Teacher Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxTeacherData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxTeacherData.ResumeLayout(False)
- Me.gbxTeacherData.PerformLayout()
- CType(Me.txtTeacherNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTeacherName, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- If Not EditDataRow Is Nothing Then
- txtTeacherNo.Text = EditDataRow.Item("TeacherNo").ToString
- txtTeacherName.Text = EditDataRow.Item("TeacherName").ToString
- 'txtDescription是RichTextBox Control,因為TextBox無法正常顯示多行換行的資料
- txtDescription.Text = EditDataRow.Item("Description").ToString
- End If
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- SetCreator(gUserNo)
- SetCreateDate(Now)
- ElseIf DefMode = 1 Then 'Edit
- txtTeacherNo.ReadOnly = True
- SetCreator(EditDataRow.Item("Creator").ToString)
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetReviser(gUserNo)
- SetReviseDate(Now)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtTeacherNo.Focus()
- Else
- txtTeacherName.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtTeacherNo.Focus()
- Else
- txtTeacherName.Focus()
-
- End If
-
- Cursor.Current = Cursors.Default
- btnApplyEnabled = False
-
- End Sub
-
- Private Sub frmSubcontractorDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTeacherNo.Click
- txtTeacherNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTeacherNo.Enter
- txtTeacherNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTeacherNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTeacherNo.Leave
- txtTeacherNo.Text = UCase(txtTeacherNo.Text)
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTeacherNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtSubcontractorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTeacherName.Click
- txtTeacherName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTeacherName.Enter
- txtTeacherName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTeacherName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTeacherName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查
- '******************************************************************************
- If txtTeacherNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%TeacherNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtTeacherNo.Focus()
- Exit Function
- End If
-
- If txtTeacherName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%TeacherName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtTeacherName.Focus()
- Exit Function
- End If
-
- '2.
- '******************************************************************************
- '寫回資料庫
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("teacherno", "TeacherNo", "String", CInput(txtTeacherNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("teachername", "TeacherName", "String", CInput(txtTeacherName.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter = strParameter & CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("createdate", "CreateDate", "DateTime", Format(Now, "yyyy/MM/dd HH:mm:ss"), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.AddSubcontractor(InXml)
- OutXml = InvokeSrv("SXS.wsENT_21674.AddTeacher", InXml)
-
- Else
- '修改
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", EditDataRow.Item("IssueState").ToString, "")
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.EditSubcontractor(InXml)
- OutXml = InvokeSrv("SXS.wsENT_21674.EditTeacher", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtTeacherNo.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-
- Private Sub lblSubcontractorNo_Click(sender As Object, e As EventArgs) Handles lblTeacherNo.Click
-
- End Sub
-
- Private Sub btnConfirm_Click_1(sender As Object, e As EventArgs) Handles btnConfirm.Click
-
- End Sub
-
- Private Sub lblSubcontractorName_Click(sender As Object, e As EventArgs) Handles lblTeacherName.Click
-
- End Sub
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/ET_Subcontractor_21710.sln b/SRC/MESWin/SYS2/ET_Subcontractor/ET_Subcontractor_21710.sln
deleted file mode 100644
index f53561a..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/ET_Subcontractor_21710.sln
+++ /dev/null
@@ -1,31 +0,0 @@
-
-Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio Version 16
-VisualStudioVersion = 16.0.34407.143
-MinimumVisualStudioVersion = 10.0.40219.1
-Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "ET_Subcontractor_21710", "ET_Subcontractor_21710.vbproj", "{D6EE7B96-F10E-44E2-9731-162B70B4C8DD}"
-EndProject
-Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Test", "..\..\Test\Test.vbproj", "{C4A48E3F-38E4-4E88-A47D-FA5510686E57}"
-EndProject
-Global
- GlobalSection(SolutionConfigurationPlatforms) = preSolution
- Debug|x86 = Debug|x86
- Release|x86 = Release|x86
- EndGlobalSection
- GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.ActiveCfg = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.Build.0 = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.ActiveCfg = Release|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.Build.0 = Release|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.ActiveCfg = Debug|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.Build.0 = Debug|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Release|x86.ActiveCfg = Release|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Release|x86.Build.0 = Release|x86
- EndGlobalSection
- GlobalSection(SolutionProperties) = preSolution
- HideSolutionNode = FALSE
- EndGlobalSection
- GlobalSection(ExtensibilityGlobals) = postSolution
- SolutionGuid = {6D3C286F-62F4-4F6B-BEAD-599D39767969}
- EndGlobalSection
-EndGlobal
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/ET_Subcontractor_21710.vbproj b/SRC/MESWin/SYS2/ET_Subcontractor/ET_Subcontractor_21710.vbproj
deleted file mode 100644
index 9032857..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/ET_Subcontractor_21710.vbproj
+++ /dev/null
@@ -1,194 +0,0 @@
-
-
-
-
- Debug
- x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}
- Library
- ET_Subcontractor_21710
- ET_Subcontractor_21710
- 512
- Windows
- v4.6.2
-
- SAK
- SAK
- SAK
- SAK
-
-
- On
-
-
- Binary
-
-
- Off
-
-
- On
-
-
- true
- true
- true
- ..\..\..\MESClient\
- ET_Subcontractor_21710.xml
- 0
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- full
- x86
- MinimumRecommendedRules.ruleset
- false
-
-
- true
- ..\..\..\MESClient\
- ET_Subcontractor_21710.xml
- true
- 0
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- pdbonly
- x86
- MinimumRecommendedRules.ruleset
- false
-
-
- true
-
-
- iMES.snk
-
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinGrid.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinEditors.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.Misc.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Shared.v19.1.dll
- False
-
-
- ..\..\..\MESClient\COM_Kit.dll
- False
-
-
- ..\..\..\MES_C_DLL\iMESExceptionManager.dll
- False
-
-
- ..\..\..\MES_C_DLL\iMESUltraGrid.dll
- False
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- modConstant.vb
-
-
- Form
-
-
- Form
-
-
- Form
-
-
-
- True
- Application.myapp
- True
-
-
- True
- True
- Resources.resx
-
-
- True
- Settings.settings
- True
-
-
-
-
- frmTest.vb
-
-
- frmTestContDef.vb
-
-
- frmTestDef.vb
-
-
-
- VbMyResourcesResXFileCodeGenerator
- Resources.Designer.vb
- My.Resources
- Designer
-
-
-
-
-
- MyApplicationCodeGenerator
- Application.Designer.vb
-
-
- SettingsSingleFileGenerator
- My
- Settings.Designer.vb
-
-
-
-
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/ET_Subcontractor_21710_02.sln b/SRC/MESWin/SYS2/ET_Subcontractor/ET_Subcontractor_21710_02.sln
deleted file mode 100644
index 85b1902..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/ET_Subcontractor_21710_02.sln
+++ /dev/null
@@ -1,39 +0,0 @@
-
-Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio 14
-VisualStudioVersion = 14.0.25123.0
-MinimumVisualStudioVersion = 10.0.40219.1
-Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "ET_Subcontractor", "ET_Subcontractor.vbproj", "{D6EE7B96-F10E-44E2-9731-162B70B4C8DD}"
-EndProject
-Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Test", "..\..\Test\Test.vbproj", "{C4A48E3F-38E4-4E88-A47D-FA5510686E57}"
-EndProject
-Global
- GlobalSection(SolutionConfigurationPlatforms) = preSolution
- Debug|x86 = Debug|x86
- Release|x86 = Release|x86
- EndGlobalSection
- GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.ActiveCfg = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.Build.0 = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.ActiveCfg = Release|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.Build.0 = Release|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.ActiveCfg = Debug|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.Build.0 = Debug|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Release|x86.ActiveCfg = Release|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Release|x86.Build.0 = Release|x86
- EndGlobalSection
- GlobalSection(SolutionProperties) = preSolution
- HideSolutionNode = FALSE
- EndGlobalSection
- GlobalSection(TeamFoundationVersionControl) = preSolution
- SccNumberOfProjects = 3
- SccEnterpriseProvider = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C}
- SccTeamFoundationServer = http://tfs.imestech.com:8080/tfs/messeries6
- SccProjectUniqueName0 = ET_Subcontractor.vbproj
- SccLocalPath0 = .
- SccProjectUniqueName1 = ..\\..\\Test\\Test.vbproj
- SccProjectName1 = ../../Test
- SccLocalPath1 = ..\\..\\Test
- SccLocalPath2 = .
- EndGlobalSection
-EndGlobal
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Application.Designer.vb b/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Application.Designer.vb
deleted file mode 100644
index 537244b..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Application.Designer.vb
+++ /dev/null
@@ -1,13 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Application.myapp b/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Application.myapp
deleted file mode 100644
index 758895d..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Application.myapp
+++ /dev/null
@@ -1,10 +0,0 @@
-
-
- false
- false
- 0
- true
- 0
- 1
- true
-
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/BuildIncrementVersionInfo.vb b/SRC/MESWin/SYS2/ET_Subcontractor/My Project/BuildIncrementVersionInfo.vb
deleted file mode 100644
index d2f2e21..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/BuildIncrementVersionInfo.vb
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Resources.Designer.vb b/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Resources.Designer.vb
deleted file mode 100644
index c0877f0..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Resources.Designer.vb
+++ /dev/null
@@ -1,63 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-Imports System
-
-Namespace My.Resources
-
- '此类是由 StronglyTypedResourceBuilder
- '类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
- '若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen
- '(以 /str 作为命令选项),或重新生成 VS 项目。
- '''
- ''' 一个强类型的资源类,用于查找本地化的字符串等。
- '''
- _
- Friend Module Resources
-
- Private resourceMan As Global.System.Resources.ResourceManager
-
- Private resourceCulture As Global.System.Globalization.CultureInfo
-
- '''
- ''' 返回此类使用的缓存的 ResourceManager 实例。
- '''
- _
- Friend ReadOnly Property ResourceManager() As Global.System.Resources.ResourceManager
- Get
- If Object.ReferenceEquals(resourceMan, Nothing) Then
- Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("ET_Subcontractor_21710.Resources", GetType(Resources).Assembly)
- resourceMan = temp
- End If
- Return resourceMan
- End Get
- End Property
-
- '''
- ''' 重写当前线程的 CurrentUICulture 属性,对
- ''' 使用此强类型资源类的所有资源查找执行重写。
- '''
- _
- Friend Property Culture() As Global.System.Globalization.CultureInfo
- Get
- Return resourceCulture
- End Get
- Set
- resourceCulture = value
- End Set
- End Property
- End Module
-End Namespace
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Settings.Designer.vb b/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Settings.Designer.vb
deleted file mode 100644
index 548a053..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Settings.Designer.vb
+++ /dev/null
@@ -1,73 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-
-Namespace My
-
- _
- Partial Friend NotInheritable Class MySettings
- Inherits Global.System.Configuration.ApplicationSettingsBase
-
- Private Shared defaultInstance As MySettings = CType(Global.System.Configuration.ApplicationSettingsBase.Synchronized(New MySettings()),MySettings)
-
-#Region "My.Settings 自动保存功能"
-#If _MyType = "WindowsForms" Then
- Private Shared addedHandler As Boolean
-
- Private Shared addedHandlerLockObject As New Object
-
- _
- Private Shared Sub AutoSaveSettings(sender As Global.System.Object, e As Global.System.EventArgs)
- If My.Application.SaveMySettingsOnExit Then
- My.Settings.Save()
- End If
- End Sub
-#End If
-#End Region
-
- Public Shared ReadOnly Property [Default]() As MySettings
- Get
-
-#If _MyType = "WindowsForms" Then
- If Not addedHandler Then
- SyncLock addedHandlerLockObject
- If Not addedHandler Then
- AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings
- addedHandler = True
- End If
- End SyncLock
- End If
-#End If
- Return defaultInstance
- End Get
- End Property
- End Class
-End Namespace
-
-Namespace My
-
- _
- Friend Module MySettingsProperty
-
- _
- Friend ReadOnly Property Settings() As Global.ET_Subcontractor_21710.My.MySettings
- Get
- Return Global.ET_Subcontractor_21710.My.MySettings.Default
- End Get
- End Property
- End Module
-End Namespace
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Settings.settings b/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Settings.settings
deleted file mode 100644
index 85b890b..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/Settings.settings
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
-
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/licenses.licx b/SRC/MESWin/SYS2/ET_Subcontractor/My Project/licenses.licx
deleted file mode 100644
index e3f40e2..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/My Project/licenses.licx
+++ /dev/null
@@ -1,7 +0,0 @@
-Infragistics.Win.Misc.UltraButton, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraRadioButton, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraComboEditor, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraGroupBox, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraTextEditor, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraLabel, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraPanel, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/frmTest.vb b/SRC/MESWin/SYS2/ET_Subcontractor/frmTest.vb
deleted file mode 100644
index ff08a12..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/frmTest.vb
+++ /dev/null
@@ -1,1129 +0,0 @@
-Imports iMESExceptionManager
-
-Imports Infragistics.Win
-Imports Infragistics.Win.UltraWinGrid
-Public Class frmTest
-
- Inherits COM_Kit.frmBasisTemplat
-
- Public PrivFunNo As String = defString
-
- '//WS相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT '宣告Web Service物件?
- Dim tmpStringReader As System.IO.StringReader '將字串轉換成可讀入DataSet的物件
- Dim XmlData As String '儲存取回之資料
- Dim XmlSchema As String '儲存取回之資料結構
- Dim InXml As String '儲存呼叫Web Service的傳入參數(Request字串)
- Dim OutXml As String '儲存Web Service的傳回值(Response字串)
- Dim strIdentity As String '儲存Identity XML字串?
- Dim strParameter As String '儲存Parameter XML字串
-
- '//資料表相關變數
-
- Dim dsENT As New DataSet '資料集:儲存取回之資料?
-
- Dim tblENTSubcontractor As String '儲存取回資料表的名稱(master)?
- Dim tblENTSubcontractorCont As String '明細資料表名稱(detail)
- Dim strFilter As String 'Filter string及列印的過濾條件
-
- '//其他共用變數
- Dim SubcontractorNo As String 'for Gird to Focus
- Dim ContactorName As String 'for DetailGrid to Focus
- Dim ugrRow As Infragistics.Win.UltraWinGrid.UltraGridRow
- Friend WithEvents btnAdd As Misc.UltraButton
- Friend WithEvents btnEdit As Misc.UltraButton
- Friend WithEvents btnDel As Misc.UltraButton
- Friend WithEvents btnCopy As Misc.UltraButton
- Friend WithEvents btnApprove As Misc.UltraButton
- Friend WithEvents iugSubcontractor As iMESUltraGrid.iMESUltraGridControl
- Dim i As Integer
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.Container
- Friend WithEvents iugDetail As iMESUltraGrid.iMESUltraGridControl
- Friend WithEvents btnClose As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnEMail As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDCopy As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDDel As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDEdit As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDAdd As Infragistics.Win.Misc.UltraButton
- Private Sub InitializeComponent()
- Me.btnClose = New Infragistics.Win.Misc.UltraButton()
- Me.btnEMail = New Infragistics.Win.Misc.UltraButton()
- Me.btnDCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnDDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnDEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDAdd = New Infragistics.Win.Misc.UltraButton()
- Me.iugDetail = New iMESUltraGrid.iMESUltraGridControl()
- Me.btnAdd = New Infragistics.Win.Misc.UltraButton()
- Me.btnEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnApprove = New Infragistics.Win.Misc.UltraButton()
- Me.iugSubcontractor = New iMESUltraGrid.iMESUltraGridControl()
- Me.SuspendLayout()
- '
- 'btnClose
- '
- Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnClose.Location = New System.Drawing.Point(912, 552)
- Me.btnClose.Name = "btnClose"
- Me.btnClose.Size = New System.Drawing.Size(88, 32)
- Me.btnClose.TabIndex = 18
- Me.btnClose.Text = "Close (&X)"
- '
- 'btnEMail
- '
- Me.btnEMail.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEMail.Location = New System.Drawing.Point(912, 429)
- Me.btnEMail.Name = "btnEMail"
- Me.btnEMail.Size = New System.Drawing.Size(88, 32)
- Me.btnEMail.TabIndex = 17
- Me.btnEMail.Text = "Mail"
- '
- 'btnDCopy
- '
- Me.btnDCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDCopy.Location = New System.Drawing.Point(912, 389)
- Me.btnDCopy.Name = "btnDCopy"
- Me.btnDCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnDCopy.TabIndex = 16
- Me.btnDCopy.Text = "Copy"
- '
- 'btnDDel
- '
- Me.btnDDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDDel.Location = New System.Drawing.Point(912, 349)
- Me.btnDDel.Name = "btnDDel"
- Me.btnDDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDDel.TabIndex = 15
- Me.btnDDel.Text = "DEL"
- '
- 'btnDEdit
- '
- Me.btnDEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDEdit.Location = New System.Drawing.Point(912, 309)
- Me.btnDEdit.Name = "btnDEdit"
- Me.btnDEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnDEdit.TabIndex = 14
- Me.btnDEdit.Text = "EDIT"
- '
- 'btnDAdd
- '
- Me.btnDAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDAdd.Location = New System.Drawing.Point(912, 269)
- Me.btnDAdd.Name = "btnDAdd"
- Me.btnDAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnDAdd.TabIndex = 13
- Me.btnDAdd.Text = "ADD"
- '
- 'iugDetail
- '
- Me.iugDetail.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugDetail.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugDetail.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugDetail.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugDetail.Identity = "IMes"
- Me.iugDetail.IdentityForm = ""
- Me.iugDetail.LayOutFilePath = ""
- Me.iugDetail.Location = New System.Drawing.Point(12, 270)
- Me.iugDetail.Name = "iugDetail"
- Me.iugDetail.PrintFitWidthToPages = 0
- Me.iugDetail.PrintLandscape = True
- Me.iugDetail.PrintPageFooter = ""
- Me.iugDetail.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageFooterHeight = 20
- Me.iugDetail.PrintPageHeader = ""
- Me.iugDetail.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageHeaderHeight = 20
- Me.iugDetail.PrintZoom = 1.0R
- Me.iugDetail.Size = New System.Drawing.Size(894, 314)
- Me.iugDetail.TabIndex = 12
- Me.iugDetail.UserNo = "IMes"
- '
- 'btnAdd
- '
- Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnAdd.Location = New System.Drawing.Point(912, 53)
- Me.btnAdd.Name = "btnAdd"
- Me.btnAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnAdd.TabIndex = 20
- Me.btnAdd.Text = "Add(&A)"
- '
- 'btnEdit
- '
- Me.btnEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEdit.Location = New System.Drawing.Point(912, 93)
- Me.btnEdit.Name = "btnEdit"
- Me.btnEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnEdit.TabIndex = 21
- Me.btnEdit.Text = "Edit(&E)"
- '
- 'btnDel
- '
- Me.btnDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDel.Location = New System.Drawing.Point(912, 133)
- Me.btnDel.Name = "btnDel"
- Me.btnDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDel.TabIndex = 22
- Me.btnDel.Text = "Del(&D)"
- '
- 'btnCopy
- '
- Me.btnCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnCopy.Location = New System.Drawing.Point(912, 173)
- Me.btnCopy.Name = "btnCopy"
- Me.btnCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnCopy.TabIndex = 23
- Me.btnCopy.Text = "Copy(&C)"
- '
- 'btnApprove
- '
- Me.btnApprove.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnApprove.Location = New System.Drawing.Point(912, 213)
- Me.btnApprove.Name = "btnApprove"
- Me.btnApprove.Size = New System.Drawing.Size(88, 32)
- Me.btnApprove.TabIndex = 24
- Me.btnApprove.Text = "Approve(&Y)"
- '
- 'iugSubcontractor
- '
- Me.iugSubcontractor.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugSubcontractor.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugSubcontractor.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugSubcontractor.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugSubcontractor.Identity = "IMes"
- Me.iugSubcontractor.IdentityForm = ""
- Me.iugSubcontractor.LayOutFilePath = ""
- Me.iugSubcontractor.Location = New System.Drawing.Point(12, 53)
- Me.iugSubcontractor.Name = "iugSubcontractor"
- Me.iugSubcontractor.PrintFitWidthToPages = 0
- Me.iugSubcontractor.PrintLandscape = True
- Me.iugSubcontractor.PrintPageFooter = ""
- Me.iugSubcontractor.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageFooterHeight = 20
- Me.iugSubcontractor.PrintPageHeader = ""
- Me.iugSubcontractor.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageHeaderHeight = 20
- Me.iugSubcontractor.PrintZoom = 1.0R
- Me.iugSubcontractor.Size = New System.Drawing.Size(894, 192)
- Me.iugSubcontractor.TabIndex = 25
- Me.iugSubcontractor.UserNo = "IMes"
- '
- 'frmSubcontractor
- '
- Me.ClientSize = New System.Drawing.Size(1008, 591)
- Me.Controls.Add(Me.btnClose)
- Me.Controls.Add(Me.btnApprove)
- Me.Controls.Add(Me.btnEMail)
- Me.Controls.Add(Me.btnDCopy)
- Me.Controls.Add(Me.btnCopy)
- Me.Controls.Add(Me.btnDDel)
- Me.Controls.Add(Me.iugSubcontractor)
- Me.Controls.Add(Me.btnDEdit)
- Me.Controls.Add(Me.btnAdd)
- Me.Controls.Add(Me.btnDAdd)
- Me.Controls.Add(Me.btnDel)
- Me.Controls.Add(Me.iugDetail)
- Me.Controls.Add(Me.btnEdit)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractor"
- Me.Text = "ENT Subcontractor & Contactor"
- Me.WindowState = System.Windows.Forms.FormWindowState.Maximized
- Me.Controls.SetChildIndex(Me.btnEdit, 0)
- Me.Controls.SetChildIndex(Me.iugDetail, 0)
- Me.Controls.SetChildIndex(Me.btnDel, 0)
- Me.Controls.SetChildIndex(Me.btnDAdd, 0)
- Me.Controls.SetChildIndex(Me.btnAdd, 0)
- Me.Controls.SetChildIndex(Me.btnDEdit, 0)
- Me.Controls.SetChildIndex(Me.iugSubcontractor, 0)
- Me.Controls.SetChildIndex(Me.btnDDel, 0)
- Me.Controls.SetChildIndex(Me.btnCopy, 0)
- Me.Controls.SetChildIndex(Me.btnDCopy, 0)
- Me.Controls.SetChildIndex(Me.btnEMail, 0)
- Me.Controls.SetChildIndex(Me.btnApprove, 0)
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractor_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- Call funiMESUltraGridIni() 'Grid初始設定
-
- '//取出資料
- Call funLoadSubcontractor()
-
- SetIssueState(Issue.Unfrozen) '預設在Unforzen上
- SetSearchFieldName(New String() {"SubcontractorNo", "SubcontractorNaME"}) '設置搜尋欄位
-
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractor_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- If Not dsENT Is Nothing Then dsENT.Dispose()
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
- Protected Overrides Sub rdoIssue_CheckedChanged(sender As Object, e As EventArgs)
- If IsNothing(dsENT) Then Exit Sub
-
- Select Case GetIssueState()
- Case Issue.Unfrozen
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=0"
- Case Issue.Pending
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=1"
- Case Issue.Active
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=2"
- Case Issue.Unused
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=-1"
- End Select
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
- Call funShowActiveDetail()
- End Sub
-
- Protected Overrides Sub Finalize()
- MyBase.Finalize()
- End Sub
-
- Private Sub btnAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAdd.Click
-
- Dim fSubcontractorDef As New frmTestDef
-
- fSubcontractorDef.DefMode = 0
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End Sub
-
- Private Sub btnEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEdit.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'")
-
- '核准狀態為"Unfrozen"者才可修改
-
- If Rows(0).Item("IssueState") <> 0 Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-202202", "[%NOT ALLOWED TO EDIT%]"), MsgBoxStyle.Exclamation, Me.Text)
- Exit Sub
- End If
-
- Dim fSubcontractorDef As New frmTestDef
- fSubcontractorDef.DefMode = 1
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDel.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Or intIssueState = -1 Or intIssueState = 2 Then '狀態為Unforzen或Unused時直接刪除
-
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", CInput(intIssueState), "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOWED TO delete%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCopy.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorDef As New frmTestDef
- fSubcontractorDef.DefMode = 2
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnApprove_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnApprove.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100002", "[%ARE YOU SURE TO APPROVE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Then
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo").Value.ToString), "")
- strParameter += CombineXMLParameter("issuestate", "IssueState", "String", intIssueState, "")
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.ApproveSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.ApproveSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.ApproveSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Approve failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOW TO APPROVE%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDAdd.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
-
- 'Dim Rows As DataRow()
- Dim fSubcontractorContDef As New frmTestContDef
-
- fSubcontractorContDef.DefMode = 0
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- End If
- End Sub
-
- Private Sub btnDEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDEdit.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmTestContDef
- fSubcontractorContDef.DefMode = 1
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnDDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDDel.Click
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
-
- Cursor.Current = Cursors.WaitCursor
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugDetail.iMESUltraGrid.Selected.Rows.Count - 1
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("ContactorName", "ContactorName", "String", CInput(Me.iugDetail.iMESUltraGrid.Selected.Rows(i).Cells("ContactorName").Value.ToString), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractorCont", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
-
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDCopy.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmTestContDef
- fSubcontractorContDef.DefMode = 2
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEMail.Click
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
- Dim proMail As New System.Diagnostics.Process
- Dim strAccount As String
-
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- strAccount = "mailto:" & Rows(0).Item("EMail").ToString
- proMail.Start(strAccount)
-
- End If
-
- End Sub
-
- Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnQuery_Click(sender As Object, e As EventArgs)
- Cursor.Current = Cursors.WaitCursor
-
- funLoadSubcontractor()
-
- Cursor.Current = Cursors.Default
- End Sub
-
-#Region "Ultra Grid"
-
- Private Sub iugSubcontractor_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugSubcontractor.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo")
- .Header.Caption = "SubcontractorNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("SubcontractorName")
- .Header.Caption = "SubcontractorName"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("IssueState")
- .Header.Caption = "IssueState"
- .Width = 114
- .Hidden = True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 7
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
- Private Sub iugSubcontractor_iMESUltraGrid_AfterRowActivate(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles iugSubcontractor.iMESUltraGrid_AfterRowActivate
-
- 'IsGroupByRow不做任何處理
- If Not iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
- Else
- Exit Sub
- End If
-
- End Sub
-
- Private Sub iugDetail_iMESUltraGrid_InitializeLayOut(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugDetail.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo")
- .Header.Caption = "SubcontractorNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("ContactorName")
- .Header.Caption = "ContactorName"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("TelNo")
- .Header.Caption = "TelNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("FaxNo")
- .Header.Caption = "FaxNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("Title")
- .Header.Caption = "Title"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("Address")
- .Header.Caption = "Address"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("EMail")
- .Header.Caption = "EMail"
- .Width = 150
- .Hidden = False
- .CellAppearance.ForeColor = System.Drawing.Color.Blue
- .CellAppearance.FontData.Underline = DefaultableBoolean.True
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 200
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 7
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 8
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 9
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 10
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 11
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
-#End Region
-
-#Region "Load Function"
-
- '//取出tblENTSubcontractor 外包商資料
-
- Private Sub funLoadSubcontractor()
-
- '先判斷是否dataset中已有ENTSubcontractor之datatable,若有,需先remove否則會有錯誤
- If Not IsNothing(dsENT.Tables(tblENTSubcontractor)) Then
- dsENT.Tables.Remove(tblENTSubcontractor)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- '加上IssueState要求取出所有資料
- strParameter = CombineXMLParameter("issuestate", "IssueState", "Integer", defInteger, "")
- '加上查詢條件 cboSearchFieldName,txtSearchFieldValue
- strParameter += CombineXMLQueryCondition()
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT_21710_02.LoadTest", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
-
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractor = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadTest").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
-
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadTest").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadTest").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- strFilter = ""
- Select Case GetIssueState()
- Case Issue.Unfrozen
- strFilter = FilterByInteger(strFilter, "IssueState", 0)
- Case Issue.Pending
- strFilter = FilterByInteger(strFilter, "IssueState", 1)
- Case Issue.Active
- strFilter = FilterByInteger(strFilter, "IssueState", 2)
- Case Issue.Unused
- strFilter = FilterByInteger(strFilter, "IssueState", -1)
- End Select
-
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = strFilter
- dsENT.Tables(tblENTSubcontractor).DefaultView.Sort = "SubcontractorNo"
-
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit Sub
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- '//取出tblENTSubcontractorCont聯絡人資料
-
- Private Sub funLoadSubcontractorCont(ByRef SubcontractorNo As String)
-
- If Not IsNothing(dsENT.Tables(tblENTSubcontractorCont)) Then
- dsENT.Tables.Remove(tblENTSubcontractorCont)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", SubcontractorNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.LoadSubcontractorCont", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractorCont = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractorcont").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- Me.iugDetail.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractorCont).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Cont Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- Private Sub funShowActiveDetail()
-
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.DataSource = Nothing
- Else
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
- End If
-
- End Sub
-
- Private Sub funiMESUltraGridIni()
-
- 'iugSubcontractor 初始設定
- With Me.iugSubcontractor.iMESUltraGrid
- .Text = ""
- .DisplayLayout.GroupByBox.Hidden = True
- .DisplayLayout.UseFixedHeaders = False
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugSubcontractor.UserNo = gUserNo
-
- 'iugDetail 初始設定
- With Me.iugDetail.iMESUltraGrid.DisplayLayout
- .GroupByBox.Hidden = True
- .Override.ExpansionIndicator = ShowExpansionIndicator.Default
- .ViewStyle = ViewStyle.SingleBand
- .RowConnectorStyle = RowConnectorStyle.Default
-
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugDetail.UserNo = gUserNo
-
- End Sub
-
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/frmTestContDef.resx b/SRC/MESWin/SYS2/ET_Subcontractor/frmTestContDef.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/frmTestContDef.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/frmTestContDef.vb b/SRC/MESWin/SYS2/ET_Subcontractor/frmTestContDef.vb
deleted file mode 100644
index c90a334..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/frmTestContDef.vb
+++ /dev/null
@@ -1,656 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmTestContDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
-
- Public SubcontractorNo As String = defString
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblAddress As System.Windows.Forms.Label
- Friend WithEvents lblEMail As System.Windows.Forms.Label
- Friend WithEvents lblTitle As System.Windows.Forms.Label
- Friend WithEvents lblFaxNo As System.Windows.Forms.Label
- Friend WithEvents lblTelNo As System.Windows.Forms.Label
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblContactorName As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorContData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtContactorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtFaxNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTelNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtEMail As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTitle As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtAddress As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorContData = New System.Windows.Forms.GroupBox()
- Me.txtAddress = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtEMail = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTitle = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtFaxNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblAddress = New System.Windows.Forms.Label()
- Me.lblEMail = New System.Windows.Forms.Label()
- Me.lblTitle = New System.Windows.Forms.Label()
- Me.lblFaxNo = New System.Windows.Forms.Label()
- Me.lblTelNo = New System.Windows.Forms.Label()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblContactorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtContactorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTelNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorContData.SuspendLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 322)
- Me.gbxBasisData.Size = New System.Drawing.Size(472, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(396, 401)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(208, 401)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(302, 401)
- '
- 'gbxSubcontractorContData
- '
- Me.gbxSubcontractorContData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTelNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTelNo)
- Me.gbxSubcontractorContData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorContData.Location = New System.Drawing.Point(15, 8)
- Me.gbxSubcontractorContData.Name = "gbxSubcontractorContData"
- Me.gbxSubcontractorContData.Size = New System.Drawing.Size(469, 306)
- Me.gbxSubcontractorContData.TabIndex = 0
- Me.gbxSubcontractorContData.TabStop = False
- Me.gbxSubcontractorContData.Text = "ENT Subcontractor Contactor Data"
- '
- 'txtAddress
- '
- Me.txtAddress.Location = New System.Drawing.Point(120, 152)
- Me.txtAddress.Name = "txtAddress"
- Me.txtAddress.Size = New System.Drawing.Size(336, 22)
- Me.txtAddress.TabIndex = 13
- '
- 'txtEMail
- '
- Me.txtEMail.Location = New System.Drawing.Point(320, 120)
- Me.txtEMail.Name = "txtEMail"
- Me.txtEMail.Size = New System.Drawing.Size(136, 22)
- Me.txtEMail.TabIndex = 11
- '
- 'txtTitle
- '
- Me.txtTitle.Location = New System.Drawing.Point(120, 120)
- Me.txtTitle.Name = "txtTitle"
- Me.txtTitle.Size = New System.Drawing.Size(114, 22)
- Me.txtTitle.TabIndex = 9
- '
- 'txtFaxNo
- '
- Me.txtFaxNo.Location = New System.Drawing.Point(320, 88)
- Me.txtFaxNo.Name = "txtFaxNo"
- Me.txtFaxNo.Size = New System.Drawing.Size(136, 22)
- Me.txtFaxNo.TabIndex = 7
- '
- 'lblAddress
- '
- Me.lblAddress.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblAddress.Location = New System.Drawing.Point(24, 154)
- Me.lblAddress.Name = "lblAddress"
- Me.lblAddress.Size = New System.Drawing.Size(86, 14)
- Me.lblAddress.TabIndex = 12
- Me.lblAddress.Text = "Address"
- Me.lblAddress.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblEMail
- '
- Me.lblEMail.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblEMail.Location = New System.Drawing.Point(248, 123)
- Me.lblEMail.Name = "lblEMail"
- Me.lblEMail.Size = New System.Drawing.Size(64, 14)
- Me.lblEMail.TabIndex = 10
- Me.lblEMail.Text = "EMail"
- Me.lblEMail.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTitle
- '
- Me.lblTitle.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTitle.Location = New System.Drawing.Point(24, 121)
- Me.lblTitle.Name = "lblTitle"
- Me.lblTitle.Size = New System.Drawing.Size(86, 14)
- Me.lblTitle.TabIndex = 8
- Me.lblTitle.Text = "Title"
- Me.lblTitle.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblFaxNo
- '
- Me.lblFaxNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblFaxNo.Location = New System.Drawing.Point(248, 90)
- Me.lblFaxNo.Name = "lblFaxNo"
- Me.lblFaxNo.Size = New System.Drawing.Size(64, 14)
- Me.lblFaxNo.TabIndex = 6
- Me.lblFaxNo.Text = "FaxNo"
- Me.lblFaxNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTelNo
- '
- Me.lblTelNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTelNo.Location = New System.Drawing.Point(24, 90)
- Me.lblTelNo.Name = "lblTelNo"
- Me.lblTelNo.Size = New System.Drawing.Size(86, 14)
- Me.lblTelNo.TabIndex = 4
- Me.lblTelNo.Text = "TelNo"
- Me.lblTelNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(120, 184)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(336, 108)
- Me.txtDescription.TabIndex = 15
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(24, 186)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(86, 14)
- Me.lblDescription.TabIndex = 14
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(14, 29)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 14)
- Me.lblSubcontractorNo.TabIndex = 0
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblContactorName
- '
- Me.lblContactorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblContactorName.Location = New System.Drawing.Point(24, 59)
- Me.lblContactorName.Name = "lblContactorName"
- Me.lblContactorName.Size = New System.Drawing.Size(86, 14)
- Me.lblContactorName.TabIndex = 2
- Me.lblContactorName.Text = "Contactor Name"
- Me.lblContactorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(120, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.ReadOnly = True
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(114, 22)
- Me.txtSubcontractorNo.TabIndex = 1
- Me.txtSubcontractorNo.TabStop = False
- '
- 'txtContactorName
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Appearance = Appearance1
- Me.txtContactorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Location = New System.Drawing.Point(120, 56)
- Me.txtContactorName.Name = "txtContactorName"
- Me.txtContactorName.Size = New System.Drawing.Size(160, 22)
- Me.txtContactorName.TabIndex = 3
- '
- 'txtTelNo
- '
- Me.txtTelNo.Location = New System.Drawing.Point(120, 88)
- Me.txtTelNo.Name = "txtTelNo"
- Me.txtTelNo.Size = New System.Drawing.Size(114, 22)
- Me.txtTelNo.TabIndex = 5
- '
- 'frmSubcontractorContDef
- '
- Me.ClientSize = New System.Drawing.Size(496, 446)
- Me.Controls.Add(Me.gbxSubcontractorContData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorContDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Contactor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorContData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorContData.ResumeLayout(False)
- Me.gbxSubcontractorContData.PerformLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorContDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據()
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
- If DefMode = 0 Or DefMode = 2 Then
- SetCreateDate(Now)
- SetCreator(gUserNo)
- End If
- If Not EditDataRow Is Nothing Then '修改 or Copy
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtContactorName.Text = EditDataRow.Item("ContactorName").ToString
- txtTelNo.Text = EditDataRow.Item("TelNo").ToString
- txtFaxNo.Text = EditDataRow.Item("FaxNo").ToString
- txtTitle.Text = EditDataRow.Item("Title").ToString
- txtAddress.Text = EditDataRow.Item("Address").ToString
- txtEMail.Text = EditDataRow.Item("EMail").ToString
- 'txtDescription是RichTextBox(Control, 因為TextBox無法正常顯示多行換行的資料)
- txtDescription.Text = EditDataRow.Item("Description").ToString
- If DefMode = 1 Then
- If (Not IsDBNull(EditDataRow("Creator"))) Then
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetCreator(EditDataRow.Item("Creator").ToString)
- End If
- End If
- End If
-
- If DefMode = 0 Then 'Add
- txtSubcontractorNo.Text = SubcontractorNo
- SetCreateDate(Now)
- SetCreator(gUserNo)
- ElseIf DefMode = 1 Then 'Edit
- txtContactorName.ReadOnly = True
- SetReviseDate(Now)
- SetReviser(gUserNo)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorContDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
-
- txtEMail.Text = ""
- btnApplyEnabled = False
- Cursor.Current = Cursors.Default
-
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtContactorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Click
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Enter
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtContactorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtContactorName_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Leave
- If txtContactorName.Text <> "" And txtEMail.Text = "" Then
- txtEMail.Text = txtContactorName.Text & "@"
- End If
- txtContactorName.Text = UCase(txtContactorName.Text)
- End Sub
-
- Private Sub txtContactorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTelNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Click
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Enter
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTelNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTelNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtFaxNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Click
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Enter
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtFaxNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtFaxNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTitle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Click
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Enter
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTitle.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTitle_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Click
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Enter
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtEMail.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtEMail_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtAddress_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Click
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Enter
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtAddress.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtAddress_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtDescription.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查()
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
- If txtContactorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%ContactorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtContactorName.Focus()
- Exit Function
- End If
-
- '******************************************************************************
- '2.寫回資料庫()
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("contactorname", "ContactorName", "String", CInput(txtContactorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("telno", "TelNo", "String", txtTelNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("faxno", "FaxNo", "String", txtFaxNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("title", "Title", "String", CInput(txtTitle.Text), "")
- strParameter = strParameter & CombineXMLParameter("address", "Address", "String", CInput(txtAddress.Text), "")
- strParameter = strParameter & CombineXMLParameter("email", "EMail", "String", CInput(txtEMail.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.AddSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.AddSubcontractorCont", InXml)
-
- Else 'Edit
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.EditSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.EditSubcontractorCont", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtContactorName.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Contactor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-#End Region
-
-
- Private Sub frmSubcontractorContDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-End Class
-
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/frmTestDef.resx b/SRC/MESWin/SYS2/ET_Subcontractor/frmTestDef.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/frmTestDef.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/frmTestDef.vb b/SRC/MESWin/SYS2/ET_Subcontractor/frmTestDef.vb
deleted file mode 100644
index cd5f907..0000000
--- a/SRC/MESWin/SYS2/ET_Subcontractor/frmTestDef.vb
+++ /dev/null
@@ -1,421 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmTestDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorName As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtSubcontractorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance2 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorData = New System.Windows.Forms.GroupBox()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblSubcontractorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtSubcontractorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorData.SuspendLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 185)
- Me.gbxBasisData.Size = New System.Drawing.Size(479, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(403, 264)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(215, 264)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(309, 264)
- '
- 'gbxSubcontractorData
- '
- Me.gbxSubcontractorData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorName)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorName)
- Me.gbxSubcontractorData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorData.Location = New System.Drawing.Point(12, 8)
- Me.gbxSubcontractorData.Name = "gbxSubcontractorData"
- Me.gbxSubcontractorData.Size = New System.Drawing.Size(479, 169)
- Me.gbxSubcontractorData.TabIndex = 7
- Me.gbxSubcontractorData.TabStop = False
- Me.gbxSubcontractorData.Text = "Subcontractor Data"
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(128, 86)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(334, 67)
- Me.txtDescription.TabIndex = 2
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(56, 88)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(64, 14)
- Me.lblDescription.TabIndex = 13
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(24, 24)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 32)
- Me.lblSubcontractorNo.TabIndex = 5
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorName
- '
- Me.lblSubcontractorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorName.Location = New System.Drawing.Point(8, 56)
- Me.lblSubcontractorName.Name = "lblSubcontractorName"
- Me.lblSubcontractorName.Size = New System.Drawing.Size(112, 32)
- Me.lblSubcontractorName.TabIndex = 9
- Me.lblSubcontractorName.Text = "Subcontractor Name"
- Me.lblSubcontractorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Appearance = Appearance1
- Me.txtSubcontractorNo.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(128, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(152, 22)
- Me.txtSubcontractorNo.TabIndex = 0
- '
- 'txtSubcontractorName
- '
- Appearance2.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Appearance = Appearance2
- Me.txtSubcontractorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Location = New System.Drawing.Point(128, 55)
- Me.txtSubcontractorName.Name = "txtSubcontractorName"
- Me.txtSubcontractorName.Size = New System.Drawing.Size(334, 22)
- Me.txtSubcontractorName.TabIndex = 1
- '
- 'frmSubcontractorDef
- '
- Me.ClientSize = New System.Drawing.Size(503, 309)
- Me.Controls.Add(Me.gbxSubcontractorData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorData.ResumeLayout(False)
- Me.gbxSubcontractorData.PerformLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- If Not EditDataRow Is Nothing Then
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtSubcontractorName.Text = EditDataRow.Item("SubcontractorName").ToString
- 'txtDescription是RichTextBox Control,因為TextBox無法正常顯示多行換行的資料
- txtDescription.Text = EditDataRow.Item("Description").ToString
- End If
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- SetCreator(gUserNo)
- SetCreateDate(Now)
- ElseIf DefMode = 1 Then 'Edit
- txtSubcontractorNo.ReadOnly = True
- SetCreator(EditDataRow.Item("Creator").ToString)
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetReviser(gUserNo)
- SetReviseDate(Now)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
-
- End If
-
- Cursor.Current = Cursors.Default
- btnApplyEnabled = False
-
- End Sub
-
- Private Sub frmSubcontractorDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Leave
- txtSubcontractorNo.Text = UCase(txtSubcontractorNo.Text)
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtSubcontractorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Click
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Enter
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
-
- If txtSubcontractorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorName.Focus()
- Exit Function
- End If
-
- '2.
- '******************************************************************************
- '寫回資料庫
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("subcontractorname", "SubcontractorName", "String", CInput(txtSubcontractorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter = strParameter & CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("createdate", "CreateDate", "DateTime", Format(Now, "yyyy/MM/dd HH:mm:ss"), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.AddSubcontractor(InXml)
- OutXml = InvokeSrv("wsENT.AddSubcontractor", InXml)
-
- Else
- '修改
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", EditDataRow.Item("IssueState").ToString, "")
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.EditSubcontractor(InXml)
- OutXml = InvokeSrv("wsENT.EditSubcontractor", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtSubcontractorNo.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS2/ET_Subcontractor/iMES.snk b/SRC/MESWin/SYS2/ET_Subcontractor/iMES.snk
deleted file mode 100644
index 4206cdc36eceddde7f30ac484d1852eb3f9be236..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 596
zcmV-a0;~N80ssI2Bme+XQ$aES1ONa50097#g3R+{UF+SWBpq3jKsGz4Rg)jp;sR@&
z9YKT-w@gNp-L~38+1NJ=1XDRJDW25AI*NovDaNnzDN>{Bkv1jod=Ji9)a&FRUaAtf
zi1{sH^ycmTE>;(=WPI@cVijY>(
z68QMK9TPTAYPREpfq+h^Nne$)zO;6bx%j96AK_A|B+TR7U>0P)(eEk{J#@4Mx&M05
zCmJxuxSLKS802l^7))Rwj&-Awxzy
zL|h&Z8u5{hxZ#i*aB?roJ=(>%lFM~AM)K&^89a(nzv>UkL3%^1E^(B=&$CpC*k&Uu
zoWIXD#zo%*oEY3D5w(^p%?
zO5a)yp9j|(odT|vi)x=2V4i$!>r`bocbgd;9#&HU{hI|N6Z$Mk4?^qLlWtab5
z>NP5P^SUu%0a4(t?J}R)?1B(lBxj+?ehgOdZcWno8ix^tn9J&06)
-
-
-
- Debug
- x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}
- Library
- ET_Subcontractor_21687
- ET_Subcontractor_21687
- 512
- Windows
- v4.6.2
-
- SAK
- SAK
- SAK
- SAK
-
-
- On
-
-
- Binary
-
-
- Off
-
-
- On
-
-
- true
- true
- true
- ..\..\..\MESClient\
- ET_Subcontractor_21687.xml
- 0
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- full
- x86
- MinimumRecommendedRules.ruleset
- false
-
-
- true
- ..\..\..\MESClient\
- ET_Subcontractor_21687.xml
- true
- 0
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- pdbonly
- x86
- MinimumRecommendedRules.ruleset
- false
-
-
- true
-
-
- iMES.snk
-
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinGrid.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinEditors.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.Misc.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Shared.v19.1.dll
- False
-
-
- ..\..\..\MESClient\COM_Kit.dll
- False
-
-
- ..\..\..\MES_C_DLL\iMESExceptionManager.dll
- False
-
-
- ..\..\..\MES_C_DLL\iMESUltraGrid.dll
- False
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- modConstant.vb
-
-
- Form
-
-
- Form
-
-
- Form
-
-
-
- True
- Application.myapp
- True
-
-
- True
- True
- Resources.resx
-
-
- True
- Settings.settings
- True
-
-
-
-
- frmSubcontractor.vb
-
-
- frmSubcontractorContDef.vb
-
-
- frmSubcontractorDef.vb
-
-
-
- VbMyResourcesResXFileCodeGenerator
- Resources.Designer.vb
- My.Resources
- Designer
-
-
-
-
-
- MyApplicationCodeGenerator
- Application.Designer.vb
-
-
- SettingsSingleFileGenerator
- My
- Settings.Designer.vb
-
-
-
-
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractor.resx b/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractor.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractor.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorContDef.resx b/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorContDef.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorContDef.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorContDef.vb b/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorContDef.vb
deleted file mode 100644
index 9f4f65b..0000000
--- a/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorContDef.vb
+++ /dev/null
@@ -1,784 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorContDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
-
- Public SubcontractorNo As String = defString
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Friend WithEvents gbxBasisData As Infragistics.Win.Misc.UltraGroupBox
- Friend WithEvents txtReviseDate As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtReviser As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents lblReviseDate As Infragistics.Win.Misc.UltraLabel
- Friend WithEvents lblReviser As Infragistics.Win.Misc.UltraLabel
- Friend WithEvents txtCreateDate As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtCreator As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents lblCreateDate As Infragistics.Win.Misc.UltraLabel
- Friend WithEvents lblCreator As Infragistics.Win.Misc.UltraLabel
- Friend WithEvents btnApply As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnConfirm As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnClose As Infragistics.Win.Misc.UltraButton
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblAddress As System.Windows.Forms.Label
- Friend WithEvents lblEMail As System.Windows.Forms.Label
- Friend WithEvents lblTitle As System.Windows.Forms.Label
- Friend WithEvents lblFaxNo As System.Windows.Forms.Label
- Friend WithEvents lblTelNo As System.Windows.Forms.Label
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblContactorName As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorContData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtContactorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtFaxNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTelNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtEMail As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTitle As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtAddress As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance2 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance3 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance4 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance5 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.txtReviseDate = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtReviser = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblReviseDate = New Infragistics.Win.Misc.UltraLabel()
- Me.lblReviser = New Infragistics.Win.Misc.UltraLabel()
- Me.txtCreateDate = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtCreator = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblCreateDate = New Infragistics.Win.Misc.UltraLabel()
- Me.lblCreator = New Infragistics.Win.Misc.UltraLabel()
- Me.gbxSubcontractorContData = New System.Windows.Forms.GroupBox()
- Me.txtAddress = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtEMail = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTitle = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtFaxNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblAddress = New System.Windows.Forms.Label()
- Me.lblEMail = New System.Windows.Forms.Label()
- Me.lblTitle = New System.Windows.Forms.Label()
- Me.lblFaxNo = New System.Windows.Forms.Label()
- Me.lblTelNo = New System.Windows.Forms.Label()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblContactorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtContactorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTelNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtReviseDate, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtReviser, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtCreateDate, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtCreator, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorContData.SuspendLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 322)
- Me.gbxBasisData.Size = New System.Drawing.Size(472, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(395, 401)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(207, 401)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(301, 401)
- '
- 'txtReviseDate
- '
- Me.txtReviseDate.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.txtReviseDate.Location = New System.Drawing.Point(327, 39)
- Me.txtReviseDate.Margin = New System.Windows.Forms.Padding(3, 5, 3, 5)
- Me.txtReviseDate.Name = "txtReviseDate"
- Me.txtReviseDate.ReadOnly = True
- Me.txtReviseDate.Size = New System.Drawing.Size(140, 21)
- Me.txtReviseDate.TabIndex = 31
- '
- 'txtReviser
- '
- Me.txtReviser.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.txtReviser.Location = New System.Drawing.Point(100, 39)
- Me.txtReviser.Margin = New System.Windows.Forms.Padding(3, 5, 3, 5)
- Me.txtReviser.Name = "txtReviser"
- Me.txtReviser.ReadOnly = True
- Me.txtReviser.Size = New System.Drawing.Size(140, 21)
- Me.txtReviser.TabIndex = 29
- '
- 'lblReviseDate
- '
- Me.lblReviseDate.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Appearance1.TextHAlignAsString = "Right"
- Appearance1.TextVAlignAsString = "Middle"
- Me.lblReviseDate.Appearance = Appearance1
- Me.lblReviseDate.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblReviseDate.Location = New System.Drawing.Point(246, 40)
- Me.lblReviseDate.Margin = New System.Windows.Forms.Padding(3, 5, 3, 5)
- Me.lblReviseDate.Name = "lblReviseDate"
- Me.lblReviseDate.Size = New System.Drawing.Size(75, 22)
- Me.lblReviseDate.TabIndex = 30
- Me.lblReviseDate.Text = "Revise Date"
- '
- 'lblReviser
- '
- Me.lblReviser.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Appearance2.TextHAlignAsString = "Right"
- Appearance2.TextVAlignAsString = "Middle"
- Me.lblReviser.Appearance = Appearance2
- Me.lblReviser.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblReviser.Location = New System.Drawing.Point(19, 40)
- Me.lblReviser.Margin = New System.Windows.Forms.Padding(3, 5, 3, 5)
- Me.lblReviser.Name = "lblReviser"
- Me.lblReviser.Size = New System.Drawing.Size(75, 22)
- Me.lblReviser.TabIndex = 28
- Me.lblReviser.Text = "Reviser"
- '
- 'txtCreateDate
- '
- Me.txtCreateDate.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.txtCreateDate.Location = New System.Drawing.Point(327, 7)
- Me.txtCreateDate.Margin = New System.Windows.Forms.Padding(3, 5, 3, 5)
- Me.txtCreateDate.Name = "txtCreateDate"
- Me.txtCreateDate.ReadOnly = True
- Me.txtCreateDate.Size = New System.Drawing.Size(140, 21)
- Me.txtCreateDate.TabIndex = 27
- '
- 'txtCreator
- '
- Me.txtCreator.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.txtCreator.Location = New System.Drawing.Point(100, 7)
- Me.txtCreator.Margin = New System.Windows.Forms.Padding(3, 5, 3, 5)
- Me.txtCreator.Name = "txtCreator"
- Me.txtCreator.ReadOnly = True
- Me.txtCreator.Size = New System.Drawing.Size(140, 21)
- Me.txtCreator.TabIndex = 25
- '
- 'lblCreateDate
- '
- Me.lblCreateDate.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Appearance3.TextHAlignAsString = "Right"
- Appearance3.TextVAlignAsString = "Middle"
- Me.lblCreateDate.Appearance = Appearance3
- Me.lblCreateDate.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblCreateDate.Location = New System.Drawing.Point(246, 8)
- Me.lblCreateDate.Margin = New System.Windows.Forms.Padding(3, 5, 3, 5)
- Me.lblCreateDate.Name = "lblCreateDate"
- Me.lblCreateDate.Size = New System.Drawing.Size(75, 22)
- Me.lblCreateDate.TabIndex = 26
- Me.lblCreateDate.Text = "Create Date"
- '
- 'lblCreator
- '
- Me.lblCreator.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Appearance4.TextHAlignAsString = "Right"
- Appearance4.TextVAlignAsString = "Middle"
- Me.lblCreator.Appearance = Appearance4
- Me.lblCreator.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblCreator.Location = New System.Drawing.Point(19, 8)
- Me.lblCreator.Margin = New System.Windows.Forms.Padding(3, 5, 3, 5)
- Me.lblCreator.Name = "lblCreator"
- Me.lblCreator.Size = New System.Drawing.Size(75, 22)
- Me.lblCreator.TabIndex = 24
- Me.lblCreator.Text = "Creator"
- '
- 'gbxSubcontractorContData
- '
- Me.gbxSubcontractorContData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTelNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTelNo)
- Me.gbxSubcontractorContData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorContData.Location = New System.Drawing.Point(15, 8)
- Me.gbxSubcontractorContData.Name = "gbxSubcontractorContData"
- Me.gbxSubcontractorContData.Size = New System.Drawing.Size(469, 306)
- Me.gbxSubcontractorContData.TabIndex = 0
- Me.gbxSubcontractorContData.TabStop = False
- Me.gbxSubcontractorContData.Text = "ENT Subcontractor Contactor Data"
- '
- 'txtAddress
- '
- Me.txtAddress.Location = New System.Drawing.Point(120, 152)
- Me.txtAddress.Name = "txtAddress"
- Me.txtAddress.Size = New System.Drawing.Size(336, 22)
- Me.txtAddress.TabIndex = 13
- '
- 'txtEMail
- '
- Me.txtEMail.Location = New System.Drawing.Point(320, 120)
- Me.txtEMail.Name = "txtEMail"
- Me.txtEMail.Size = New System.Drawing.Size(136, 22)
- Me.txtEMail.TabIndex = 11
- '
- 'txtTitle
- '
- Me.txtTitle.Location = New System.Drawing.Point(120, 120)
- Me.txtTitle.Name = "txtTitle"
- Me.txtTitle.Size = New System.Drawing.Size(114, 22)
- Me.txtTitle.TabIndex = 9
- '
- 'txtFaxNo
- '
- Me.txtFaxNo.Location = New System.Drawing.Point(320, 88)
- Me.txtFaxNo.Name = "txtFaxNo"
- Me.txtFaxNo.Size = New System.Drawing.Size(136, 22)
- Me.txtFaxNo.TabIndex = 7
- '
- 'lblAddress
- '
- Me.lblAddress.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblAddress.Location = New System.Drawing.Point(24, 154)
- Me.lblAddress.Name = "lblAddress"
- Me.lblAddress.Size = New System.Drawing.Size(86, 14)
- Me.lblAddress.TabIndex = 12
- Me.lblAddress.Text = "Address"
- Me.lblAddress.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblEMail
- '
- Me.lblEMail.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblEMail.Location = New System.Drawing.Point(248, 123)
- Me.lblEMail.Name = "lblEMail"
- Me.lblEMail.Size = New System.Drawing.Size(64, 14)
- Me.lblEMail.TabIndex = 10
- Me.lblEMail.Text = "EMail"
- Me.lblEMail.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTitle
- '
- Me.lblTitle.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTitle.Location = New System.Drawing.Point(24, 121)
- Me.lblTitle.Name = "lblTitle"
- Me.lblTitle.Size = New System.Drawing.Size(86, 14)
- Me.lblTitle.TabIndex = 8
- Me.lblTitle.Text = "Title"
- Me.lblTitle.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblFaxNo
- '
- Me.lblFaxNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblFaxNo.Location = New System.Drawing.Point(248, 90)
- Me.lblFaxNo.Name = "lblFaxNo"
- Me.lblFaxNo.Size = New System.Drawing.Size(64, 14)
- Me.lblFaxNo.TabIndex = 6
- Me.lblFaxNo.Text = "FaxNo"
- Me.lblFaxNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTelNo
- '
- Me.lblTelNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTelNo.Location = New System.Drawing.Point(24, 90)
- Me.lblTelNo.Name = "lblTelNo"
- Me.lblTelNo.Size = New System.Drawing.Size(86, 14)
- Me.lblTelNo.TabIndex = 4
- Me.lblTelNo.Text = "TelNo"
- Me.lblTelNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(120, 184)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(336, 108)
- Me.txtDescription.TabIndex = 15
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(24, 186)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(86, 14)
- Me.lblDescription.TabIndex = 14
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(14, 29)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 14)
- Me.lblSubcontractorNo.TabIndex = 0
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblContactorName
- '
- Me.lblContactorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblContactorName.Location = New System.Drawing.Point(24, 59)
- Me.lblContactorName.Name = "lblContactorName"
- Me.lblContactorName.Size = New System.Drawing.Size(86, 14)
- Me.lblContactorName.TabIndex = 2
- Me.lblContactorName.Text = "Contactor Name"
- Me.lblContactorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(120, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.ReadOnly = True
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(114, 22)
- Me.txtSubcontractorNo.TabIndex = 1
- Me.txtSubcontractorNo.TabStop = False
- '
- 'txtContactorName
- '
- Appearance5.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Appearance = Appearance5
- Me.txtContactorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Location = New System.Drawing.Point(120, 56)
- Me.txtContactorName.Name = "txtContactorName"
- Me.txtContactorName.Size = New System.Drawing.Size(160, 22)
- Me.txtContactorName.TabIndex = 3
- '
- 'txtTelNo
- '
- Me.txtTelNo.Location = New System.Drawing.Point(120, 88)
- Me.txtTelNo.Name = "txtTelNo"
- Me.txtTelNo.Size = New System.Drawing.Size(114, 22)
- Me.txtTelNo.TabIndex = 5
- '
- 'frmSubcontractorContDef
- '
- Me.ClientSize = New System.Drawing.Size(496, 446)
- Me.Controls.Add(Me.gbxSubcontractorContData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorContDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Contactor Define"
- Me.Controls.SetChildIndex(Me.gbxSubcontractorContData, 0)
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtReviseDate, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtReviser, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtCreateDate, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtCreator, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorContData.ResumeLayout(False)
- Me.gbxSubcontractorContData.PerformLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorContDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據()
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
- If DefMode = 0 Or DefMode = 2 Then
- SetCreateDate(Now)
- SetCreator(gUserNo)
- End If
- If Not EditDataRow Is Nothing Then '修改 or Copy
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtContactorName.Text = EditDataRow.Item("ContactorName").ToString
- txtTelNo.Text = EditDataRow.Item("TelNo").ToString
- txtFaxNo.Text = EditDataRow.Item("FaxNo").ToString
- txtTitle.Text = EditDataRow.Item("Title").ToString
- txtAddress.Text = EditDataRow.Item("Address").ToString
- txtEMail.Text = EditDataRow.Item("EMail").ToString
- 'txtDescription是RichTextBox(Control, 因為TextBox無法正常顯示多行換行的資料)
- txtDescription.Text = EditDataRow.Item("Description").ToString
- If DefMode = 1 Then
- If (Not IsDBNull(EditDataRow("Creator"))) Then
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetCreator(EditDataRow.Item("Creator").ToString)
- End If
- End If
- End If
-
- If DefMode = 0 Then 'Add
- txtSubcontractorNo.Text = SubcontractorNo
- SetCreateDate(Now)
- SetCreator(gUserNo)
- ElseIf DefMode = 1 Then 'Edit
- txtContactorName.ReadOnly = True
- SetReviseDate(Now)
- SetReviser(gUserNo)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorContDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
-
- txtEMail.Text = ""
- btnApplyEnabled = False
- Cursor.Current = Cursors.Default
-
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtContactorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Click
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Enter
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtContactorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtContactorName_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Leave
- If txtContactorName.Text <> "" And txtEMail.Text = "" Then
- txtEMail.Text = txtContactorName.Text & "@"
- End If
- txtContactorName.Text = UCase(txtContactorName.Text)
- End Sub
-
- Private Sub txtContactorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTelNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Click
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Enter
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTelNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTelNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtFaxNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Click
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Enter
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtFaxNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtFaxNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTitle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Click
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Enter
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTitle.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTitle_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Click
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Enter
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtEMail.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtEMail_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtAddress_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Click
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Enter
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtAddress.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtAddress_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtDescription.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查()
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
- If txtContactorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%ContactorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtContactorName.Focus()
- Exit Function
- End If
-
- '******************************************************************************
- '2.寫回資料庫()
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("contactorname", "ContactorName", "String", CInput(txtContactorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("telno", "TelNo", "String", txtTelNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("faxno", "FaxNo", "String", txtFaxNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("title", "Title", "String", CInput(txtTitle.Text), "")
- strParameter = strParameter & CombineXMLParameter("address", "Address", "String", CInput(txtAddress.Text), "")
- strParameter = strParameter & CombineXMLParameter("email", "EMail", "String", CInput(txtEMail.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.AddSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS687.wsENT.AddSubcontractorCont", InXml)
-
- Else 'Edit
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.EditSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS687.wsENT.EditSubcontractorCont", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtContactorName.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Contactor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-#End Region
-
-
- Private Sub frmSubcontractorContDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-End Class
-
diff --git a/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorDef.resx b/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorDef.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorDef.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorDef.vb b/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorDef.vb
deleted file mode 100644
index 87fdf9f..0000000
--- a/SRC/MESWin/SYS2/SYSENT21687/frmSubcontractorDef.vb
+++ /dev/null
@@ -1,458 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Friend WithEvents Label1 As Label
-
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents txtbox As System.Windows.Forms.RichTextBox
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorName As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtSubcontractorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance2 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorData = New System.Windows.Forms.GroupBox()
- Me.Label1 = New System.Windows.Forms.Label()
- Me.txtbox = New System.Windows.Forms.RichTextBox()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblSubcontractorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtSubcontractorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorData.SuspendLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 323)
- Me.gbxBasisData.Size = New System.Drawing.Size(479, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(403, 402)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(215, 402)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(309, 402)
- '
- 'gbxSubcontractorData
- '
- Me.gbxSubcontractorData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorData.Controls.Add(Me.Label1)
- Me.gbxSubcontractorData.Controls.Add(Me.txtbox)
- Me.gbxSubcontractorData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorName)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorName)
- Me.gbxSubcontractorData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorData.Location = New System.Drawing.Point(12, 8)
- Me.gbxSubcontractorData.Name = "gbxSubcontractorData"
- Me.gbxSubcontractorData.Size = New System.Drawing.Size(479, 307)
- Me.gbxSubcontractorData.TabIndex = 7
- Me.gbxSubcontractorData.TabStop = False
- Me.gbxSubcontractorData.Text = "Subcontractor Data"
- '
- 'Label1
- '
- Me.Label1.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Label1.Location = New System.Drawing.Point(58, 162)
- Me.Label1.Name = "Label1"
- Me.Label1.Size = New System.Drawing.Size(64, 14)
- Me.Label1.TabIndex = 15
- Me.Label1.Text = "testTXT"
- Me.Label1.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtbox
- '
- Me.txtbox.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtbox.Location = New System.Drawing.Point(128, 159)
- Me.txtbox.Name = "txtbox"
- Me.txtbox.Size = New System.Drawing.Size(334, 67)
- Me.txtbox.TabIndex = 14
- Me.txtbox.Text = ""
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(128, 86)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(334, 67)
- Me.txtDescription.TabIndex = 2
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(56, 88)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(64, 14)
- Me.lblDescription.TabIndex = 13
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(24, 24)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 32)
- Me.lblSubcontractorNo.TabIndex = 5
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorName
- '
- Me.lblSubcontractorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorName.Location = New System.Drawing.Point(8, 56)
- Me.lblSubcontractorName.Name = "lblSubcontractorName"
- Me.lblSubcontractorName.Size = New System.Drawing.Size(112, 32)
- Me.lblSubcontractorName.TabIndex = 9
- Me.lblSubcontractorName.Text = "Subcontractor Name"
- Me.lblSubcontractorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Appearance = Appearance1
- Me.txtSubcontractorNo.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(128, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(152, 26)
- Me.txtSubcontractorNo.TabIndex = 0
- '
- 'txtSubcontractorName
- '
- Appearance2.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Appearance = Appearance2
- Me.txtSubcontractorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Location = New System.Drawing.Point(128, 55)
- Me.txtSubcontractorName.Name = "txtSubcontractorName"
- Me.txtSubcontractorName.Size = New System.Drawing.Size(334, 26)
- Me.txtSubcontractorName.TabIndex = 1
- '
- 'frmSubcontractorDef
- '
- Me.ClientSize = New System.Drawing.Size(503, 447)
- Me.Controls.Add(Me.gbxSubcontractorData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorData.ResumeLayout(False)
- Me.gbxSubcontractorData.PerformLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- If Not EditDataRow Is Nothing Then
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtSubcontractorName.Text = EditDataRow.Item("SubcontractorName").ToString
- 'txtDescription是RichTextBox Control,因為TextBox無法正常顯示多行換行的資料
- txtDescription.Text = EditDataRow.Item("Description").ToString
- txtbox.Text = EditDataRow.Item("Test21687").ToString
- End If
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- SetCreator(gUserNo)
- SetCreateDate(Now)
- ElseIf DefMode = 1 Then 'Edit
- txtSubcontractorNo.ReadOnly = True
- SetCreator(EditDataRow.Item("Creator").ToString)
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetReviser(gUserNo)
- SetReviseDate(Now)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnConfirm.Click
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
-
- End If
-
- Cursor.Current = Cursors.Default
- btnApplyEnabled = False
-
- End Sub
-
- Private Sub frmSubcontractorDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Leave
- txtSubcontractorNo.Text = UCase(txtSubcontractorNo.Text)
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtSubcontractorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Click
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Enter
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtbox_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter, txtbox.Enter
- txtbox.SelectAll()
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
-
- If txtSubcontractorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorName.Focus()
- Exit Function
- End If
-
- '2.
- '******************************************************************************
- '寫回資料庫
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("subcontractorname", "SubcontractorName", "String", CInput(txtSubcontractorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
- strParameter = strParameter & CombineXMLParameter("test21687", "Test21687", "String", CInput(txtbox.Text), "")
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter = strParameter & CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("createdate", "CreateDate", "DateTime", Format(Now, "yyyy/MM/dd HH:mm:ss"), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.AddSubcontractor(InXml)
- OutXml = InvokeSrv("SXS687.wsENT.AddSubcontractor", InXml)
-
- Else
- '修改
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", EditDataRow.Item("IssueState").ToString, "")
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.EditSubcontractor(InXml)
- OutXml = InvokeSrv("SXS687.wsENT.EditSubcontractor", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtSubcontractorNo.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-
- Private Sub txtbox_TextChanged(sender As Object, e As EventArgs) Handles txtbox.TextChanged
- btnApplyEnabled = True
- End Sub
-
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS2/新建 文本文档.txt b/SRC/MESWin/SYS2/新建 文本文档.txt
deleted file mode 100644
index e69de29..0000000
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/ET_Subcontractor.sln b/SRC/MESWin/SYS3/ET_Subcontractor_21676/ET_Subcontractor.sln
deleted file mode 100644
index 9d2004a..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/ET_Subcontractor.sln
+++ /dev/null
@@ -1,31 +0,0 @@
-
-Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio Version 16
-VisualStudioVersion = 16.0.34407.143
-MinimumVisualStudioVersion = 10.0.40219.1
-Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "ET_Subcontractor_21676", "ET_Subcontractor_21676.vbproj", "{D6EE7B96-F10E-44E2-9731-162B70B4C8DD}"
-EndProject
-Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Test", "..\..\Test\Test.vbproj", "{C4A48E3F-38E4-4E88-A47D-FA5510686E57}"
-EndProject
-Global
- GlobalSection(SolutionConfigurationPlatforms) = preSolution
- Debug|x86 = Debug|x86
- Release|x86 = Release|x86
- EndGlobalSection
- GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.ActiveCfg = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.Build.0 = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.ActiveCfg = Release|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.Build.0 = Release|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.ActiveCfg = Debug|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.Build.0 = Debug|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Release|x86.ActiveCfg = Release|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Release|x86.Build.0 = Release|x86
- EndGlobalSection
- GlobalSection(SolutionProperties) = preSolution
- HideSolutionNode = FALSE
- EndGlobalSection
- GlobalSection(ExtensibilityGlobals) = postSolution
- SolutionGuid = {E2B8A98D-2A89-4F3A-84D9-5910CE795ED7}
- EndGlobalSection
-EndGlobal
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Application.Designer.vb b/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Application.Designer.vb
deleted file mode 100644
index 537244b..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Application.Designer.vb
+++ /dev/null
@@ -1,13 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Application.myapp b/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Application.myapp
deleted file mode 100644
index 758895d..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Application.myapp
+++ /dev/null
@@ -1,10 +0,0 @@
-
-
- false
- false
- 0
- true
- 0
- 1
- true
-
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/BuildIncrementVersionInfo.vb b/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/BuildIncrementVersionInfo.vb
deleted file mode 100644
index d2f2e21..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/BuildIncrementVersionInfo.vb
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Resources.Designer.vb b/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Resources.Designer.vb
deleted file mode 100644
index 6d51f55..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Resources.Designer.vb
+++ /dev/null
@@ -1,63 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-Imports System
-
-Namespace My.Resources
-
- '此类是由 StronglyTypedResourceBuilder
- '类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
- '若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen
- '(以 /str 作为命令选项),或重新生成 VS 项目。
- '''
- ''' 一个强类型的资源类,用于查找本地化的字符串等。
- '''
- _
- Friend Module Resources
-
- Private resourceMan As Global.System.Resources.ResourceManager
-
- Private resourceCulture As Global.System.Globalization.CultureInfo
-
- '''
- ''' 返回此类使用的缓存的 ResourceManager 实例。
- '''
- _
- Friend ReadOnly Property ResourceManager() As Global.System.Resources.ResourceManager
- Get
- If Object.ReferenceEquals(resourceMan, Nothing) Then
- Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("ET_Subcontractor_21676.Resources", GetType(Resources).Assembly)
- resourceMan = temp
- End If
- Return resourceMan
- End Get
- End Property
-
- '''
- ''' 重写当前线程的 CurrentUICulture 属性,对
- ''' 使用此强类型资源类的所有资源查找执行重写。
- '''
- _
- Friend Property Culture() As Global.System.Globalization.CultureInfo
- Get
- Return resourceCulture
- End Get
- Set
- resourceCulture = value
- End Set
- End Property
- End Module
-End Namespace
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Resources.resx b/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Resources.resx
deleted file mode 100644
index af7dbeb..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Resources.resx
+++ /dev/null
@@ -1,117 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Settings.Designer.vb b/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Settings.Designer.vb
deleted file mode 100644
index ef91bf4..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Settings.Designer.vb
+++ /dev/null
@@ -1,73 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-
-Namespace My
-
- _
- Partial Friend NotInheritable Class MySettings
- Inherits Global.System.Configuration.ApplicationSettingsBase
-
- Private Shared defaultInstance As MySettings = CType(Global.System.Configuration.ApplicationSettingsBase.Synchronized(New MySettings()),MySettings)
-
-#Region "My.Settings 自动保存功能"
-#If _MyType = "WindowsForms" Then
- Private Shared addedHandler As Boolean
-
- Private Shared addedHandlerLockObject As New Object
-
- _
- Private Shared Sub AutoSaveSettings(sender As Global.System.Object, e As Global.System.EventArgs)
- If My.Application.SaveMySettingsOnExit Then
- My.Settings.Save()
- End If
- End Sub
-#End If
-#End Region
-
- Public Shared ReadOnly Property [Default]() As MySettings
- Get
-
-#If _MyType = "WindowsForms" Then
- If Not addedHandler Then
- SyncLock addedHandlerLockObject
- If Not addedHandler Then
- AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings
- addedHandler = True
- End If
- End SyncLock
- End If
-#End If
- Return defaultInstance
- End Get
- End Property
- End Class
-End Namespace
-
-Namespace My
-
- _
- Friend Module MySettingsProperty
-
- _
- Friend ReadOnly Property Settings() As Global.ET_Subcontractor_21676.My.MySettings
- Get
- Return Global.ET_Subcontractor_21676.My.MySettings.Default
- End Get
- End Property
- End Module
-End Namespace
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Settings.settings b/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Settings.settings
deleted file mode 100644
index 85b890b..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/Settings.settings
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
-
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/licenses.licx b/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/licenses.licx
deleted file mode 100644
index e3f40e2..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/My Project/licenses.licx
+++ /dev/null
@@ -1,7 +0,0 @@
-Infragistics.Win.Misc.UltraButton, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraRadioButton, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraComboEditor, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraGroupBox, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraTextEditor, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraLabel, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraPanel, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor.resx b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor.vb b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor.vb
deleted file mode 100644
index dbb69ad..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor.vb
+++ /dev/null
@@ -1,1133 +0,0 @@
-Imports iMESExceptionManager
-
-Imports Infragistics.Win
-Imports Infragistics.Win.UltraWinGrid
-Public Class frmSubcontractor
-
- Inherits COM_Kit.frmBasisTemplat
-
- Public PrivFunNo As String = defString
-
- '//WS相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT '宣告Web Service物件?
- Dim tmpStringReader As System.IO.StringReader '將字串轉換成可讀入DataSet的物件
- Dim XmlData As String '儲存取回之資料
- Dim XmlSchema As String '儲存取回之資料結構
- Dim InXml As String '儲存呼叫Web Service的傳入參數(Request字串)
- Dim OutXml As String '儲存Web Service的傳回值(Response字串)
- Dim strIdentity As String '儲存Identity XML字串?
- Dim strParameter As String '儲存Parameter XML字串
-
- '//資料表相關變數
-
- Dim dsENT As New DataSet '資料集:儲存取回之資料?
-
- Dim tblENTSubcontractor As String '儲存取回資料表的名稱(master)?
- Dim tblENTSubcontractorCont As String '明細資料表名稱(detail)
- Dim strFilter As String 'Filter string及列印的過濾條件
-
- '//其他共用變數
- Dim SubcontractorNo_21676 As String 'for Gird to Focus
- Dim ContactorName As String 'for DetailGrid to Focus
- Dim ugrRow As Infragistics.Win.UltraWinGrid.UltraGridRow
- Friend WithEvents btnAdd As Misc.UltraButton
- Friend WithEvents btnEdit As Misc.UltraButton
- Friend WithEvents btnDel As Misc.UltraButton
- Friend WithEvents btnCopy As Misc.UltraButton
- Friend WithEvents btnApprove As Misc.UltraButton
- Friend WithEvents iugSubcontractor As iMESUltraGrid.iMESUltraGridControl
- Dim i As Integer
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.Container
- Friend WithEvents iugDetail As iMESUltraGrid.iMESUltraGridControl
- Friend WithEvents btnClose As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnEMail As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDCopy As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDDel As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDEdit As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDAdd As Infragistics.Win.Misc.UltraButton
- Private Sub InitializeComponent()
- Me.btnClose = New Infragistics.Win.Misc.UltraButton()
- Me.btnEMail = New Infragistics.Win.Misc.UltraButton()
- Me.btnDCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnDDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnDEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDAdd = New Infragistics.Win.Misc.UltraButton()
- Me.iugDetail = New iMESUltraGrid.iMESUltraGridControl()
- Me.btnAdd = New Infragistics.Win.Misc.UltraButton()
- Me.btnEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnApprove = New Infragistics.Win.Misc.UltraButton()
- Me.iugSubcontractor = New iMESUltraGrid.iMESUltraGridControl()
- Me.SuspendLayout()
- '
- 'btnClose
- '
- Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnClose.Location = New System.Drawing.Point(1002, 616)
- Me.btnClose.Name = "btnClose"
- Me.btnClose.Size = New System.Drawing.Size(88, 32)
- Me.btnClose.TabIndex = 18
- Me.btnClose.Text = "Close (&X)"
- '
- 'btnEMail
- '
- Me.btnEMail.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEMail.Location = New System.Drawing.Point(1002, 429)
- Me.btnEMail.Name = "btnEMail"
- Me.btnEMail.Size = New System.Drawing.Size(88, 32)
- Me.btnEMail.TabIndex = 17
- Me.btnEMail.Text = "Mail"
- '
- 'btnDCopy
- '
- Me.btnDCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDCopy.Location = New System.Drawing.Point(1002, 389)
- Me.btnDCopy.Name = "btnDCopy"
- Me.btnDCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnDCopy.TabIndex = 16
- Me.btnDCopy.Text = "Copy"
- '
- 'btnDDel
- '
- Me.btnDDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDDel.Location = New System.Drawing.Point(1002, 349)
- Me.btnDDel.Name = "btnDDel"
- Me.btnDDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDDel.TabIndex = 15
- Me.btnDDel.Text = "DEL"
- '
- 'btnDEdit
- '
- Me.btnDEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDEdit.Location = New System.Drawing.Point(1002, 309)
- Me.btnDEdit.Name = "btnDEdit"
- Me.btnDEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnDEdit.TabIndex = 14
- Me.btnDEdit.Text = "EDIT"
- '
- 'btnDAdd
- '
- Me.btnDAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDAdd.Location = New System.Drawing.Point(1002, 269)
- Me.btnDAdd.Name = "btnDAdd"
- Me.btnDAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnDAdd.TabIndex = 13
- Me.btnDAdd.Text = "ADD"
- '
- 'iugDetail
- '
- Me.iugDetail.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugDetail.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugDetail.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugDetail.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugDetail.Identity = "IMes"
- Me.iugDetail.IdentityForm = ""
- Me.iugDetail.LayOutFilePath = ""
- Me.iugDetail.Location = New System.Drawing.Point(12, 270)
- Me.iugDetail.Name = "iugDetail"
- Me.iugDetail.PrintFitWidthToPages = 0
- Me.iugDetail.PrintLandscape = True
- Me.iugDetail.PrintPageFooter = ""
- Me.iugDetail.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageFooterHeight = 20
- Me.iugDetail.PrintPageHeader = ""
- Me.iugDetail.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageHeaderHeight = 20
- Me.iugDetail.PrintZoom = 1.0R
- Me.iugDetail.Size = New System.Drawing.Size(984, 378)
- Me.iugDetail.TabIndex = 12
- Me.iugDetail.UserNo = "IMes"
- '
- 'btnAdd
- '
- Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnAdd.Location = New System.Drawing.Point(1002, 53)
- Me.btnAdd.Name = "btnAdd"
- Me.btnAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnAdd.TabIndex = 20
- Me.btnAdd.Text = "Add(&A)"
- '
- 'btnEdit
- '
- Me.btnEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEdit.Location = New System.Drawing.Point(1002, 93)
- Me.btnEdit.Name = "btnEdit"
- Me.btnEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnEdit.TabIndex = 21
- Me.btnEdit.Text = "Edit(&E)"
- '
- 'btnDel
- '
- Me.btnDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDel.Location = New System.Drawing.Point(1002, 133)
- Me.btnDel.Name = "btnDel"
- Me.btnDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDel.TabIndex = 22
- Me.btnDel.Text = "Del(&D)"
- '
- 'btnCopy
- '
- Me.btnCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnCopy.Location = New System.Drawing.Point(1002, 173)
- Me.btnCopy.Name = "btnCopy"
- Me.btnCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnCopy.TabIndex = 23
- Me.btnCopy.Text = "Copy(&C)"
- '
- 'btnApprove
- '
- Me.btnApprove.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnApprove.Location = New System.Drawing.Point(1002, 213)
- Me.btnApprove.Name = "btnApprove"
- Me.btnApprove.Size = New System.Drawing.Size(88, 32)
- Me.btnApprove.TabIndex = 24
- Me.btnApprove.Text = "Approve(&Y)"
- '
- 'iugSubcontractor
- '
- Me.iugSubcontractor.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugSubcontractor.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugSubcontractor.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugSubcontractor.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugSubcontractor.Identity = "IMes"
- Me.iugSubcontractor.IdentityForm = ""
- Me.iugSubcontractor.LayOutFilePath = ""
- Me.iugSubcontractor.Location = New System.Drawing.Point(12, 53)
- Me.iugSubcontractor.Name = "iugSubcontractor"
- Me.iugSubcontractor.PrintFitWidthToPages = 0
- Me.iugSubcontractor.PrintLandscape = True
- Me.iugSubcontractor.PrintPageFooter = ""
- Me.iugSubcontractor.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageFooterHeight = 20
- Me.iugSubcontractor.PrintPageHeader = ""
- Me.iugSubcontractor.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageHeaderHeight = 20
- Me.iugSubcontractor.PrintZoom = 1.0R
- Me.iugSubcontractor.Size = New System.Drawing.Size(984, 256)
- Me.iugSubcontractor.TabIndex = 25
- Me.iugSubcontractor.UserNo = "IMes"
- '
- 'frmSubcontractor
- '
- Me.ClientSize = New System.Drawing.Size(1098, 655)
- Me.Controls.Add(Me.btnClose)
- Me.Controls.Add(Me.btnApprove)
- Me.Controls.Add(Me.btnEMail)
- Me.Controls.Add(Me.btnDCopy)
- Me.Controls.Add(Me.btnCopy)
- Me.Controls.Add(Me.btnDDel)
- Me.Controls.Add(Me.iugSubcontractor)
- Me.Controls.Add(Me.btnDEdit)
- Me.Controls.Add(Me.btnAdd)
- Me.Controls.Add(Me.btnDAdd)
- Me.Controls.Add(Me.btnDel)
- Me.Controls.Add(Me.iugDetail)
- Me.Controls.Add(Me.btnEdit)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractor"
- Me.Text = "ENT Subcontractor & Contactor"
- Me.WindowState = System.Windows.Forms.FormWindowState.Maximized
- Me.Controls.SetChildIndex(Me.btnEdit, 0)
- Me.Controls.SetChildIndex(Me.iugDetail, 0)
- Me.Controls.SetChildIndex(Me.btnDel, 0)
- Me.Controls.SetChildIndex(Me.btnDAdd, 0)
- Me.Controls.SetChildIndex(Me.btnAdd, 0)
- Me.Controls.SetChildIndex(Me.btnDEdit, 0)
- Me.Controls.SetChildIndex(Me.iugSubcontractor, 0)
- Me.Controls.SetChildIndex(Me.btnDDel, 0)
- Me.Controls.SetChildIndex(Me.btnCopy, 0)
- Me.Controls.SetChildIndex(Me.btnDCopy, 0)
- Me.Controls.SetChildIndex(Me.btnEMail, 0)
- Me.Controls.SetChildIndex(Me.btnApprove, 0)
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractor_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- Call funiMESUltraGridIni() 'Grid初始設定
-
- '//取出資料
- Call funLoadSubcontractor()
-
- SetIssueState(Issue.Unfrozen) '預設在Unforzen上
- SetSearchFieldName(New String() {"SubcontractorNo_21676", "SubcontractorNaME"}) '設置搜尋欄位
-
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractor_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- If Not dsENT Is Nothing Then dsENT.Dispose()
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
- Protected Overrides Sub rdoIssue_CheckedChanged(sender As Object, e As EventArgs)
- If IsNothing(dsENT) Then Exit Sub
-
- Select Case GetIssueState()
- Case Issue.Unfrozen
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=0"
- Case Issue.Pending
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=1"
- Case Issue.Active
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=2"
- Case Issue.Unused
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=-1"
- End Select
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
- Call funShowActiveDetail()
- End Sub
-
- Protected Overrides Sub Finalize()
- MyBase.Finalize()
- End Sub
-
- Private Sub btnAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAdd.Click
-
- Dim fSubcontractorDef As New frmSubcontractorDef
-
- fSubcontractorDef.DefMode = 0
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo_21676 = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo_21676", SubcontractorNo_21676)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End Sub
-
- Private Sub btnEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEdit.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo_21676 = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString, "'", "''") & "'")
-
- '核准狀態為"Unfrozen"者才可修改
-
- If Rows(0).Item("IssueState") <> 0 Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-202202", "[%NOT ALLOWED TO EDIT%]"), MsgBoxStyle.Exclamation, Me.Text)
- Exit Sub
- End If
-
- Dim fSubcontractorDef As New frmSubcontractorDef
- fSubcontractorDef.DefMode = 1
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo_21676 = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo_21676", SubcontractorNo_21676)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDel.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Or intIssueState = -1 Or intIssueState = 2 Then '狀態為Unforzen或Unused時直接刪除
-
- strParameter = CombineXMLParameter("SubcontractorNo_21676", "SubcontractorNo_21676", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo_21676").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", CInput(intIssueState), "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOWED TO delete%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCopy.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo_21676 = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorDef As New frmSubcontractorDef
- fSubcontractorDef.DefMode = 2
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo_21676 = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo_21676", SubcontractorNo_21676)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnApprove_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnApprove.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100002", "[%ARE YOU SURE TO APPROVE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Then
- strParameter = CombineXMLParameter("SubcontractorNo_21676", "SubcontractorNo_21676", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo_21676").Value.ToString), "")
- strParameter += CombineXMLParameter("issuestate", "IssueState", "String", intIssueState, "")
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.ApproveSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.ApproveSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.ApproveSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Approve failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOW TO APPROVE%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDAdd.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
-
- 'Dim Rows As DataRow()
- Dim fSubcontractorContDef As New frmSubcontractorContDef
-
- fSubcontractorContDef.DefMode = 0
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- End If
- End Sub
-
- Private Sub btnDEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDEdit.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo_21676 = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmSubcontractorContDef
- fSubcontractorContDef.DefMode = 1
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnDDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDDel.Click
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
-
- Cursor.Current = Cursors.WaitCursor
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugDetail.iMESUltraGrid.Selected.Rows.Count - 1
- strParameter = CombineXMLParameter("SubcontractorNo_21676", "SubcontractorNo_21676", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("ContactorName", "ContactorName", "String", CInput(Me.iugDetail.iMESUltraGrid.Selected.Rows(i).Cells("ContactorName").Value.ToString), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractorCont", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
-
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDCopy.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo_21676 = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmSubcontractorContDef
- fSubcontractorContDef.DefMode = 2
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEMail.Click
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
- Dim proMail As New System.Diagnostics.Process
- Dim strAccount As String
-
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo_21676 = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- strAccount = "mailto:" & Rows(0).Item("EMail").ToString
- proMail.Start(strAccount)
-
- End If
-
- End Sub
-
- Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnQuery_Click(sender As Object, e As EventArgs)
- Cursor.Current = Cursors.WaitCursor
-
- funLoadSubcontractor()
-
- Cursor.Current = Cursors.Default
- End Sub
-
-#Region "Ultra Grid"
-
- Private Sub iugSubcontractor_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugSubcontractor.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo_21676")
- .Header.Caption = "SubcontractorNo_21676"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("SubcontractorName")
- .Header.Caption = "SubcontractorName"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("IssueState")
- .Header.Caption = "IssueState"
- .Width = 114
- .Hidden = True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 7
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
- Private Sub iugSubcontractor_iMESUltraGrid_AfterRowActivate(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles iugSubcontractor.iMESUltraGrid_AfterRowActivate
-
- 'IsGroupByRow不做任何處理
- If Not iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
- Else
- Exit Sub
- End If
-
- End Sub
-
- Private Sub iugDetail_iMESUltraGrid_InitializeLayOut(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugDetail.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo_21676")
- .Header.Caption = "SubcontractorNo_21676"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("ContactorName")
- .Header.Caption = "ContactorName"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("TelNo")
- .Header.Caption = "TelNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("FaxNo")
- .Header.Caption = "FaxNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("Title")
- .Header.Caption = "Title"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("Address")
- .Header.Caption = "Address"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("EMail")
- .Header.Caption = "EMail"
- .Width = 150
- .Hidden = False
- .CellAppearance.ForeColor = System.Drawing.Color.Blue
- .CellAppearance.FontData.Underline = DefaultableBoolean.True
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 200
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 7
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 8
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 9
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 10
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 11
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
-#End Region
-
-#Region "Load Function"
-
- '//取出tblENTSubcontractor 外包商資料
-
- Private Sub funLoadSubcontractor()
-
- '先判斷是否dataset中已有ENTSubcontractor之datatable,若有,需先remove否則會有錯誤
- If Not IsNothing(dsENT.Tables(tblENTSubcontractor)) Then
- dsENT.Tables.Remove(tblENTSubcontractor)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- '加上IssueState要求取出所有資料
- strParameter = CombineXMLParameter("issuestate", "IssueState", "Integer", defInteger, "")
- '加上查詢條件 cboSearchFieldName,txtSearchFieldValue
- strParameter += CombineXMLQueryCondition()
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.LoadSubcontractor", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
-
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractor = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractor").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
-
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractor").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractor").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- strFilter = ""
- Select Case GetIssueState()
- Case Issue.Unfrozen
- strFilter = FilterByInteger(strFilter, "IssueState", 0)
- Case Issue.Pending
- strFilter = FilterByInteger(strFilter, "IssueState", 1)
- Case Issue.Active
- strFilter = FilterByInteger(strFilter, "IssueState", 2)
- Case Issue.Unused
- strFilter = FilterByInteger(strFilter, "IssueState", -1)
- End Select
-
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = strFilter
- dsENT.Tables(tblENTSubcontractor).DefaultView.Sort = "SubcontractorNo_21676"
-
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit Sub
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- '//取出tblENTSubcontractorCont聯絡人資料
-
- Private Sub funLoadSubcontractorCont(ByRef SubcontractorNo_21676 As String)
-
- If Not IsNothing(dsENT.Tables(tblENTSubcontractorCont)) Then
- dsENT.Tables.Remove(tblENTSubcontractorCont)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("SubcontractorNo_21676", "SubcontractorNo_21676", "String", SubcontractorNo_21676, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.LoadSubcontractorCont", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractorCont = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractorcont").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- Me.iugDetail.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractorCont).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Cont Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- Private Sub funShowActiveDetail()
-
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.DataSource = Nothing
- Else
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
- End If
-
- End Sub
-
- Private Sub funiMESUltraGridIni()
-
- 'iugSubcontractor 初始設定
- With Me.iugSubcontractor.iMESUltraGrid
- .Text = ""
- .DisplayLayout.GroupByBox.Hidden = True
- .DisplayLayout.UseFixedHeaders = False
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugSubcontractor.UserNo = gUserNo
-
- 'iugDetail 初始設定
- With Me.iugDetail.iMESUltraGrid.DisplayLayout
- .GroupByBox.Hidden = True
- .Override.ExpansionIndicator = ShowExpansionIndicator.Default
- .ViewStyle = ViewStyle.SingleBand
- .RowConnectorStyle = RowConnectorStyle.Default
-
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugDetail.UserNo = gUserNo
-
- End Sub
-
- Private Sub iugDetail_Load(sender As Object, e As EventArgs) Handles iugDetail.Load
-
- End Sub
-
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef.resx b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef.vb b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef.vb
deleted file mode 100644
index c489735..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef.vb
+++ /dev/null
@@ -1,656 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorContDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
-
- Public SubcontractorNo As String = defString
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblAddress As System.Windows.Forms.Label
- Friend WithEvents lblEMail As System.Windows.Forms.Label
- Friend WithEvents lblTitle As System.Windows.Forms.Label
- Friend WithEvents lblFaxNo As System.Windows.Forms.Label
- Friend WithEvents lblTelNo As System.Windows.Forms.Label
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblContactorName As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorContData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtContactorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtFaxNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTelNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtEMail As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTitle As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtAddress As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorContData = New System.Windows.Forms.GroupBox()
- Me.txtAddress = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtEMail = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTitle = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtFaxNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblAddress = New System.Windows.Forms.Label()
- Me.lblEMail = New System.Windows.Forms.Label()
- Me.lblTitle = New System.Windows.Forms.Label()
- Me.lblFaxNo = New System.Windows.Forms.Label()
- Me.lblTelNo = New System.Windows.Forms.Label()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblContactorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtContactorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTelNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorContData.SuspendLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 322)
- Me.gbxBasisData.Size = New System.Drawing.Size(472, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(396, 401)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(208, 401)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(302, 401)
- '
- 'gbxSubcontractorContData
- '
- Me.gbxSubcontractorContData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTelNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTelNo)
- Me.gbxSubcontractorContData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorContData.Location = New System.Drawing.Point(15, 8)
- Me.gbxSubcontractorContData.Name = "gbxSubcontractorContData"
- Me.gbxSubcontractorContData.Size = New System.Drawing.Size(469, 306)
- Me.gbxSubcontractorContData.TabIndex = 0
- Me.gbxSubcontractorContData.TabStop = False
- Me.gbxSubcontractorContData.Text = "ENT Subcontractor Contactor Data"
- '
- 'txtAddress
- '
- Me.txtAddress.Location = New System.Drawing.Point(120, 152)
- Me.txtAddress.Name = "txtAddress"
- Me.txtAddress.Size = New System.Drawing.Size(336, 22)
- Me.txtAddress.TabIndex = 13
- '
- 'txtEMail
- '
- Me.txtEMail.Location = New System.Drawing.Point(320, 120)
- Me.txtEMail.Name = "txtEMail"
- Me.txtEMail.Size = New System.Drawing.Size(136, 22)
- Me.txtEMail.TabIndex = 11
- '
- 'txtTitle
- '
- Me.txtTitle.Location = New System.Drawing.Point(120, 120)
- Me.txtTitle.Name = "txtTitle"
- Me.txtTitle.Size = New System.Drawing.Size(114, 22)
- Me.txtTitle.TabIndex = 9
- '
- 'txtFaxNo
- '
- Me.txtFaxNo.Location = New System.Drawing.Point(320, 88)
- Me.txtFaxNo.Name = "txtFaxNo"
- Me.txtFaxNo.Size = New System.Drawing.Size(136, 22)
- Me.txtFaxNo.TabIndex = 7
- '
- 'lblAddress
- '
- Me.lblAddress.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblAddress.Location = New System.Drawing.Point(24, 154)
- Me.lblAddress.Name = "lblAddress"
- Me.lblAddress.Size = New System.Drawing.Size(86, 14)
- Me.lblAddress.TabIndex = 12
- Me.lblAddress.Text = "Address"
- Me.lblAddress.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblEMail
- '
- Me.lblEMail.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblEMail.Location = New System.Drawing.Point(248, 123)
- Me.lblEMail.Name = "lblEMail"
- Me.lblEMail.Size = New System.Drawing.Size(64, 14)
- Me.lblEMail.TabIndex = 10
- Me.lblEMail.Text = "EMail"
- Me.lblEMail.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTitle
- '
- Me.lblTitle.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTitle.Location = New System.Drawing.Point(24, 121)
- Me.lblTitle.Name = "lblTitle"
- Me.lblTitle.Size = New System.Drawing.Size(86, 14)
- Me.lblTitle.TabIndex = 8
- Me.lblTitle.Text = "Title"
- Me.lblTitle.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblFaxNo
- '
- Me.lblFaxNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblFaxNo.Location = New System.Drawing.Point(248, 90)
- Me.lblFaxNo.Name = "lblFaxNo"
- Me.lblFaxNo.Size = New System.Drawing.Size(64, 14)
- Me.lblFaxNo.TabIndex = 6
- Me.lblFaxNo.Text = "FaxNo"
- Me.lblFaxNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTelNo
- '
- Me.lblTelNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTelNo.Location = New System.Drawing.Point(24, 90)
- Me.lblTelNo.Name = "lblTelNo"
- Me.lblTelNo.Size = New System.Drawing.Size(86, 14)
- Me.lblTelNo.TabIndex = 4
- Me.lblTelNo.Text = "TelNo"
- Me.lblTelNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(120, 184)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(336, 108)
- Me.txtDescription.TabIndex = 15
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(24, 186)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(86, 14)
- Me.lblDescription.TabIndex = 14
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(14, 29)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 14)
- Me.lblSubcontractorNo.TabIndex = 0
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblContactorName
- '
- Me.lblContactorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblContactorName.Location = New System.Drawing.Point(24, 59)
- Me.lblContactorName.Name = "lblContactorName"
- Me.lblContactorName.Size = New System.Drawing.Size(86, 14)
- Me.lblContactorName.TabIndex = 2
- Me.lblContactorName.Text = "Contactor Name"
- Me.lblContactorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(120, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.ReadOnly = True
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(114, 22)
- Me.txtSubcontractorNo.TabIndex = 1
- Me.txtSubcontractorNo.TabStop = False
- '
- 'txtContactorName
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Appearance = Appearance1
- Me.txtContactorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Location = New System.Drawing.Point(120, 56)
- Me.txtContactorName.Name = "txtContactorName"
- Me.txtContactorName.Size = New System.Drawing.Size(160, 22)
- Me.txtContactorName.TabIndex = 3
- '
- 'txtTelNo
- '
- Me.txtTelNo.Location = New System.Drawing.Point(120, 88)
- Me.txtTelNo.Name = "txtTelNo"
- Me.txtTelNo.Size = New System.Drawing.Size(114, 22)
- Me.txtTelNo.TabIndex = 5
- '
- 'frmSubcontractorContDef
- '
- Me.ClientSize = New System.Drawing.Size(496, 446)
- Me.Controls.Add(Me.gbxSubcontractorContData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorContDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Contactor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorContData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorContData.ResumeLayout(False)
- Me.gbxSubcontractorContData.PerformLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorContDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據()
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
- If DefMode = 0 Or DefMode = 2 Then
- SetCreateDate(Now)
- SetCreator(gUserNo)
- End If
- If Not EditDataRow Is Nothing Then '修改 or Copy
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtContactorName.Text = EditDataRow.Item("ContactorName").ToString
- txtTelNo.Text = EditDataRow.Item("TelNo").ToString
- txtFaxNo.Text = EditDataRow.Item("FaxNo").ToString
- txtTitle.Text = EditDataRow.Item("Title").ToString
- txtAddress.Text = EditDataRow.Item("Address").ToString
- txtEMail.Text = EditDataRow.Item("EMail").ToString
- 'txtDescription是RichTextBox(Control, 因為TextBox無法正常顯示多行換行的資料)
- txtDescription.Text = EditDataRow.Item("Description").ToString
- If DefMode = 1 Then
- If (Not IsDBNull(EditDataRow("Creator"))) Then
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetCreator(EditDataRow.Item("Creator").ToString)
- End If
- End If
- End If
-
- If DefMode = 0 Then 'Add
- txtSubcontractorNo.Text = SubcontractorNo
- SetCreateDate(Now)
- SetCreator(gUserNo)
- ElseIf DefMode = 1 Then 'Edit
- txtContactorName.ReadOnly = True
- SetReviseDate(Now)
- SetReviser(gUserNo)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorContDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
-
- txtEMail.Text = ""
- btnApplyEnabled = False
- Cursor.Current = Cursors.Default
-
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtContactorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Click
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Enter
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtContactorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtContactorName_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Leave
- If txtContactorName.Text <> "" And txtEMail.Text = "" Then
- txtEMail.Text = txtContactorName.Text & "@"
- End If
- txtContactorName.Text = UCase(txtContactorName.Text)
- End Sub
-
- Private Sub txtContactorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTelNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Click
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Enter
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTelNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTelNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtFaxNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Click
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Enter
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtFaxNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtFaxNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTitle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Click
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Enter
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTitle.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTitle_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Click
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Enter
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtEMail.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtEMail_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtAddress_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Click
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Enter
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtAddress.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtAddress_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtDescription.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查()
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
- If txtContactorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%ContactorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtContactorName.Focus()
- Exit Function
- End If
-
- '******************************************************************************
- '2.寫回資料庫()
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("contactorname", "ContactorName", "String", CInput(txtContactorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("telno", "TelNo", "String", txtTelNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("faxno", "FaxNo", "String", txtFaxNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("title", "Title", "String", CInput(txtTitle.Text), "")
- strParameter = strParameter & CombineXMLParameter("address", "Address", "String", CInput(txtAddress.Text), "")
- strParameter = strParameter & CombineXMLParameter("email", "EMail", "String", CInput(txtEMail.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.AddSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.AddSubcontractorCont", InXml)
-
- Else 'Edit
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.EditSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.EditSubcontractorCont", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtContactorName.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Contactor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-#End Region
-
-
- Private Sub frmSubcontractorContDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-End Class
-
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef_21676.resx b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef_21676.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef_21676.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef_21676.vb b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef_21676.vb
deleted file mode 100644
index 1cf01db..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorContDef_21676.vb
+++ /dev/null
@@ -1,656 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorContDef_21676
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
-
- Public SubcontractorNo_21676 As String = defString
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblAddress As System.Windows.Forms.Label
- Friend WithEvents lblEMail As System.Windows.Forms.Label
- Friend WithEvents lblTitle As System.Windows.Forms.Label
- Friend WithEvents lblFaxNo As System.Windows.Forms.Label
- Friend WithEvents lblTelNo As System.Windows.Forms.Label
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblContactorName As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorContData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtContactorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtFaxNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTelNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtEMail As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTitle As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtAddress As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorContData = New System.Windows.Forms.GroupBox()
- Me.txtAddress = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtEMail = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTitle = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtFaxNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblAddress = New System.Windows.Forms.Label()
- Me.lblEMail = New System.Windows.Forms.Label()
- Me.lblTitle = New System.Windows.Forms.Label()
- Me.lblFaxNo = New System.Windows.Forms.Label()
- Me.lblTelNo = New System.Windows.Forms.Label()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblContactorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtContactorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTelNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorContData.SuspendLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 322)
- Me.gbxBasisData.Size = New System.Drawing.Size(472, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(396, 401)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(208, 401)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(302, 401)
- '
- 'gbxSubcontractorContData
- '
- Me.gbxSubcontractorContData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTelNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTelNo)
- Me.gbxSubcontractorContData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorContData.Location = New System.Drawing.Point(15, 8)
- Me.gbxSubcontractorContData.Name = "gbxSubcontractorContData"
- Me.gbxSubcontractorContData.Size = New System.Drawing.Size(469, 306)
- Me.gbxSubcontractorContData.TabIndex = 0
- Me.gbxSubcontractorContData.TabStop = False
- Me.gbxSubcontractorContData.Text = "ENT Subcontractor Contactor Data"
- '
- 'txtAddress
- '
- Me.txtAddress.Location = New System.Drawing.Point(120, 152)
- Me.txtAddress.Name = "txtAddress"
- Me.txtAddress.Size = New System.Drawing.Size(336, 22)
- Me.txtAddress.TabIndex = 13
- '
- 'txtEMail
- '
- Me.txtEMail.Location = New System.Drawing.Point(320, 120)
- Me.txtEMail.Name = "txtEMail"
- Me.txtEMail.Size = New System.Drawing.Size(136, 22)
- Me.txtEMail.TabIndex = 11
- '
- 'txtTitle
- '
- Me.txtTitle.Location = New System.Drawing.Point(120, 120)
- Me.txtTitle.Name = "txtTitle"
- Me.txtTitle.Size = New System.Drawing.Size(114, 22)
- Me.txtTitle.TabIndex = 9
- '
- 'txtFaxNo
- '
- Me.txtFaxNo.Location = New System.Drawing.Point(320, 88)
- Me.txtFaxNo.Name = "txtFaxNo"
- Me.txtFaxNo.Size = New System.Drawing.Size(136, 22)
- Me.txtFaxNo.TabIndex = 7
- '
- 'lblAddress
- '
- Me.lblAddress.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblAddress.Location = New System.Drawing.Point(24, 154)
- Me.lblAddress.Name = "lblAddress"
- Me.lblAddress.Size = New System.Drawing.Size(86, 14)
- Me.lblAddress.TabIndex = 12
- Me.lblAddress.Text = "Address"
- Me.lblAddress.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblEMail
- '
- Me.lblEMail.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblEMail.Location = New System.Drawing.Point(248, 123)
- Me.lblEMail.Name = "lblEMail"
- Me.lblEMail.Size = New System.Drawing.Size(64, 14)
- Me.lblEMail.TabIndex = 10
- Me.lblEMail.Text = "EMail"
- Me.lblEMail.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTitle
- '
- Me.lblTitle.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTitle.Location = New System.Drawing.Point(24, 121)
- Me.lblTitle.Name = "lblTitle"
- Me.lblTitle.Size = New System.Drawing.Size(86, 14)
- Me.lblTitle.TabIndex = 8
- Me.lblTitle.Text = "Title"
- Me.lblTitle.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblFaxNo
- '
- Me.lblFaxNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblFaxNo.Location = New System.Drawing.Point(248, 90)
- Me.lblFaxNo.Name = "lblFaxNo"
- Me.lblFaxNo.Size = New System.Drawing.Size(64, 14)
- Me.lblFaxNo.TabIndex = 6
- Me.lblFaxNo.Text = "FaxNo"
- Me.lblFaxNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTelNo
- '
- Me.lblTelNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTelNo.Location = New System.Drawing.Point(24, 90)
- Me.lblTelNo.Name = "lblTelNo"
- Me.lblTelNo.Size = New System.Drawing.Size(86, 14)
- Me.lblTelNo.TabIndex = 4
- Me.lblTelNo.Text = "TelNo"
- Me.lblTelNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(120, 184)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(336, 108)
- Me.txtDescription.TabIndex = 15
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(24, 186)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(86, 14)
- Me.lblDescription.TabIndex = 14
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(14, 29)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 14)
- Me.lblSubcontractorNo.TabIndex = 0
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblContactorName
- '
- Me.lblContactorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblContactorName.Location = New System.Drawing.Point(24, 59)
- Me.lblContactorName.Name = "lblContactorName"
- Me.lblContactorName.Size = New System.Drawing.Size(86, 14)
- Me.lblContactorName.TabIndex = 2
- Me.lblContactorName.Text = "Contactor Name"
- Me.lblContactorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(120, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.ReadOnly = True
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(114, 22)
- Me.txtSubcontractorNo.TabIndex = 1
- Me.txtSubcontractorNo.TabStop = False
- '
- 'txtContactorName
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Appearance = Appearance1
- Me.txtContactorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Location = New System.Drawing.Point(120, 56)
- Me.txtContactorName.Name = "txtContactorName"
- Me.txtContactorName.Size = New System.Drawing.Size(160, 22)
- Me.txtContactorName.TabIndex = 3
- '
- 'txtTelNo
- '
- Me.txtTelNo.Location = New System.Drawing.Point(120, 88)
- Me.txtTelNo.Name = "txtTelNo"
- Me.txtTelNo.Size = New System.Drawing.Size(114, 22)
- Me.txtTelNo.TabIndex = 5
- '
- 'frmSubcontractorContDef
- '
- Me.ClientSize = New System.Drawing.Size(496, 446)
- Me.Controls.Add(Me.gbxSubcontractorContData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorContDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Contactor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorContData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorContData.ResumeLayout(False)
- Me.gbxSubcontractorContData.PerformLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorContDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據()
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
- If DefMode = 0 Or DefMode = 2 Then
- SetCreateDate(Now)
- SetCreator(gUserNo)
- End If
- If Not EditDataRow Is Nothing Then '修改 or Copy
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo_21676").ToString
- txtContactorName.Text = EditDataRow.Item("ContactorName_21676").ToString
- txtTelNo.Text = EditDataRow.Item("TelNo_21676").ToString
- txtFaxNo.Text = EditDataRow.Item("FaxNo_21676").ToString
- txtTitle.Text = EditDataRow.Item("Title_21676").ToString
- txtAddress.Text = EditDataRow.Item("Address_21676").ToString
- txtEMail.Text = EditDataRow.Item("EMail_21676").ToString
- 'txtDescription是RichTextBox(Control, 因為TextBox無法正常顯示多行換行的資料)
- txtDescription.Text = EditDataRow.Item("Description_21676").ToString
- If DefMode = 1 Then
- If (Not IsDBNull(EditDataRow("Creator"))) Then
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetCreator(EditDataRow.Item("Creator").ToString)
- End If
- End If
- End If
-
- If DefMode = 0 Then 'Add
- txtSubcontractorNo.Text = SubcontractorNo_21676
- SetCreateDate(Now)
- SetCreator(gUserNo)
- ElseIf DefMode = 1 Then 'Edit
- txtContactorName.ReadOnly = True
- SetReviseDate(Now)
- SetReviser(gUserNo)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorContDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
-
- txtEMail.Text = ""
- btnApplyEnabled = False
- Cursor.Current = Cursors.Default
-
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtContactorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Click
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Enter
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtContactorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtContactorName_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Leave
- If txtContactorName.Text <> "" And txtEMail.Text = "" Then
- txtEMail.Text = txtContactorName.Text & "@"
- End If
- txtContactorName.Text = UCase(txtContactorName.Text)
- End Sub
-
- Private Sub txtContactorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTelNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Click
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Enter
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTelNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTelNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtFaxNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Click
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Enter
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtFaxNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtFaxNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTitle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Click
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Enter
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTitle.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTitle_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Click
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Enter
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtEMail.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtEMail_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtAddress_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Click
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Enter
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtAddress.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtAddress_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtDescription.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查()
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo_21676%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
- If txtContactorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%ContactorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtContactorName.Focus()
- Exit Function
- End If
-
- '******************************************************************************
- '2.寫回資料庫()
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("SubcontractorNo_21676", "SubcontractorNo_21676", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("contactorname_21676", "ContactorName_21676", "String", CInput(txtContactorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("telno_21676", "TelNo_21676", "String_21676", txtTelNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("faxno_21676", "FaxNo_21676", "String", txtFaxNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("title_21676", "Title_21676", "String", CInput(txtTitle.Text), "")
- strParameter = strParameter & CombineXMLParameter("address_21676", "Address_21676", "String", CInput(txtAddress.Text), "")
- strParameter = strParameter & CombineXMLParameter("email_21676", "EMail_21676", "String", CInput(txtEMail.Text), "")
- strParameter = strParameter & CombineXMLParameter("description_21676", "Description_21676", "String", CInput(txtDescription.Text), "")
-
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.AddSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT_21676.AddSubcontractorCont", InXml)
-
- Else 'Edit
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.EditSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT_21676.EditSubcontractorCont", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtContactorName.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Contactor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-#End Region
-
-
- Private Sub frmSubcontractorContDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-End Class
-
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef.resx b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef.vb b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef.vb
deleted file mode 100644
index ff97a9a..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef.vb
+++ /dev/null
@@ -1,421 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorName As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtSubcontractorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance2 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorData = New System.Windows.Forms.GroupBox()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblSubcontractorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtSubcontractorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorData.SuspendLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 185)
- Me.gbxBasisData.Size = New System.Drawing.Size(479, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(403, 264)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(215, 264)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(309, 264)
- '
- 'gbxSubcontractorData
- '
- Me.gbxSubcontractorData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorName)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorName)
- Me.gbxSubcontractorData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorData.Location = New System.Drawing.Point(12, 8)
- Me.gbxSubcontractorData.Name = "gbxSubcontractorData"
- Me.gbxSubcontractorData.Size = New System.Drawing.Size(479, 169)
- Me.gbxSubcontractorData.TabIndex = 7
- Me.gbxSubcontractorData.TabStop = False
- Me.gbxSubcontractorData.Text = "Subcontractor Data"
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(128, 86)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(334, 67)
- Me.txtDescription.TabIndex = 2
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(56, 88)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(64, 14)
- Me.lblDescription.TabIndex = 13
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(24, 24)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 32)
- Me.lblSubcontractorNo.TabIndex = 5
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorName
- '
- Me.lblSubcontractorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorName.Location = New System.Drawing.Point(8, 56)
- Me.lblSubcontractorName.Name = "lblSubcontractorName"
- Me.lblSubcontractorName.Size = New System.Drawing.Size(112, 32)
- Me.lblSubcontractorName.TabIndex = 9
- Me.lblSubcontractorName.Text = "Subcontractor Name"
- Me.lblSubcontractorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Appearance = Appearance1
- Me.txtSubcontractorNo.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(128, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(152, 22)
- Me.txtSubcontractorNo.TabIndex = 0
- '
- 'txtSubcontractorName
- '
- Appearance2.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Appearance = Appearance2
- Me.txtSubcontractorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Location = New System.Drawing.Point(128, 55)
- Me.txtSubcontractorName.Name = "txtSubcontractorName"
- Me.txtSubcontractorName.Size = New System.Drawing.Size(334, 22)
- Me.txtSubcontractorName.TabIndex = 1
- '
- 'frmSubcontractorDef
- '
- Me.ClientSize = New System.Drawing.Size(503, 309)
- Me.Controls.Add(Me.gbxSubcontractorData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorData.ResumeLayout(False)
- Me.gbxSubcontractorData.PerformLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- If Not EditDataRow Is Nothing Then
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtSubcontractorName.Text = EditDataRow.Item("SubcontractorName").ToString
- 'txtDescription是RichTextBox Control,因為TextBox無法正常顯示多行換行的資料
- txtDescription.Text = EditDataRow.Item("Description").ToString
- End If
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- SetCreator(gUserNo)
- SetCreateDate(Now)
- ElseIf DefMode = 1 Then 'Edit
- txtSubcontractorNo.ReadOnly = True
- SetCreator(EditDataRow.Item("Creator").ToString)
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetReviser(gUserNo)
- SetReviseDate(Now)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
-
- End If
-
- Cursor.Current = Cursors.Default
- btnApplyEnabled = False
-
- End Sub
-
- Private Sub frmSubcontractorDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Leave
- txtSubcontractorNo.Text = UCase(txtSubcontractorNo.Text)
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtSubcontractorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Click
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Enter
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
-
- If txtSubcontractorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorName.Focus()
- Exit Function
- End If
-
- '2.
- '******************************************************************************
- '寫回資料庫
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("subcontractorname", "SubcontractorName", "String", CInput(txtSubcontractorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter = strParameter & CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("createdate", "CreateDate", "DateTime", Format(Now, "yyyy/MM/dd HH:mm:ss"), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.AddSubcontractor(InXml)
- OutXml = InvokeSrv("wsENT.AddSubcontractor", InXml)
-
- Else
- '修改
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", EditDataRow.Item("IssueState").ToString, "")
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.EditSubcontractor(InXml)
- OutXml = InvokeSrv("wsENT.EditSubcontractor", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtSubcontractorNo.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef_21676.resx b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef_21676.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef_21676.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef_21676.vb b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef_21676.vb
deleted file mode 100644
index 52abcc8..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractorDef_21676.vb
+++ /dev/null
@@ -1,421 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorDef_21676
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorName As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtSubcontractorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance2 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorData = New System.Windows.Forms.GroupBox()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblSubcontractorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtSubcontractorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorData.SuspendLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 185)
- Me.gbxBasisData.Size = New System.Drawing.Size(479, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(403, 264)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(215, 264)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(309, 264)
- '
- 'gbxSubcontractorData
- '
- Me.gbxSubcontractorData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorName)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorName)
- Me.gbxSubcontractorData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorData.Location = New System.Drawing.Point(12, 8)
- Me.gbxSubcontractorData.Name = "gbxSubcontractorData"
- Me.gbxSubcontractorData.Size = New System.Drawing.Size(479, 169)
- Me.gbxSubcontractorData.TabIndex = 7
- Me.gbxSubcontractorData.TabStop = False
- Me.gbxSubcontractorData.Text = "Subcontractor Data"
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(128, 86)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(334, 67)
- Me.txtDescription.TabIndex = 2
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(56, 88)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(64, 14)
- Me.lblDescription.TabIndex = 13
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(24, 24)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 32)
- Me.lblSubcontractorNo.TabIndex = 5
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorName
- '
- Me.lblSubcontractorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorName.Location = New System.Drawing.Point(8, 56)
- Me.lblSubcontractorName.Name = "lblSubcontractorName"
- Me.lblSubcontractorName.Size = New System.Drawing.Size(112, 32)
- Me.lblSubcontractorName.TabIndex = 9
- Me.lblSubcontractorName.Text = "Subcontractor Name"
- Me.lblSubcontractorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Appearance = Appearance1
- Me.txtSubcontractorNo.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(128, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(152, 22)
- Me.txtSubcontractorNo.TabIndex = 0
- '
- 'txtSubcontractorName
- '
- Appearance2.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Appearance = Appearance2
- Me.txtSubcontractorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Location = New System.Drawing.Point(128, 55)
- Me.txtSubcontractorName.Name = "txtSubcontractorName"
- Me.txtSubcontractorName.Size = New System.Drawing.Size(334, 22)
- Me.txtSubcontractorName.TabIndex = 1
- '
- 'frmSubcontractorDef
- '
- Me.ClientSize = New System.Drawing.Size(503, 309)
- Me.Controls.Add(Me.gbxSubcontractorData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorDef_21676"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorData.ResumeLayout(False)
- Me.gbxSubcontractorData.PerformLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- If Not EditDataRow Is Nothing Then
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo_21676").ToString
- txtSubcontractorName.Text = EditDataRow.Item("SubcontractorName_21676").ToString
- 'txtDescription是RichTextBox Control,因為TextBox無法正常顯示多行換行的資料
- txtDescription.Text = EditDataRow.Item("Description_21676").ToString
- End If
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- SetCreator(gUserNo)
- SetCreateDate(Now)
- ElseIf DefMode = 1 Then 'Edit
- txtSubcontractorNo.ReadOnly = True
- SetCreator(EditDataRow.Item("Creator").ToString)
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetReviser(gUserNo)
- SetReviseDate(Now)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
-
- End If
-
- Cursor.Current = Cursors.Default
- btnApplyEnabled = False
-
- End Sub
-
- Private Sub frmSubcontractorDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Leave
- txtSubcontractorNo.Text = UCase(txtSubcontractorNo.Text)
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtSubcontractorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Click
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Enter
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%subcontractorno_21676%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
-
- If txtSubcontractorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorName_21676%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorName.Focus()
- Exit Function
- End If
-
- '2.
- '******************************************************************************
- '寫回資料庫
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno_21676", "SubcontractorNo_21676", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("subcontractorname_21676", "SubcontractorName_21676", "String", CInput(txtSubcontractorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("description_21676", "Description_21676", "String", CInput(txtDescription.Text), "")
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter = strParameter & CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("createdate", "CreateDate", "DateTime", Format(Now, "yyyy/MM/dd HH:mm:ss"), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.AddSubcontractor(InXml)
- OutXml = InvokeSrv("SXS.wsENT_21676.AddSubcontractor", InXml)
-
- Else
- '修改
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", EditDataRow.Item("IssueState").ToString, "")
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.EditSubcontractor(InXml)
- OutXml = InvokeSrv("SXS.wsENT_21676.EditSubcontractor", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtSubcontractorNo.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor_21676.resx b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor_21676.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor_21676.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor_21676.vb b/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor_21676.vb
deleted file mode 100644
index cbb9c8e..0000000
--- a/SRC/MESWin/SYS3/ET_Subcontractor_21676/frmSubcontractor_21676.vb
+++ /dev/null
@@ -1,1137 +0,0 @@
-Imports iMESExceptionManager
-
-Imports Infragistics.Win
-Imports Infragistics.Win.UltraWinGrid
-Public Class frmSubcontractor_21676
-
- Inherits COM_Kit.frmBasisTemplat
-
- Public PrivFunNo As String = defString
-
- '//WS相關變數
- ' 2016 YF, Dim wsENT_21676 As New wsENT_21676.wsENT_21676 '宣告Web Service物件?
- Dim tmpStringReader As System.IO.StringReader '將字串轉換成可讀入DataSet的物件
- Dim XmlData As String '儲存取回之資料
- Dim XmlSchema As String '儲存取回之資料結構
- Dim InXml As String '儲存呼叫Web Service的傳入參數(Request字串)
- Dim OutXml As String '儲存Web Service的傳回值(Response字串)
- Dim strIdentity As String '儲存Identity XML字串?
- Dim strParameter As String '儲存Parameter XML字串
-
- '//資料表相關變數
-
- Dim dsENT As New DataSet '資料集:儲存取回之資料?
-
- Dim tblENTSubcontractor_21676 As String '儲存取回資料表的名稱(master)?
- Dim tblENTSubcontractorCont_21676 As String '明細資料表名稱(detail)
- Dim strFilter As String 'Filter string及列印的過濾條件
-
- '//其他共用變數
- Dim SubcontractorNo_21676 As String 'for Gird to Focus
- Dim ContactorName_21676 As String 'for DetailGrid to Focus
- Dim ugrRow As Infragistics.Win.UltraWinGrid.UltraGridRow
- Friend WithEvents btnAdd As Misc.UltraButton
- Friend WithEvents btnEdit As Misc.UltraButton
- Friend WithEvents btnDel As Misc.UltraButton
- Friend WithEvents btnCopy As Misc.UltraButton
- Friend WithEvents btnApprove As Misc.UltraButton
- Friend WithEvents iugSubcontractor As iMESUltraGrid.iMESUltraGridControl
- Dim i As Integer
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.Container
- Friend WithEvents iugDetail As iMESUltraGrid.iMESUltraGridControl
- Friend WithEvents btnClose As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnEMail As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDCopy As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDDel As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDEdit As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDAdd As Infragistics.Win.Misc.UltraButton
- Private Sub InitializeComponent()
- Me.btnClose = New Infragistics.Win.Misc.UltraButton()
- Me.btnEMail = New Infragistics.Win.Misc.UltraButton()
- Me.btnDCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnDDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnDEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDAdd = New Infragistics.Win.Misc.UltraButton()
- Me.iugDetail = New iMESUltraGrid.iMESUltraGridControl()
- Me.btnAdd = New Infragistics.Win.Misc.UltraButton()
- Me.btnEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnApprove = New Infragistics.Win.Misc.UltraButton()
- Me.iugSubcontractor = New iMESUltraGrid.iMESUltraGridControl()
- Me.SuspendLayout()
- '
- 'btnClose
- '
- Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnClose.Location = New System.Drawing.Point(1002, 616)
- Me.btnClose.Name = "btnClose"
- Me.btnClose.Size = New System.Drawing.Size(88, 32)
- Me.btnClose.TabIndex = 18
- Me.btnClose.Text = "Close (&X)"
- '
- 'btnEMail
- '
- Me.btnEMail.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEMail.Location = New System.Drawing.Point(1002, 429)
- Me.btnEMail.Name = "btnEMail"
- Me.btnEMail.Size = New System.Drawing.Size(88, 32)
- Me.btnEMail.TabIndex = 17
- Me.btnEMail.Text = "Mail"
- '
- 'btnDCopy
- '
- Me.btnDCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDCopy.Location = New System.Drawing.Point(1002, 389)
- Me.btnDCopy.Name = "btnDCopy"
- Me.btnDCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnDCopy.TabIndex = 16
- Me.btnDCopy.Text = "Copy"
- '
- 'btnDDel
- '
- Me.btnDDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDDel.Location = New System.Drawing.Point(1002, 349)
- Me.btnDDel.Name = "btnDDel"
- Me.btnDDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDDel.TabIndex = 15
- Me.btnDDel.Text = "DEL"
- '
- 'btnDEdit
- '
- Me.btnDEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDEdit.Location = New System.Drawing.Point(1002, 309)
- Me.btnDEdit.Name = "btnDEdit"
- Me.btnDEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnDEdit.TabIndex = 14
- Me.btnDEdit.Text = "EDIT"
- '
- 'btnDAdd
- '
- Me.btnDAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDAdd.Location = New System.Drawing.Point(1002, 269)
- Me.btnDAdd.Name = "btnDAdd"
- Me.btnDAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnDAdd.TabIndex = 13
- Me.btnDAdd.Text = "ADD"
- '
- 'iugDetail
- '
- Me.iugDetail.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugDetail.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugDetail.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugDetail.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugDetail.Identity = "IMes"
- Me.iugDetail.IdentityForm = ""
- Me.iugDetail.LayOutFilePath = ""
- Me.iugDetail.Location = New System.Drawing.Point(12, 270)
- Me.iugDetail.Name = "iugDetail"
- Me.iugDetail.PrintFitWidthToPages = 0
- Me.iugDetail.PrintLandscape = True
- Me.iugDetail.PrintPageFooter = ""
- Me.iugDetail.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageFooterHeight = 20
- Me.iugDetail.PrintPageHeader = ""
- Me.iugDetail.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageHeaderHeight = 20
- Me.iugDetail.PrintZoom = 1.0R
- Me.iugDetail.Size = New System.Drawing.Size(984, 378)
- Me.iugDetail.TabIndex = 12
- Me.iugDetail.UserNo = "IMes"
- '
- 'btnAdd
- '
- Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnAdd.Location = New System.Drawing.Point(1002, 53)
- Me.btnAdd.Name = "btnAdd"
- Me.btnAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnAdd.TabIndex = 20
- Me.btnAdd.Text = "Add(&A)"
- '
- 'btnEdit
- '
- Me.btnEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEdit.Location = New System.Drawing.Point(1002, 93)
- Me.btnEdit.Name = "btnEdit"
- Me.btnEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnEdit.TabIndex = 21
- Me.btnEdit.Text = "Edit(&E)"
- '
- 'btnDel
- '
- Me.btnDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDel.Location = New System.Drawing.Point(1002, 133)
- Me.btnDel.Name = "btnDel"
- Me.btnDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDel.TabIndex = 22
- Me.btnDel.Text = "Del(&D)"
- '
- 'btnCopy
- '
- Me.btnCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnCopy.Location = New System.Drawing.Point(1002, 173)
- Me.btnCopy.Name = "btnCopy"
- Me.btnCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnCopy.TabIndex = 23
- Me.btnCopy.Text = "Copy(&C)"
- '
- 'btnApprove
- '
- Me.btnApprove.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnApprove.Location = New System.Drawing.Point(1002, 213)
- Me.btnApprove.Name = "btnApprove"
- Me.btnApprove.Size = New System.Drawing.Size(88, 32)
- Me.btnApprove.TabIndex = 24
- Me.btnApprove.Text = "Approve(&Y)"
- '
- 'iugSubcontractor
- '
- Me.iugSubcontractor.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugSubcontractor.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugSubcontractor.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugSubcontractor.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugSubcontractor.Identity = "IMes"
- Me.iugSubcontractor.IdentityForm = ""
- Me.iugSubcontractor.LayOutFilePath = ""
- Me.iugSubcontractor.Location = New System.Drawing.Point(12, 53)
- Me.iugSubcontractor.Name = "iugSubcontractor"
- Me.iugSubcontractor.PrintFitWidthToPages = 0
- Me.iugSubcontractor.PrintLandscape = True
- Me.iugSubcontractor.PrintPageFooter = ""
- Me.iugSubcontractor.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageFooterHeight = 20
- Me.iugSubcontractor.PrintPageHeader = ""
- Me.iugSubcontractor.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageHeaderHeight = 20
- Me.iugSubcontractor.PrintZoom = 1.0R
- Me.iugSubcontractor.Size = New System.Drawing.Size(984, 256)
- Me.iugSubcontractor.TabIndex = 25
- Me.iugSubcontractor.UserNo = "IMes"
- '
- 'frmSubcontractor_21676
- '
- Me.ClientSize = New System.Drawing.Size(1098, 655)
- Me.Controls.Add(Me.btnClose)
- Me.Controls.Add(Me.btnApprove)
- Me.Controls.Add(Me.btnEMail)
- Me.Controls.Add(Me.btnDCopy)
- Me.Controls.Add(Me.btnCopy)
- Me.Controls.Add(Me.btnDDel)
- Me.Controls.Add(Me.iugSubcontractor)
- Me.Controls.Add(Me.btnDEdit)
- Me.Controls.Add(Me.btnAdd)
- Me.Controls.Add(Me.btnDAdd)
- Me.Controls.Add(Me.btnDel)
- Me.Controls.Add(Me.iugDetail)
- Me.Controls.Add(Me.btnEdit)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractor_21676"
- Me.Text = "ENT Subcontractor & Contactor"
- Me.WindowState = System.Windows.Forms.FormWindowState.Maximized
- Me.Controls.SetChildIndex(Me.btnEdit, 0)
- Me.Controls.SetChildIndex(Me.iugDetail, 0)
- Me.Controls.SetChildIndex(Me.btnDel, 0)
- Me.Controls.SetChildIndex(Me.btnDAdd, 0)
- Me.Controls.SetChildIndex(Me.btnAdd, 0)
- Me.Controls.SetChildIndex(Me.btnDEdit, 0)
- Me.Controls.SetChildIndex(Me.iugSubcontractor, 0)
- Me.Controls.SetChildIndex(Me.btnDDel, 0)
- Me.Controls.SetChildIndex(Me.btnCopy, 0)
- Me.Controls.SetChildIndex(Me.btnDCopy, 0)
- Me.Controls.SetChildIndex(Me.btnEMail, 0)
- Me.Controls.SetChildIndex(Me.btnApprove, 0)
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractor_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- ' 2016 YF, wsENT_21676.Url = LocalizeWebService(wsENT_21676.Url.ToString)
- ' 2016 YF, wsENT_21676.EnableDecompression = True
-
- Call funiMESUltraGridIni() 'Grid初始設定
-
- '//取出資料
- Call funLoadSubcontractor()
-
- SetIssueState(Issue.Unfrozen) '預設在Unforzen上
- SetSearchFieldName(New String() {"SubcontractorNo_21676", "SubcontractorName_21676"}) '設置搜尋欄位
-
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractor_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- If Not dsENT Is Nothing Then dsENT.Dispose()
- ' 2016 YF, If Not wsENT_21676 Is Nothing Then wsENT_21676.Dispose()
- End Sub
-
- Protected Overrides Sub rdoIssue_CheckedChanged(sender As Object, e As EventArgs)
- If IsNothing(dsENT) Then Exit Sub
-
- Select Case GetIssueState()
- Case Issue.Unfrozen
- dsENT.Tables(tblENTSubcontractor_21676).DefaultView.RowFilter = "IssueState=0"
- Case Issue.Pending
- dsENT.Tables(tblENTSubcontractor_21676).DefaultView.RowFilter = "IssueState=1"
- Case Issue.Active
- dsENT.Tables(tblENTSubcontractor_21676).DefaultView.RowFilter = "IssueState=2"
- Case Issue.Unused
- dsENT.Tables(tblENTSubcontractor_21676).DefaultView.RowFilter = "IssueState=-1"
- End Select
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor_21676).DefaultView
- Call funShowActiveDetail()
- End Sub
-
- Protected Overrides Sub Finalize()
- MyBase.Finalize()
- End Sub
-
- Private Sub btnAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAdd.Click
-
- Dim fSubcontractorDef As New frmSubcontractorDef_21676
-
- fSubcontractorDef.DefMode = 0
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo_21676 = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo_21676", SubcontractorNo_21676)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End Sub
-
- Private Sub btnEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEdit.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor_21676).Select("SubcontractorNo_21676 = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString, "'", "''") & "'")
-
- '核准狀態為"Unfrozen"者才可修改
-
- If Rows(0).Item("IssueState") <> 0 Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-202202", "[%NOT ALLOWED TO EDIT%]"), MsgBoxStyle.Exclamation, Me.Text)
- Exit Sub
- End If
-
- Dim fSubcontractorDef As New frmSubcontractorDef_21676
- fSubcontractorDef.DefMode = 1
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo_21676 = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo_21676", SubcontractorNo_21676)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDel.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Or intIssueState = -1 Or intIssueState = 2 Then '狀態為Unforzen或Unused時直接刪除
-
- strParameter = CombineXMLParameter("SubcontractorNo_21676", "SubcontractorNo_21676", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo_21676").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", CInput(intIssueState), "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT_21676.DelSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT_21676.DelSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT_21676.DelSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOWED TO delete%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCopy.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor_21676).Select("SubcontractorNo_21676 = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorDef As New frmSubcontractorDef_21676
- fSubcontractorDef.DefMode = 2
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo_21676 = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo_21676", SubcontractorNo_21676)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnApprove_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnApprove.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100002", "[%ARE YOU SURE TO APPROVE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Then
- strParameter = CombineXMLParameter("SubcontractorNo_21676", "SubcontractorNo_21676", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo_21676").Value.ToString), "")
- strParameter += CombineXMLParameter("issuestate", "IssueState", "String", intIssueState, "")
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT_21676.ApproveSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT_21676.ApproveSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT_21676.ApproveSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Approve failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOW TO APPROVE%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDAdd.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
-
- 'Dim Rows As DataRow()
- Dim fSubcontractorContDef As New frmSubcontractorContDef_21676
-
- fSubcontractorContDef.DefMode = 0
- fSubcontractorContDef.SubcontractorNo_21676 = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName_21676 = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName_21676", ContactorName_21676)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- End If
- End Sub
-
- Private Sub btnDEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDEdit.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont_21676).Select("SubcontractorNo_21676 = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString, "'", "''") & "'" _
- & " And ContactorName_21676 = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName_21676").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmSubcontractorContDef_21676
- fSubcontractorContDef.DefMode = 1
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo_21676 = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName_21676 = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName_21676", ContactorName_21676)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnDDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDDel.Click
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
-
- Cursor.Current = Cursors.WaitCursor
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugDetail.iMESUltraGrid.Selected.Rows.Count - 1
- strParameter = CombineXMLParameter("SubcontractorNo_21676", "SubcontractorNo_21676", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("ContactorName_21676", "ContactorName_21676", "String", CInput(Me.iugDetail.iMESUltraGrid.Selected.Rows(i).Cells("ContactorName_21676").Value.ToString), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT_21676.DelSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT_21676.DelSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT_21676.DelSubcontractorCont", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
-
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDCopy.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont_21676).Select("SubcontractorNo_21676 = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString, "'", "''") & "'" _
- & " And ContactorName_21676 = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName_21676").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmSubcontractorContDef_21676
- fSubcontractorContDef.DefMode = 2
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo_21676 = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName_21676 = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName_21676", ContactorName_21676)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEMail.Click
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
- Dim proMail As New System.Diagnostics.Process
- Dim strAccount As String
-
- Rows = dsENT.Tables(tblENTSubcontractorCont_21676).Select("SubcontractorNo_21676 = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString, "'", "''") & "'" _
- & " And ContactorName_21676 = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName_21676").Value.ToString, "'", "''") & "'")
-
- strAccount = "mailto:" & Rows(0).Item("EMail").ToString
- proMail.Start(strAccount)
-
- End If
-
- End Sub
-
- Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnQuery_Click(sender As Object, e As EventArgs)
- Cursor.Current = Cursors.WaitCursor
-
- funLoadSubcontractor()
-
- Cursor.Current = Cursors.Default
- End Sub
-
-#Region "Ultra Grid"
-
- Private Sub iugSubcontractor_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugSubcontractor.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo_21676")
- .Header.Caption = "SubcontractorNo_21676"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("SubcontractorName_21676")
- .Header.Caption = "SubcontractorName_21676"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("Description_21676")
- .Header.Caption = "Description_21676"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("IssueState")
- .Header.Caption = "IssueState"
- .Width = 114
- .Hidden = True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 7
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
- Private Sub iugSubcontractor_iMESUltraGrid_AfterRowActivate(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles iugSubcontractor.iMESUltraGrid_AfterRowActivate
-
- 'IsGroupByRow不做任何處理
- If Not iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
- Else
- Exit Sub
- End If
-
- End Sub
-
- Private Sub iugDetail_iMESUltraGrid_InitializeLayOut(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugDetail.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo_21676")
- .Header.Caption = "SubcontractorNo_21676"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("ContactorName_21676")
- .Header.Caption = "ContactorName_21676"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("TelNo_21676")
- .Header.Caption = "TelNo_21676"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("FaxNo_21676")
- .Header.Caption = "FaxNo_21676"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("Title_21676")
- .Header.Caption = "Title_21676"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("Address_21676")
- .Header.Caption = "Address_21676"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("EMail_21676")
- .Header.Caption = "EMail_21676"
- .Width = 150
- .Hidden = False
- .CellAppearance.ForeColor = System.Drawing.Color.Blue
- .CellAppearance.FontData.Underline = DefaultableBoolean.True
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("Description_21676")
- .Header.Caption = "Description_21676"
- .Width = 200
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 7
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 8
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 9
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 10
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 11
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
-#End Region
-
-#Region "Load Function"
-
- '//取出tblENTSubcontractor 外包商資料
-
- Private Sub funLoadSubcontractor()
-
- '先判斷是否dataset中已有ENTSubcontractor之datatable,若有,需先remove否則會有錯誤
- If Not IsNothing(dsENT.Tables(tblENTSubcontractor_21676)) Then
- dsENT.Tables.Remove(tblENTSubcontractor_21676)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- '加上IssueState要求取出所有資料
- strParameter = CombineXMLParameter("issuestate", "IssueState", "Integer", defInteger, "")
- '加上查詢條件 cboSearchFieldName,txtSearchFieldValue
- strParameter += CombineXMLQueryCondition()
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT_21676.LoadSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT_21676.LoadSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT_21676.LoadSubcontractor", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件.wsENT_21676
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
-
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractor_21676 = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractor").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
-
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractor").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractor").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- strFilter = ""
- Select Case GetIssueState()
- Case Issue.Unfrozen
- strFilter = FilterByInteger(strFilter, "IssueState", 0)
- Case Issue.Pending
- strFilter = FilterByInteger(strFilter, "IssueState", 1)
- Case Issue.Active
- strFilter = FilterByInteger(strFilter, "IssueState", 2)
- Case Issue.Unused
- strFilter = FilterByInteger(strFilter, "IssueState", -1)
- End Select
-
- dsENT.Tables(tblENTSubcontractor_21676).DefaultView.RowFilter = strFilter
- dsENT.Tables(tblENTSubcontractor_21676).DefaultView.Sort = "SubcontractorNo_21676"
-
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor_21676).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit Sub
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- '//取出tblENTSubcontractorCont聯絡人資料
-
- Private Sub funLoadSubcontractorCont(ByRef SubcontractorNo_21676 As String)
-
- If Not IsNothing(dsENT.Tables(tblENTSubcontractorCont_21676)) Then
- dsENT.Tables.Remove(tblENTSubcontractorCont_21676)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("SubcontractorNo_21676", "SubcontractorNo_21676", "String", SubcontractorNo_21676, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT_21676.LoadSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT_21676.LoadSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT_21676.LoadSubcontractorCont", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractorCont_21676 = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractorcont").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- Me.iugDetail.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractorCont_21676).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Cont Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- Private Sub funShowActiveDetail()
-
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.DataSource = Nothing
- Else
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo_21676").Value.ToString)
- End If
-
- End Sub
-
- Private Sub funiMESUltraGridIni()
-
- 'iugSubcontractor 初始設定
- With Me.iugSubcontractor.iMESUltraGrid
- .Text = ""
- .DisplayLayout.GroupByBox.Hidden = True
- .DisplayLayout.UseFixedHeaders = False
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugSubcontractor.UserNo = gUserNo
-
- 'iugDetail 初始設定
- With Me.iugDetail.iMESUltraGrid.DisplayLayout
- .GroupByBox.Hidden = True
- .Override.ExpansionIndicator = ShowExpansionIndicator.Default
- .ViewStyle = ViewStyle.SingleBand
- .RowConnectorStyle = RowConnectorStyle.Default
-
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugDetail.UserNo = gUserNo
-
- End Sub
-
- Private Sub iugDetail_Load(sender As Object, e As EventArgs) Handles iugDetail.Load
-
- End Sub
-
- Private Sub iugSubcontractor_Load(sender As Object, e As EventArgs) Handles iugSubcontractor.Load
-
- End Sub
-
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS3/ET_Subcontractor_21676/iMES.snk b/SRC/MESWin/SYS3/ET_Subcontractor_21676/iMES.snk
deleted file mode 100644
index 4206cdc36eceddde7f30ac484d1852eb3f9be236..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 596
zcmV-a0;~N80ssI2Bme+XQ$aES1ONa50097#g3R+{UF+SWBpq3jKsGz4Rg)jp;sR@&
z9YKT-w@gNp-L~38+1NJ=1XDRJDW25AI*NovDaNnzDN>{Bkv1jod=Ji9)a&FRUaAtf
zi1{sH^ycmTE>;(=WPI@cVijY>(
z68QMK9TPTAYPREpfq+h^Nne$)zO;6bx%j96AK_A|B+TR7U>0P)(eEk{J#@4Mx&M05
zCmJxuxSLKS802l^7))Rwj&-Awxzy
zL|h&Z8u5{hxZ#i*aB?roJ=(>%lFM~AM)K&^89a(nzv>UkL3%^1E^(B=&$CpC*k&Uu
zoWIXD#zo%*oEY3D5w(^p%?
zO5a)yp9j|(odT|vi)x=2V4i$!>r`bocbgd;9#&HU{hI|N6Z$Mk4?^qLlWtab5
z>NP5P^SUu%0a4(t?J}R)?1B(lBxj+?ehgOdZcWno8ix^tn9J&06)
-
-
-
- Debug
- x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}
- Library
- ET_TESTDATA21676
- ET_TESTDATA21676
- 512
- Windows
- v4.6.2
-
- SAK
- SAK
- SAK
- SAK
-
-
- On
-
-
- Binary
-
-
- Off
-
-
- On
-
-
- true
- true
- true
- ..\..\..\MESClient\
- ET_TESTDATA21676.xml
- 0
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- full
- x86
- MinimumRecommendedRules.ruleset
- false
-
-
- true
- ..\..\..\MESClient\
- ET_TESTDATA21676.xml
- true
- 0
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- pdbonly
- x86
- MinimumRecommendedRules.ruleset
- false
-
-
- true
-
-
- iMES.snk
-
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinGrid.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinEditors.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.Misc.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Shared.v19.1.dll
- False
-
-
- ..\..\..\MESClient\COM_Kit.dll
- False
-
-
- ..\..\..\MES_C_DLL\iMESExceptionManager.dll
- False
-
-
- ..\..\..\MES_C_DLL\iMESUltraGrid.dll
- False
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- modConstant.vb
-
-
- Form
-
-
- Form
-
-
- Form
-
-
-
- True
- Application.myapp
- True
-
-
- True
- True
- Resources.resx
-
-
- True
- Settings.settings
- True
-
-
-
-
- frmTESTDATA21676.vb
-
-
- frmTESTDATA21676ContDef.vb
-
-
- frmTESTDATA21676Def.vb
-
-
-
- VbMyResourcesResXFileCodeGenerator
- Resources.Designer.vb
- My.Resources
- Designer
-
-
-
-
-
- MyApplicationCodeGenerator
- Application.Designer.vb
-
-
- SettingsSingleFileGenerator
- My
- Settings.Designer.vb
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/ET_Subcontractor.vbproj.vspscc b/SRC/MESWin/SYS3/ET_TESTDATA21676/ET_Subcontractor.vbproj.vspscc
deleted file mode 100644
index b6d3289..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/ET_Subcontractor.vbproj.vspscc
+++ /dev/null
@@ -1,10 +0,0 @@
-""
-{
-"FILE_VERSION" = "9237"
-"ENLISTMENT_CHOICE" = "NEVER"
-"PROJECT_FILE_RELATIVE_PATH" = ""
-"NUMBER_OF_EXCLUDED_FILES" = "0"
-"ORIGINAL_PROJECT_FILE_PATH" = ""
-"NUMBER_OF_NESTED_PROJECTS" = "0"
-"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROVIDER"
-}
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Application.Designer.vb b/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Application.Designer.vb
deleted file mode 100644
index 537244b..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Application.Designer.vb
+++ /dev/null
@@ -1,13 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Application.myapp b/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Application.myapp
deleted file mode 100644
index 758895d..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Application.myapp
+++ /dev/null
@@ -1,10 +0,0 @@
-
-
- false
- false
- 0
- true
- 0
- 1
- true
-
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/AssemblyInfo.vb b/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/AssemblyInfo.vb
deleted file mode 100644
index b0cdd98..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/AssemblyInfo.vb
+++ /dev/null
@@ -1,35 +0,0 @@
-Imports System
-Imports System.Reflection
-Imports System.Runtime.InteropServices
-
-' 組件的一般資訊是由下列的屬性集控制。
-' 變更這些屬性的值即可修改組件的相關
-' 資訊。
-
-' 檢閱組件屬性的值
-
-
-
-
-
-
-
-
-
-
-'下列 GUID 為專案公開 (Expose) 至 COM 時所要使用的 typelib ID
-
-
-' 組件的版本資訊由下列四個值所組成:
-'
-' 主要版本
-' 次要版本
-' 組建編號
-' 修訂編號
-'
-' 您可以指定所有的值,也可以依照以下的方式,使用 '*' 將組建和修訂編號
-' 指定為預設值:
-'
-
-
-
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/BuildIncrementVersionInfo.vb b/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/BuildIncrementVersionInfo.vb
deleted file mode 100644
index d2f2e21..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/BuildIncrementVersionInfo.vb
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Resources.Designer.vb b/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Resources.Designer.vb
deleted file mode 100644
index 53530c2..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Resources.Designer.vb
+++ /dev/null
@@ -1,63 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-Imports System
-
-Namespace My.Resources
-
- '此类是由 StronglyTypedResourceBuilder
- '类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
- '若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen
- '(以 /str 作为命令选项),或重新生成 VS 项目。
- '''
- ''' 一个强类型的资源类,用于查找本地化的字符串等。
- '''
- _
- Friend Module Resources
-
- Private resourceMan As Global.System.Resources.ResourceManager
-
- Private resourceCulture As Global.System.Globalization.CultureInfo
-
- '''
- ''' 返回此类使用的缓存的 ResourceManager 实例。
- '''
- _
- Friend ReadOnly Property ResourceManager() As Global.System.Resources.ResourceManager
- Get
- If Object.ReferenceEquals(resourceMan, Nothing) Then
- Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("ET_TESTDATA21676.Resources", GetType(Resources).Assembly)
- resourceMan = temp
- End If
- Return resourceMan
- End Get
- End Property
-
- '''
- ''' 重写当前线程的 CurrentUICulture 属性,对
- ''' 使用此强类型资源类的所有资源查找执行重写。
- '''
- _
- Friend Property Culture() As Global.System.Globalization.CultureInfo
- Get
- Return resourceCulture
- End Get
- Set
- resourceCulture = value
- End Set
- End Property
- End Module
-End Namespace
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Resources.resx b/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Resources.resx
deleted file mode 100644
index af7dbeb..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Resources.resx
+++ /dev/null
@@ -1,117 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Settings.Designer.vb b/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Settings.Designer.vb
deleted file mode 100644
index 784ed03..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Settings.Designer.vb
+++ /dev/null
@@ -1,73 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' 此代码由工具生成。
-' 运行时版本:4.0.30319.42000
-'
-' 对此文件的更改可能会导致不正确的行为,并且如果
-' 重新生成代码,这些更改将会丢失。
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-
-Namespace My
-
- _
- Partial Friend NotInheritable Class MySettings
- Inherits Global.System.Configuration.ApplicationSettingsBase
-
- Private Shared defaultInstance As MySettings = CType(Global.System.Configuration.ApplicationSettingsBase.Synchronized(New MySettings()),MySettings)
-
-#Region "My.Settings 自动保存功能"
-#If _MyType = "WindowsForms" Then
- Private Shared addedHandler As Boolean
-
- Private Shared addedHandlerLockObject As New Object
-
- _
- Private Shared Sub AutoSaveSettings(sender As Global.System.Object, e As Global.System.EventArgs)
- If My.Application.SaveMySettingsOnExit Then
- My.Settings.Save()
- End If
- End Sub
-#End If
-#End Region
-
- Public Shared ReadOnly Property [Default]() As MySettings
- Get
-
-#If _MyType = "WindowsForms" Then
- If Not addedHandler Then
- SyncLock addedHandlerLockObject
- If Not addedHandler Then
- AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings
- addedHandler = True
- End If
- End SyncLock
- End If
-#End If
- Return defaultInstance
- End Get
- End Property
- End Class
-End Namespace
-
-Namespace My
-
- _
- Friend Module MySettingsProperty
-
- _
- Friend ReadOnly Property Settings() As Global.ET_TESTDATA21676.My.MySettings
- Get
- Return Global.ET_TESTDATA21676.My.MySettings.Default
- End Get
- End Property
- End Module
-End Namespace
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Settings.settings b/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Settings.settings
deleted file mode 100644
index 85b890b..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/Settings.settings
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
-
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/licenses.licx b/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/licenses.licx
deleted file mode 100644
index e3f40e2..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/My Project/licenses.licx
+++ /dev/null
@@ -1,7 +0,0 @@
-Infragistics.Win.Misc.UltraButton, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraRadioButton, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraComboEditor, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraGroupBox, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraTextEditor, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraLabel, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraPanel, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676.resx b/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676.vb b/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676.vb
deleted file mode 100644
index 3f9ecb3..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676.vb
+++ /dev/null
@@ -1,1130 +0,0 @@
-Imports iMESExceptionManager
-
-Imports Infragistics.Win
-Imports Infragistics.Win.UltraWinGrid
-Public Class frmTESTDATA21676
-
- Inherits COM_Kit.frmBasisTemplat
-
- Public PrivFunNo As String = defString
-
- '//WS相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT '宣告Web Service物件?
- Dim tmpStringReader As System.IO.StringReader '將字串轉換成可讀入DataSet的物件
- Dim XmlData As String '儲存取回之資料
- Dim XmlSchema As String '儲存取回之資料結構
- Dim InXml As String '儲存呼叫Web Service的傳入參數(Request字串)
- Dim OutXml As String '儲存Web Service的傳回值(Response字串)
- Dim strIdentity As String '儲存Identity XML字串?
- Dim strParameter As String '儲存Parameter XML字串
-
- '//資料表相關變數
-
- Dim dsENT As New DataSet '資料集:儲存取回之資料?
-
- Dim tblENTSubcontractor As String '儲存取回資料表的名稱(master)?
- Dim tblENTSubcontractorCont As String '明細資料表名稱(detail)
- Dim strFilter As String 'Filter string及列印的過濾條件
-
- '//其他共用變數
- Dim SubcontractorNo As String 'for Gird to Focus
- Dim ContactorName As String 'for DetailGrid to Focus
- Dim ugrRow As Infragistics.Win.UltraWinGrid.UltraGridRow
- Friend WithEvents btnAdd As Misc.UltraButton
- Friend WithEvents btnEdit As Misc.UltraButton
- Friend WithEvents btnDel As Misc.UltraButton
- Friend WithEvents btnCopy As Misc.UltraButton
- Friend WithEvents btnApprove As Misc.UltraButton
- Friend WithEvents iugSubcontractor As iMESUltraGrid.iMESUltraGridControl
- Dim i As Integer
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.Container
- Friend WithEvents iugDetail As iMESUltraGrid.iMESUltraGridControl
- Friend WithEvents btnClose As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnEMail As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDCopy As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDDel As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDEdit As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDAdd As Infragistics.Win.Misc.UltraButton
- Private Sub InitializeComponent()
- Me.btnClose = New Infragistics.Win.Misc.UltraButton()
- Me.btnEMail = New Infragistics.Win.Misc.UltraButton()
- Me.btnDCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnDDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnDEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDAdd = New Infragistics.Win.Misc.UltraButton()
- Me.iugDetail = New iMESUltraGrid.iMESUltraGridControl()
- Me.btnAdd = New Infragistics.Win.Misc.UltraButton()
- Me.btnEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnApprove = New Infragistics.Win.Misc.UltraButton()
- Me.iugSubcontractor = New iMESUltraGrid.iMESUltraGridControl()
- Me.SuspendLayout()
- '
- 'btnClose
- '
- Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnClose.Location = New System.Drawing.Point(1002, 616)
- Me.btnClose.Name = "btnClose"
- Me.btnClose.Size = New System.Drawing.Size(88, 32)
- Me.btnClose.TabIndex = 18
- Me.btnClose.Text = "Close (&X)"
- '
- 'btnEMail
- '
- Me.btnEMail.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEMail.Location = New System.Drawing.Point(1002, 429)
- Me.btnEMail.Name = "btnEMail"
- Me.btnEMail.Size = New System.Drawing.Size(88, 32)
- Me.btnEMail.TabIndex = 17
- Me.btnEMail.Text = "Mail"
- '
- 'btnDCopy
- '
- Me.btnDCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDCopy.Location = New System.Drawing.Point(1002, 389)
- Me.btnDCopy.Name = "btnDCopy"
- Me.btnDCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnDCopy.TabIndex = 16
- Me.btnDCopy.Text = "Copy"
- '
- 'btnDDel
- '
- Me.btnDDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDDel.Location = New System.Drawing.Point(1002, 349)
- Me.btnDDel.Name = "btnDDel"
- Me.btnDDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDDel.TabIndex = 15
- Me.btnDDel.Text = "DEL"
- '
- 'btnDEdit
- '
- Me.btnDEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDEdit.Location = New System.Drawing.Point(1002, 309)
- Me.btnDEdit.Name = "btnDEdit"
- Me.btnDEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnDEdit.TabIndex = 14
- Me.btnDEdit.Text = "EDIT"
- '
- 'btnDAdd
- '
- Me.btnDAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDAdd.Location = New System.Drawing.Point(1002, 269)
- Me.btnDAdd.Name = "btnDAdd"
- Me.btnDAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnDAdd.TabIndex = 13
- Me.btnDAdd.Text = "ADD"
- '
- 'iugDetail
- '
- Me.iugDetail.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugDetail.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugDetail.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugDetail.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugDetail.Identity = "IMes"
- Me.iugDetail.IdentityForm = ""
- Me.iugDetail.LayOutFilePath = ""
- Me.iugDetail.Location = New System.Drawing.Point(12, 270)
- Me.iugDetail.Name = "iugDetail"
- Me.iugDetail.PrintFitWidthToPages = 0
- Me.iugDetail.PrintLandscape = True
- Me.iugDetail.PrintPageFooter = ""
- Me.iugDetail.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageFooterHeight = 20
- Me.iugDetail.PrintPageHeader = ""
- Me.iugDetail.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageHeaderHeight = 20
- Me.iugDetail.PrintZoom = 1.0R
- Me.iugDetail.Size = New System.Drawing.Size(984, 378)
- Me.iugDetail.TabIndex = 12
- Me.iugDetail.UserNo = "IMes"
- '
- 'btnAdd
- '
- Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnAdd.Location = New System.Drawing.Point(1002, 53)
- Me.btnAdd.Name = "btnAdd"
- Me.btnAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnAdd.TabIndex = 20
- Me.btnAdd.Text = "Add(&A)"
- '
- 'btnEdit
- '
- Me.btnEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEdit.Location = New System.Drawing.Point(1002, 93)
- Me.btnEdit.Name = "btnEdit"
- Me.btnEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnEdit.TabIndex = 21
- Me.btnEdit.Text = "Edit(&E)"
- '
- 'btnDel
- '
- Me.btnDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDel.Location = New System.Drawing.Point(1002, 133)
- Me.btnDel.Name = "btnDel"
- Me.btnDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDel.TabIndex = 22
- Me.btnDel.Text = "Del(&D)"
- '
- 'btnCopy
- '
- Me.btnCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnCopy.Location = New System.Drawing.Point(1002, 173)
- Me.btnCopy.Name = "btnCopy"
- Me.btnCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnCopy.TabIndex = 23
- Me.btnCopy.Text = "Copy(&C)"
- '
- 'btnApprove
- '
- Me.btnApprove.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnApprove.Location = New System.Drawing.Point(1002, 213)
- Me.btnApprove.Name = "btnApprove"
- Me.btnApprove.Size = New System.Drawing.Size(88, 32)
- Me.btnApprove.TabIndex = 24
- Me.btnApprove.Text = "Approve(&Y)"
- '
- 'iugSubcontractor
- '
- Me.iugSubcontractor.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugSubcontractor.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugSubcontractor.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugSubcontractor.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugSubcontractor.Identity = "IMes"
- Me.iugSubcontractor.IdentityForm = ""
- Me.iugSubcontractor.LayOutFilePath = ""
- Me.iugSubcontractor.Location = New System.Drawing.Point(12, 53)
- Me.iugSubcontractor.Name = "iugSubcontractor"
- Me.iugSubcontractor.PrintFitWidthToPages = 0
- Me.iugSubcontractor.PrintLandscape = True
- Me.iugSubcontractor.PrintPageFooter = ""
- Me.iugSubcontractor.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageFooterHeight = 20
- Me.iugSubcontractor.PrintPageHeader = ""
- Me.iugSubcontractor.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageHeaderHeight = 20
- Me.iugSubcontractor.PrintZoom = 1.0R
- Me.iugSubcontractor.Size = New System.Drawing.Size(984, 256)
- Me.iugSubcontractor.TabIndex = 25
- Me.iugSubcontractor.UserNo = "IMes"
- '
- 'frmSubcontractor
- '
- Me.ClientSize = New System.Drawing.Size(1098, 655)
- Me.Controls.Add(Me.btnClose)
- Me.Controls.Add(Me.btnApprove)
- Me.Controls.Add(Me.btnEMail)
- Me.Controls.Add(Me.btnDCopy)
- Me.Controls.Add(Me.btnCopy)
- Me.Controls.Add(Me.btnDDel)
- Me.Controls.Add(Me.iugSubcontractor)
- Me.Controls.Add(Me.btnDEdit)
- Me.Controls.Add(Me.btnAdd)
- Me.Controls.Add(Me.btnDAdd)
- Me.Controls.Add(Me.btnDel)
- Me.Controls.Add(Me.iugDetail)
- Me.Controls.Add(Me.btnEdit)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractor"
- Me.Text = "ENT Subcontractor & Contactor"
- Me.WindowState = System.Windows.Forms.FormWindowState.Maximized
- Me.Controls.SetChildIndex(Me.btnEdit, 0)
- Me.Controls.SetChildIndex(Me.iugDetail, 0)
- Me.Controls.SetChildIndex(Me.btnDel, 0)
- Me.Controls.SetChildIndex(Me.btnDAdd, 0)
- Me.Controls.SetChildIndex(Me.btnAdd, 0)
- Me.Controls.SetChildIndex(Me.btnDEdit, 0)
- Me.Controls.SetChildIndex(Me.iugSubcontractor, 0)
- Me.Controls.SetChildIndex(Me.btnDDel, 0)
- Me.Controls.SetChildIndex(Me.btnCopy, 0)
- Me.Controls.SetChildIndex(Me.btnDCopy, 0)
- Me.Controls.SetChildIndex(Me.btnEMail, 0)
- Me.Controls.SetChildIndex(Me.btnApprove, 0)
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractor_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- Call funiMESUltraGridIni() 'Grid初始設定
-
- '//取出資料
- Call funLoadSubcontractor()
-
- SetIssueState(Issue.Unfrozen) '預設在Unforzen上
- SetSearchFieldName(New String() {"SubcontractorNo", "SubcontractorNaME"}) '設置搜尋欄位
-
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractor_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- If Not dsENT Is Nothing Then dsENT.Dispose()
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
- Protected Overrides Sub rdoIssue_CheckedChanged(sender As Object, e As EventArgs)
- If IsNothing(dsENT) Then Exit Sub
-
- Select Case GetIssueState()
- Case Issue.Unfrozen
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=0"
- Case Issue.Pending
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=1"
- Case Issue.Active
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=2"
- Case Issue.Unused
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=-1"
- End Select
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
- Call funShowActiveDetail()
- End Sub
-
- Protected Overrides Sub Finalize()
- MyBase.Finalize()
- End Sub
-
- Private Sub btnAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAdd.Click
-
- Dim fSubcontractorDef As New frmTESTDATA21676Def
-
- fSubcontractorDef.DefMode = 0
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End Sub
-
- Private Sub btnEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEdit.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'")
-
- '核准狀態為"Unfrozen"者才可修改
-
- If Rows(0).Item("IssueState") <> 0 Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-202202", "[%NOT ALLOWED TO EDIT%]"), MsgBoxStyle.Exclamation, Me.Text)
- Exit Sub
- End If
-
- Dim fSubcontractorDef As New frmTESTDATA21676Def
- fSubcontractorDef.DefMode = 1
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDel.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Or intIssueState = -1 Or intIssueState = 2 Then '狀態為Unforzen或Unused時直接刪除
-
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", CInput(intIssueState), "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsTEST_21676.DelTESTDATA_21676", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOWED TO delete%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCopy.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorDef As New frmTESTDATA21676Def
- fSubcontractorDef.DefMode = 2
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnApprove_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnApprove.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100002", "[%ARE YOU SURE TO APPROVE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Then
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo").Value.ToString), "")
- strParameter += CombineXMLParameter("issuestate", "IssueState", "String", intIssueState, "")
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.ApproveSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.ApproveSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsTEST_21676.ApproveTESTDATA_21676", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Approve failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOW TO APPROVE%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDAdd.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
-
- 'Dim Rows As DataRow()
- Dim fSubcontractorContDef As New frmTESTDATA21676ContDef
-
- fSubcontractorContDef.DefMode = 0
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- End If
- End Sub
-
- Private Sub btnDEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDEdit.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmTESTDATA21676ContDef
- fSubcontractorContDef.DefMode = 1
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnDDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDDel.Click
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
-
- Cursor.Current = Cursors.WaitCursor
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugDetail.iMESUltraGrid.Selected.Rows.Count - 1
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("ContactorName", "ContactorName", "String", CInput(Me.iugDetail.iMESUltraGrid.Selected.Rows(i).Cells("ContactorName").Value.ToString), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractorCont", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
-
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDCopy.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmTESTDATA21676ContDef
- fSubcontractorContDef.DefMode = 2
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEMail.Click
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
- Dim proMail As New System.Diagnostics.Process
- Dim strAccount As String
-
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- strAccount = "mailto:" & Rows(0).Item("EMail").ToString
- proMail.Start(strAccount)
-
- End If
-
- End Sub
-
- Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnQuery_Click(sender As Object, e As EventArgs)
- Cursor.Current = Cursors.WaitCursor
-
- funLoadSubcontractor()
-
- Cursor.Current = Cursors.Default
- End Sub
-
-#Region "Ultra Grid"
-
- Private Sub iugSubcontractor_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugSubcontractor.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo")
- .Header.Caption = "SubcontractorNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("SubcontractorName")
- .Header.Caption = "SubcontractorName"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("IssueState")
- .Header.Caption = "IssueState"
- .Width = 114
- .Hidden = True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 7
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
- Private Sub iugSubcontractor_iMESUltraGrid_AfterRowActivate(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles iugSubcontractor.iMESUltraGrid_AfterRowActivate
-
- 'IsGroupByRow不做任何處理
- If Not iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
- Else
- Exit Sub
- End If
-
- End Sub
-
- Private Sub iugDetail_iMESUltraGrid_InitializeLayOut(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugDetail.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo")
- .Header.Caption = "SubcontractorNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("ContactorName")
- .Header.Caption = "ContactorName"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("TelNo")
- .Header.Caption = "TelNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("FaxNo")
- .Header.Caption = "FaxNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("Title")
- .Header.Caption = "Title"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("Address")
- .Header.Caption = "Address"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("EMail")
- .Header.Caption = "EMail"
- .Width = 150
- .Hidden = False
- .CellAppearance.ForeColor = System.Drawing.Color.Blue
- .CellAppearance.FontData.Underline = DefaultableBoolean.True
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 200
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 7
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 8
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 9
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 10
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 11
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
-#End Region
-
-#Region "Load Function"
-
-
- Private Sub funLoadSubcontractor()
-
- '先判斷是否dataset中已有ENTSubcontractor之datatable,若有,需先remove否則會有錯誤
- If Not IsNothing(dsENT.Tables(tblENTSubcontractor)) Then
- dsENT.Tables.Remove(tblENTSubcontractor)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- '加上IssueState要求取出所有資料
- strParameter = CombineXMLParameter("issuestate", "IssueState", "Integer", defInteger, "")
- '加上查詢條件 cboSearchFieldName,txtSearchFieldValue
- strParameter += CombineXMLQueryCondition()
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractor", InXml) LoadSubcontractor
- OutXml = InvokeSrv("SXS.wsTEST_21676.LoadTESTDATA_21676", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
-
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractor = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("TESTDATA21676").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
-
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("TESTDATA21676").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("TESTDATA21676").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- strFilter = ""
- Select Case GetIssueState()
- Case Issue.Unfrozen
- strFilter = FilterByInteger(strFilter, "IssueState", 0)
- Case Issue.Pending
- strFilter = FilterByInteger(strFilter, "IssueState", 1)
- Case Issue.Active
- strFilter = FilterByInteger(strFilter, "IssueState", 2)
- Case Issue.Unused
- strFilter = FilterByInteger(strFilter, "IssueState", -1)
- End Select
-
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = strFilter
- dsENT.Tables(tblENTSubcontractor).DefaultView.Sort = "SubcontractorNo"
-
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit Sub
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- Private Sub funLoadSubcontractorCont(ByRef SubcontractorNo As String)
-
- If Not IsNothing(dsENT.Tables(tblENTSubcontractorCont)) Then
- dsENT.Tables.Remove(tblENTSubcontractorCont)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", SubcontractorNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsTEST_21676.LoadTESTDATA_21676Cont", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractorCont = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractorcont").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- Me.iugDetail.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractorCont).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Cont Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- Private Sub funShowActiveDetail()
-
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.DataSource = Nothing
- Else
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
- End If
-
- End Sub
-
- Private Sub funiMESUltraGridIni()
-
- 'iugSubcontractor 初始設定
- With Me.iugSubcontractor.iMESUltraGrid
- .Text = ""
- .DisplayLayout.GroupByBox.Hidden = True
- .DisplayLayout.UseFixedHeaders = False
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugSubcontractor.UserNo = gUserNo
-
- 'iugDetail 初始設定
- With Me.iugDetail.iMESUltraGrid.DisplayLayout
- .GroupByBox.Hidden = True
- .Override.ExpansionIndicator = ShowExpansionIndicator.Default
- .ViewStyle = ViewStyle.SingleBand
- .RowConnectorStyle = RowConnectorStyle.Default
-
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugDetail.UserNo = gUserNo
-
- End Sub
-
- Private Sub iugDetail_Load(sender As Object, e As EventArgs) Handles iugDetail.Load
-
- End Sub
-
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676ContDef.resx b/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676ContDef.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676ContDef.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676ContDef.vb b/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676ContDef.vb
deleted file mode 100644
index 83386d1..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676ContDef.vb
+++ /dev/null
@@ -1,656 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmTESTDATA21676ContDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
-
- Public SubcontractorNo As String = defString
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblAddress As System.Windows.Forms.Label
- Friend WithEvents lblEMail As System.Windows.Forms.Label
- Friend WithEvents lblTitle As System.Windows.Forms.Label
- Friend WithEvents lblFaxNo As System.Windows.Forms.Label
- Friend WithEvents lblTelNo As System.Windows.Forms.Label
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblContactorName As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorContData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtContactorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtFaxNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTelNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtEMail As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTitle As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtAddress As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorContData = New System.Windows.Forms.GroupBox()
- Me.txtAddress = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtEMail = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTitle = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtFaxNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblAddress = New System.Windows.Forms.Label()
- Me.lblEMail = New System.Windows.Forms.Label()
- Me.lblTitle = New System.Windows.Forms.Label()
- Me.lblFaxNo = New System.Windows.Forms.Label()
- Me.lblTelNo = New System.Windows.Forms.Label()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblContactorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtContactorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTelNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorContData.SuspendLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 322)
- Me.gbxBasisData.Size = New System.Drawing.Size(472, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(396, 401)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(208, 401)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(302, 401)
- '
- 'gbxSubcontractorContData
- '
- Me.gbxSubcontractorContData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTelNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTelNo)
- Me.gbxSubcontractorContData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorContData.Location = New System.Drawing.Point(15, 8)
- Me.gbxSubcontractorContData.Name = "gbxSubcontractorContData"
- Me.gbxSubcontractorContData.Size = New System.Drawing.Size(469, 306)
- Me.gbxSubcontractorContData.TabIndex = 0
- Me.gbxSubcontractorContData.TabStop = False
- Me.gbxSubcontractorContData.Text = "ENT Subcontractor Contactor Data"
- '
- 'txtAddress
- '
- Me.txtAddress.Location = New System.Drawing.Point(120, 152)
- Me.txtAddress.Name = "txtAddress"
- Me.txtAddress.Size = New System.Drawing.Size(336, 22)
- Me.txtAddress.TabIndex = 13
- '
- 'txtEMail
- '
- Me.txtEMail.Location = New System.Drawing.Point(320, 120)
- Me.txtEMail.Name = "txtEMail"
- Me.txtEMail.Size = New System.Drawing.Size(136, 22)
- Me.txtEMail.TabIndex = 11
- '
- 'txtTitle
- '
- Me.txtTitle.Location = New System.Drawing.Point(120, 120)
- Me.txtTitle.Name = "txtTitle"
- Me.txtTitle.Size = New System.Drawing.Size(114, 22)
- Me.txtTitle.TabIndex = 9
- '
- 'txtFaxNo
- '
- Me.txtFaxNo.Location = New System.Drawing.Point(320, 88)
- Me.txtFaxNo.Name = "txtFaxNo"
- Me.txtFaxNo.Size = New System.Drawing.Size(136, 22)
- Me.txtFaxNo.TabIndex = 7
- '
- 'lblAddress
- '
- Me.lblAddress.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblAddress.Location = New System.Drawing.Point(24, 154)
- Me.lblAddress.Name = "lblAddress"
- Me.lblAddress.Size = New System.Drawing.Size(86, 14)
- Me.lblAddress.TabIndex = 12
- Me.lblAddress.Text = "Address"
- Me.lblAddress.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblEMail
- '
- Me.lblEMail.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblEMail.Location = New System.Drawing.Point(248, 123)
- Me.lblEMail.Name = "lblEMail"
- Me.lblEMail.Size = New System.Drawing.Size(64, 14)
- Me.lblEMail.TabIndex = 10
- Me.lblEMail.Text = "EMail"
- Me.lblEMail.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTitle
- '
- Me.lblTitle.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTitle.Location = New System.Drawing.Point(24, 121)
- Me.lblTitle.Name = "lblTitle"
- Me.lblTitle.Size = New System.Drawing.Size(86, 14)
- Me.lblTitle.TabIndex = 8
- Me.lblTitle.Text = "Title"
- Me.lblTitle.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblFaxNo
- '
- Me.lblFaxNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblFaxNo.Location = New System.Drawing.Point(248, 90)
- Me.lblFaxNo.Name = "lblFaxNo"
- Me.lblFaxNo.Size = New System.Drawing.Size(64, 14)
- Me.lblFaxNo.TabIndex = 6
- Me.lblFaxNo.Text = "FaxNo"
- Me.lblFaxNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTelNo
- '
- Me.lblTelNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTelNo.Location = New System.Drawing.Point(24, 90)
- Me.lblTelNo.Name = "lblTelNo"
- Me.lblTelNo.Size = New System.Drawing.Size(86, 14)
- Me.lblTelNo.TabIndex = 4
- Me.lblTelNo.Text = "TelNo"
- Me.lblTelNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(120, 184)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(336, 108)
- Me.txtDescription.TabIndex = 15
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(24, 186)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(86, 14)
- Me.lblDescription.TabIndex = 14
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(14, 29)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 14)
- Me.lblSubcontractorNo.TabIndex = 0
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblContactorName
- '
- Me.lblContactorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblContactorName.Location = New System.Drawing.Point(24, 59)
- Me.lblContactorName.Name = "lblContactorName"
- Me.lblContactorName.Size = New System.Drawing.Size(86, 14)
- Me.lblContactorName.TabIndex = 2
- Me.lblContactorName.Text = "Contactor Name"
- Me.lblContactorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(120, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.ReadOnly = True
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(114, 22)
- Me.txtSubcontractorNo.TabIndex = 1
- Me.txtSubcontractorNo.TabStop = False
- '
- 'txtContactorName
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Appearance = Appearance1
- Me.txtContactorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Location = New System.Drawing.Point(120, 56)
- Me.txtContactorName.Name = "txtContactorName"
- Me.txtContactorName.Size = New System.Drawing.Size(160, 22)
- Me.txtContactorName.TabIndex = 3
- '
- 'txtTelNo
- '
- Me.txtTelNo.Location = New System.Drawing.Point(120, 88)
- Me.txtTelNo.Name = "txtTelNo"
- Me.txtTelNo.Size = New System.Drawing.Size(114, 22)
- Me.txtTelNo.TabIndex = 5
- '
- 'frmSubcontractorContDef
- '
- Me.ClientSize = New System.Drawing.Size(496, 446)
- Me.Controls.Add(Me.gbxSubcontractorContData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorContDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Contactor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorContData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorContData.ResumeLayout(False)
- Me.gbxSubcontractorContData.PerformLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorContDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據()
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
- If DefMode = 0 Or DefMode = 2 Then
- SetCreateDate(Now)
- SetCreator(gUserNo)
- End If
- If Not EditDataRow Is Nothing Then '修改 or Copy
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtContactorName.Text = EditDataRow.Item("ContactorName").ToString
- txtTelNo.Text = EditDataRow.Item("TelNo").ToString
- txtFaxNo.Text = EditDataRow.Item("FaxNo").ToString
- txtTitle.Text = EditDataRow.Item("Title").ToString
- txtAddress.Text = EditDataRow.Item("Address").ToString
- txtEMail.Text = EditDataRow.Item("EMail").ToString
- 'txtDescription是RichTextBox(Control, 因為TextBox無法正常顯示多行換行的資料)
- txtDescription.Text = EditDataRow.Item("Description").ToString
- If DefMode = 1 Then
- If (Not IsDBNull(EditDataRow("Creator"))) Then
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetCreator(EditDataRow.Item("Creator").ToString)
- End If
- End If
- End If
-
- If DefMode = 0 Then 'Add
- txtSubcontractorNo.Text = SubcontractorNo
- SetCreateDate(Now)
- SetCreator(gUserNo)
- ElseIf DefMode = 1 Then 'Edit
- txtContactorName.ReadOnly = True
- SetReviseDate(Now)
- SetReviser(gUserNo)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorContDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
-
- txtEMail.Text = ""
- btnApplyEnabled = False
- Cursor.Current = Cursors.Default
-
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtContactorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Click
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Enter
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtContactorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtContactorName_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Leave
- If txtContactorName.Text <> "" And txtEMail.Text = "" Then
- txtEMail.Text = txtContactorName.Text & "@"
- End If
- txtContactorName.Text = UCase(txtContactorName.Text)
- End Sub
-
- Private Sub txtContactorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTelNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Click
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Enter
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTelNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTelNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtFaxNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Click
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Enter
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtFaxNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtFaxNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTitle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Click
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Enter
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTitle.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTitle_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Click
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Enter
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtEMail.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtEMail_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtAddress_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Click
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Enter
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtAddress.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtAddress_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtDescription.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查()
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
- If txtContactorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%ContactorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtContactorName.Focus()
- Exit Function
- End If
-
- '******************************************************************************
- '2.寫回資料庫()
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("contactorname", "ContactorName", "String", CInput(txtContactorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("telno", "TelNo", "String", txtTelNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("faxno", "FaxNo", "String", txtFaxNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("title", "Title", "String", CInput(txtTitle.Text), "")
- strParameter = strParameter & CombineXMLParameter("address", "Address", "String", CInput(txtAddress.Text), "")
- strParameter = strParameter & CombineXMLParameter("email", "EMail", "String", CInput(txtEMail.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.AddSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsTEST_21676.AddTESTDATA_21676", InXml)
-
- Else 'Edit
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.EditSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsTEST_21676.EditTESTDATA_21676", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtContactorName.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Contactor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-#End Region
-
-
- Private Sub frmSubcontractorContDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-End Class
-
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676Def.resx b/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676Def.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676Def.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676Def.vb b/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676Def.vb
deleted file mode 100644
index cde340b..0000000
--- a/SRC/MESWin/SYS3/ET_TESTDATA21676/frmTESTDATA21676Def.vb
+++ /dev/null
@@ -1,421 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmTESTDATA21676Def
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorName As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtSubcontractorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance2 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorData = New System.Windows.Forms.GroupBox()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblSubcontractorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtSubcontractorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorData.SuspendLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 185)
- Me.gbxBasisData.Size = New System.Drawing.Size(479, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(403, 264)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(215, 264)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(309, 264)
- '
- 'gbxSubcontractorData
- '
- Me.gbxSubcontractorData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorName)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorName)
- Me.gbxSubcontractorData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorData.Location = New System.Drawing.Point(12, 8)
- Me.gbxSubcontractorData.Name = "gbxSubcontractorData"
- Me.gbxSubcontractorData.Size = New System.Drawing.Size(479, 169)
- Me.gbxSubcontractorData.TabIndex = 7
- Me.gbxSubcontractorData.TabStop = False
- Me.gbxSubcontractorData.Text = "Subcontractor Data"
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(128, 86)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(334, 67)
- Me.txtDescription.TabIndex = 2
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(56, 88)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(64, 14)
- Me.lblDescription.TabIndex = 13
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(24, 24)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 32)
- Me.lblSubcontractorNo.TabIndex = 5
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorName
- '
- Me.lblSubcontractorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorName.Location = New System.Drawing.Point(8, 56)
- Me.lblSubcontractorName.Name = "lblSubcontractorName"
- Me.lblSubcontractorName.Size = New System.Drawing.Size(112, 32)
- Me.lblSubcontractorName.TabIndex = 9
- Me.lblSubcontractorName.Text = "Subcontractor Name"
- Me.lblSubcontractorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Appearance = Appearance1
- Me.txtSubcontractorNo.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(128, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(152, 22)
- Me.txtSubcontractorNo.TabIndex = 0
- '
- 'txtSubcontractorName
- '
- Appearance2.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Appearance = Appearance2
- Me.txtSubcontractorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Location = New System.Drawing.Point(128, 55)
- Me.txtSubcontractorName.Name = "txtSubcontractorName"
- Me.txtSubcontractorName.Size = New System.Drawing.Size(334, 22)
- Me.txtSubcontractorName.TabIndex = 1
- '
- 'frmSubcontractorDef
- '
- Me.ClientSize = New System.Drawing.Size(503, 309)
- Me.Controls.Add(Me.gbxSubcontractorData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorData.ResumeLayout(False)
- Me.gbxSubcontractorData.PerformLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- If Not EditDataRow Is Nothing Then
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtSubcontractorName.Text = EditDataRow.Item("SubcontractorName").ToString
- 'txtDescription是RichTextBox Control,因為TextBox無法正常顯示多行換行的資料
- txtDescription.Text = EditDataRow.Item("Description").ToString
- End If
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- SetCreator(gUserNo)
- SetCreateDate(Now)
- ElseIf DefMode = 1 Then 'Edit
- txtSubcontractorNo.ReadOnly = True
- SetCreator(EditDataRow.Item("Creator").ToString)
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetReviser(gUserNo)
- SetReviseDate(Now)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
-
- End If
-
- Cursor.Current = Cursors.Default
- btnApplyEnabled = False
-
- End Sub
-
- Private Sub frmSubcontractorDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Leave
- txtSubcontractorNo.Text = UCase(txtSubcontractorNo.Text)
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtSubcontractorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Click
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Enter
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
-
- If txtSubcontractorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorName.Focus()
- Exit Function
- End If
-
- '2.
- '******************************************************************************
- '寫回資料庫
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("subcontractorname", "SubcontractorName", "String", CInput(txtSubcontractorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter = strParameter & CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("createdate", "CreateDate", "DateTime", Format(Now, "yyyy/MM/dd HH:mm:ss"), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.AddSubcontractor(InXml)
- OutXml = InvokeSrv("wsTEST_21676.AddTESTDATA_21676", InXml)
-
- Else
- '修改
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", EditDataRow.Item("IssueState").ToString, "")
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.EditSubcontractor(InXml)
- OutXml = InvokeSrv("wsTEST_21676.EditTESTDATA_21676", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtSubcontractorNo.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS3/ET_TESTDATA21676/iMES.snk b/SRC/MESWin/SYS3/ET_TESTDATA21676/iMES.snk
deleted file mode 100644
index 4206cdc36eceddde7f30ac484d1852eb3f9be236..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 596
zcmV-a0;~N80ssI2Bme+XQ$aES1ONa50097#g3R+{UF+SWBpq3jKsGz4Rg)jp;sR@&
z9YKT-w@gNp-L~38+1NJ=1XDRJDW25AI*NovDaNnzDN>{Bkv1jod=Ji9)a&FRUaAtf
zi1{sH^ycmTE>;(=WPI@cVijY>(
z68QMK9TPTAYPREpfq+h^Nne$)zO;6bx%j96AK_A|B+TR7U>0P)(eEk{J#@4Mx&M05
zCmJxuxSLKS802l^7))Rwj&-Awxzy
zL|h&Z8u5{hxZ#i*aB?roJ=(>%lFM~AM)K&^89a(nzv>UkL3%^1E^(B=&$CpC*k&Uu
zoWIXD#zo%*oEY3D5w(^p%?
zO5a)yp9j|(odT|vi)x=2V4i$!>r`bocbgd;9#&HU{hI|N6Z$Mk4?^qLlWtab5
z>NP5P^SUu%0a4(t?J}R)?1B(lBxj+?ehgOdZcWno8ix^tn9J&06)
-
-
-
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/ET_Demo.sln b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/ET_Demo.sln
deleted file mode 100644
index cfdcadb..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/ET_Demo.sln
+++ /dev/null
@@ -1,25 +0,0 @@
-
-Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio Version 16
-VisualStudioVersion = 16.0.32630.194
-MinimumVisualStudioVersion = 10.0.40219.1
-Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "ET_Demo", "ET_Demo.vbproj", "{735A5B4F-8D51-408F-9411-235CDB01F9F3}"
-EndProject
-Global
- GlobalSection(SolutionConfigurationPlatforms) = preSolution
- Debug|Any CPU = Debug|Any CPU
- Release|Any CPU = Release|Any CPU
- EndGlobalSection
- GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {735A5B4F-8D51-408F-9411-235CDB01F9F3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {735A5B4F-8D51-408F-9411-235CDB01F9F3}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {735A5B4F-8D51-408F-9411-235CDB01F9F3}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {735A5B4F-8D51-408F-9411-235CDB01F9F3}.Release|Any CPU.Build.0 = Release|Any CPU
- EndGlobalSection
- GlobalSection(SolutionProperties) = preSolution
- HideSolutionNode = FALSE
- EndGlobalSection
- GlobalSection(ExtensibilityGlobals) = postSolution
- SolutionGuid = {05370154-7301-4A5A-B360-EAF02EF9EFDA}
- EndGlobalSection
-EndGlobal
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/ET_Demo.vbproj b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/ET_Demo.vbproj
deleted file mode 100644
index 7d56649..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/ET_Demo.vbproj
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
- Debug
- AnyCPU
- {735A5B4F-8D51-408F-9411-235CDB01F9F3}
- WinExe
- ET_Demo.My.MyApplication
- ET_Demo
- ET_Demo
- 512
- WindowsForms
- v4.6.2
- true
- true
-
-
- AnyCPU
- true
- full
- true
- true
- bin\Debug\
- ET_Demo.xml
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
-
-
- AnyCPU
- pdbonly
- false
- true
- true
- bin\Release\
- ET_Demo.xml
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
-
-
- On
-
-
- Binary
-
-
- Off
-
-
- On
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Form
-
-
- Form1.vb
- Form
-
-
-
- True
- Application.myapp
-
-
- True
- True
- Resources.resx
-
-
- True
- Settings.settings
- True
-
-
-
-
- VbMyResourcesResXFileCodeGenerator
- Resources.Designer.vb
- My.Resources
- Designer
-
-
-
-
- MyApplicationCodeGenerator
- Application.Designer.vb
-
-
- SettingsSingleFileGenerator
- My
- Settings.Designer.vb
-
-
-
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Application.Designer.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Application.Designer.vb
deleted file mode 100644
index deffe98..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Application.Designer.vb
+++ /dev/null
@@ -1,38 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' This code was generated by a tool.
-' Runtime Version:4.0.30319.42000
-'
-' Changes to this file may cause incorrect behavior and will be lost if
-' the code is regenerated.
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-
-Namespace My
-
- 'NOTE: This file is auto-generated; do not modify it directly. To make changes,
- ' or if you encounter build errors in this file, go to the Project Designer
- ' (go to Project Properties or double-click the My Project node in
- ' Solution Explorer), and make changes on the Application tab.
- '
- Partial Friend Class MyApplication
-
- _
- Public Sub New()
- MyBase.New(Global.Microsoft.VisualBasic.ApplicationServices.AuthenticationMode.Windows)
- Me.IsSingleInstance = false
- Me.EnableVisualStyles = true
- Me.SaveMySettingsOnExit = true
- Me.ShutDownStyle = Global.Microsoft.VisualBasic.ApplicationServices.ShutdownMode.AfterMainFormCloses
- End Sub
-
- _
- Protected Overrides Sub OnCreateMainForm()
- Me.MainForm = Global.ET_Demo.frmDemo
- End Sub
- End Class
-End Namespace
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Application.myapp b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Application.myapp
deleted file mode 100644
index 1243847..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Application.myapp
+++ /dev/null
@@ -1,11 +0,0 @@
-
-
- true
- Form1
- false
- 0
- true
- 0
- 0
- true
-
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/AssemblyInfo.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/AssemblyInfo.vb
deleted file mode 100644
index fd8a417..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/AssemblyInfo.vb
+++ /dev/null
@@ -1,35 +0,0 @@
-Imports System
-Imports System.Reflection
-Imports System.Runtime.InteropServices
-
-' 有关程序集的一般信息由以下
-' 控制。更改这些特性值可修改
-' 与程序集关联的信息。
-
-'查看程序集特性的值
-
-
-
-
-
-
-
-
-
-
-'如果此项目向 COM 公开,则下列 GUID 用于 typelib 的 ID
-
-
-' 程序集的版本信息由下列四个值组成:
-'
-' 主版本
-' 次版本
-' 生成号
-' 修订号
-'
-'可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
-'通过使用 "*",如下所示:
-'
-
-
-
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Resources.Designer.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Resources.Designer.vb
deleted file mode 100644
index 24dbe56..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Resources.Designer.vb
+++ /dev/null
@@ -1,62 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' This code was generated by a tool.
-' Runtime Version:4.0.30319.42000
-'
-' Changes to this file may cause incorrect behavior and will be lost if
-' the code is regenerated.
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-
-Namespace My.Resources
-
- 'This class was auto-generated by the StronglyTypedResourceBuilder
- 'class via a tool like ResGen or Visual Studio.
- 'To add or remove a member, edit your .ResX file then rerun ResGen
- 'with the /str option, or rebuild your VS project.
- '''
- ''' A strongly-typed resource class, for looking up localized strings, etc.
- '''
- _
- Friend Module Resources
-
- Private resourceMan As Global.System.Resources.ResourceManager
-
- Private resourceCulture As Global.System.Globalization.CultureInfo
-
- '''
- ''' Returns the cached ResourceManager instance used by this class.
- '''
- _
- Friend ReadOnly Property ResourceManager() As Global.System.Resources.ResourceManager
- Get
- If Object.ReferenceEquals(resourceMan, Nothing) Then
- Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("ET_Demo.Resources", GetType(Resources).Assembly)
- resourceMan = temp
- End If
- Return resourceMan
- End Get
- End Property
-
- '''
- ''' Overrides the current thread's CurrentUICulture property for all
- ''' resource lookups using this strongly typed resource class.
- '''
- _
- Friend Property Culture() As Global.System.Globalization.CultureInfo
- Get
- Return resourceCulture
- End Get
- Set(ByVal value As Global.System.Globalization.CultureInfo)
- resourceCulture = value
- End Set
- End Property
- End Module
-End Namespace
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Resources.resx b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Resources.resx
deleted file mode 100644
index af7dbeb..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Resources.resx
+++ /dev/null
@@ -1,117 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Settings.Designer.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Settings.Designer.vb
deleted file mode 100644
index 551e93e..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Settings.Designer.vb
+++ /dev/null
@@ -1,73 +0,0 @@
-'------------------------------------------------------------------------------
-'
-' This code was generated by a tool.
-' Runtime Version:4.0.30319.42000
-'
-' Changes to this file may cause incorrect behavior and will be lost if
-' the code is regenerated.
-'
-'------------------------------------------------------------------------------
-
-Option Strict On
-Option Explicit On
-
-
-Namespace My
-
- _
- Partial Friend NotInheritable Class MySettings
- Inherits Global.System.Configuration.ApplicationSettingsBase
-
- Private Shared defaultInstance As MySettings = CType(Global.System.Configuration.ApplicationSettingsBase.Synchronized(New MySettings), MySettings)
-
-#Region "My.Settings Auto-Save Functionality"
-#If _MyType = "WindowsForms" Then
- Private Shared addedHandler As Boolean
-
- Private Shared addedHandlerLockObject As New Object
-
- _
- Private Shared Sub AutoSaveSettings(ByVal sender As Global.System.Object, ByVal e As Global.System.EventArgs)
- If My.Application.SaveMySettingsOnExit Then
- My.Settings.Save()
- End If
- End Sub
-#End If
-#End Region
-
- Public Shared ReadOnly Property [Default]() As MySettings
- Get
-
-#If _MyType = "WindowsForms" Then
- If Not addedHandler Then
- SyncLock addedHandlerLockObject
- If Not addedHandler Then
- AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings
- addedHandler = True
- End If
- End SyncLock
- End If
-#End If
- Return defaultInstance
- End Get
- End Property
- End Class
-End Namespace
-
-Namespace My
-
- _
- Friend Module MySettingsProperty
-
- _
- Friend ReadOnly Property Settings() As Global.ET_Demo.My.MySettings
- Get
- Return Global.ET_Demo.My.MySettings.Default
- End Get
- End Property
- End Module
-End Namespace
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Settings.settings b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Settings.settings
deleted file mode 100644
index 85b890b..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/My Project/Settings.settings
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
-
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/frmDemo.Designer.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/frmDemo.Designer.vb
deleted file mode 100644
index ee5dcb7..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/frmDemo.Designer.vb
+++ /dev/null
@@ -1,236 +0,0 @@
- _
-Partial Class frmDemo
- ' Inherits System.Windows.Forms.Form
- Inherits COM_Kit.frmBasisTemplat
- 'Form 重写 Dispose,以清理组件列表。
- _
- Protected Overrides Sub Dispose(ByVal disposing As Boolean)
- Try
- If disposing AndAlso components IsNot Nothing Then
- components.Dispose()
- End If
- Finally
- MyBase.Dispose(disposing)
- End Try
- End Sub
-
- 'Windows 窗体设计器所必需的
- Private components As System.ComponentModel.IContainer
-
- '注意: 以下过程是 Windows 窗体设计器所必需的
- '可以使用 Windows 窗体设计器修改它。
- '不要使用代码编辑器修改它。
- _
- Private Sub InitializeComponent()
- Me.iugBasis = New iMESUltraGrid.iMESUltraGridControl()
- Me.iugDetail = New iMESUltraGrid.iMESUltraGridControl()
- Me.btnClose = New Infragistics.Win.Misc.UltraButton()
- Me.btnApprove = New Infragistics.Win.Misc.UltraButton()
- Me.btnEMail = New Infragistics.Win.Misc.UltraButton()
- Me.btnDCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnDDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnDEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnAdd = New Infragistics.Win.Misc.UltraButton()
- Me.btnDAdd = New Infragistics.Win.Misc.UltraButton()
- Me.btnDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnEdit = New Infragistics.Win.Misc.UltraButton()
- Me.SuspendLayout()
- '
- 'iugBasis
- '
- Me.iugBasis.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugBasis.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugBasis.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugBasis.Identity = "iMES"
- Me.iugBasis.IdentityForm = ""
- Me.iugBasis.LayOutFilePath = ""
- Me.iugBasis.Location = New System.Drawing.Point(12, 53)
- Me.iugBasis.Name = "iugBasis"
- Me.iugBasis.PrintFitWidthToPages = 0
- Me.iugBasis.PrintLandscape = True
- Me.iugBasis.PrintPageFooter = ""
- Me.iugBasis.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugBasis.PrintPageFooterHeight = 20
- Me.iugBasis.PrintPageHeader = ""
- Me.iugBasis.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugBasis.PrintPageHeaderHeight = 20
- Me.iugBasis.PrintZoom = 1.0R
- Me.iugBasis.Size = New System.Drawing.Size(791, 200)
- Me.iugBasis.TabIndex = 41
- Me.iugBasis.UserNo = "iMES"
- '
- 'iugDetail
- '
- Me.iugDetail.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugDetail.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugDetail.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugDetail.Identity = "iMES"
- Me.iugDetail.IdentityForm = ""
- Me.iugDetail.LayOutFilePath = ""
- Me.iugDetail.Location = New System.Drawing.Point(12, 260)
- Me.iugDetail.Name = "iugDetail"
- Me.iugDetail.PrintFitWidthToPages = 0
- Me.iugDetail.PrintLandscape = True
- Me.iugDetail.PrintPageFooter = ""
- Me.iugDetail.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageFooterHeight = 20
- Me.iugDetail.PrintPageHeader = ""
- Me.iugDetail.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageHeaderHeight = 20
- Me.iugDetail.PrintZoom = 1.0R
- Me.iugDetail.Size = New System.Drawing.Size(791, 291)
- Me.iugDetail.TabIndex = 42
- Me.iugDetail.UserNo = "iMES"
- '
- 'btnClose
- '
- Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnClose.Location = New System.Drawing.Point(827, 523)
- Me.btnClose.Name = "btnClose"
- Me.btnClose.Size = New System.Drawing.Size(88, 32)
- Me.btnClose.TabIndex = 48
- Me.btnClose.Text = "Close (&X)"
- '
- 'btnApprove
- '
- Me.btnApprove.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnApprove.Location = New System.Drawing.Point(827, 213)
- Me.btnApprove.Name = "btnApprove"
- Me.btnApprove.Size = New System.Drawing.Size(88, 32)
- Me.btnApprove.TabIndex = 53
- Me.btnApprove.Text = "Approve(&Y)"
- '
- 'btnEMail
- '
- Me.btnEMail.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEMail.Location = New System.Drawing.Point(827, 429)
- Me.btnEMail.Name = "btnEMail"
- Me.btnEMail.Size = New System.Drawing.Size(88, 32)
- Me.btnEMail.TabIndex = 47
- Me.btnEMail.Text = "Mail"
- '
- 'btnDCopy
- '
- Me.btnDCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDCopy.Location = New System.Drawing.Point(827, 389)
- Me.btnDCopy.Name = "btnDCopy"
- Me.btnDCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnDCopy.TabIndex = 46
- Me.btnDCopy.Text = "Copy"
- '
- 'btnCopy
- '
- Me.btnCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnCopy.Location = New System.Drawing.Point(827, 173)
- Me.btnCopy.Name = "btnCopy"
- Me.btnCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnCopy.TabIndex = 52
- Me.btnCopy.Text = "Copy(&C)"
- '
- 'btnDDel
- '
- Me.btnDDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDDel.Location = New System.Drawing.Point(827, 349)
- Me.btnDDel.Name = "btnDDel"
- Me.btnDDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDDel.TabIndex = 45
- Me.btnDDel.Text = "DEL"
- '
- 'btnDEdit
- '
- Me.btnDEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDEdit.Location = New System.Drawing.Point(827, 309)
- Me.btnDEdit.Name = "btnDEdit"
- Me.btnDEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnDEdit.TabIndex = 44
- Me.btnDEdit.Text = "EDIT"
- '
- 'btnAdd
- '
- Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnAdd.Location = New System.Drawing.Point(827, 53)
- Me.btnAdd.Name = "btnAdd"
- Me.btnAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnAdd.TabIndex = 49
- Me.btnAdd.Text = "Add(&A)"
- '
- 'btnDAdd
- '
- Me.btnDAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDAdd.Location = New System.Drawing.Point(827, 269)
- Me.btnDAdd.Name = "btnDAdd"
- Me.btnDAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnDAdd.TabIndex = 43
- Me.btnDAdd.Text = "ADD"
- '
- 'btnDel
- '
- Me.btnDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDel.Location = New System.Drawing.Point(827, 133)
- Me.btnDel.Name = "btnDel"
- Me.btnDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDel.TabIndex = 51
- Me.btnDel.Text = "Del(&D)"
- '
- 'btnEdit
- '
- Me.btnEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEdit.Location = New System.Drawing.Point(827, 93)
- Me.btnEdit.Name = "btnEdit"
- Me.btnEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnEdit.TabIndex = 50
- Me.btnEdit.Text = "Edit(&E)"
- '
- 'frmDemo
- '
- Me.AutoScaleDimensions = New System.Drawing.SizeF(7.0!, 15.0!)
- Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
- Me.ClientSize = New System.Drawing.Size(927, 562)
- Me.Controls.Add(Me.btnClose)
- Me.Controls.Add(Me.btnApprove)
- Me.Controls.Add(Me.btnEMail)
- Me.Controls.Add(Me.btnDCopy)
- Me.Controls.Add(Me.btnCopy)
- Me.Controls.Add(Me.btnDDel)
- Me.Controls.Add(Me.btnDEdit)
- Me.Controls.Add(Me.btnAdd)
- Me.Controls.Add(Me.btnDAdd)
- Me.Controls.Add(Me.btnDel)
- Me.Controls.Add(Me.btnEdit)
- Me.Controls.Add(Me.iugDetail)
- Me.Controls.Add(Me.iugBasis)
- Me.Margin = New System.Windows.Forms.Padding(3, 4, 3, 4)
- Me.Name = "frmDemo"
- Me.Text = "Demo"
- Me.Controls.SetChildIndex(Me.iugBasis, 0)
- Me.Controls.SetChildIndex(Me.iugDetail, 0)
- Me.Controls.SetChildIndex(Me.btnEdit, 0)
- Me.Controls.SetChildIndex(Me.btnDel, 0)
- Me.Controls.SetChildIndex(Me.btnDAdd, 0)
- Me.Controls.SetChildIndex(Me.btnAdd, 0)
- Me.Controls.SetChildIndex(Me.btnDEdit, 0)
- Me.Controls.SetChildIndex(Me.btnDDel, 0)
- Me.Controls.SetChildIndex(Me.btnCopy, 0)
- Me.Controls.SetChildIndex(Me.btnDCopy, 0)
- Me.Controls.SetChildIndex(Me.btnEMail, 0)
- Me.Controls.SetChildIndex(Me.btnApprove, 0)
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.ResumeLayout(False)
-
- End Sub
-
- Friend WithEvents iugBasis As iMESUltraGrid.iMESUltraGridControl
- Friend WithEvents iugDetail As iMESUltraGrid.iMESUltraGridControl
- Friend WithEvents btnClose As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnApprove As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnEMail As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDCopy As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnCopy As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDDel As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDEdit As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnAdd As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDAdd As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDel As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnEdit As Infragistics.Win.Misc.UltraButton
-End Class
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/frmDemo.resx b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/frmDemo.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/frmDemo.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/frmDemo.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/frmDemo.vb
deleted file mode 100644
index 4d5c94c..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Demo/frmDemo.vb
+++ /dev/null
@@ -1,14 +0,0 @@
-Imports iMESExceptionManager
-
-Imports Infragistics.Win
-Imports Infragistics.Win.UltraWinGrid
-Public Class frmDemo
-
- Private Sub frmDemo_Load(sender As Object, e As EventArgs) Handles MyBase.Load
-
- End Sub
-
- Private Sub btnAdd_Click(sender As Object, e As EventArgs) Handles btnAdd.Click
-
- End Sub
-End Class
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/ET_Subcontractor.sln b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/ET_Subcontractor.sln
deleted file mode 100644
index 85b1902..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/ET_Subcontractor.sln
+++ /dev/null
@@ -1,39 +0,0 @@
-
-Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio 14
-VisualStudioVersion = 14.0.25123.0
-MinimumVisualStudioVersion = 10.0.40219.1
-Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "ET_Subcontractor", "ET_Subcontractor.vbproj", "{D6EE7B96-F10E-44E2-9731-162B70B4C8DD}"
-EndProject
-Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Test", "..\..\Test\Test.vbproj", "{C4A48E3F-38E4-4E88-A47D-FA5510686E57}"
-EndProject
-Global
- GlobalSection(SolutionConfigurationPlatforms) = preSolution
- Debug|x86 = Debug|x86
- Release|x86 = Release|x86
- EndGlobalSection
- GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.ActiveCfg = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Debug|x86.Build.0 = Debug|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.ActiveCfg = Release|x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}.Release|x86.Build.0 = Release|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.ActiveCfg = Debug|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Debug|x86.Build.0 = Debug|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Release|x86.ActiveCfg = Release|x86
- {C4A48E3F-38E4-4E88-A47D-FA5510686E57}.Release|x86.Build.0 = Release|x86
- EndGlobalSection
- GlobalSection(SolutionProperties) = preSolution
- HideSolutionNode = FALSE
- EndGlobalSection
- GlobalSection(TeamFoundationVersionControl) = preSolution
- SccNumberOfProjects = 3
- SccEnterpriseProvider = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C}
- SccTeamFoundationServer = http://tfs.imestech.com:8080/tfs/messeries6
- SccProjectUniqueName0 = ET_Subcontractor.vbproj
- SccLocalPath0 = .
- SccProjectUniqueName1 = ..\\..\\Test\\Test.vbproj
- SccProjectName1 = ../../Test
- SccLocalPath1 = ..\\..\\Test
- SccLocalPath2 = .
- EndGlobalSection
-EndGlobal
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/ET_Subcontractor.vbproj b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/ET_Subcontractor.vbproj
deleted file mode 100644
index 0c339dc..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/ET_Subcontractor.vbproj
+++ /dev/null
@@ -1,205 +0,0 @@
-
-
-
-
- Debug
- x86
- {D6EE7B96-F10E-44E2-9731-162B70B4C8DD}
- Library
- ET_Subcontractor
- ET_Subcontractor
- 512
- Windows
- v4.6.2
-
- SAK
- SAK
- SAK
- SAK
-
-
- On
-
-
- Binary
-
-
- Off
-
-
- On
-
-
- true
- true
- true
- ..\..\..\MESClient\
- ET_Subcontractor.xml
- 0
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- full
- x86
- MinimumRecommendedRules.ruleset
- false
-
-
- true
- ..\..\..\MESClient\
- ET_Subcontractor.xml
- true
- 0
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
- pdbonly
- x86
- MinimumRecommendedRules.ruleset
- false
-
-
- true
-
-
- iMES.snk
-
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinGrid.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.UltraWinEditors.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Win.Misc.v19.1.dll
- False
-
-
- False
- C:\Program Files (x86)\Infragistics\2019.1\Windows Forms\CLR4.0\Bin\Infragistics4.Shared.v19.1.dll
- False
-
-
- ..\..\..\MESClient\COM_Kit.dll
- False
-
-
- ..\..\..\MES_C_DLL\iMESExceptionManager.dll
- False
-
-
- ..\..\..\MES_C_DLL\iMESUltraGrid.dll
- False
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- modConstant.vb
-
-
- Form1.vb
-
-
- Form
-
-
- Form
-
-
- Form
-
-
- Form
-
-
- Form
-
-
-
- True
- Application.myapp
-
-
- True
- True
- Resources.resx
-
-
- True
- Settings.settings
- True
-
-
-
-
- frmBusiness21670.vb
-
-
- frmSubcontractor.vb
-
-
- frmSubcontractorContDef.vb
-
-
- frmSubcontractorDef.vb
-
-
-
- VbMyResourcesResXFileCodeGenerator
- Resources.Designer.vb
- My.Resources
- Designer
-
-
-
-
-
- MyApplicationCodeGenerator
- Application.Designer.vb
-
-
- SettingsSingleFileGenerator
- My
- Settings.Designer.vb
-
-
-
-
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/ET_Subcontractor.vbproj.vspscc b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/ET_Subcontractor.vbproj.vspscc
deleted file mode 100644
index b6d3289..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/ET_Subcontractor.vbproj.vspscc
+++ /dev/null
@@ -1,10 +0,0 @@
-""
-{
-"FILE_VERSION" = "9237"
-"ENLISTMENT_CHOICE" = "NEVER"
-"PROJECT_FILE_RELATIVE_PATH" = ""
-"NUMBER_OF_EXCLUDED_FILES" = "0"
-"ORIGINAL_PROJECT_FILE_PATH" = ""
-"NUMBER_OF_NESTED_PROJECTS" = "0"
-"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROVIDER"
-}
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/Form1.Designer.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/Form1.Designer.vb
deleted file mode 100644
index c29cf72..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/Form1.Designer.vb
+++ /dev/null
@@ -1,32 +0,0 @@
-
-Partial Class Form1
-
-
- Inherits COM_Kit.frmBasisTemplat
-
- 'Form 重写 Dispose,以清理组件列表。
-
- Protected Overrides Sub Dispose(ByVal disposing As Boolean)
- Try
- If disposing AndAlso components IsNot Nothing Then
- components.Dispose()
- End If
- Finally
- MyBase.Dispose(disposing)
- End Try
- End Sub
-
- 'Windows 窗体设计器所必需的
- Private components As System.ComponentModel.IContainer
-
- '注意: 以下过程是 Windows 窗体设计器所必需的
- '可以使用 Windows 窗体设计器修改它。
- '不要使用代码编辑器修改它。
-
- Private Sub InitializeComponent()
- components = New System.ComponentModel.Container
- Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
- Me.ClientSize = New System.Drawing.Size(800, 450)
- Me.Text = "Form1"
- End Sub
-End Class
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/Form1.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/Form1.vb
deleted file mode 100644
index 10d55d4..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/Form1.vb
+++ /dev/null
@@ -1,3 +0,0 @@
-Public Class Form1
-
-End Class
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/AssemblyInfo.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/AssemblyInfo.vb
deleted file mode 100644
index b0cdd98..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/AssemblyInfo.vb
+++ /dev/null
@@ -1,35 +0,0 @@
-Imports System
-Imports System.Reflection
-Imports System.Runtime.InteropServices
-
-' 組件的一般資訊是由下列的屬性集控制。
-' 變更這些屬性的值即可修改組件的相關
-' 資訊。
-
-' 檢閱組件屬性的值
-
-
-
-
-
-
-
-
-
-
-'下列 GUID 為專案公開 (Expose) 至 COM 時所要使用的 typelib ID
-
-
-' 組件的版本資訊由下列四個值所組成:
-'
-' 主要版本
-' 次要版本
-' 組建編號
-' 修訂編號
-'
-' 您可以指定所有的值,也可以依照以下的方式,使用 '*' 將組建和修訂編號
-' 指定為預設值:
-'
-
-
-
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/BuildIncrementVersionInfo.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/BuildIncrementVersionInfo.vb
deleted file mode 100644
index 755cff8..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/BuildIncrementVersionInfo.vb
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/Resources.resx b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/Resources.resx
deleted file mode 100644
index af7dbeb..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/Resources.resx
+++ /dev/null
@@ -1,117 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/Settings.settings b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/Settings.settings
deleted file mode 100644
index 85b890b..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/Settings.settings
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
-
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/licenses.licx b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/licenses.licx
deleted file mode 100644
index e3f40e2..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/My Project/licenses.licx
+++ /dev/null
@@ -1,7 +0,0 @@
-Infragistics.Win.Misc.UltraButton, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraRadioButton, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraComboEditor, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraGroupBox, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.UltraWinEditors.UltraTextEditor, Infragistics4.Win.UltraWinEditors.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraLabel, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
-Infragistics.Win.Misc.UltraPanel, Infragistics4.Win.Misc.v19.1, Version=19.1.20191.294, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmBusiness21670.resx b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmBusiness21670.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmBusiness21670.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmBusiness21670.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmBusiness21670.vb
deleted file mode 100644
index cbad98c..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmBusiness21670.vb
+++ /dev/null
@@ -1,1129 +0,0 @@
-Imports iMESExceptionManager
-
-Imports Infragistics.Win
-Imports Infragistics.Win.UltraWinGrid
-Public Class frmSubcontractor1
-
- Inherits COM_Kit.frmBasisTemplat
-
- Public PrivFunNo As String = defString
-
- '//WS相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT '宣告Web Service物件?
- Dim tmpStringReader As System.IO.StringReader '將字串轉換成可讀入DataSet的物件
- Dim XmlData As String '儲存取回之資料
- Dim XmlSchema As String '儲存取回之資料結構
- Dim InXml As String '儲存呼叫Web Service的傳入參數(Request字串)
- Dim OutXml As String '儲存Web Service的傳回值(Response字串)
- Dim strIdentity As String '儲存Identity XML字串?
- Dim strParameter As String '儲存Parameter XML字串
-
- '//資料表相關變數
-
- Dim dsENT As New DataSet '資料集:儲存取回之資料?
-
- Dim tblENTSubcontractor As String '儲存取回資料表的名稱(master)?
- Dim tblENTSubcontractorCont As String '明細資料表名稱(detail)
- Dim strFilter As String 'Filter string及列印的過濾條件
-
- '//其他共用變數
- Dim SubcontractorNo As String 'for Gird to Focus
- Dim ContactorName As String 'for DetailGrid to Focus
- Dim ugrRow As Infragistics.Win.UltraWinGrid.UltraGridRow
- Friend WithEvents btnAdd As Misc.UltraButton
- Friend WithEvents btnEdit As Misc.UltraButton
- Friend WithEvents btnDel As Misc.UltraButton
- Friend WithEvents btnCopy As Misc.UltraButton
- Friend WithEvents btnApprove As Misc.UltraButton
- Friend WithEvents iugSubcontractor As iMESUltraGrid.iMESUltraGridControl
- Dim i As Integer
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.Container
- Friend WithEvents iugDetail As iMESUltraGrid.iMESUltraGridControl
- Friend WithEvents btnClose As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnEMail As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDCopy As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDDel As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDEdit As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDAdd As Infragistics.Win.Misc.UltraButton
- Private Sub InitializeComponent()
- Me.btnClose = New Infragistics.Win.Misc.UltraButton()
- Me.btnEMail = New Infragistics.Win.Misc.UltraButton()
- Me.btnDCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnDDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnDEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDAdd = New Infragistics.Win.Misc.UltraButton()
- Me.iugDetail = New iMESUltraGrid.iMESUltraGridControl()
- Me.btnAdd = New Infragistics.Win.Misc.UltraButton()
- Me.btnEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnApprove = New Infragistics.Win.Misc.UltraButton()
- Me.iugSubcontractor = New iMESUltraGrid.iMESUltraGridControl()
- Me.SuspendLayout()
- '
- 'btnClose
- '
- Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnClose.Location = New System.Drawing.Point(912, 552)
- Me.btnClose.Name = "btnClose"
- Me.btnClose.Size = New System.Drawing.Size(88, 32)
- Me.btnClose.TabIndex = 18
- Me.btnClose.Text = "Close (&X)"
- '
- 'btnEMail
- '
- Me.btnEMail.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEMail.Location = New System.Drawing.Point(912, 429)
- Me.btnEMail.Name = "btnEMail"
- Me.btnEMail.Size = New System.Drawing.Size(88, 32)
- Me.btnEMail.TabIndex = 17
- Me.btnEMail.Text = "Mail"
- '
- 'btnDCopy
- '
- Me.btnDCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDCopy.Location = New System.Drawing.Point(912, 389)
- Me.btnDCopy.Name = "btnDCopy"
- Me.btnDCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnDCopy.TabIndex = 16
- Me.btnDCopy.Text = "Copy"
- '
- 'btnDDel
- '
- Me.btnDDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDDel.Location = New System.Drawing.Point(912, 349)
- Me.btnDDel.Name = "btnDDel"
- Me.btnDDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDDel.TabIndex = 15
- Me.btnDDel.Text = "DEL"
- '
- 'btnDEdit
- '
- Me.btnDEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDEdit.Location = New System.Drawing.Point(912, 309)
- Me.btnDEdit.Name = "btnDEdit"
- Me.btnDEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnDEdit.TabIndex = 14
- Me.btnDEdit.Text = "EDIT"
- '
- 'btnDAdd
- '
- Me.btnDAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDAdd.Location = New System.Drawing.Point(912, 269)
- Me.btnDAdd.Name = "btnDAdd"
- Me.btnDAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnDAdd.TabIndex = 13
- Me.btnDAdd.Text = "ADD"
- '
- 'iugDetail
- '
- Me.iugDetail.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugDetail.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugDetail.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugDetail.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugDetail.Identity = "IMes"
- Me.iugDetail.IdentityForm = ""
- Me.iugDetail.LayOutFilePath = ""
- Me.iugDetail.Location = New System.Drawing.Point(12, 270)
- Me.iugDetail.Name = "iugDetail"
- Me.iugDetail.PrintFitWidthToPages = 0
- Me.iugDetail.PrintLandscape = True
- Me.iugDetail.PrintPageFooter = ""
- Me.iugDetail.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageFooterHeight = 20
- Me.iugDetail.PrintPageHeader = ""
- Me.iugDetail.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageHeaderHeight = 20
- Me.iugDetail.PrintZoom = 1.0R
- Me.iugDetail.Size = New System.Drawing.Size(894, 314)
- Me.iugDetail.TabIndex = 12
- Me.iugDetail.UserNo = "IMes"
- '
- 'btnAdd
- '
- Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnAdd.Location = New System.Drawing.Point(912, 53)
- Me.btnAdd.Name = "btnAdd"
- Me.btnAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnAdd.TabIndex = 20
- Me.btnAdd.Text = "Add(&A)"
- '
- 'btnEdit
- '
- Me.btnEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEdit.Location = New System.Drawing.Point(912, 93)
- Me.btnEdit.Name = "btnEdit"
- Me.btnEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnEdit.TabIndex = 21
- Me.btnEdit.Text = "Edit(&E)"
- '
- 'btnDel
- '
- Me.btnDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDel.Location = New System.Drawing.Point(912, 133)
- Me.btnDel.Name = "btnDel"
- Me.btnDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDel.TabIndex = 22
- Me.btnDel.Text = "Del(&D)"
- '
- 'btnCopy
- '
- Me.btnCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnCopy.Location = New System.Drawing.Point(912, 173)
- Me.btnCopy.Name = "btnCopy"
- Me.btnCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnCopy.TabIndex = 23
- Me.btnCopy.Text = "Copy(&C)"
- '
- 'btnApprove
- '
- Me.btnApprove.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnApprove.Location = New System.Drawing.Point(912, 213)
- Me.btnApprove.Name = "btnApprove"
- Me.btnApprove.Size = New System.Drawing.Size(88, 32)
- Me.btnApprove.TabIndex = 24
- Me.btnApprove.Text = "Approve(&Y)"
- '
- 'iugSubcontractor
- '
- Me.iugSubcontractor.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugSubcontractor.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugSubcontractor.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugSubcontractor.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugSubcontractor.Identity = "IMes"
- Me.iugSubcontractor.IdentityForm = ""
- Me.iugSubcontractor.LayOutFilePath = ""
- Me.iugSubcontractor.Location = New System.Drawing.Point(12, 53)
- Me.iugSubcontractor.Name = "iugSubcontractor"
- Me.iugSubcontractor.PrintFitWidthToPages = 0
- Me.iugSubcontractor.PrintLandscape = True
- Me.iugSubcontractor.PrintPageFooter = ""
- Me.iugSubcontractor.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageFooterHeight = 20
- Me.iugSubcontractor.PrintPageHeader = ""
- Me.iugSubcontractor.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageHeaderHeight = 20
- Me.iugSubcontractor.PrintZoom = 1.0R
- Me.iugSubcontractor.Size = New System.Drawing.Size(894, 192)
- Me.iugSubcontractor.TabIndex = 25
- Me.iugSubcontractor.UserNo = "IMes"
- '
- 'frmSubcontractor
- '
- Me.ClientSize = New System.Drawing.Size(1008, 591)
- Me.Controls.Add(Me.btnClose)
- Me.Controls.Add(Me.btnApprove)
- Me.Controls.Add(Me.btnEMail)
- Me.Controls.Add(Me.btnDCopy)
- Me.Controls.Add(Me.btnCopy)
- Me.Controls.Add(Me.btnDDel)
- Me.Controls.Add(Me.iugSubcontractor)
- Me.Controls.Add(Me.btnDEdit)
- Me.Controls.Add(Me.btnAdd)
- Me.Controls.Add(Me.btnDAdd)
- Me.Controls.Add(Me.btnDel)
- Me.Controls.Add(Me.iugDetail)
- Me.Controls.Add(Me.btnEdit)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractor"
- Me.Text = "ENT Subcontractor & Contactor"
- Me.WindowState = System.Windows.Forms.FormWindowState.Maximized
- Me.Controls.SetChildIndex(Me.btnEdit, 0)
- Me.Controls.SetChildIndex(Me.iugDetail, 0)
- Me.Controls.SetChildIndex(Me.btnDel, 0)
- Me.Controls.SetChildIndex(Me.btnDAdd, 0)
- Me.Controls.SetChildIndex(Me.btnAdd, 0)
- Me.Controls.SetChildIndex(Me.btnDEdit, 0)
- Me.Controls.SetChildIndex(Me.iugSubcontractor, 0)
- Me.Controls.SetChildIndex(Me.btnDDel, 0)
- Me.Controls.SetChildIndex(Me.btnCopy, 0)
- Me.Controls.SetChildIndex(Me.btnDCopy, 0)
- Me.Controls.SetChildIndex(Me.btnEMail, 0)
- Me.Controls.SetChildIndex(Me.btnApprove, 0)
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractor_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- Call funiMESUltraGridIni() 'Grid初始設定
-
- '//取出資料
- Call funLoadSubcontractor()
-
- SetIssueState(Issue.Unfrozen) '預設在Unforzen上
- SetSearchFieldName(New String() {"SubcontractorNo", "SubcontractorNaME"}) '設置搜尋欄位
-
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractor_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- If Not dsENT Is Nothing Then dsENT.Dispose()
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
- Protected Overrides Sub rdoIssue_CheckedChanged(sender As Object, e As EventArgs)
- If IsNothing(dsENT) Then Exit Sub
-
- Select Case GetIssueState()
- Case Issue.Unfrozen
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=0"
- Case Issue.Pending
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=1"
- Case Issue.Active
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=2"
- Case Issue.Unused
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=-1"
- End Select
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
- Call funShowActiveDetail()
- End Sub
-
- Protected Overrides Sub Finalize()
- MyBase.Finalize()
- End Sub
-
- Private Sub btnAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAdd.Click
-
- Dim fSubcontractorDef As New frmSubcontractorDef
-
- fSubcontractorDef.DefMode = 0
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End Sub
-
- Private Sub btnEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEdit.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'")
-
- '核准狀態為"Unfrozen"者才可修改
-
- If Rows(0).Item("IssueState") <> 0 Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-202202", "[%NOT ALLOWED TO EDIT%]"), MsgBoxStyle.Exclamation, Me.Text)
- Exit Sub
- End If
-
- Dim fSubcontractorDef As New frmSubcontractorDef
- fSubcontractorDef.DefMode = 1
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDel.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Or intIssueState = -1 Or intIssueState = 2 Then '狀態為Unforzen或Unused時直接刪除
-
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", CInput(intIssueState), "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOWED TO delete%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCopy.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorDef As New frmSubcontractorDef
- fSubcontractorDef.DefMode = 2
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnApprove_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnApprove.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100002", "[%ARE YOU SURE TO APPROVE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Then
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo").Value.ToString), "")
- strParameter += CombineXMLParameter("issuestate", "IssueState", "String", intIssueState, "")
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.ApproveSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.ApproveSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.ApproveSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Approve failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOW TO APPROVE%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDAdd.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
-
- 'Dim Rows As DataRow()
- Dim fSubcontractorContDef As New frmSubcontractorContDef
-
- fSubcontractorContDef.DefMode = 0
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- End If
- End Sub
-
- Private Sub btnDEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDEdit.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmSubcontractorContDef
- fSubcontractorContDef.DefMode = 1
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnDDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDDel.Click
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
-
- Cursor.Current = Cursors.WaitCursor
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugDetail.iMESUltraGrid.Selected.Rows.Count - 1
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("ContactorName", "ContactorName", "String", CInput(Me.iugDetail.iMESUltraGrid.Selected.Rows(i).Cells("ContactorName").Value.ToString), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractorCont", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
-
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDCopy.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmSubcontractorContDef
- fSubcontractorContDef.DefMode = 2
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEMail.Click
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
- Dim proMail As New System.Diagnostics.Process
- Dim strAccount As String
-
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- strAccount = "mailto:" & Rows(0).Item("EMail").ToString
- proMail.Start(strAccount)
-
- End If
-
- End Sub
-
- Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnQuery_Click(sender As Object, e As EventArgs)
- Cursor.Current = Cursors.WaitCursor
-
- funLoadSubcontractor()
-
- Cursor.Current = Cursors.Default
- End Sub
-
-#Region "Ultra Grid"
-
- Private Sub iugSubcontractor_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugSubcontractor.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo")
- .Header.Caption = "SubcontractorNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("SubcontractorName")
- .Header.Caption = "SubcontractorName"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("IssueState")
- .Header.Caption = "IssueState"
- .Width = 114
- .Hidden = True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 7
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
- Private Sub iugSubcontractor_iMESUltraGrid_AfterRowActivate(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles iugSubcontractor.iMESUltraGrid_AfterRowActivate
-
- 'IsGroupByRow不做任何處理
- If Not iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
- Else
- Exit Sub
- End If
-
- End Sub
-
- Private Sub iugDetail_iMESUltraGrid_InitializeLayOut(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugDetail.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo")
- .Header.Caption = "SubcontractorNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("ContactorName")
- .Header.Caption = "ContactorName"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("TelNo")
- .Header.Caption = "TelNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("FaxNo")
- .Header.Caption = "FaxNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("Title")
- .Header.Caption = "Title"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("Address")
- .Header.Caption = "Address"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("EMail")
- .Header.Caption = "EMail"
- .Width = 150
- .Hidden = False
- .CellAppearance.ForeColor = System.Drawing.Color.Blue
- .CellAppearance.FontData.Underline = DefaultableBoolean.True
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 200
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 7
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 8
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 9
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 10
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 11
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
-#End Region
-
-#Region "Load Function"
-
- '//取出tblENTSubcontractor 外包商資料
-
- Private Sub funLoadSubcontractor()
-
- '先判斷是否dataset中已有ENTSubcontractor之datatable,若有,需先remove否則會有錯誤
- If Not IsNothing(dsENT.Tables(tblENTSubcontractor)) Then
- dsENT.Tables.Remove(tblENTSubcontractor)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- '加上IssueState要求取出所有資料
- strParameter = CombineXMLParameter("issuestate", "IssueState", "Integer", defInteger, "")
- '加上查詢條件 cboSearchFieldName,txtSearchFieldValue
- strParameter += CombineXMLQueryCondition()
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.LoadSubcontractor", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
-
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractor = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractor").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
-
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractor").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractor").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- strFilter = ""
- Select Case GetIssueState()
- Case Issue.Unfrozen
- strFilter = FilterByInteger(strFilter, "IssueState", 0)
- Case Issue.Pending
- strFilter = FilterByInteger(strFilter, "IssueState", 1)
- Case Issue.Active
- strFilter = FilterByInteger(strFilter, "IssueState", 2)
- Case Issue.Unused
- strFilter = FilterByInteger(strFilter, "IssueState", -1)
- End Select
-
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = strFilter
- dsENT.Tables(tblENTSubcontractor).DefaultView.Sort = "SubcontractorNo"
-
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit Sub
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- '//取出tblENTSubcontractorCont聯絡人資料
-
- Private Sub funLoadSubcontractorCont(ByRef SubcontractorNo As String)
-
- If Not IsNothing(dsENT.Tables(tblENTSubcontractorCont)) Then
- dsENT.Tables.Remove(tblENTSubcontractorCont)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", SubcontractorNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.LoadSubcontractorCont", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractorCont = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractorcont").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- Me.iugDetail.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractorCont).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Cont Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- Private Sub funShowActiveDetail()
-
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.DataSource = Nothing
- Else
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
- End If
-
- End Sub
-
- Private Sub funiMESUltraGridIni()
-
- 'iugSubcontractor 初始設定
- With Me.iugSubcontractor.iMESUltraGrid
- .Text = ""
- .DisplayLayout.GroupByBox.Hidden = True
- .DisplayLayout.UseFixedHeaders = False
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugSubcontractor.UserNo = gUserNo
-
- 'iugDetail 初始設定
- With Me.iugDetail.iMESUltraGrid.DisplayLayout
- .GroupByBox.Hidden = True
- .Override.ExpansionIndicator = ShowExpansionIndicator.Default
- .ViewStyle = ViewStyle.SingleBand
- .RowConnectorStyle = RowConnectorStyle.Default
-
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugDetail.UserNo = gUserNo
-
- End Sub
-
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractor.resx b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractor.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractor.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractor.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractor.vb
deleted file mode 100644
index 64a05ce..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractor.vb
+++ /dev/null
@@ -1,1129 +0,0 @@
-Imports iMESExceptionManager
-
-Imports Infragistics.Win
-Imports Infragistics.Win.UltraWinGrid
-Public Class frmSubcontractor
-
- Inherits COM_Kit.frmBasisTemplat
-
- Public PrivFunNo As String = defString
-
- '//WS相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT '宣告Web Service物件?
- Dim tmpStringReader As System.IO.StringReader '將字串轉換成可讀入DataSet的物件
- Dim XmlData As String '儲存取回之資料
- Dim XmlSchema As String '儲存取回之資料結構
- Dim InXml As String '儲存呼叫Web Service的傳入參數(Request字串)
- Dim OutXml As String '儲存Web Service的傳回值(Response字串)
- Dim strIdentity As String '儲存Identity XML字串?
- Dim strParameter As String '儲存Parameter XML字串
-
- '//資料表相關變數
-
- Dim dsENT As New DataSet '資料集:儲存取回之資料?
-
- Dim tblENTSubcontractor As String '儲存取回資料表的名稱(master)?
- Dim tblENTSubcontractorCont As String '明細資料表名稱(detail)
- Dim strFilter As String 'Filter string及列印的過濾條件
-
- '//其他共用變數
- Dim SubcontractorNo As String 'for Gird to Focus
- Dim ContactorName As String 'for DetailGrid to Focus
- Dim ugrRow As Infragistics.Win.UltraWinGrid.UltraGridRow
- Friend WithEvents btnAdd As Misc.UltraButton
- Friend WithEvents btnEdit As Misc.UltraButton
- Friend WithEvents btnDel As Misc.UltraButton
- Friend WithEvents btnCopy As Misc.UltraButton
- Friend WithEvents btnApprove As Misc.UltraButton
- Friend WithEvents iugSubcontractor As iMESUltraGrid.iMESUltraGridControl
- Dim i As Integer
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.Container
- Friend WithEvents iugDetail As iMESUltraGrid.iMESUltraGridControl
- Friend WithEvents btnClose As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnEMail As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDCopy As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDDel As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDEdit As Infragistics.Win.Misc.UltraButton
- Friend WithEvents btnDAdd As Infragistics.Win.Misc.UltraButton
- Private Sub InitializeComponent()
- Me.btnClose = New Infragistics.Win.Misc.UltraButton()
- Me.btnEMail = New Infragistics.Win.Misc.UltraButton()
- Me.btnDCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnDDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnDEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDAdd = New Infragistics.Win.Misc.UltraButton()
- Me.iugDetail = New iMESUltraGrid.iMESUltraGridControl()
- Me.btnAdd = New Infragistics.Win.Misc.UltraButton()
- Me.btnEdit = New Infragistics.Win.Misc.UltraButton()
- Me.btnDel = New Infragistics.Win.Misc.UltraButton()
- Me.btnCopy = New Infragistics.Win.Misc.UltraButton()
- Me.btnApprove = New Infragistics.Win.Misc.UltraButton()
- Me.iugSubcontractor = New iMESUltraGrid.iMESUltraGridControl()
- Me.SuspendLayout()
- '
- 'btnClose
- '
- Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnClose.Location = New System.Drawing.Point(912, 552)
- Me.btnClose.Name = "btnClose"
- Me.btnClose.Size = New System.Drawing.Size(88, 32)
- Me.btnClose.TabIndex = 18
- Me.btnClose.Text = "Close (&X)"
- '
- 'btnEMail
- '
- Me.btnEMail.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEMail.Location = New System.Drawing.Point(912, 429)
- Me.btnEMail.Name = "btnEMail"
- Me.btnEMail.Size = New System.Drawing.Size(88, 32)
- Me.btnEMail.TabIndex = 17
- Me.btnEMail.Text = "Mail"
- '
- 'btnDCopy
- '
- Me.btnDCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDCopy.Location = New System.Drawing.Point(912, 389)
- Me.btnDCopy.Name = "btnDCopy"
- Me.btnDCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnDCopy.TabIndex = 16
- Me.btnDCopy.Text = "Copy"
- '
- 'btnDDel
- '
- Me.btnDDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDDel.Location = New System.Drawing.Point(912, 349)
- Me.btnDDel.Name = "btnDDel"
- Me.btnDDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDDel.TabIndex = 15
- Me.btnDDel.Text = "DEL"
- '
- 'btnDEdit
- '
- Me.btnDEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDEdit.Location = New System.Drawing.Point(912, 309)
- Me.btnDEdit.Name = "btnDEdit"
- Me.btnDEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnDEdit.TabIndex = 14
- Me.btnDEdit.Text = "EDIT"
- '
- 'btnDAdd
- '
- Me.btnDAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDAdd.Location = New System.Drawing.Point(912, 269)
- Me.btnDAdd.Name = "btnDAdd"
- Me.btnDAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnDAdd.TabIndex = 13
- Me.btnDAdd.Text = "ADD"
- '
- 'iugDetail
- '
- Me.iugDetail.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugDetail.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugDetail.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugDetail.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugDetail.Identity = "IMes"
- Me.iugDetail.IdentityForm = ""
- Me.iugDetail.LayOutFilePath = ""
- Me.iugDetail.Location = New System.Drawing.Point(12, 269)
- Me.iugDetail.Name = "iugDetail"
- Me.iugDetail.PrintFitWidthToPages = 0
- Me.iugDetail.PrintLandscape = True
- Me.iugDetail.PrintPageFooter = ""
- Me.iugDetail.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageFooterHeight = 20
- Me.iugDetail.PrintPageHeader = ""
- Me.iugDetail.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugDetail.PrintPageHeaderHeight = 20
- Me.iugDetail.PrintZoom = 1.0R
- Me.iugDetail.Size = New System.Drawing.Size(894, 314)
- Me.iugDetail.TabIndex = 12
- Me.iugDetail.UserNo = "IMes"
- '
- 'btnAdd
- '
- Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnAdd.Location = New System.Drawing.Point(912, 53)
- Me.btnAdd.Name = "btnAdd"
- Me.btnAdd.Size = New System.Drawing.Size(88, 32)
- Me.btnAdd.TabIndex = 20
- Me.btnAdd.Text = "Add(&A)"
- '
- 'btnEdit
- '
- Me.btnEdit.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnEdit.Location = New System.Drawing.Point(912, 93)
- Me.btnEdit.Name = "btnEdit"
- Me.btnEdit.Size = New System.Drawing.Size(88, 32)
- Me.btnEdit.TabIndex = 21
- Me.btnEdit.Text = "Edit(&E)"
- '
- 'btnDel
- '
- Me.btnDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnDel.Location = New System.Drawing.Point(912, 133)
- Me.btnDel.Name = "btnDel"
- Me.btnDel.Size = New System.Drawing.Size(88, 32)
- Me.btnDel.TabIndex = 22
- Me.btnDel.Text = "Del(&D)"
- '
- 'btnCopy
- '
- Me.btnCopy.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnCopy.Location = New System.Drawing.Point(912, 173)
- Me.btnCopy.Name = "btnCopy"
- Me.btnCopy.Size = New System.Drawing.Size(88, 32)
- Me.btnCopy.TabIndex = 23
- Me.btnCopy.Text = "Copy(&C)"
- '
- 'btnApprove
- '
- Me.btnApprove.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.btnApprove.Location = New System.Drawing.Point(912, 213)
- Me.btnApprove.Name = "btnApprove"
- Me.btnApprove.Size = New System.Drawing.Size(88, 32)
- Me.btnApprove.TabIndex = 24
- Me.btnApprove.Text = "Approve(&Y)"
- '
- 'iugSubcontractor
- '
- Me.iugSubcontractor.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.iugSubcontractor.EnterDirection = iMESUltraGrid.iMESUltraGridControl.EnterDirectionEnum.Down
- Me.iugSubcontractor.GroupBoxPromptText = "Drag a column header here to group by that column."
- Me.iugSubcontractor.GroupBoxTextForeColor = System.Drawing.Color.Red
- Me.iugSubcontractor.Identity = "IMes"
- Me.iugSubcontractor.IdentityForm = ""
- Me.iugSubcontractor.LayOutFilePath = ""
- Me.iugSubcontractor.Location = New System.Drawing.Point(12, 53)
- Me.iugSubcontractor.Name = "iugSubcontractor"
- Me.iugSubcontractor.PrintFitWidthToPages = 0
- Me.iugSubcontractor.PrintLandscape = True
- Me.iugSubcontractor.PrintPageFooter = ""
- Me.iugSubcontractor.PrintPageFooterHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageFooterHeight = 20
- Me.iugSubcontractor.PrintPageHeader = ""
- Me.iugSubcontractor.PrintPageHeaderHAlign = Infragistics.Win.HAlign.[Default]
- Me.iugSubcontractor.PrintPageHeaderHeight = 20
- Me.iugSubcontractor.PrintZoom = 1.0R
- Me.iugSubcontractor.Size = New System.Drawing.Size(894, 192)
- Me.iugSubcontractor.TabIndex = 25
- Me.iugSubcontractor.UserNo = "IMes"
- '
- 'frmSubcontractor
- '
- Me.ClientSize = New System.Drawing.Size(1008, 591)
- Me.Controls.Add(Me.btnClose)
- Me.Controls.Add(Me.btnApprove)
- Me.Controls.Add(Me.btnEMail)
- Me.Controls.Add(Me.btnDCopy)
- Me.Controls.Add(Me.btnCopy)
- Me.Controls.Add(Me.btnDDel)
- Me.Controls.Add(Me.iugSubcontractor)
- Me.Controls.Add(Me.btnDEdit)
- Me.Controls.Add(Me.btnAdd)
- Me.Controls.Add(Me.btnDAdd)
- Me.Controls.Add(Me.btnDel)
- Me.Controls.Add(Me.iugDetail)
- Me.Controls.Add(Me.btnEdit)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractor"
- Me.Text = "ENT Subcontractor & Contactor"
- Me.WindowState = System.Windows.Forms.FormWindowState.Maximized
- Me.Controls.SetChildIndex(Me.btnEdit, 0)
- Me.Controls.SetChildIndex(Me.iugDetail, 0)
- Me.Controls.SetChildIndex(Me.btnDel, 0)
- Me.Controls.SetChildIndex(Me.btnDAdd, 0)
- Me.Controls.SetChildIndex(Me.btnAdd, 0)
- Me.Controls.SetChildIndex(Me.btnDEdit, 0)
- Me.Controls.SetChildIndex(Me.iugSubcontractor, 0)
- Me.Controls.SetChildIndex(Me.btnDDel, 0)
- Me.Controls.SetChildIndex(Me.btnCopy, 0)
- Me.Controls.SetChildIndex(Me.btnDCopy, 0)
- Me.Controls.SetChildIndex(Me.btnEMail, 0)
- Me.Controls.SetChildIndex(Me.btnApprove, 0)
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractor_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- Call funiMESUltraGridIni() 'Grid初始設定
-
- '//取出資料
- Call funLoadSubcontractor()
-
- SetIssueState(Issue.Unfrozen) '預設在Unforzen上
- SetSearchFieldName(New String() {"SubcontractorNo", "SubcontractorNaME"}) '設置搜尋欄位
-
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractor_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- If Not dsENT Is Nothing Then dsENT.Dispose()
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
- Protected Overrides Sub rdoIssue_CheckedChanged(sender As Object, e As EventArgs)
- If IsNothing(dsENT) Then Exit Sub
-
- Select Case GetIssueState()
- Case Issue.Unfrozen
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=0"
- Case Issue.Pending
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=1"
- Case Issue.Active
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=2"
- Case Issue.Unused
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = "IssueState=-1"
- End Select
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
- Call funShowActiveDetail()
- End Sub
-
- Protected Overrides Sub Finalize()
- MyBase.Finalize()
- End Sub
-
- Private Sub btnAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAdd.Click
-
- Dim fSubcontractorDef As New frmSubcontractorDef
-
- fSubcontractorDef.DefMode = 0
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End Sub
-
- Private Sub btnEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEdit.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'")
-
- '核准狀態為"Unfrozen"者才可修改
-
- If Rows(0).Item("IssueState") <> 0 Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-202202", "[%NOT ALLOWED TO EDIT%]"), MsgBoxStyle.Exclamation, Me.Text)
- Exit Sub
- End If
-
- Dim fSubcontractorDef As New frmSubcontractorDef
- fSubcontractorDef.DefMode = 1
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
- fSubcontractorDef.Dispose()
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDel.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Or intIssueState = -1 Or intIssueState = 2 Then '狀態為Unforzen或Unused時直接刪除
-
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", CInput(intIssueState), "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOWED TO delete%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCopy.Click
-
-
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- 'IsGroupByRow不做任何處理
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Exit Sub
- End If
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractor).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorDef As New frmSubcontractorDef
- fSubcontractorDef.DefMode = 2
- fSubcontractorDef.EditDataRow = Rows(0)
- fSubcontractorDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- SubcontractorNo = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractor()
-
- If GetIssueState() = Issue.Unfrozen Then
- ugrRow = FindRecordPosition(iugSubcontractor, "SubcontractorNo", SubcontractorNo)
- If Not ugrRow Is Nothing Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
- End If
-
- End If
- End Sub
-
- Private Sub btnApprove_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnApprove.Click
-
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Cursor.Current = Cursors.WaitCursor
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100002", "[%ARE YOU SURE TO APPROVE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugSubcontractor.iMESUltraGrid.Selected.Rows.Count - 1
- intIssueState = Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("IssueState").Value
- If intIssueState = 0 Then
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("SubcontractorNo").Value.ToString), "")
- strParameter += CombineXMLParameter("issuestate", "IssueState", "String", intIssueState, "")
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("datastamp", "DataStamp", "Integer", iugSubcontractor.iMESUltraGrid.Selected.Rows(i).Cells("DataStamp").Value, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.ApproveSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.ApproveSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.ApproveSubcontractor", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Approve failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
- Else
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200021", "[%NOT ALLOW TO APPROVE%]"), MsgBoxStyle.Exclamation, Me.Text)
- End If
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then
-
- Call funLoadSubcontractor()
-
- Call funShowActiveDetail()
-
- End If
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDAdd.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
-
- 'Dim Rows As DataRow()
- Dim fSubcontractorContDef As New frmSubcontractorContDef
-
- fSubcontractorContDef.DefMode = 0
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- End If
- End Sub
-
- Private Sub btnDEdit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDEdit.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmSubcontractorContDef
- fSubcontractorContDef.DefMode = 1
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnDDel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDDel.Click
-
-
- '1.先檢查是否為單筆,是:將其Selecte
- If Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then Exit Sub
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
-
- Cursor.Current = Cursors.WaitCursor
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow.Selected Then
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
-
- '2.Multi
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Count > 0 Then
- If Me.iugDetail.iMESUltraGrid.Selected.Rows.Item(0).IsGroupByRow Then
- Exit Sub 'Selected.Rows,不會包含GroupRow & 一般的Row在一起,故若是GroupRow不做任何處理
- End If
- If iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-100001", "[%ARE YOU SURE TO DELETE ALL SELECTED RECORDS%]"), MsgBoxStyle.OkCancel + MsgBoxStyle.Question + MsgBoxStyle.DefaultButton2, Me.Text) = MsgBoxResult.Cancel Then
- Exit Sub
- End If
-
- '共用資料
- Dim XmlDoc As New XmlDocument
- Dim blnReLoad As Boolean = False
- Dim intIssueState As Integer
-
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- For i = 0 To Me.iugDetail.iMESUltraGrid.Selected.Rows.Count - 1
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", CInput(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString), "")
- strParameter = strParameter & CombineXMLParameter("ContactorName", "ContactorName", "String", CInput(Me.iugDetail.iMESUltraGrid.Selected.Rows(i).Cells("ContactorName").Value.ToString), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- Try
- ' 2016 YF, OutXml = wsENT.DelSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.DelSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.DelSubcontractorCont", InXml)
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- If Not blnReLoad Then blnReLoad = True
- Else
- '找出Exception訊並顯示出來
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit For
- End If
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Delete failed," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- Exit For
- End Try
-
- Next
-
- XmlDoc = Nothing
-
- If blnReLoad Then Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- End If
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub btnDCopy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDCopy.Click
-
- If Not Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing And Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow OrElse iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
-
- '找出DataSet中在目前游標列的資料列(DataRow)
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- Dim fSubcontractorContDef As New frmSubcontractorContDef
- fSubcontractorContDef.DefMode = 2
- fSubcontractorContDef.EditDataRow = Rows(0)
- fSubcontractorContDef.SubcontractorNo = Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString
- fSubcontractorContDef.ShowDialog(Me)
-
- If gReturnKeyValue = "" Then Exit Sub
-
- ContactorName = gReturnKeyValue
-
- '重新取出資料
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
-
- ugrRow = FindRecordPosition(iugDetail, "ContactorName", ContactorName)
- If Not ugrRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.ActiveRow = ugrRow
- Me.iugDetail.iMESUltraGrid.ActiveRow.Selected = True
- End If
- Else
-
- Exit Sub
- End If
-
- End Sub
-
- Private Sub btnEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEMail.Click
-
- If Not Me.iugDetail.iMESUltraGrid.ActiveRow Is Nothing Then
- If iugDetail.iMESUltraGrid.ActiveRow.IsGroupByRow Then Exit Sub
- Dim Rows As DataRow()
- Dim proMail As New System.Diagnostics.Process
- Dim strAccount As String
-
- Rows = dsENT.Tables(tblENTSubcontractorCont).Select("SubcontractorNo = '" _
- & Replace(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString, "'", "''") & "'" _
- & " And ContactorName = '" & Replace(Me.iugDetail.iMESUltraGrid.ActiveRow.Cells("ContactorName").Value.ToString, "'", "''") & "'")
-
- strAccount = "mailto:" & Rows(0).Item("EMail").ToString
- proMail.Start(strAccount)
-
- End If
-
- End Sub
-
- Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnQuery_Click(sender As Object, e As EventArgs)
- Cursor.Current = Cursors.WaitCursor
-
- funLoadSubcontractor()
-
- Cursor.Current = Cursors.Default
- End Sub
-
-#Region "Ultra Grid"
-
- Private Sub iugSubcontractor_iMESUltraGrid_InitializeLayOut(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugSubcontractor.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo")
- .Header.Caption = "SubcontractorNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("SubcontractorName")
- .Header.Caption = "SubcontractorName"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("IssueState")
- .Header.Caption = "IssueState"
- .Width = 114
- .Hidden = True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 7
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
- Private Sub iugSubcontractor_iMESUltraGrid_AfterRowActivate(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles iugSubcontractor.iMESUltraGrid_AfterRowActivate
-
- 'IsGroupByRow不做任何處理
- If Not iugSubcontractor.iMESUltraGrid.ActiveRow.IsGroupByRow Then
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
- Else
- Exit Sub
- End If
-
- End Sub
-
- Private Sub iugDetail_iMESUltraGrid_InitializeLayOut(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs) Handles iugDetail.iMESUltraGrid_InitializeLayOut
-
- With e.Layout
- With .Bands(0).Columns("SubcontractorNo")
- .Header.Caption = "SubcontractorNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 0
- End With
- With .Bands(0).Columns("ContactorName")
- .Header.Caption = "ContactorName"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 1
- End With
- With .Bands(0).Columns("TelNo")
- .Header.Caption = "TelNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 2
- End With
- With .Bands(0).Columns("FaxNo")
- .Header.Caption = "FaxNo"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 3
- End With
- With .Bands(0).Columns("Title")
- .Header.Caption = "Title"
- .Width = 110
- .Hidden = False
- .Header.VisiblePosition = 4
- End With
- With .Bands(0).Columns("Address")
- .Header.Caption = "Address"
- .Width = 110
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 5
- End With
- With .Bands(0).Columns("EMail")
- .Header.Caption = "EMail"
- .Width = 150
- .Hidden = False
- .CellAppearance.ForeColor = System.Drawing.Color.Blue
- .CellAppearance.FontData.Underline = DefaultableBoolean.True
- .Header.VisiblePosition = 6
- End With
- With .Bands(0).Columns("Description")
- .Header.Caption = "Description"
- .Width = 200
- .Hidden = False
- .CellMultiLine = DefaultableBoolean.True
- .Header.VisiblePosition = 7
- End With
- With .Bands(0).Columns("Creator")
- .Header.Caption = "Creator"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 8
- End With
- With .Bands(0).Columns("CreateDate")
- .Header.Caption = "CreateDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 9
- End With
- With .Bands(0).Columns("Reviser")
- .Header.Caption = "Reviser"
- .Width = 80
- .Hidden = False
- .Header.VisiblePosition = 10
- End With
- With .Bands(0).Columns("ReviseDate")
- .Header.Caption = "ReviseDate"
- .Width = 150
- .Format = "yyyy/MM/dd HH:mm:ss"
- .Hidden = False
- .Header.VisiblePosition = 11
- End With
- With e.Layout.Bands(0).Columns("DataStamp")
- .Hidden = True
- End With
- End With
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- End Sub
-
-#End Region
-
-#Region "Load Function"
-
- '//取出tblENTSubcontractor 外包商資料
-
- Private Sub funLoadSubcontractor()
-
- '先判斷是否dataset中已有ENTSubcontractor之datatable,若有,需先remove否則會有錯誤
- If Not IsNothing(dsENT.Tables(tblENTSubcontractor)) Then
- dsENT.Tables.Remove(tblENTSubcontractor)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- '加上IssueState要求取出所有資料
- strParameter = CombineXMLParameter("issuestate", "IssueState", "Integer", defInteger, "")
- '加上查詢條件 cboSearchFieldName,txtSearchFieldValue
- strParameter += CombineXMLQueryCondition()
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractor(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractor", InXml)
- OutXml = InvokeSrv("SXS.wsENT.LoadSubcontractor", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
-
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractor = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractor").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
-
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractor").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractor").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- strFilter = ""
- Select Case GetIssueState()
- Case Issue.Unfrozen
- strFilter = FilterByInteger(strFilter, "IssueState", 0)
- Case Issue.Pending
- strFilter = FilterByInteger(strFilter, "IssueState", 1)
- Case Issue.Active
- strFilter = FilterByInteger(strFilter, "IssueState", 2)
- Case Issue.Unused
- strFilter = FilterByInteger(strFilter, "IssueState", -1)
- End Select
-
- dsENT.Tables(tblENTSubcontractor).DefaultView.RowFilter = strFilter
- dsENT.Tables(tblENTSubcontractor).DefaultView.Sort = "SubcontractorNo"
-
- Me.iugSubcontractor.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractor).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- Exit Sub
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- '//取出tblENTSubcontractorCont聯絡人資料
-
- Private Sub funLoadSubcontractorCont(ByRef SubcontractorNo As String)
-
- If Not IsNothing(dsENT.Tables(tblENTSubcontractorCont)) Then
- dsENT.Tables.Remove(tblENTSubcontractorCont)
- End If
-
- '組InXml的字串
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("SubcontractorNo", "SubcontractorNo", "String", SubcontractorNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- Try
- ' 2016 YF, OutXml = wsENT.LoadSubcontractorCont(InXml)
- 'OutXml = InvokeSrv("wsENT.LoadSubcontractorCont", InXml)
- OutXml = InvokeSrv("SXS.wsENT.LoadSubcontractorCont", InXml)
-
- Dim XmlDoc As New XmlDocument '處理Xml字串之物件?
-
- '利用XmlDoc物件處理ReturnValue
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- '讀取取出資料表之名稱
-
- tblENTSubcontractorCont = XmlDoc.GetElementsByTagName("returnvalue").Item(0).SelectNodes("loadSubcontractorcont").Item(0).SelectNodes("name").Item(0).InnerXml
- '取出Schema,dataset讀取Schema可防止Null Field及DateTime的問題
- XmlSchema = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("schema").Item(0).InnerXml
- If XmlSchema <> "" Then
- '將XML讀入String Reader object中,因為Dataset讀入XML時必須透過String Reader物件
- tmpStringReader = New System.IO.StringReader(XmlSchema)
- dsENT.ReadXmlSchema(tmpStringReader)
- tmpStringReader.Close()
- End If
-
- '取出Data
- XmlData = XmlDoc.DocumentElement.GetElementsByTagName("loadSubcontractorcont").Item(0).SelectNodes("value").Item(0).InnerXml
- If XmlData <> "" Then
- tmpStringReader = New System.IO.StringReader(XmlData)
- dsENT.ReadXml(tmpStringReader, XmlReadMode.InferSchema)
- tmpStringReader.Close()
- End If
-
- Me.iugDetail.iMESUltraGrid.DataSource = dsENT.Tables(tblENTSubcontractorCont).DefaultView
-
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- XmlDoc = Nothing
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Load ENT Subcontractor Cont Failed!!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- End Sub
-
- Private Sub funShowActiveDetail()
-
- If Me.iugSubcontractor.iMESUltraGrid.ActiveRow Is Nothing Then
- Me.iugDetail.iMESUltraGrid.DataSource = Nothing
- Else
- Call funLoadSubcontractorCont(Me.iugSubcontractor.iMESUltraGrid.ActiveRow.Cells("SubcontractorNo").Value.ToString)
- End If
-
- End Sub
-
- Private Sub funiMESUltraGridIni()
-
- 'iugSubcontractor 初始設定
- With Me.iugSubcontractor.iMESUltraGrid
- .Text = ""
- .DisplayLayout.GroupByBox.Hidden = True
- .DisplayLayout.UseFixedHeaders = False
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugSubcontractor.UserNo = gUserNo
-
- 'iugDetail 初始設定
- With Me.iugDetail.iMESUltraGrid.DisplayLayout
- .GroupByBox.Hidden = True
- .Override.ExpansionIndicator = ShowExpansionIndicator.Default
- .ViewStyle = ViewStyle.SingleBand
- .RowConnectorStyle = RowConnectorStyle.Default
-
- End With
-
- '系統會以UserNo做為Layout的檔名
-
- iugDetail.UserNo = gUserNo
-
- End Sub
-
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorContDef.resx b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorContDef.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorContDef.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorContDef.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorContDef.vb
deleted file mode 100644
index c489735..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorContDef.vb
+++ /dev/null
@@ -1,656 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorContDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
-
- Public SubcontractorNo As String = defString
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblAddress As System.Windows.Forms.Label
- Friend WithEvents lblEMail As System.Windows.Forms.Label
- Friend WithEvents lblTitle As System.Windows.Forms.Label
- Friend WithEvents lblFaxNo As System.Windows.Forms.Label
- Friend WithEvents lblTelNo As System.Windows.Forms.Label
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblContactorName As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorContData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtContactorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtFaxNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTelNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtEMail As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtTitle As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtAddress As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorContData = New System.Windows.Forms.GroupBox()
- Me.txtAddress = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtEMail = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTitle = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtFaxNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.lblAddress = New System.Windows.Forms.Label()
- Me.lblEMail = New System.Windows.Forms.Label()
- Me.lblTitle = New System.Windows.Forms.Label()
- Me.lblFaxNo = New System.Windows.Forms.Label()
- Me.lblTelNo = New System.Windows.Forms.Label()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblContactorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtContactorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtTelNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorContData.SuspendLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 322)
- Me.gbxBasisData.Size = New System.Drawing.Size(472, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(396, 401)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(208, 401)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(302, 401)
- '
- 'gbxSubcontractorContData
- '
- Me.gbxSubcontractorContData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblAddress)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblEMail)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTitle)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblFaxNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblTelNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.lblContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtContactorName)
- Me.gbxSubcontractorContData.Controls.Add(Me.txtTelNo)
- Me.gbxSubcontractorContData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorContData.Location = New System.Drawing.Point(15, 8)
- Me.gbxSubcontractorContData.Name = "gbxSubcontractorContData"
- Me.gbxSubcontractorContData.Size = New System.Drawing.Size(469, 306)
- Me.gbxSubcontractorContData.TabIndex = 0
- Me.gbxSubcontractorContData.TabStop = False
- Me.gbxSubcontractorContData.Text = "ENT Subcontractor Contactor Data"
- '
- 'txtAddress
- '
- Me.txtAddress.Location = New System.Drawing.Point(120, 152)
- Me.txtAddress.Name = "txtAddress"
- Me.txtAddress.Size = New System.Drawing.Size(336, 22)
- Me.txtAddress.TabIndex = 13
- '
- 'txtEMail
- '
- Me.txtEMail.Location = New System.Drawing.Point(320, 120)
- Me.txtEMail.Name = "txtEMail"
- Me.txtEMail.Size = New System.Drawing.Size(136, 22)
- Me.txtEMail.TabIndex = 11
- '
- 'txtTitle
- '
- Me.txtTitle.Location = New System.Drawing.Point(120, 120)
- Me.txtTitle.Name = "txtTitle"
- Me.txtTitle.Size = New System.Drawing.Size(114, 22)
- Me.txtTitle.TabIndex = 9
- '
- 'txtFaxNo
- '
- Me.txtFaxNo.Location = New System.Drawing.Point(320, 88)
- Me.txtFaxNo.Name = "txtFaxNo"
- Me.txtFaxNo.Size = New System.Drawing.Size(136, 22)
- Me.txtFaxNo.TabIndex = 7
- '
- 'lblAddress
- '
- Me.lblAddress.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblAddress.Location = New System.Drawing.Point(24, 154)
- Me.lblAddress.Name = "lblAddress"
- Me.lblAddress.Size = New System.Drawing.Size(86, 14)
- Me.lblAddress.TabIndex = 12
- Me.lblAddress.Text = "Address"
- Me.lblAddress.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblEMail
- '
- Me.lblEMail.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblEMail.Location = New System.Drawing.Point(248, 123)
- Me.lblEMail.Name = "lblEMail"
- Me.lblEMail.Size = New System.Drawing.Size(64, 14)
- Me.lblEMail.TabIndex = 10
- Me.lblEMail.Text = "EMail"
- Me.lblEMail.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTitle
- '
- Me.lblTitle.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTitle.Location = New System.Drawing.Point(24, 121)
- Me.lblTitle.Name = "lblTitle"
- Me.lblTitle.Size = New System.Drawing.Size(86, 14)
- Me.lblTitle.TabIndex = 8
- Me.lblTitle.Text = "Title"
- Me.lblTitle.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblFaxNo
- '
- Me.lblFaxNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblFaxNo.Location = New System.Drawing.Point(248, 90)
- Me.lblFaxNo.Name = "lblFaxNo"
- Me.lblFaxNo.Size = New System.Drawing.Size(64, 14)
- Me.lblFaxNo.TabIndex = 6
- Me.lblFaxNo.Text = "FaxNo"
- Me.lblFaxNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblTelNo
- '
- Me.lblTelNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblTelNo.Location = New System.Drawing.Point(24, 90)
- Me.lblTelNo.Name = "lblTelNo"
- Me.lblTelNo.Size = New System.Drawing.Size(86, 14)
- Me.lblTelNo.TabIndex = 4
- Me.lblTelNo.Text = "TelNo"
- Me.lblTelNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(120, 184)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(336, 108)
- Me.txtDescription.TabIndex = 15
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(24, 186)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(86, 14)
- Me.lblDescription.TabIndex = 14
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(14, 29)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 14)
- Me.lblSubcontractorNo.TabIndex = 0
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblContactorName
- '
- Me.lblContactorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblContactorName.Location = New System.Drawing.Point(24, 59)
- Me.lblContactorName.Name = "lblContactorName"
- Me.lblContactorName.Size = New System.Drawing.Size(86, 14)
- Me.lblContactorName.TabIndex = 2
- Me.lblContactorName.Text = "Contactor Name"
- Me.lblContactorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(120, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.ReadOnly = True
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(114, 22)
- Me.txtSubcontractorNo.TabIndex = 1
- Me.txtSubcontractorNo.TabStop = False
- '
- 'txtContactorName
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Appearance = Appearance1
- Me.txtContactorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtContactorName.Location = New System.Drawing.Point(120, 56)
- Me.txtContactorName.Name = "txtContactorName"
- Me.txtContactorName.Size = New System.Drawing.Size(160, 22)
- Me.txtContactorName.TabIndex = 3
- '
- 'txtTelNo
- '
- Me.txtTelNo.Location = New System.Drawing.Point(120, 88)
- Me.txtTelNo.Name = "txtTelNo"
- Me.txtTelNo.Size = New System.Drawing.Size(114, 22)
- Me.txtTelNo.TabIndex = 5
- '
- 'frmSubcontractorContDef
- '
- Me.ClientSize = New System.Drawing.Size(496, 446)
- Me.Controls.Add(Me.gbxSubcontractorContData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorContDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Contactor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorContData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorContData.ResumeLayout(False)
- Me.gbxSubcontractorContData.PerformLayout()
- CType(Me.txtAddress, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtEMail, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTitle, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtFaxNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtContactorName, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtTelNo, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorContDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據()
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
- If DefMode = 0 Or DefMode = 2 Then
- SetCreateDate(Now)
- SetCreator(gUserNo)
- End If
- If Not EditDataRow Is Nothing Then '修改 or Copy
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtContactorName.Text = EditDataRow.Item("ContactorName").ToString
- txtTelNo.Text = EditDataRow.Item("TelNo").ToString
- txtFaxNo.Text = EditDataRow.Item("FaxNo").ToString
- txtTitle.Text = EditDataRow.Item("Title").ToString
- txtAddress.Text = EditDataRow.Item("Address").ToString
- txtEMail.Text = EditDataRow.Item("EMail").ToString
- 'txtDescription是RichTextBox(Control, 因為TextBox無法正常顯示多行換行的資料)
- txtDescription.Text = EditDataRow.Item("Description").ToString
- If DefMode = 1 Then
- If (Not IsDBNull(EditDataRow("Creator"))) Then
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetCreator(EditDataRow.Item("Creator").ToString)
- End If
- End If
- End If
-
- If DefMode = 0 Then 'Add
- txtSubcontractorNo.Text = SubcontractorNo
- SetCreateDate(Now)
- SetCreator(gUserNo)
- ElseIf DefMode = 1 Then 'Edit
- txtContactorName.ReadOnly = True
- SetReviseDate(Now)
- SetReviser(gUserNo)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorContDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtContactorName.Focus()
- Else
- txtTelNo.Focus()
- End If
-
- txtEMail.Text = ""
- btnApplyEnabled = False
- Cursor.Current = Cursors.Default
-
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtContactorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Click
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Enter
- txtContactorName.SelectAll()
- End Sub
-
- Private Sub txtContactorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtContactorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtContactorName_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.Leave
- If txtContactorName.Text <> "" And txtEMail.Text = "" Then
- txtEMail.Text = txtContactorName.Text & "@"
- End If
- txtContactorName.Text = UCase(txtContactorName.Text)
- End Sub
-
- Private Sub txtContactorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtContactorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTelNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Click
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.Enter
- txtTelNo.SelectAll()
- End Sub
-
- Private Sub txtTelNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTelNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTelNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTelNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtFaxNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Click
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.Enter
- txtFaxNo.SelectAll()
- End Sub
-
- Private Sub txtFaxNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtFaxNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtFaxNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtFaxNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtTitle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Click
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.Enter
- txtTitle.SelectAll()
- End Sub
-
- Private Sub txtTitle_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtTitle.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtTitle_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtTitle.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtEMail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Click
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.Enter
- txtEMail.SelectAll()
- End Sub
-
- Private Sub txtEMail_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtEMail.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtEMail_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtEMail.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtAddress_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Click
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.Enter
- txtAddress.SelectAll()
- End Sub
-
- Private Sub txtAddress_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtAddress.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtAddress_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtAddress.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtDescription.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查()
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
- If txtContactorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%ContactorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtContactorName.Focus()
- Exit Function
- End If
-
- '******************************************************************************
- '2.寫回資料庫()
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("contactorname", "ContactorName", "String", CInput(txtContactorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("telno", "TelNo", "String", txtTelNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("faxno", "FaxNo", "String", txtFaxNo.Text, "")
- strParameter = strParameter & CombineXMLParameter("title", "Title", "String", CInput(txtTitle.Text), "")
- strParameter = strParameter & CombineXMLParameter("address", "Address", "String", CInput(txtAddress.Text), "")
- strParameter = strParameter & CombineXMLParameter("email", "EMail", "String", CInput(txtEMail.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter += CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.AddSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.AddSubcontractorCont", InXml)
-
- Else 'Edit
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
- ' 2016 YF, OutXml = wsENT.EditSubcontractorCont(InXml)
- OutXml = InvokeSrv("SXS.wsENT.EditSubcontractorCont", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtContactorName.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Contactor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-#End Region
-
-
- Private Sub frmSubcontractorContDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-End Class
-
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorDef.resx b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorDef.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorDef.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
\ No newline at end of file
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorDef.vb b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorDef.vb
deleted file mode 100644
index ff97a9a..0000000
--- a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/frmSubcontractorDef.vb
+++ /dev/null
@@ -1,421 +0,0 @@
-Imports iMESExceptionManager
-
-Public Class frmSubcontractorDef
-
- Inherits COM_Kit.frmDefTemplat
-
- '//Public Variables
- Public EditDataRow As DataRow
- Public DefMode As Integer = 0 '0. ADD, 1.Edit, 2. Copy
- Public PrivFunNo As String = defString
-
- '//Web Service相關變數
- ' 2016 YF, Dim wsENT As New wsENT.wsENT
- Dim InXml As String
- Dim OutXml As String
-
- Dim strIdentity As String
- Dim strParameter As String
- Dim intDataStamp As Integer '紀錄DataStamp
-
-#Region " Windows Form Designer generated code "
-
- Public Sub New()
- MyBase.New()
-
- 'This call is required by the Windows Form Designer.
- InitializeComponent()
-
- 'Add any initialization after the InitializeComponent() call
-
- End Sub
-
- 'Form overrides dispose to clean up the component list.
- Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
- If disposing Then
- If Not (components Is Nothing) Then
- components.Dispose()
- End If
- End If
- MyBase.Dispose(disposing)
- End Sub
-
- 'Required by the Windows Form Designer
- Private components As System.ComponentModel.IContainer
-
- 'NOTE: The following procedure is required by the Windows Form Designer
- 'It can be modified using the Windows Form Designer.
- 'Do not modify it using the code editor.
- Friend WithEvents txtDescription As System.Windows.Forms.RichTextBox
- Friend WithEvents lblDescription As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorNo As System.Windows.Forms.Label
- Friend WithEvents lblSubcontractorName As System.Windows.Forms.Label
- Friend WithEvents gbxSubcontractorData As System.Windows.Forms.GroupBox
- Friend WithEvents txtSubcontractorNo As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Friend WithEvents txtSubcontractorName As Infragistics.Win.UltraWinEditors.UltraTextEditor
- Private Sub InitializeComponent()
- Dim Appearance1 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Dim Appearance2 As Infragistics.Win.Appearance = New Infragistics.Win.Appearance()
- Me.gbxSubcontractorData = New System.Windows.Forms.GroupBox()
- Me.txtDescription = New System.Windows.Forms.RichTextBox()
- Me.lblDescription = New System.Windows.Forms.Label()
- Me.lblSubcontractorNo = New System.Windows.Forms.Label()
- Me.lblSubcontractorName = New System.Windows.Forms.Label()
- Me.txtSubcontractorNo = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- Me.txtSubcontractorName = New Infragistics.Win.UltraWinEditors.UltraTextEditor()
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.gbxSubcontractorData.SuspendLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).BeginInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).BeginInit()
- Me.SuspendLayout()
- '
- 'gbxBasisData
- '
- Me.gbxBasisData.Location = New System.Drawing.Point(12, 185)
- Me.gbxBasisData.Size = New System.Drawing.Size(479, 70)
- '
- 'btnApply
- '
- Me.btnApply.Location = New System.Drawing.Point(403, 264)
- '
- 'btnConfirm
- '
- Me.btnConfirm.Location = New System.Drawing.Point(215, 264)
- '
- 'btnClose
- '
- Me.btnClose.Location = New System.Drawing.Point(309, 264)
- '
- 'gbxSubcontractorData
- '
- Me.gbxSubcontractorData.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
- Or System.Windows.Forms.AnchorStyles.Left) _
- Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
- Me.gbxSubcontractorData.Controls.Add(Me.txtDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblDescription)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.lblSubcontractorName)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorNo)
- Me.gbxSubcontractorData.Controls.Add(Me.txtSubcontractorName)
- Me.gbxSubcontractorData.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.gbxSubcontractorData.Location = New System.Drawing.Point(12, 8)
- Me.gbxSubcontractorData.Name = "gbxSubcontractorData"
- Me.gbxSubcontractorData.Size = New System.Drawing.Size(479, 169)
- Me.gbxSubcontractorData.TabIndex = 7
- Me.gbxSubcontractorData.TabStop = False
- Me.gbxSubcontractorData.Text = "Subcontractor Data"
- '
- 'txtDescription
- '
- Me.txtDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.txtDescription.Location = New System.Drawing.Point(128, 86)
- Me.txtDescription.Name = "txtDescription"
- Me.txtDescription.Size = New System.Drawing.Size(334, 67)
- Me.txtDescription.TabIndex = 2
- Me.txtDescription.Text = ""
- '
- 'lblDescription
- '
- Me.lblDescription.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblDescription.Location = New System.Drawing.Point(56, 88)
- Me.lblDescription.Name = "lblDescription"
- Me.lblDescription.Size = New System.Drawing.Size(64, 14)
- Me.lblDescription.TabIndex = 13
- Me.lblDescription.Text = "Description"
- Me.lblDescription.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorNo
- '
- Me.lblSubcontractorNo.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorNo.Location = New System.Drawing.Point(24, 24)
- Me.lblSubcontractorNo.Name = "lblSubcontractorNo"
- Me.lblSubcontractorNo.Size = New System.Drawing.Size(96, 32)
- Me.lblSubcontractorNo.TabIndex = 5
- Me.lblSubcontractorNo.Text = "Subcontractor No"
- Me.lblSubcontractorNo.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'lblSubcontractorName
- '
- Me.lblSubcontractorName.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.lblSubcontractorName.Location = New System.Drawing.Point(8, 56)
- Me.lblSubcontractorName.Name = "lblSubcontractorName"
- Me.lblSubcontractorName.Size = New System.Drawing.Size(112, 32)
- Me.lblSubcontractorName.TabIndex = 9
- Me.lblSubcontractorName.Text = "Subcontractor Name"
- Me.lblSubcontractorName.TextAlign = System.Drawing.ContentAlignment.TopRight
- '
- 'txtSubcontractorNo
- '
- Appearance1.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Appearance = Appearance1
- Me.txtSubcontractorNo.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorNo.Location = New System.Drawing.Point(128, 24)
- Me.txtSubcontractorNo.Name = "txtSubcontractorNo"
- Me.txtSubcontractorNo.Size = New System.Drawing.Size(152, 22)
- Me.txtSubcontractorNo.TabIndex = 0
- '
- 'txtSubcontractorName
- '
- Appearance2.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Appearance = Appearance2
- Me.txtSubcontractorName.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
- Me.txtSubcontractorName.Location = New System.Drawing.Point(128, 55)
- Me.txtSubcontractorName.Name = "txtSubcontractorName"
- Me.txtSubcontractorName.Size = New System.Drawing.Size(334, 22)
- Me.txtSubcontractorName.TabIndex = 1
- '
- 'frmSubcontractorDef
- '
- Me.ClientSize = New System.Drawing.Size(503, 309)
- Me.Controls.Add(Me.gbxSubcontractorData)
- Me.Font = New System.Drawing.Font("Times New Roman", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
- Me.Name = "frmSubcontractorDef"
- Me.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide
- Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
- Me.Text = "ENT Subcontractor Define"
- Me.Controls.SetChildIndex(Me.btnClose, 0)
- Me.Controls.SetChildIndex(Me.btnConfirm, 0)
- Me.Controls.SetChildIndex(Me.btnApply, 0)
- Me.Controls.SetChildIndex(Me.gbxBasisData, 0)
- Me.Controls.SetChildIndex(Me.gbxSubcontractorData, 0)
- CType(Me.gbxBasisData, System.ComponentModel.ISupportInitialize).EndInit()
- Me.gbxSubcontractorData.ResumeLayout(False)
- Me.gbxSubcontractorData.PerformLayout()
- CType(Me.txtSubcontractorNo, System.ComponentModel.ISupportInitialize).EndInit()
- CType(Me.txtSubcontractorName, System.ComponentModel.ISupportInitialize).EndInit()
- Me.ResumeLayout(False)
-
- End Sub
-
-#End Region
-
- Private Sub frmSubcontractorDef_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
-
- Cursor.Current = Cursors.WaitCursor
-
- Select Case DefMode
- Case 0
- Me.Text = Me.Text & "(ADD)"
- Case 1
- Me.Text = Me.Text & "(EDIT)"
- Case 2
- Me.Text = Me.Text & "(Copy)"
- Case Else
- Me.Text = Me.Text & "(Unknown)"
- End Select
-
- '做為MainForm判斷是否重新LoadData的依據
- gReturnKeyValue = ""
-
- ' 2016 YF, wsENT.Url = LocalizeWebService(wsENT.Url.ToString)
- ' 2016 YF, wsENT.EnableDecompression = True
-
- If Not EditDataRow Is Nothing Then
- txtSubcontractorNo.Text = EditDataRow.Item("SubcontractorNo").ToString
- txtSubcontractorName.Text = EditDataRow.Item("SubcontractorName").ToString
- 'txtDescription是RichTextBox Control,因為TextBox無法正常顯示多行換行的資料
- txtDescription.Text = EditDataRow.Item("Description").ToString
- End If
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- SetCreator(gUserNo)
- SetCreateDate(Now)
- ElseIf DefMode = 1 Then 'Edit
- txtSubcontractorNo.ReadOnly = True
- SetCreator(EditDataRow.Item("Creator").ToString)
- SetCreateDate(Convert.ToDateTime(EditDataRow.Item("CreateDate")))
- SetReviser(gUserNo)
- SetReviseDate(Now)
- intDataStamp = EditDataRow.Item("DataStamp")
- End If
-
- btnApplyEnabled = False
-
- '語系切換
- Call ExeChangeResource(Me, gLanguageMode)
- ExeGroupControlPriv(Me, PrivFunNo)
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Private Sub frmSubcontractorDef_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Activated
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
- End If
- End Sub
-
- Protected Overrides Sub btnConfirm_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- Me.Close()
-
- Cursor.Current = Cursors.Default
-
- End Sub
-
- Protected Overrides Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
- Me.Close()
- End Sub
-
- Protected Overrides Sub btnApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
-
- Cursor.Current = Cursors.WaitCursor
-
- If funAddorEdit(sender) < 0 Then Exit Sub
-
- If DefMode = 0 Or DefMode = 2 Then
- txtSubcontractorNo.Focus()
- Else
- txtSubcontractorName.Focus()
-
- End If
-
- Cursor.Current = Cursors.Default
- btnApplyEnabled = False
-
- End Sub
-
- Private Sub frmSubcontractorDef_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
- ' 2016 YF, If Not wsENT Is Nothing Then wsENT.Dispose()
- End Sub
-
-#Region "Control KeyPress"
-
- Private Sub txtSubcontractorNo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Click
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Enter
- txtSubcontractorNo.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorNo_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorNo.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorNo_Leave(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.Leave
- txtSubcontractorNo.Text = UCase(txtSubcontractorNo.Text)
- End Sub
-
- Private Sub txtSubcontractorNo_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorNo.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtSubcontractorName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Click
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.Enter
- txtSubcontractorName.SelectAll()
- End Sub
-
- Private Sub txtSubcontractorName_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtSubcontractorName.KeyPress
- If e.KeyChar = Convert.ToChar(13) Then
- SendKeys.Send("{TAB}")
- End If
- End Sub
-
- Private Sub txtSubcontractorName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtSubcontractorName.TextChanged
- btnApplyEnabled = True
- End Sub
-
- Private Sub txtDescription_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Click
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_Enter(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtDescription.Enter
- txtDescription.SelectAll()
- End Sub
-
- Private Sub txtDescription_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtDescription.TextChanged
- btnApplyEnabled = True
- End Sub
-
-#End Region
-
-#Region "Others"
-
- Private Function funAddorEdit(sender As Object) As Integer
-
- funAddorEdit = -1
-
- '******************************************************************************
- '1.基本檢查
- '******************************************************************************
- If txtSubcontractorNo.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorNo%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorNo.Focus()
- Exit Function
- End If
-
- If txtSubcontractorName.Text = "" Then
- iMESExceptionManager.ExceptionManager.iMESMsgBoxShowDialog(ChgTranslateName_Msg("0000-200001", "[%SubcontractorName%]"), MsgBoxStyle.Exclamation, Me.Text)
- txtSubcontractorName.Focus()
- Exit Function
- End If
-
- '2.
- '******************************************************************************
- '寫回資料庫
- '******************************************************************************
- Dim XmlDoc As New XmlDocument
-
- Try
- strIdentity = CombineXMLIdentity(gComputerName, gUserNo, GetNow())
- strParameter = CombineXMLParameter("subcontractorno", "SubcontractorNo", "String", CInput(txtSubcontractorNo.Text), "")
- strParameter = strParameter & CombineXMLParameter("subcontractorname", "SubcontractorName", "String", CInput(txtSubcontractorName.Text), "")
- strParameter = strParameter & CombineXMLParameter("description", "Description", "String", CInput(txtDescription.Text), "")
-
- If DefMode = 0 Or DefMode = 2 Then 'Add or Copy
- strParameter = strParameter & CombineXMLParameter("creator", "Creator", "String", gUserNo, "")
- strParameter = strParameter & CombineXMLParameter("createdate", "CreateDate", "DateTime", Format(Now, "yyyy/MM/dd HH:mm:ss"), "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.AddSubcontractor(InXml)
- OutXml = InvokeSrv("wsENT.AddSubcontractor", InXml)
-
- Else
- '修改
- strParameter = strParameter & CombineXMLParameter("issuestate", "IssueState", "String", EditDataRow.Item("IssueState").ToString, "")
- ' 增加Datastamp
- strParameter += CombineXMLParameter("datastamp", "Datastamp", "Integer", intDataStamp, "")
- InXml = CombineXMLRequest(strIdentity, strParameter)
-
- ' 2016 YF, OutXml = wsENT.EditSubcontractor(InXml)
- OutXml = InvokeSrv("wsENT.EditSubcontractor", InXml)
-
- End If
-
- XmlDoc.LoadXml(OutXml)
- If ChkExecutionSuccess(XmlDoc) Then
- gReturnKeyValue = txtSubcontractorNo.Text
-
- funAddorEdit = 0
- If sender.Equals(btnApply) Then
- intDataStamp += 1
- End If
- Else
- ExceptionManager.iMESShowDialog(GetExceptionCode(XmlDoc), GetExceptionSysMsg(XmlDoc), GetExceptionStack(XmlDoc))
- End If
-
- Catch ex As Exception
- 'MsgBox("Unexpected Error. Add or Edit ENT Subcontractor Failed!," & e1.Message, MsgBoxStyle.Exclamation)
- ExceptionManager.iMESShowDialog(defWinErrCode, ex.Message, ex.StackTrace)
- End Try
-
- XmlDoc = Nothing
-
- End Function
-
-#End Region
-
-End Class
-
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/iMES.snk b/SRC/MESWin/SYS4/21670ll/MESWin/ENT/ET_Subcontractor/iMES.snk
deleted file mode 100644
index 4206cdc36eceddde7f30ac484d1852eb3f9be236..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 596
zcmV-a0;~N80ssI2Bme+XQ$aES1ONa50097#g3R+{UF+SWBpq3jKsGz4Rg)jp;sR@&
z9YKT-w@gNp-L~38+1NJ=1XDRJDW25AI*NovDaNnzDN>{Bkv1jod=Ji9)a&FRUaAtf
zi1{sH^ycmTE>;(=WPI@cVijY>(
z68QMK9TPTAYPREpfq+h^Nne$)zO;6bx%j96AK_A|B+TR7U>0P)(eEk{J#@4Mx&M05
zCmJxuxSLKS802l^7))Rwj&-Awxzy
zL|h&Z8u5{hxZ#i*aB?roJ=(>%lFM~AM)K&^89a(nzv>UkL3%^1E^(B=&$CpC*k&Uu
zoWIXD#zo%*oEY3D5w(^p%?
zO5a)yp9j|(odT|vi)x=2V4i$!>r`bocbgd;9#&HU{hI|N6Z$Mk4?^qLlWtab5
z>NP5P^SUu%0a4(t?J}R)?1B(lBxj+?ehgOdZcWno8ix^tn9J&06)7S#xUquW+<{pmSf9OgduCn
zkS&Tb*~-U>l+>v(Dr=U$an9*{-ydJ!dtLAQJiq7q-S=<1uj{$qtBwv<`$XkL0RX^0
z8*6iC?h4#}g$23a;E0H2?jlRIaHXCm`A}(I6g&^7s1`{9)m%^KV7H+
zNYGzNxuP9`C=vw^)YH<_#6qCDKp0#Lst46IfSv$qL!dffhz=O4qY2eUK;Q_d9`Nr6
z#EnM5`5>IlE&qS?yKvD2sR1yV4A_e~FqN5*)
zN(%NPk%1@_Pz~*cB?Rr-$NvPN(FmKMV5(OT7H?yY1aT>}2m~Agu4`rn)zvnDYeUVT
zPzxP12n=co(bv}2fuFS0hrxbe%}Ll0B0h-v1B?3)7XDN0t`>-7Ze(*jg%FCzSyD(u
z;GZ=k2tUt7|EGL^V{t#v1@==cn41iEce4LA=^sa2`Rs20(Jj~bNBQ_5uG}eHT@M5>
zrvU(wej9T$OxWa27ZD8Rz0?CzVXv&rejHhZmp3uNu2cg1P{8RbsM!15?1ARKstT1!
ze?qDyF{7-~4%-{~K7nvLrF=2ZPhIYs1#_VM9=!(v(RsR>J-y~5Xo)T*yf1jN8Lq>L
zdKJyt=Fk+6CW5xA(xyadwzj;aoasH)u(J%23}0e(ct-8Z4{0sXa*vfq=wtJndoi
zfqUn3@0gIc>?hMs$yw&hpqVGf?-sg$>T%TN3uVbaEw^Mf)-Mu@J=-M|YfTWx!pC4o
zC7e>e!|1AOPa=(XKBXRW`M56Lx)NoSb>)MY_ZRkfEiPGLgNcZU~!Ng$^8GsvKu
z7c~mhR)>fl95djt2kqmp=1(j=uk3EkICtBjDAqwv?t-G>{jVR}2KLBjR)}+^D#VwJ
zz{ZmF5SI9$_|;P%4IxePGK1N^sFZ*_P>F;Y_yU+Q(tXa52%T09udu=WvQwZB)GeiX
zG`Qeo_KO`(NO15rd*em-Nsad}6DhFPM&Q-Qyd@6X`z*h=y1TzlSFUotF=wQ^Z!lKn
zrBo8D>0gDKhB={;)qVWYCUxVwPfxw9Qw|9`W8YFcCz?IS)XxWTe4JY3AAR50c~DL7
z2>0DGuiD3J;vaZL)yGg~SX@;!W{ZAH*ikJj%-a+JeXCPZ+;-EoBXB!gYJ>5r?cv+{
z`Fx3^ouUpW)Oiy3Z&g1<&z&t-Nj+ujaD4rK84IbSb1}rB_h?7lG9a^;!BRH0krcM)
zMbWo9PFBWzGu%j*n1g*&O?y3&`TgU{#A{NHF^0cN9zI?
z)vQ;PD>_}Vj_t;@@T=W0)8wxeYtLjd>qwqk#m>On(iN5{sp_$BUu>K6zQaA)AC$GV
zwckZwaBVz>`vMw*y2goB@9n#XPUSs*E9P?Ro3l$S_N1==M7-VOV4C7!-j}X7OX|*s
ze&hWdUq!hhx2Fx$?3x{NdtPNWHh1KDTg1$POEEak?*Hrg&JIm#g^XRW;|yW23NZ-Za)|mYWdzvHE?Wb37X2wyR>4f
z=6P5!+3(!eOhZb*ne7iV-M`f<)tvHmXGeZjdUjEHc&RBP%=dW?%-Lst3%^-o8^-gql;&aFM_4yLM&3Nk%>Bh!8#NOg!U?cO&0Y0|fDAHCX&D|P!JB4>kQq^ML
z`Swqg7d!1JizD_P){TRrZkucSqM|RY!lxcDvz?LGR(+P7>W4yx_7A1x7uA)Ou68Gj
z=PaB!t|hi=WMy~x%7SY;CC%4dp^|^CKy@n9e>j2fYS)#cwz<*|An!*u+H-QEbsAj8
zJ`c?R;qp?yTuJz9(TiQ&Xgam18;U6Dp0!VGtDdzvYaW7`eUs88LdL&ZosgQFI}0i+
ztvbhlQ`ovSd9dWgJ3xL94>2qG=5uWk8)wDe=7(^Nv4UyhI-UkETih~WvI@sC(=?o3
zI|fpBW?%;L-M==QUeqTj)|QWsMAdK9>5d`W#F5rfv^NP78=4Z1CAwA3?)A3^gaw3P
zIiHhlGrx6NMMx3&=#p=RjRG55k9arvvBhi!_yTjRJ=2?hRqV~`6GS11i^k%boke1|
zI}xpy)?Me`O^lwIc{`GUXsw*Eb*L1i&hC4pe7!)_w081
zJpub0L#3?%dl&NXpykzvuQN-HUfl;EXZC(Lppe2ov{v|J6b>n5Tp6ra=s}!Zud{e#=^n8_M|7{-)mL(3jhEB
diff --git a/SRC/MESWin/SYS4/21670ll/MESWin/Resources/AutoRPTMeasureData.xls b/SRC/MESWin/SYS4/21670ll/MESWin/Resources/AutoRPTMeasureData.xls
deleted file mode 100644
index 471b5c5806691d602f55cae0d53e6b174c488fab..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001
literal 19456
zcmeHP3vgW3c|Lb{wYu_4mTmmPme!JAvL#tw*gn6Zg1%&sN;5S4|8
z7E}~MrYUw4kQ1C3wFya>0C^iiLP8Rg=_JF9=o3mvfgw!D(57vIn@kf1*nZzR_w0S0
zyS_`IGj4q~XLZm2|L6bD`TzfX=iIYb`n$iad*y*|%>J1OTn%n
z4bN0R4Kz=K`7@CaUr#-SPa$4K*(Gi!4s6c%9ca6*=g_{)|H5^d>_d;mKAc8h*I8-w
zE&)G($Eqa~ZSUQ?`ePYp`zi(Rw
z2`*hb5}i`+FXU&V{G5bOOMFYV`KhEV2ax?5^0v5#PP0DxYRdY0zI|v?;n|b#7w<6`
zD&Fz#?A4U%=h{e~h4DQ}*BQrGSEk*HGVNAGwo71%FpsYn6KYk2&XzK~R2kljh-s8g
z#&&%~Uw(~txrn}yR};zOa%dhO?Ts_=>QgfTrdUWD=QlRBG&Qxa+109V>r->FEMq~{
zgf%<2=5M^-D^QO$8>_7rXlwVjN3A~9gb-ux^-2V^NU@b-iD(yMH;pgJ$e!$ORef=*
z4!5zj5xm{4ox5A>Q!S!dEMh}fY?tSrbf5e>(So4(450%7TZ-bE%jH~yE5uT<%wtfu
zcI@k>(yX^#2Dyg~N#ix!98d3VUbAblTiw-MpIQKKX96vV>6ZqOwCH|Oc^g&*ieOKxW!ebTq6Bn^21+6&{coJ@~S^!
z`WGVfd?SMXn53tH2eLoElhMM5j$^Zt&IcTS|Gy;l@S#W2pT!grC6KQUgU?sNLtVw6t8-2l%yec%x~3Bqvu0PPLzCsDaUFc$;_@12poRBv
z&5$iSir}!9oUK7H6_%obnmfi}>){lKtF1Nv%jU&`DYHiHd?zH%Hk;_)B+wvjQ}Fy&Rd!G<@lvK_~t
zad0;nk9j5=ro38Vu;ILP-KJ>k!gVi`*=0J8Y9>|oI-zR`^{IS;KqlJ?fszYZAvT|t~SKE8gZsnMtI{~
zhp$xe=2g=@-9vXB$zHu<=i1&89G3e$nwW{EUJ3d(G%iMnBjJGoBUFR8KM?s(cdtR@
zKN!$B4qYaPFQjU36>&(Qox=xw*Ey=Doug{nIjY7WwK7PL+&!uAXZdS)j@ZirCRZXz
znyaUh_Pmo2<3$^{M|$_U+OHus7kQz0I=OUy%H)OnJqSKtEYrG(+Cg3O99>?d#@CwN
zn`FZ9(cGu2UF#w`2X!rQba@e3i2J{Lomtm%t&1oe)Ya_h@**#A>Bi5Qb!D|KPQswB
zR!5f?VTJg>mw#l|)uD9}RfD>gJG#6`D#U-?ccn=eH*-k6SvPfkDg>v=TBII1ItQxp
zywk98NKQ_Rd9;#wM2U>xGsrp=&Mb9V$;rqg&D9gZs{_#FLRFQ7kBeN5%!Q!Fx{^kf
z4KkZNy>c`ba}S+<8N+2CFLpIDBZ3;Ilr*ZGh|s9E9|@^(m8+3?5tu#6sU?lf3}+$o
z_K_2QHNC#-)3o*d$s7s
z-4VPvJ?N3>0&Sn@1#LMt)qCU{ydS~1mvYu%5!=?A&krsqWd~70Q?jI-;7O0Bbeyzj
zij$sxsj~tOL5R=eh3U_Gcx-nJemIgml6=at#ZwTT`%6o_C9cE^mqM^i7Abxyy>s!E
zJ$ncH2e#!0`g#sDUoRInOjUhN&|+6_*f^L!xVb+pGASU^b1)wkDw(^yXE49<&|rSx
zh{>F-b#?U*9u8|MncCKK@a6;gZGC@YFjcK}Z0fl+tit8?9SUJu;-*9QTvCHfZGfVy6(EWih7q3~VXu@ysa8Fpm38XjL!B{(k
z*O3mgoxwY7L^&wnnD9n8D3VhBWORcpN4*=_pg>Z!MO33WeTRY^#~z~@WI5hekqk1c
zlr0&>ATObK8!nAvbO#wu&k?yG$8p()-kyO$6`GJ=N;AhR6ppXctL~8TQdV^vvdZaM
zcerPzd;>3Rt%$b*ZIQ>fR(w0>HhdY?2#mQE-zPNykP7%pXd)Kc&G=U5xA?u+o{pj+
zMg1`rYYA~5kn27V=d#xf$-g@|rf7oqh^wp*
zf%8;~wk|;Vu#~<_elCP`L0-SeE%MwiE@^o^*X+4}Kr~8?SpD#m67)icy#6t#e~SsD
z_Chi0b^|T^*IMqINADeo+%uiD<
zkojrq9Wg&my$0r|(Su&Q-Px5kmXHI7-;p2rc#Wf)SYH3>VIazE=6Q^eyOgy`f4
zt{loy%=4qZ9KQsAo>?oB0A#Q&Y*ulX`W3cCRdSc|9ZUW_u-ZrMvuB8Xp4OP}d?HO=
z9uF)yl@DR-^E-U+ckX}%2dP0q|Hg6F`vevWTA8%x!9s!KdkGfw=~VdE3m|Wo0EClH
z)%XWsyjW9k!YQa~w
zD9@S#CFY2#kw7^QZlqXNY7vHW_HS#FWngTPvG^uLjQJysg
zZG0C})yShfYYOQ2ileHLM|sv1?D5S-RU?n`tSJ!W3yG>m9_3k6kl0YFk(Y653Lxi|
zYUDLKHF~mEYJMJPwp-!m?baOpU3&Q+37=@`!YA*;@R?BXNv3+&shAT*Gkj*>6?}4N
z?)5NU1o;03oq8YTdf{CMhbqj$={QSpT;u2d9np&@Ma1F%VIYDKDToN1`J{0s^Y{7d
z|DFfl!GU3wJSszwJs0!hm5+Sp%`|CV4LS8|mbf8x1ko*QkuaPsjJ7=O#}zsm8yh{9EmWa!%4q)X6LA
zcRh@8+>DFboV&MK_qIb!fFKRh(G>o|Enn<>r{_*ylgVT9fJ{0wB$-KOhDlEXiFx!aFE{SwK@!Sff?-IylR%Qe
zVaRI9EW@j`NLJ%S$r`dNs1%5ZoU$g_}}km)nbbBy~pk=p)lMBO0z@i!-{KI~)wJE73T+rfQ6
zTp=!#a$JF$>e3{UaOk&MhB&Rs`p%^avqo$bSBt&)>yv$74J{O;OoR-I-MHUZfoLoE
zGX`?}P=*SqzN#O1r5bS_IBb_PUT>%Pb3PkoJ}&`5PIMsd1Ed}{V1wGShj
zr&0M6kr1CxJ%p*G3EUOy*sACT9TsCl<|hj{C{9W6`Ij`P&!M32P#S9xug*9o{f;)}A)4<%#~
zqSkZ3cf}#u?EUXZIiJsW4NWLKdi3?GyBGY5*Zy_<>MF>&BC^gw{~n;~99#byDzsZ%
zq21!hb_vV}_Wtd{=vf*;v%NxHszTk9uxS)c+ICfhEYG1`Eukl%5MiO_@z8dIxA=QN|tibt8MORM%}iKo^2gXsdmvO=CffLZL4ul
zxDS7&XopdJj37XOmx7ep<#J_)i^W25rom9R_W0|jlC9Y;1K-2yqxqtZo~F08E#KN&
zE^cjWO3j6~GXWf>tpMUYXnl@}NVa}@fRN-uEPLjKF+)@(`ZIFvB*dSJ6X7p9oyZW*
z)tH3;@f7^E&;zyT$hE7d&qP4a4985VkNNdqg8yd({O$<&XCvUZM!-K80sl+{{NE$s
z2O{86@pB|MFIAm#aAX)Ro|9owvM
z?q>Y*e_GPv4oAWt#ez?)!lqWy;jYJzukBlBrOzFb#Q$(Z!;!H^#){M}o}BGg{4^r3
z#1F{NU6v=$rMSiBN%zZxA8Tl69NP%`M$zETT_+j|X5%BvX;MLme
zza$;*8f|iNC+YQfJ#I_-XCyS>P_NPhcbpzPgIhEYzyo^V?o{HJ?4rgOcdQ!z;Oqxy
zYkN&8!3zZi|Du$iJ6nlg(x-|8-0ezufG@x*&Rp8i(39!Oi1Y$UhyEtx&n^w0ow>%H
zBCer>mQs)SM&q<4LvDu{^1+Faz%G1>+;KQ4spUgw*95F565$3!sj2~&g;h1+)~Bil
z+<#QnfQJ%QHQ=0CRfF1U8_+0KaiH0&YQXqYRRac~sv0oTRMmi?rm6-U^HnuqFsRtz
z9|GfnQ6d>V9#V3ktHt(he&1X@GvumB$chh)6f`1DqDxg
zsWFIDwhqr@%S2G{&n0T?WVM
zb%HZ}Gl*0Sg~0|buhbwI_Rc7Y$vOX6UKD+63EH0(#a|yQmWTL7fdD)g7^&z0TI4IBaNr$z$UAk}n{(lVVf;yQGA{CYRp+I+9(V$j#hh2YRD1z(BlP61D
z*+n8>d+oJF)tO9&T@1qN3>eU58e@Tl*KlpXt=NlTw->xpgP=(jAwCp|xqrpNgX;B3gIHj~@@|&V*^*5eC{aY2BHyunUM8s>{Kv
z3bm@L3y%dB9t@?Pu4?mzXP^0voyQa#k0ll!ofaM{`pSN|u*dKI
zVCON_#^WptkF14<3eJ*8UB2+rFQ2gUXe5utG5l&ac!cpvx=M}qerfb)b{^AgJZyf|
zV&P%>)oAa}@BfmW$8;MHn_tbh@G$*qwD<9!Jz(cC!^XqrR|_pXOuriK9X;_wJCB(*
z9yY%^)562_tI^*3p8AEI$7wbmHoxk&@G$*qwD-lw?zQtcojlHp;a3^(2;-IgD%<^$
zdmdLj7_5*=@oJWhht03fu<$VbD%<_Uk&oDUG}(CA{HoQ$!}P0c_t(CE)XrnJjfc&z
z+ATaxzshzWzx`Ww9vK@Cn_qQVc$j{b?LPd77k7j9m}BE%^Q*-c9;RPqyI(kQ$kq?c
zio>Ef;x0rG1a~hvjwoUqv$p+uPUx1YEhUw^pH^rSZ~XEp)Q(x~~)+tkTM*GKp(o;l#K@lS~i|4c(SF${NWml=4zn1f7zej@aPpJdpI#(v_e3~z4^#{
z@6Xq78*#7lb4)ZAQ$p8rLCJ}Udf;MK^X0jM1hhwAwscX5>X&+VOEat*oZSK^Uaf;n6Z9tPub7nQz)@b!%FTszF+dJX&TX
z72?mgTwtTc#T;C3#^t^L77C}ydbl2Iv=7u`zcYLFkQ|&2{b&jOh!`2cJ;+LAjx3d&
z>4plWWe4JILNM8t2Y$#Dw-XOinkjkT2%-wb3X>^w|o?WI$j|ftn
zRHCSSB7&k?ek3HtrDclri@@kfPA*ZTXLu8lDI*8`GHQM42lE$>xcz>uC8j{@tTDqQ
z4nKjkd{**1C}b8vZS##QNdT$ae7?A>GA2!;py=-
zbnEHOI)cfFjgtgz2Oc+g(Qv$2NuMYjc-tm>L>&vC(6!npBs~N#N#g_VX7K@I@En5c
zG~jO&CgID(9+AhJ*n@ccoOf%Gci`P?zL~vDtjFDcyd^zoVDtjEQ|tn45f;^#$~Sm#
zLce$O&=ix{#$EaR;37f}(CalMOUN{y#A!(PQFppHYRIL|3e@@aC-8RkCyY9_I|x1O
zPwr1XBVH7DCMKhf*%c{1l)muX)r0xHYy0Jdh9Roc7+-bY-h2?jYk$E&
z|K9WZ21C_p)qYdIt#Z7s9PHb3{=h*0z=ebF3DU=lLzHh*KX7{c2iIP`H;6I8z}VQg
z_sTta3z=~WX-li_Xxk+bbV?}bY#6CTM|U`k;;C#)tLk(Zp+U