AdvancedHMI Software

General Category => Support Questions => Topic started by: scott.clark on November 11, 2015, 10:16:26 AM

Title: Method for requiring Password to Exit the Application
Post by: scott.clark on November 11, 2015, 10:16:26 AM
Advanced HMI v3.99a

Any suggestions on how I can require the operator to enter a numeric password to exit the AdvancedHMI application? 

Also, how can I prevent them from dragging the form?  Ultimately, I am wanting to prevent them from getting to the PC.

Thanks,
Scott
Title: Re: Method for requiring Password to Exit the Application
Post by: Archie on November 11, 2015, 06:04:32 PM
    Private Sub MainForm_FormClosing(sender As Object, e As FormClosingEventArgs) Handles Me.FormClosing
        Dim kpd As New MfgControl.AdvancedHMI.Controls.Keypad
        kpd.ShowDialog()
        If kpd.Value <> "1234" Then
            e.Cancel = True
        End If
    End Sub