public static void StartReports(string connectionString, string programAndVersion, string serialNumber, string min, string currentusername, string currentuserid) { Properties.Settings.Default.UserConnectionString = connectionString; Properties.Settings.Default.ProgramVersion = programAndVersion; Properties.Settings.Default.SN = serialNumber; Properties.Settings.Default.MIN = min; Properties.Settings.Default.Username = currentusername; Properties.Settings.Default.CurrentUserId = currentuserid; MainFormNew frm = new MainFormNew(); frm.ShowDialog(); }
static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); //for testing purposes. var access = new UserAccessItem { CanAccess = true, CanAdd = true, CanDelete = true, CanEdit = true, CanExport = true, CanPrint = true, CanSave = true, CanSearch = true, }; var main = new MainFormNew(); //Change to main when deployment var form = new Sales(); //Testing of form form.UserAccess = access; Application.Run(main); }