borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder

AndreaVB | Forum | News | Downloads | Register | Help | Member List | Statistics | Search | PM | Profile

Print This Topic
Next Topic (MILAGE CALCULATOR) New Topic New Poll Post Reply
AndreaVB Forum : VB General : Need Help On Desire to Implement Proactive Support
Poster Message
matt_1ca
Level: Scholar

Registered: 27-03-2005
Posts: 44

icon Need Help On Desire to Implement Proactive Support

I was wondering about a technique whereby the line number in a module or class or form or subroutine or function where an error is coming from can be reported from an .EXE itself and not just from VB IDE.

After deploying a number of programs on the network, I have concluded that the best way to maintain the system is to become pro-active by the having the program report errors immediately when it happens.

The problem with phone calls is that I as a programmer often do not have adequate information when I get that phone call and could really use a clue as to which portion of the code is failing.

On some situations I do not get the call for problems that they can endure, which is even worse as I do not have any clue that someone is already having problems and I am just sitting around not doing what I can do to help.

Anyhow, my plan is to be able to deploy something in the network which will have somekind of error handling routine in every function and subroutine so that it would report to me if an error has happened and write it down on a text file where I can see it.

Some functions and subroutines that I have however are many lines long and it would really be a great help if I can know exactly which line is the error coming from.

Thank you so much for all the kind help you can give.

Gratefully,
Matt

29-12-2007 at 06:50 PM
View Profile Send Email to User Show All Posts | Quote Reply
stickleprojects
Level: Moderator


Registered: 09-09-2002
Posts: 923
icon Re: Need Help On Desire to Implement Proactive Support

Hi Matt,
In short... reduce the size of your procs!!! Also, download MZ-tools as this is a really cool product for adding error-handlers, line numbers, etc.
I really don't recommend adding line numbers to your entire app as maintenance becomes a real pain.
My error handler appends the name of the current routine into the source, and raises the error back to the calling routine and finally shows it in a tree on the gui, I also log a bunch of important stuff and dump this out if an issue occurs - much more helpful: "error 5 occured in line 10 - index out of range" becomes "Dear User, I'm sorry but an error occured:
Error 5, index out of range
in
frmAccountsEdit
   cmdSaveInvoice_Click
      dbfuncs.OpenDB
         dbfuncs.ReadIniSettings

Please click the button to mail support information to our helpdesk."
you get the idea,
Kieron


____________________________
Build it better, faster, quicker, easier.. then fix it (non-offical MS mission statement)

30-12-2007 at 09:15 AM
View Profile Send Email to User Show All Posts | Quote Reply
matt_1ca
Level: Scholar

Registered: 27-03-2005
Posts: 44
icon Re: Need Help On Desire to Implement Proactive Support

Hello Kieron,

Thanks for sharing with me the technique .. I will go and dig deeper into the MZ-tools you mentioned.  

Thanks again,
Matt

31-12-2007 at 06:22 PM
View Profile Send Email to User Show All Posts | Quote Reply
AndreaVB Forum : VB General : Need Help On Desire to Implement Proactive Support
Next Topic (MILAGE CALCULATOR) New Topic New Poll Post Reply
Surf To:


Not Logged In? Username: Password: Lost your password?
Partners: Download Actual Software | Free Software Download
borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder