예제 #1
0
        private GlobalMethods()
        {
            clientSession = (ClientSession)Activator.CreateInstance(Type.GetTypeFromProgID("FIClient.ClientSession"));
            var boo = clientSession.StartSession(ClientType.clientBackgroundProcess);

            instItemAttr      = (Item_Attr)Activator.CreateInstance(Type.GetTypeFromProgID("FIProd.Item_Attr"));
            instItemClassAttr =
                (Item_Class_Attr)Activator.CreateInstance(Type.GetTypeFromProgID("FIProd.Item_Class_Attr"));
            instanceItem_Class =
                (Item_Class)Activator.CreateInstance(Type.GetTypeFromProgID("FIProd.Item_Class"));
            instanceItem           = (Item)Activator.CreateInstance(Type.GetTypeFromProgID("FIProd.Item"));
            instanceJob_Exec       = (Job_Exec)Activator.CreateInstance(Type.GetTypeFromProgID("FIProd.Job_Exec"));
            instanceItem_Prod      = (Wo)Activator.CreateInstance(Type.GetTypeFromProgID("FIProd.Wo"));
            instanceJob            = (Job)Activator.CreateInstance(Type.GetTypeFromProgID("FIProd.Job"));
            instanceJob_Attr       = (Job_Attr)Activator.CreateInstance(Type.GetTypeFromProgID("FIProd.Job_Attr"));
            instanceWo_Attr        = (Wo_Attr)Activator.CreateInstance(Type.GetTypeFromProgID("FIProd.Wo_Attr"));
            instanceJob_Route      = (Job_Route)Activator.CreateInstance(Type.GetTypeFromProgID("FIProd.Job_Route"));
            instanceJob_Bom        = (FIEnProd.Job_Bom)Activator.CreateInstance(Type.GetTypeFromProgID("FIEnProd.Job_Bom"));
            instanceBom_Item       = (FIEnProd.Bom_Item)Activator.CreateInstance(Type.GetTypeFromProgID("FIEnProd.Bom_Item"));
            instanceBom_Item_Subst =
                (FIEnProd.Bom_Item_Subst)Activator.CreateInstance(Type.GetTypeFromProgID("FIEnProd.Bom_Item_Subst"));
            instanceEnt        = (FICore.Ent)Activator.CreateInstance(Type.GetTypeFromProgID("FICore.Ent"));
            instanceDx_Map_Imp = (FIDX.Dx_Map_Imp)Activator.CreateInstance(Type.GetTypeFromProgID("FIDX.Dx_Map_Imp"));
            //TODO:settings = new Parameters(); тестовые параметры
            settings = new Parameters();
            settings.CreateWOFromProcess = true;
            settings.WoDescIsWoId        = true;
        }
예제 #2
0
 public void Dispose()
 {
     instanceItem       = null;
     instItemAttr       = null;
     instanceItem_Class = null;
     instAttr           = null;
     clientSession.EndSession();
 }