View Single Post
  #2  
Old November 13th 08, 03:48 PM posted to microsoft.public.outlook.program_forms
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default ADO code with combox box gives errors

Is this code running in an Outlook custom form? If so it uses VBScript code
and all objects are Variant and don't take As clauses. Use only Dim Conn1.

If this code is running in an Access form then please post your question in
an Access group as it would have nothing to do with Outlook.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"Rod" wrote in message
...
I am trying to populate a combo box with records from an Access data table.
I think this is possible using ADO, so I wrote the routine to populate the
combo when the form is opened. Every time I open the form, I get an error
saying "Expected end of statement line3". Line 3 is: "Dim Conn1 As New
adodb.Connection". It is really the first line of code in the Open_Item
function. If I can get by this error, I think I can figure the rest out.

Rod



Ads