Tony,
thank you for your reply.
wrt to what I am using the ocx files for: I'm not sure. But whilst
trying to compile and save modules for the MDB on the Version 6 PC the
system could not recognise fld.Name as a function (where fld is a
member of the Fields Collection of a query opened as a dbOpenDynaset).
This Sub (see below) works perfectly well on the Version 5 PCs, so
why won't it work on the other?
************************************************** *******
Private Sub ReportFooter_Format(Cancel As Integer, FormatCount As
Integer)
'*This procedure uses the data in strqryName to fill the unbound boxes
'*on the Report Footer whose Name coincides with the query column
name.
Dim db As Database, rst As Recordset, fld As field, ctl As Control
Dim strFieldName, strqryName As String
strqryName = "qryCalculate_for_Contract_Summary"
Set db = CurrentDb()
Set rst = db.OpenRecordset(strqryName, dbOpenDynaset)
'*There is only one line of data on this query
With rst
..MoveLast
..MoveFirst
For Each ctl In Me.ReportFooter.Controls
For Each fld In rst.Fields
'*.Fields is a collection
strFieldName = fld.Name
'*.Name is a member of the Fields Collection
If strFieldName = ctl.Name Then
'*Update Control Value with the Query Value
Me(strFieldName) = rst(strFieldName)
End If
Next fld
Next ctl
End With
Set rst = Nothing
Set db = Nothing
End Sub
*******************************************
#Note: the data in the footer is not connected in any way to the
Report DataSource.
Once again, thank you for for your time.
Best wishes, Pete
Tony Toews <tt****@telusplanet.net> wrote in message news:<mj********************************@4ax.com>. ..
pe*************@baesystems.com (Peter Halfacree) wrote:
I believe that I have tracked down the cause of my problem, in that,
some PCs on the Network have comctl32.ocx version 5.01.4319 and some
have version 6.00.8022. Similarly comdlg32.ocx has versions 5.01.4319
& 6.00.8418.
Makes sense. What are you using comctl32 and comdlg32 for? See if the following is
of any assistance. We have work arounds for some of the most common functions but
not all yet.
How do you get rid of troublesome references?
http://www.granite.ab.ca/access/referencetroubles.htm
I do not think that this is a problem of "Lost References",I have
module procedures which can repair broken references and if neccessary
attach new references (courtesy of mvps). I am aware of but do not do
not know in depth how References work.
Trouble is these don't work in MDEs.
Subject: INFO: How to guarantee that references will work in your applications.
http://www.trigeminal.com/usenet/usenet026.asp?1033
Tony