C
christopher ward
Dear Experts
I am trying to execute some very simple sql from vba. The sql is
USE master;
SELECT NAME FROM sysdatabases
I want to then place the results in a list box on a vba form
To do this I am looking at recordsets and ado where I cannot find a decent
documented method i can work with. So far I have created
soucon = "Provider=" & Master.TextBox22.Value & ";Data Source=" &
Master.TextBox23.Value _
& ";Initial Catalog=" & Master.TextBox24.Value & ";User id=" &
Master.TextBox25.Value _
& ";Password=" & Master.TextBox26.Value
Set ConSource = CreateObject("ADODB.Connection")
ConSource.Open soucon
which i believe works and connects to Master - how do i now create a
recordset and populate my list box is my question ?
If you respond thank you for your time and efforts as always
kind regards
I am trying to execute some very simple sql from vba. The sql is
USE master;
SELECT NAME FROM sysdatabases
I want to then place the results in a list box on a vba form
To do this I am looking at recordsets and ado where I cannot find a decent
documented method i can work with. So far I have created
soucon = "Provider=" & Master.TextBox22.Value & ";Data Source=" &
Master.TextBox23.Value _
& ";Initial Catalog=" & Master.TextBox24.Value & ";User id=" &
Master.TextBox25.Value _
& ";Password=" & Master.TextBox26.Value
Set ConSource = CreateObject("ADODB.Connection")
ConSource.Open soucon
which i believe works and connects to Master - how do i now create a
recordset and populate my list box is my question ?
If you respond thank you for your time and efforts as always
kind regards