Thanks for the reply Mark, but after much wasted time and hair pulling, I realized I had a typo in the connection string.
Actually, if you look above, I spelled "Initial Catalog" with an extra 't' after the 'n'.
Duhhhh!
Brett
I'm using ADO from VBA to send a CreateTable statment to a SQL server. My connection string looks like this:
"Provider=SQLOLEDB;Server=ServerName;Intitial Catalog=DatabaseName;Integrated Security=SSPI"
I create a command object that uses the above connection string. I set the command...
I think I'm out of luck, but I'll ask anyways.
When the record source of a form is an Access table, a textbox will automatically limit the maximum number of characters that can be typed into to the field size of the text field it's bound to.
I'm using Access 2k and SQL server 2k. The record...
Thanks for the help.
The problem was with my SQL text fields. They were being mapped to Access as 255 character text fields (instead of memo fields.)
The simplest solution was actually decided for me. We're upgrading to office 2000. Access 2000 maps all the SQL fields to appropriate Access...
Well, ADO isn't part of Access97 per se. It's a component installed on your computer that you can use in your Access 97 databases by setting a reference to it. Much the same way you could set a reference to Microsoft Excel and create spreadsheets from your Access databases (if you really wanted...
P.S.
After you've set a refernce to ADO, you have to be very specific when declaring variables. Eg:
Dim myRS as ADODB.Recordset
Set myRS = New ADODB.Recordset
Since both ADO and DAO have recordset objects you need to include the ADODB or DAO prefix when declaring them. There are other shared...
You can use ADO from Access 97.
From any module window go to Tools menu, References... Scroll down through the list, find "Microsoft ActiveX Data Objects 2.6 Library", and put a check it. You may have several versions of ADO installed on your system (I have 2.0, 2.1, 2.6, 2.7). Just...
Try this to open a connection to an Access 97 database:
Dim conn As ADODB.Connection
conn.ConnectionString = "Provider=Microsoft.Jet.OLEDB.3.51;
Data Source=C:\MyDatabase.mdb"
conn.Open
If it's an Access 2000 database, the Provider is Microsoft.Jet.OLEDB.4.0
I've got an Access front end database attaching to SQL server tables through a DSN connection. My table has 34 fields, 26 of which are nchar or nvarchar. Entering data from the table, I'm able to type in the first 17 fields without a problem. However, if I enter any information into fields 18 to...
Sorry. The way I wrote it was confusing. There is more code after the AddNew method is called, but it never gets a chance to run. An error occurs telling me the AddNew method can not be used on that recordset.
Dim cn As New ADODB.Connection
Dim rs As New ADODB.Recordset
Dim strSQL As String...
I am attempting to open an empty recordset from an Access 97 table. Then use the AddNew method of the recordset to add a new record. I'm getting a message saying the OLE DB provider doesn't support this operation or I've chosen the wrong CursorLock.
Code sample:
Dim cn As New ADODB.Connection...
Is there a function that would return the domain user name of the individual logged onto the computer? Or maybe some way to do it through the API?
Thanks,
Brett
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.