Author Topic: basic label open another page  (Read 861 times)

Darrell

  • Full Member
  • ***
  • Posts: 198
  • Electrician / PLC Technician
    • View Profile
basic label open another page
« on: February 15, 2017, 03:33:01 PM »
how can I use a basic label to open another form . Hide the form and open another when clicked  is this all i need


 FaultPage.Show()
        ' Me.Hide()
        Me.Visible = False

But I only want it to be clickable when the basic Label is highlighted via a PLC address
« Last Edit: February 15, 2017, 03:49:09 PM by Darrell »

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5262
    • View Profile
    • AdvancedHMI
Re: basic label open another page
« Reply #1 on: February 15, 2017, 09:52:02 PM »
Try something like this:
Code: [Select]
Private Sub BasicLabel1_Click(sender As Object, e As EventArgs) Handles BasicLabel1.Click
        If BasicLabel1.Highlight Then
            FaultPage.Show
            Me.Hide()
        End If
End Sub

Darrell

  • Full Member
  • ***
  • Posts: 198
  • Electrician / PLC Technician
    • View Profile
Re: basic label open another page
« Reply #2 on: February 15, 2017, 11:03:06 PM »
thanks Archie , did the trick

Darrell