Error when creating a Combo box using the wizard

A

Al

When creating a combo box using the wizard I get the
following error Method' connection' of object -
currentproject' failed Does anyone know what I can
do to correct the problem.
I also get the same error when I try to open a database
with a start up menu that has been created using the
switchboard. When selecting debug I get the following

' Open the table of Switchboard Items, and find
' the first item for this Switchboard Page.
Set con = Application.CurrentProject.Connection
stSql = "SELECT * FROM [Switchboard Items]"
stSql = stSql & " WHERE [ItemNumber] > 0 AND
[SwitchboardID]=" & Me![SwitchboardID]
stSql = stSql & " ORDER BY [ItemNumber];"
Set rs = CreateObject("ADODB.Recordset")
rs.Open stSql, con, 1 ' 1 = adOpenKeyset


With Application.CurrentPorject.Connection hi-lited in
yellow

Al
 

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