Connecting to database using Stored Procedure 
Author Message
 Connecting to database using Stored Procedure

I am having a problem trying to connect my database. here
is the code so far:

Private Sub cboCustomer_Click()
    'Shows all the customers & their info
        AdoCustInfo.Recordset.Bookmark = Val
(cboCustomer.ListIndex) + 1
        lblFirst = AdoCustInfo.Recordset.Fields(1)
        lblLast = AdoCustInfo.Recordset.Fields(2)
        lblAddress = AdoCustInfo.Recordset.Fields(3)
        lblCity = AdoCustInfo.Recordset.Fields(4)
        lblState = AdoCustInfo.Recordset.Fields(5)
        lblZip = AdoCustInfo.Recordset.Fields(6)

    'Once you select a Customer you can select their
Orders & calendars
            If cboCustomer.Enabled = True Then
                 cboOrder.Enabled = True
            End If

    'When you select a customer,it populates the OrderID  
information
            adoDelivery.ConnectionString = Connection
            adoDelivery.RecordSource = "CustomerOrder"

End Sub

The last part of the code is missing to connect to the
databae



Mon, 28 Nov 2005 09:08:25 GMT  
 Connecting to database using Stored Procedure
Hi,

Do you need to execute stored procedure with parameters? If yes, then check
next KB with examples

http://support.microsoft.com/default.aspx?scid=kb;en-us;185125

http://support.microsoft.com/default.aspx?scid=kb;en-us;194792

http://support.microsoft.com/default.aspx?scid=kb;en-us;Q164485

--
Val Mazur
Microsoft MVP


Quote:
> I am having a problem trying to connect my database. here
> is the code so far:

> Private Sub cboCustomer_Click()
>     'Shows all the customers & their info
>         AdoCustInfo.Recordset.Bookmark = Val
> (cboCustomer.ListIndex) + 1
>         lblFirst = AdoCustInfo.Recordset.Fields(1)
>         lblLast = AdoCustInfo.Recordset.Fields(2)
>         lblAddress = AdoCustInfo.Recordset.Fields(3)
>         lblCity = AdoCustInfo.Recordset.Fields(4)
>         lblState = AdoCustInfo.Recordset.Fields(5)
>         lblZip = AdoCustInfo.Recordset.Fields(6)

>     'Once you select a Customer you can select their
> Orders & calendars
>             If cboCustomer.Enabled = True Then
>                  cboOrder.Enabled = True
>             End If

>     'When you select a customer,it populates the OrderID
> information
>             adoDelivery.ConnectionString = Connection
>             adoDelivery.RecordSource = "CustomerOrder"

> End Sub

> The last part of the code is missing to connect to the
> databae



Mon, 28 Nov 2005 20:16:40 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Adding NULL to database using Stored Procedure

2. Retrive output parameters when using stored procedure in Sybase database

3. More examples of using stored procedures / stored packages

4. To Stored Procedure or not to stored procedure

5. To stored procedure or not to stored procedure

6. sub report changes its source stored procedure to main report's stored procedure

7. To stored procedure or not to stored procedure

8. ado recordsets from stored procedures, stored procedures have input parameters

9. Unable to connect to Oracle Stored Procedure inside Package

10. Connecting to Oracle stored procedures with both input and output parameters

11. Setting stored procedure parameters using StoredProcParam for a report that uses 2 stored procedures?

12. SQL 7.0 Stored Procedures and Visual Database Tools 1.0

 

 
Powered by phpBB® Forum Software