For handling exception just need to write 4 additional statements!
BEGIN TRY
print convert(int, 'hi')
END TRY
BEGIN CATCH
print @@ERROR
print 'ERROR'
END CATCH
OUTPUT:
245
ERROR
It's simple!!
Information Sharing, Technical Articles. You can find solutions, best precticies for ASP.net application. More knowledge sharing on C#, AJAX, SQL, .Net Framework, OOPs Concepts, SQL Server 2005, SQL Server 2000, Programming.
BEGIN TRY
print convert(int, 'hi')
END TRY
BEGIN CATCH
print @@ERROR
print 'ERROR'
END CATCH
Blog.Feed() | : | Rss 2.0 |
Blog.PageCounter() | : | |
Me.Resume() | : | Imran Bhadelia |
Me.Consult() | : | Click Here |
No comments:
Post a Comment