private void Registration_Load(object sender, EventArgs e)
        {
            string error = "";

            IS_LICENSE_VALID = Licensing.validateLicense(out error);
            if (IS_LICENSE_VALID)
            {
                label5.Text = "License is valid";
            }
            else
            {
                label5.Text = "No license available";
            }
        }
Beispiel #2
0
        private void LicenseCheck()
        {
            string error   = "";
            bool   isvalid = Licensing.validateLicense(out error);

            Start_Button.Enabled = isvalid;
            Stop_Button.Enabled  = isvalid;
            if (isvalid)
            {
                Register_btn.BackColor = System.Drawing.Color.LightGreen;
                Register_btn.Text      = "Registered";
            }
            else
            {
                Register_btn.BackColor = System.Drawing.Color.LightSalmon;
                Register_btn.Text      = "Register";
            }
        }
        private void Button3_Click(object sender, EventArgs e)
        {
            SerialKey sform = new SerialKey();

            sform.ShowDialog();
            string error = "";

            IS_LICENSE_VALID = Licensing.validateLicense(out error);

            if (IS_LICENSE_VALID)
            {
                label5.Text = "License is valid";
            }
            else
            {
                label5.Text = "No license available";
                MessageBox.Show(error);
            }
        }