CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    May 2001
    Posts
    19

    Visual Interdev ADO Conn

    This is my code....


    function _initRecordset1()
    {
    var DBConn = Server.CreateObject('ADODB.Connection');
    DBConn.ConnectionTimeout = Application('Conn1_ConnectionTimeout');
    DBConn.CommandTimeout = Application('Conn1_CommandTimeout');
    *line352* DBConn.CursorLocation = Application('Conn1_CursorLocation');
    DBConn.Open(Application('Conn1_ConnectionString'), Application('Conn1_RuntimeUserName'), Application('Conn1_RuntimePassword'));
    var cmdTmp = Server.CreateObject('ADODB.Command');
    var rsTmp = Server.CreateObject('ADODB.Recordset');





    This is my error....

    --------
    ADODB.Connection error '800a0bb9'

    Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.

    /Project_dev/ASP_1.asp, line 352
    ----------

    Line 352 has an asterisk at the beginning...

    I have been beating my head against the wall for hours!! Can someone shed some light on me?! PLEASE!! :-)


    Thnx




  2. #2
    Join Date
    Jan 2000
    Location
    Olen, Belgium
    Posts
    2,477

    Re: Visual Interdev ADO Conn

    The cursolocation can be one of two things, 2 (aka adUseServer) or 3 (aka adUseClient). These are integer values, so you must make sure that whatever value Application(com1_cursorlocation') is integer. My guess is that it is not integer, or might even be empty. Check the value before assigning it, and when an invalid value is given, replace it with a default.

    Tom Cannaerts
    [email protected]

    Programming today is a race between software engineers striving to build bigger and better idot-proof programs, and the universe trying to produce bigger and better idiots. So far, the universe is winning -- Rich Cook
    Tom Cannaerts
    email: [email protected]
    www.tom.be (dutch site)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured