S
Steve
Can you please help.
I have 2 forms that are more or less the same although I
use one for editing the information. I have locked all
the fields on the HPC form.
I would like to have a button on the HPC form that brings
up the HPC_Edit form and hides the HPC form. And when I
close the HPC_Edit form I would like to save the record
information and make the HPC form visible again, making
the HPC form visible.
I was given this sample code but I get "Else without IF"
errors.
Private Sub test_Click()
If Me![HPC].Visible = -1 Then Me![HPC].Visible = 0
Else: Me![HPC].Visible = -1
If Me![HPC_Edit].Visible = 0 Then Me![HPC_Edit].Visible
= -1
Else: Me![HPC_Edit].Visible = 0
End Sub
Please help.
Many thanks
Steve
I have 2 forms that are more or less the same although I
use one for editing the information. I have locked all
the fields on the HPC form.
I would like to have a button on the HPC form that brings
up the HPC_Edit form and hides the HPC form. And when I
close the HPC_Edit form I would like to save the record
information and make the HPC form visible again, making
the HPC form visible.
I was given this sample code but I get "Else without IF"
errors.
Private Sub test_Click()
If Me![HPC].Visible = -1 Then Me![HPC].Visible = 0
Else: Me![HPC].Visible = -1
If Me![HPC_Edit].Visible = 0 Then Me![HPC_Edit].Visible
= -1
Else: Me![HPC_Edit].Visible = 0
End Sub
Please help.
Many thanks
Steve