>>I'm using an ADO data control against a MS Access secured database.
>>
>>Is there a way not to set the username/pwd ( and path, so the whole connection string in fact :) ) and set those when the form loads?
>>
>>TIA.
>
>Yes but ConnectionString and RecordSource needs to be left blank at design time. You code will then look like this:
>
>
Private Sub Form_Load()
> With Adodc1
> .ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=D:\Program Files\Microsoft Visual Studio\VB98\BIBLIO.MDB;Persist Security Info=False"
> .RecordSource = "Authors"
> .Refresh
> End With
>End Sub
Excellent.
I knew it should work but was missing something. I tried that before posting but without the recordsource property. Of course it didn't work although I believed it should have.
Thanks a lot.
Ben Rail
Business Solutions
LOGI.design