CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> General/Other

 hows to display error from stored procedure

Print topic Send  topic

Author Message
kirkholt

Posts: 1
Posted: 06/13/2006, 1:08 AM

Hello

I'm using ASP and MS sql server 2000

I have and SP that are called from several record-forms.
The SP is call from the after insert / after update / after delete event like this:


Function Tilbud_Villa_AfterUpdate(Sender) 'Tilbud_Villa_AfterUpdate @135-06BEFB6D

'Custom Code @230-73254650
' -------------------------
' Write your own code here.
call MTberegnTilbud(Sender)
' -------------------------
'End Custom Code
End Function 'Close Tilbud_Villa_AfterUpdate @135-54C34B28

The function MTberegntilbud is placed in common.asp and looks like this:

sub MTberegnTilbud(sender)
Set sender.command.Connection = Sender.datasource.Connection
sender.command.CommandType = dsProcedure
sender.command.SP = "Beregntilbud;1"
sender.command.Parameters.ParameterSources("sestilbud_id") = Session("tilbud_id")
sender.command.CommandParameters = Array(Array("@tilbud_id", "sestilbud_id", adInteger, adParamInput, 0, 0, 10, Empty, Empty))
Set sender.command.Parameters.Connection = Sender.datasource.Connection
sender.command.Parameters.AddParameter "@tilbud_id" , "sestilbud_id", ccsInteger, Empty, Empty, Empty, False
sender.command.exec(sender.errors)
end Sub

The problems is that if an error ocurs in the SP, the error is not shown in the record form.

How do I show an error from the SP on the record form ?

Best regards

Ole Kirkholt
MicroTech Software
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

MS Access to Web

Convert MS Access to Web.
Join thousands of Web developers who build Web applications with minimal coding.

CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.