Ejemplo n.º 1
0
        internal static bool Switch(int id)
        {
            var wrapper = launchedAccesses.Where(x => x.Id == id).FirstOrDefault();

            CurrentAccess = wrapper ?? CurrentAccess;
            CurrentAccess.Show();
            return(wrapper != null);
        }
Ejemplo n.º 2
0
        internal static AccessWrapper AddAccess()
        {
            //if (GetOfficeAppPath("Access.Application", "msaccess.exe") == null)
            //{
            //    throw new Exception("Can't determine path to msaccess.exe");
            //}

            var wrapper = new AccessWrapper(new AccessFormControlsTreeWalker(), new RunningObjectTableService());

            launchedAccesses.Add(wrapper);
            CurrentAccess = wrapper;
            return(wrapper);
        }
Ejemplo n.º 3
0
 internal static void Remove(AccessWrapper accessWrapper)
 {
     launchedAccesses.Remove(accessWrapper);
     CurrentAccess = launchedAccesses.FirstOrDefault();
 }