Hi Peter,
>> ... certain situations.
The exact situation will matter a lot as to where exactly you do stuff - ie are you coming from a NetWebPage, a NetWebBrowse - and so on.
I think the method you're interested in is p_web.SendError.
This is prototyped as
NetWebServerWorker.SendError PROCEDURE (long p_ErrorNumber, string p_ErrorString, string p_ErrorDescription)
so for example you can do a
p_web.SendError(500,'Internal Server Error','The server is kaput!')
Some common response codes are;
! "200" ; OK
! "201" ; Created
! "202" ; Accepted
! "204" ; No Content
! "301" ; Moved Permanently
! "302" ; Moved Temporarily
! "304" ; Not Modified
! "400" ; Bad Request
! "401" ; Unauthorized
! "403" ; Forbidden
! "404" ; Not Found
! "500" ; Internal Server Error
! "501" ; Not Implemented
! "502" ; Bad Gateway
! "503" ; Service Unavailable
On the subject of error 500 - that's considered to be a very bad "generic" error, although lots of SOAP servers use it. It's much better to have an error in the 400 range if the request itself is invalid.
cheers
Bruce