2003 access conversion to 2007

A

Acorn

After conversion to Access 2007 I encounterd many problem that caused debugs.
A reference to a number on the form now always returns Null.
The clincher was the following when tring to open a new form:

Private Sub btnStFile1_Click()
'On Error GoTo Err_btnStFile1_Click
Dim sMsg As String

sMsg = ContChk(True)
If Len(sMsg) > 0 Then
MsgBox "Complete the following Client Information before starting a file
for this evaluation." & vbCrLf & sMsg
DoCmd.GoToControl sCtrl
Exit Sub
End If
If IsNull(Forms!frmContEval!sbfEvalInfo!cmbDistrict) Or
Forms!frmContEval!sbfEvalInfo!cmbDistrict = 0 Then
MsgBox "District is required."
Exit Sub
End If

Call UpdateEvalFlow("Evaluation",
Forms!frmContEval!sbfEvalInfo!EvaluationID, LU("UserID"), "New Evaluation")

DoCmd.OpenForm "frmEval1", , , , acFormAdd, , "New"

'Exit_btnStFile1_Click:
' Exit Sub
'
'Err_btnStFile1_Click:
' MsgBox Err.Description
' Resume Exit_btnStFile1_Click

End Sub

The following message occured when executing the line: DoCmd.OpenForm...

Invalid bracketing of name
‘Forms!frmClientList![tblTripEval.EvaluationID]â€.

The help gave this messge:
Invalid bracketing of name <name>. (Error 3126)

What I read to be an easy conversion is giving me nightmares!
OS is Windows XP
Thanks in advance.
 
J

Jeanette Cunningham

Invalid bracketing:
Do it like this-->
Forms!frmClientList![tblTripEval].[EvaluationID]


A2007 is more fussy about things being correct compared with A2003.


Jeanette Cunningham MS Access MVP -- Melbourne Victoria Australia
 

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

Top