Problem Upgrading from Access 2000 to 2003

  • Thread starter Thread starter Mike Thomas
  • Start date Start date
M

Mike Thomas

We are upgrading an app from Access 2000 to Access 2003 and have run across
a case where something works in 2000, but not in 2003

In a form named 'Load Screen' we have the following snippet in code behind a
button's (btn_PickList) click event:

Public gTitle As String
Public gWhichLine As Integer
Option Explicit
Option Compare Database
_________
Private Sub btn_PickList_Click()
Me.gTitle = "COMPLETE PICK LIST"
Me.gWhichLine = -2
DoCmd.OpenReport "PickListLocation", acPreview
End Sub

When the query underlying the report runs, it opens a box asking for
'[Forms].[Load Screen].[gWhichLine]'. In the query, there is a where clause
that a value must be '> [Forms].[Load Screen].[gWhichLine]'. Access 2000 was
able to 'see' this value.

Also, when we manually supply as value and the report opens, it apparently
cannot find '[Forms].[Load Screen].gTitle'.

Does anyone know the cause and fix for this problem? This issue could be
quite the show stopper.

Thanks
Mike Thomas
 
Mike said:
We are upgrading an app from Access 2000 to Access 2003 and have run across
a case where something works in 2000, but not in 2003

In a form named 'Load Screen' we have the following snippet in code behind a
button's (btn_PickList) click event:

Public gTitle As String
Public gWhichLine As Integer
Option Explicit
Option Compare Database
_________
Private Sub btn_PickList_Click()
Me.gTitle = "COMPLETE PICK LIST"
Me.gWhichLine = -2
DoCmd.OpenReport "PickListLocation", acPreview
End Sub

When the query underlying the report runs, it opens a box asking for
'[Forms].[Load Screen].[gWhichLine]'. In the query, there is a where clause
that a value must be '> [Forms].[Load Screen].[gWhichLine]'. Access 2000 was
able to 'see' this value.

Also, when we manually supply as value and the report opens, it apparently
cannot find '[Forms].[Load Screen].gTitle'.


I have never used that abbreviated syntax so I haven't run
into the problem. However, I believe that A2003 really
wants you to use the more complete syntax:

[Forms].[Load Screen].FORM.[gWhichLine]
 
Thanks Marshall,

I'll adopt the more complete sysntax.

Mike Thomas

Marshall Barton said:
Mike said:
We are upgrading an app from Access 2000 to Access 2003 and have run
across
a case where something works in 2000, but not in 2003

In a form named 'Load Screen' we have the following snippet in code behind
a
button's (btn_PickList) click event:

Public gTitle As String
Public gWhichLine As Integer
Option Explicit
Option Compare Database
_________
Private Sub btn_PickList_Click()
Me.gTitle = "COMPLETE PICK LIST"
Me.gWhichLine = -2
DoCmd.OpenReport "PickListLocation", acPreview
End Sub

When the query underlying the report runs, it opens a box asking for
'[Forms].[Load Screen].[gWhichLine]'. In the query, there is a where
clause
that a value must be '> [Forms].[Load Screen].[gWhichLine]'. Access 2000
was
able to 'see' this value.

Also, when we manually supply as value and the report opens, it apparently
cannot find '[Forms].[Load Screen].gTitle'.


I have never used that abbreviated syntax so I haven't run
into the problem. However, I believe that A2003 really
wants you to use the more complete syntax:

[Forms].[Load Screen].FORM.[gWhichLine]
 
That's nice, but did it solve your problem?
--
Marsh
MVP [MS Access]


Mike said:
Thanks Marshall,

I'll adopt the more complete sysntax.

Mike said:
We are upgrading an app from Access 2000 to Access 2003 and have run
across
a case where something works in 2000, but not in 2003

In a form named 'Load Screen' we have the following snippet in code behind
a
button's (btn_PickList) click event:

Public gTitle As String
Public gWhichLine As Integer
Option Explicit
Option Compare Database
_________
Private Sub btn_PickList_Click()
Me.gTitle = "COMPLETE PICK LIST"
Me.gWhichLine = -2
DoCmd.OpenReport "PickListLocation", acPreview
End Sub

When the query underlying the report runs, it opens a box asking for
'[Forms].[Load Screen].[gWhichLine]'. In the query, there is a where
clause
that a value must be '> [Forms].[Load Screen].[gWhichLine]'. Access 2000
was
able to 'see' this value.

Also, when we manually supply as value and the report opens, it apparently
cannot find '[Forms].[Load Screen].gTitle'.

"Marshall Barton" wrote
I have never used that abbreviated syntax so I haven't run
into the problem. However, I believe that A2003 really
wants you to use the more complete syntax:

[Forms].[Load Screen].FORM.[gWhichLine]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top