Unconfigured Ad Widget

Collapse

Announcement

Collapse
No announcement yet.

Calling AS400 Stored Procedures from VB6

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Calling AS400 Stored Procedures from VB6

    Instead using adParamOutput use adReturnValue. Sky

  • #2
    Calling AS400 Stored Procedures from VB6

    I tried that (actually, I think it's adParamReturnValue), but I am getting the same error.

    Comment


    • #3
      Calling AS400 Stored Procedures from VB6

      cmAS400.Parameters("CustID") = quoteCust.value cmAS400.Parameters("ProdID") = productID.value cmAS400.Parameters("Status") = "" Sky

      Comment


      • #4
        Calling AS400 Stored Procedures from VB6

        I tried that, and I got a compile error "Invalid Qualifier".

        Comment


        • #5
          Calling AS400 Stored Procedures from VB6

          Try to debug your program and see if quoteCust and productID are not blanks. otherwise declare your variable public or global if it declared on different module. Your stored procedure must also have the same type as your pass parameters. Sky

          Comment


          • #6
            Calling AS400 Stored Procedures from VB6

            I did a debug, and the values of the 2 input parameters both have a value when I make the call. I have them defined as String in the VB App, and as Character in the Stored Procedure definition on the AS400. I assume these are the same (there is no String on the AS400). Also, everything is being done in one subroutine, so I don't think I need to make the variables Public, but let me know if you think otherwise.

            Comment


            • #7
              Calling AS400 Stored Procedures from VB6

              I am trying to call an AS400 stored procedure from VB6. This is a stored procedure that accepts 2 input parameters, calls an AS400 CL program, and returns 1 parameter. I have done this exact same thing from an ASP page, and it works fine, but I am having trouble doing it from VB. (See code included.) When I do the Execute, I receive the following error: "Multiple Step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done." Does anybody know what I am doing wrong?
              Code

              Comment


              • #8
                Calling AS400 Stored Procedures from VB6

                If your Stored Procedure is expecting parameters you may either hard code them in your ADO application or supply them dynamically during run time. If you decide to dynamically pass the parameters, use prepared statements and parameter markers in your program.

                Comment

                Working...
                X