473,322 Members | 1,496 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

Enterprise Library and ASP.NET AJAX

Hi misters,

I have an application web ASP.NET 2.0 using ASP.NET AJAX and Ajax Control
Toolkit. Too, we have Enterprise Library (Exception Handling, Logging)

We need handles errors of AJAX,

Any code sample for use Enterprise Library (Exception Handling) and ASP.NET
AJAX ?
void ScriptManager1_AsyncPostBackError(object sender,
AsyncPostBackErrorEventArgs e)
{
string retError = "Ooops...error ocurrido: " +
"\nsender: " +
((System.Web.UI.ScriptManager)(sender)).AsyncPostB ackSourceElementID +
"\nException Name: " + e.Exception.GetType().FullName +
"\nMessage: " + e.Exception.Message;

ScriptManager.GetCurrent(this.Page).AsyncPostBackE rrorMessage =
retError;
bool rethrow = ExceptionPolicy.HandleException(exception,
TINSA.Servicios.Base.Excepciones.Politicas.Politic asUtil.NOMBRE_POLITICA_PRESENTACION_WEB);

if (rethrow)
{
//throw exception;
}

}

I define my Policy like this:

Exception IExceptionHandler.HandleException(Exception exception, Guid
handlingInstanceId)
{

HttpContext contexto = HttpContext.Current;
if (contexto != null)
{
Page page = contexto.Handler as Page;
if (page != null)
{
// do something
RegisterStartupScript(page, "jsPoliticaExcepcionIU",
"alert('Error Politica IU: " + exception.Message.Replace("'", " ") + "');");
}
}
return exception;
}
Is it possible register script in my policy and the
AsyncPostBackErrorMessage message not appears (AJAX Client not show the
default alert with the AsyncPostBackErrorMessage value, like I cancel show
that message) ?.
Any help will be appreciated, and I'll be very grateful. Thanks in advance.
Greetings, regards.

--
http://www.alhambra-eidos.es/web2005/index.html
www.kiquenet.net
http://www.setbb.com/putainformatica...opic.php?p=843
www.trabajobasura.com/solusoft

Nov 14 '07 #1
0 992

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

Similar topics

8
by: poifull | last post by:
Is anyone using the Microsoft Enterprise Library? If yes, do you like it or not? Any feedback will be appreciated.
3
by: veera sekhar kota | last post by:
hi, im seriously looking for right answer .... We are developing windows application in c#. I implemented DAAB(Data Access Application Block) 2.0 in our application. One of the senior asked...
0
by: veera sekhar kota | last post by:
im seriously looking for right answer .... We are developing windows application in c#. I implemented DAAB(Data Access Application Block) 2.0 in our application. One of the senior asked me to...
0
by: veera sekhar kota | last post by:
im seriously looking for right answer .... We are developing windows application in c#. I implemented DAAB(Data Access Application Block) 2.0 in our application. One of the senior asked me to...
2
by: bjhogan | last post by:
Hi, I have built an c# asp.net application on my laptop, it uses the Enterprise Library blocks - Data Access Application Block, Configuration Application Block. I now want to deploy my...
7
by: galico | last post by:
Hi All, We are having a very strange problem with the above. We have designed an application in ASP.NET 2.0 that uses the enterprise library data application blocks amongst others. We seem to be...
7
by: rockdale | last post by:
hi, I just downloaded Microsoft Enterprise Library Jan 2006 and try to integrate it into my asp.net application. As i am going to connect to mySQL database, I need to include the source code in my...
2
by: Nathan Sokalski | last post by:
I am moving my website from my machine to my webhost, and need some help with what extra files I need to include due to the fact that I used AJAX in my site. Everything on the site is obviously...
1
by: GaryDean | last post by:
I now have installed (from the same install) Enterprise Library - January 2006 and Enterprise Library - June 2005. The install for these two was called Enterprise Library for .Net 2.0. (not...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.