Пример #1
0
        // ----------------------------------------------------------------------//

        #region >> Reset form_action and role_detail <<

        /// <summary>
        /// Method yang digunakan untuk mereset tabel form_action dan role_detail
        /// </summary>
        /// <param name="assembly">Assembly aplikasi</param>
        public void ResetFormAction(Assembly assembly)
        {
            try
            {
                if (MenuStrip == null)
                {
                    throw new NullReferenceException("Anda tidak mempunyai MenuStrip untuk dimapping ke tabel role_detail");
                }

                if (MenuStrip != null)
                {
                    _formActionServices.DeleteAll();
                    _roleServices.DeleteAllRoleDetail();
                    GetTypeFromAssembly(assembly);

                    PopulateMenuStrip(MenuStrip.Items);
                }
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message);
            }
        }