Solved

RaisError in Vb6 not showing up

Posted on 2002-05-21
3
750 Views
Last Modified: 2008-03-06
I have a trigger on insert that uses 2 select statements to check to see if the transaction is rolled backed or not. When the condition is met to be rolled back I use the
RaisError ('This transaction will be rolled back', 16, 1)
message. the only problem is that the message is not getting back to the vb application although the record is being rolled back. If I run it in the analyzer I do see the message.
I am using SQL 2000.

0
Comment
Question by:rvindust
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 7025687
Please maintain your open questions:

Faxing from exchange Date: 11/16/2000 11:45AM PST
http://www.experts-exchange.com/jsp/qShow.jsp?ta=exchangesvr&qid=11890858
SQL Setup Date: 03/12/2001 04:52AM PST
http://www.experts-exchange.com/jsp/qShow.jsp?ta=mssql&qid=20090209
Domain logon permissions Date: 08/29/2001 05:04AM PST
http://www.experts-exchange.com/jsp/qShow.jsp?ta=win2k&qid=20175621
DSL VPN connection sharing Date: 01/10/2002 08:45AM PST
http://www.experts-exchange.com/jsp/qShow.jsp?ta=win2k&qid=20253681
VPN Logon Date: 02/16/2002 09:16AM PST
http://www.experts-exchange.com/jsp/qShow.jsp?ta=win2k&qid=20267631

Thanks,
Anthony  
0
 

Accepted Solution

by:
VBMeera earned 50 total points
ID: 7031220
hey,
r u using the same syntax in vb
"RaisError ('This transaction will be rolled back', 16, 1)"
the above is not Vb syntax
err.raise (err.number,err.source,err.description)
try this
0
 

Author Comment

by:rvindust
ID: 7236347
I found some information on this. you have to move thru the errors collection because VB does not always raise the error.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

717 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question