By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,968 Members | 1,572 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,968 IT Pros & Developers. It's quick & easy.

Error 2450 When Form Is Definitely Open

P: n/a
What can cause Access to bring up Runtime Error 2450 saying that it
can't find a particular form when the form is definitely open? I am
opening the form and then checking if fields are populated to
determine whether labels in a report that is subsequently opened are
visible or not. Part of the code for the "On Open" event of the
report follows:

If IsNull(Forms!Details!Name2) Then Me.Name2Lbl.Visible = False
If IsNull(Forms!Details!Pos2) Then Me.Pos2Lbl.Visible = False
If IsNull(Forms!Details!Name3) Then Me.Name3Lbl.Visible = False
If IsNull(Forms!Details!Pos3) Then Me.Pos3Lbl.Visible = False
If IsNull(Forms!Details!Name4) Then Me.Name4Lbl.Visible = False
If IsNull(Forms!Details!Pos4) Then Me.Pos4Lbl.Visible = False

If I use the "On Error Resume Next" line before this code, the labels
are not visible when the when the related form field is null (this is
what I want to happen) AND they are also not visible when the related
form field is NOT null.

Any help on explaining this behaviour would be appreciated.
Nov 12 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
On 25 Jan 2004 20:46:06 -0800, Wayne Aprato wrote:
What can cause Access to bring up Runtime Error 2450 saying that it
can't find a particular form when the form is definitely open? I am
opening the form and then checking if fields are populated to
determine whether labels in a report that is subsequently opened are
visible or not. Part of the code for the "On Open" event of the
report follows:

If IsNull(Forms!Details!Name2) Then Me.Name2Lbl.Visible = False
If IsNull(Forms!Details!Pos2) Then Me.Pos2Lbl.Visible = False
If IsNull(Forms!Details!Name3) Then Me.Name3Lbl.Visible = False
If IsNull(Forms!Details!Pos3) Then Me.Pos3Lbl.Visible = False
If IsNull(Forms!Details!Name4) Then Me.Name4Lbl.Visible = False
If IsNull(Forms!Details!Pos4) Then Me.Pos4Lbl.Visible = False

If I use the "On Error Resume Next" line before this code, the labels
are not visible when the when the related form field is null (this is
what I want to happen) AND they are also not visible when the related
form field is NOT null.

Any help on explaining this behaviour would be appreciated.


Just checking...
Is Forms!Details the name of a subform on some other?
Are you 100% sure the spelling is correct?

Not to sound condescending, but I know that spelling is one of those things
I tend to overlook.
--
Mike Storr
veraccess.com
Nov 12 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.