Exemple #1
0
        private void tSB_editLicense_Click(object sender, EventArgs e)
        {
            if (lV_licenses.SelectedItems.Count > 0)
            {
                BlueFlame.Classes.DatabaseObjects.License license
                    = (BlueFlame.Classes.DatabaseObjects.License)lV_licenses.SelectedItems[0].Tag;

                EditLicenseKey editKey = new EditLicenseKey(license.Key, license.Distributed, license.Multi);
                if (editKey.ShowDialog() == DialogResult.OK)
                {
                    license.Multi       = editKey.IsMulti;
                    license.Distributed = editKey.IsDistributed;
                    license.Save();
                }
            }
            GetLicenseKeys(_product);
        }
Exemple #2
0
        private void tSB_add_Click(object sender, EventArgs e)
        {
            EditLicenseKey newKey = new EditLicenseKey();

            if (newKey.ShowDialog() == DialogResult.OK)
            {
                BlueFlame.Classes.DatabaseObjects.License license =
                    new BlueFlame.Classes.DatabaseObjects.License(
                        newKey.LicenseKey,
                        newKey.IsMulti,
                        newKey.IsDistributed,
                        "",
                        null,
                        _product);
                license.Create();
                _licenseProvider = null;
            }
            GetLicenseKeys(_product);
        }