C
Connie
Hello
Below is code behind a form that allows users to select from a list of names
which creates a mailing label list. When the form is opened, the following
error message appears "Compile Error. Error in Loading DLL". When I debug,
the word "Connection" is highlighted.
Two of the references in the database are "ActiveX Data Objects 2.7
Library", and "ADO ext. 2.7 for DLL and Security". At one time, the system
it was developed on had 2.8. We have had problems with these references
before when installing the software on a client pc if they have not upgraded
their systems (no problem really because we select the appropriate references
at the time). However, big problem now on the developing computer. The
above noted form no longer works. The developing computer has WinXP Pro but
has not been upgraded to SP2 (Was installed then uninstalled....too many
problems). Wondering if this could have caused my current DLL problem.
Any help appreciated,
Connie
Code behind form:
Private Sub Form_Load()
Dim rstTblRecordsChosen As New ADODB.Recordset
Dim intCurrRecord As Integer
'-- Open the table containing previously selected choices
rstTblRecordsChosen.Open "TblRecordsChosen", _
CurrentProject.Connection, adOpenDynamic
'-- Loop through the selected choices
Do Until rstTblRecordsChosen.EOF
'-- For each of the items in the listbox, see if it matches the
'-- current Record name.
For intCurrRecord = 0 To Me!lboRecordsToChoose.ListCount - 1
'-- If there is a match, mark it in the list box as selected
If rstTblRecordsChosen!strRecord = _
Me!lboRecordsToChoose.ItemData(intCurrRecord) Then
Me!lboRecordsToChoose.Selected(intCurrRecord) = True
Exit For
End If
Next intCurrRecord
rstTblRecordsChosen.MoveNext
Loop
End Sub
Below is code behind a form that allows users to select from a list of names
which creates a mailing label list. When the form is opened, the following
error message appears "Compile Error. Error in Loading DLL". When I debug,
the word "Connection" is highlighted.
Two of the references in the database are "ActiveX Data Objects 2.7
Library", and "ADO ext. 2.7 for DLL and Security". At one time, the system
it was developed on had 2.8. We have had problems with these references
before when installing the software on a client pc if they have not upgraded
their systems (no problem really because we select the appropriate references
at the time). However, big problem now on the developing computer. The
above noted form no longer works. The developing computer has WinXP Pro but
has not been upgraded to SP2 (Was installed then uninstalled....too many
problems). Wondering if this could have caused my current DLL problem.
Any help appreciated,
Connie
Code behind form:
Private Sub Form_Load()
Dim rstTblRecordsChosen As New ADODB.Recordset
Dim intCurrRecord As Integer
'-- Open the table containing previously selected choices
rstTblRecordsChosen.Open "TblRecordsChosen", _
CurrentProject.Connection, adOpenDynamic
'-- Loop through the selected choices
Do Until rstTblRecordsChosen.EOF
'-- For each of the items in the listbox, see if it matches the
'-- current Record name.
For intCurrRecord = 0 To Me!lboRecordsToChoose.ListCount - 1
'-- If there is a match, mark it in the list box as selected
If rstTblRecordsChosen!strRecord = _
Me!lboRecordsToChoose.ItemData(intCurrRecord) Then
Me!lboRecordsToChoose.Selected(intCurrRecord) = True
Exit For
End If
Next intCurrRecord
rstTblRecordsChosen.MoveNext
Loop
End Sub