473,698 Members | 2,439 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

handle javascript errors on the client side from arbitrary sites

Hello,

I'd like to be able to write an application that runs on a Windows XP
machine and can capture and handle javascript errors from any web site
that a user might encounter while using IE on that box. It doesn't
matter what language the application is written in.

I don't know if this is a Javascript question or a Windows component
question. Any ideas/thoughts on how to do this?

Thanks

Apr 4 '06 #1
3 1500
VK

fi*******@gmail .com wrote:
Hello,

I'd like to be able to write an application that runs on a Windows XP
machine and can capture and handle javascript errors from any web site
that a user might encounter while using IE on that box. It doesn't
matter what language the application is written in.


It is not clear what do you mean by "handle errors". To force the
script engine to disregard any errors and continue execution? This is
kinda pointless and against the common programming practice. I mean if
an error is cricial (no required object, no requested method etc.) then
how do you suppose to continue this block?

If you mean "bring all errors to the attention of user" then IE already
does it by default (red exclamation sign).

You may extend the latter option by installing free Microsoft Script
Debugger module
<http://en.wikipedia.or g/wiki/Microsoft_Scrip t_Debugger>

Now all errors will be displayed consecutively in the debugger window.
Unfortunately this debugger is weak in finding the right line causing
the error, especially with external .js files, so its highlight may be
off the base.

Presumably it is possible to patch jscript.dll so all errors would go
to some external program instead of debugger. This question is related
to C++ programming though, plus I am not sure if such action would be
legal withing your user agreement (smells a lot like reverse
engineering to me). Ask.

Apr 5 '06 #2
Thanks for the response. When I say "handle errors", I mean an
application that can catch JS errors arising from any arbitrary page
that a user browses in IE. The user should then be able to continue
browsing normally (without having to dismiss a JS error dialog).

IE does some level of this if script debugging is disabled, but is not
able to hide all errors from the user. I would like to write a program
that extends this functionality to unconditionally hide any JS error
from the user.

I am not concerned with the continued execution of the JS code; the
user is browsing any arbitrary site and I do not have access to the
code. So, if the site is broken because of a critical JS error that
they did not handle internally, that's fine. Additionally I do not
want to modify the script engine (or any other IE components).

Any ideas on how to do this? Are there any hooks into IE or the script
engine that can be used here?

Thanks

Apr 6 '06 #3
VK

fi*******@gmail .com wrote:
I would like to write a program
that extends this functionality to unconditionally hide any JS error
from the user.


AFAIK it can be done 90% without any programming:
Tools > Internet Options > Advanced
check Disable script debugging
uncheck Display a notification about every script error

That leaves the red exclamation sign only for something IE will
consider to be too important - but it still doesn't disturb the
browsing, because nothing forces you to double click on it to see
what's happened (and most users simply ignore it).

I do not think so that you can go with the rest 10%, because red sign
is not specially appointed to JScript errors. It is a notification sign
for any events browser considers important to report. Say it will be
shown if site doesn't have P3P politics for cookies, or if it tries to
set a cookie not matching to your cookie security settings, or if you
switch security protocol (on high security) etc. You will really need
to "kill" too many reporters for that. Also I would consider such build
as one with seriously damaged security - and the IE's default one is
not the most shinny under the sun ;-)

Any way, contact IEAK department and ask their advise:
<http://www.microsoft.c om/technet/prodtechnol/ie/ieak/default.mspx>

Apr 6 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

31
1758
by: drclue | last post by:
Would you like to display the weather, stocks,movie listings or perhaps send someone an SMS text message or fax? Did you think Google or Yahoo maps was cool? No matter the back end or third-party resource , chances are I could glue it all together with simple javascript running in your page.
0
8683
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8611
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9170
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9031
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8904
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
6531
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5867
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4372
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
2
2341
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.