error 91

Discussion in 'ASP General' started by abcd, Jun 1, 2005.

  1. abcd

    abcd Guest

    I am using asp page and a VB component

    VB component has a simple method which inserts a record into Access databse

    like

    Dim conn As New ADODB.Connection
    Dim cmd As New ADODB.Command
    conn.Open strDSN
    Set cmd.ActiveConnection = conn
    cmd.CommandType = adCmdText

    strQuery = "Insert into Table1 values ("
    strQuery = strQuery + "'" & strID & "',"
    strQuery = strQuery + "'" & strName & "')"

    cmd.CommandText = strQuery

    cmd.Execute

    <after this command I get error 91>

    When I test my component from another VB cient then it works great but
    getting error 91 when called from ASP

    any clues...

    thanks in advance
    abcd, Jun 1, 2005
    #1
    1. Advertising

  2. abcd

    abcd Guest

    I have found the solution....

    my .mdb files needs to have IUSR_<MACHINENAME> permissions !!!

    cheers !


    "abcd" <> wrote in message
    news:...
    >I am using asp page and a VB component
    >
    > VB component has a simple method which inserts a record into Access
    > databse
    >
    > like
    >
    > Dim conn As New ADODB.Connection
    > Dim cmd As New ADODB.Command
    > conn.Open strDSN
    > Set cmd.ActiveConnection = conn
    > cmd.CommandType = adCmdText
    >
    > strQuery = "Insert into Table1 values ("
    > strQuery = strQuery + "'" & strID & "',"
    > strQuery = strQuery + "'" & strName & "')"
    >
    > cmd.CommandText = strQuery
    >
    > cmd.Execute
    >
    > <after this command I get error 91>
    >
    > When I test my component from another VB cient then it works great but
    > getting error 91 when called from ASP
    >
    > any clues...
    >
    > thanks in advance
    >
    >
    abcd, Jun 1, 2005
    #2
    1. Advertising

  3. database permissions ?

    http://www.powerasp.com/content/new/windows_2003_server_and_permissions.asp


    "abcd" <> wrote in message
    news:...
    >I am using asp page and a VB component
    >
    > VB component has a simple method which inserts a record into Access
    > databse
    >
    > like
    >
    > Dim conn As New ADODB.Connection
    > Dim cmd As New ADODB.Command
    > conn.Open strDSN
    > Set cmd.ActiveConnection = conn
    > cmd.CommandType = adCmdText
    >
    > strQuery = "Insert into Table1 values ("
    > strQuery = strQuery + "'" & strID & "',"
    > strQuery = strQuery + "'" & strName & "')"
    >
    > cmd.CommandText = strQuery
    >
    > cmd.Execute
    >
    > <after this command I get error 91>
    >
    > When I test my component from another VB cient then it works great but
    > getting error 91 when called from ASP
    >
    > any clues...
    >
    > thanks in advance
    >
    >
    Kyle Peterson, Jun 1, 2005
    #3
  4. oops.. problem already solved


    "Kyle Peterson" <> wrote in message
    news:...
    > database permissions ?
    >
    > http://www.powerasp.com/content/new/windows_2003_server_and_permissions.asp
    >
    >
    > "abcd" <> wrote in message
    > news:...
    >>I am using asp page and a VB component
    >>
    >> VB component has a simple method which inserts a record into Access
    >> databse
    >>
    >> like
    >>
    >> Dim conn As New ADODB.Connection
    >> Dim cmd As New ADODB.Command
    >> conn.Open strDSN
    >> Set cmd.ActiveConnection = conn
    >> cmd.CommandType = adCmdText
    >>
    >> strQuery = "Insert into Table1 values ("
    >> strQuery = strQuery + "'" & strID & "',"
    >> strQuery = strQuery + "'" & strName & "')"
    >>
    >> cmd.CommandText = strQuery
    >>
    >> cmd.Execute
    >>
    >> <after this command I get error 91>
    >>
    >> When I test my component from another VB cient then it works great but
    >> getting error 91 when called from ASP
    >>
    >> any clues...
    >>
    >> thanks in advance
    >>
    >>

    >
    >
    Kyle Peterson, Jun 1, 2005
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. hfk0
    Replies:
    2
    Views:
    21,660
  2. JavaQueries
    Replies:
    1
    Views:
    3,659
    John C. Bollinger
    Mar 1, 2005
  3. Balaji
    Replies:
    3
    Views:
    10,093
  4. Bishop
    Replies:
    1
    Views:
    774
    Bishop
    Feb 24, 2007
  5. juvi
    Replies:
    3
    Views:
    1,049
    Alexey Smirnov
    Jan 22, 2009
Loading...

Share This Page