Fix passing exception through remoting problem
Messages   Related Types
This message was discovered on microsoft.public.dotnet.framework.remoting.
Responses highlighted in red are from those people who are likely to be able to contribute good, authoratitive information to this discussion. They include Microsoft employees, MVP's and others who IMHO contribute well to these kinds of discussions.
Post a new message to this list...

msnews.microsoft.com
Exception can be thrown from remoting server to client on .net frame 1.0, it
starts have problem since 1.1 came, when will MicroSoft fix this problem?

Reply to this message...
 
    
Robert Jordan
msnews.microsoft.com wrote:
[Original message clipped]

It's not a bug. You have to put this in your App.config:

<configuration>
<system.runtime.remoting>
<customErrors mode="off" />
</system.runtime.remoting>
</configuration>

bye
Rob
Reply to this message...
 
    
msnews.microsoft.com
"Robert Jordan" <Click here to reveal e-mail address> wrote in message
news:ch7lf3$vr0$00$Click here to reveal e-mail address...
[Original message clipped]

I tried customErrors off, it does not help. Somebody said that you need
implement server side exceptions to inherit ApplicationException,implement
ISerializable,IDisposible and add a default protected ctr, but I want server
propagrates all orginal exceptions to remoting client.

Simon

Reply to this message...
 
    
Charlie (VIP)
I can throw a System.Exception from remoting server to client on 1.1
Framework and I haven't nothing special in my code. I had some troubles when
I tried to throw an custom exception which inherits of a
ApplicationException, then I had to implement the constructor for the
seriabilization process... but standard .Net exception is not required.

"msnews.microsoft.com" wrote:

[Original message clipped]

Reply to this message...
 
    
msnews.microsoft.com
I can not throw System.ComponentModel.WarningException to client and oracle
exceptions defined by ODP.NET, can you?

Simon

"Charlie" <Click here to reveal e-mail address> wrote in message
news:Click here to reveal e-mail address...
[Original message clipped]

Reply to this message...
 
    
Robert Jordan
msnews.microsoft.com wrote:

[Original message clipped]

System.ComponentModel.WarningException ist not serializable,
so it cannot be transmitted.

bye
Rob
Reply to this message...
 
    
msnews.microsoft.com
I can not throw Exception either.

Simon

"Robert Jordan" <Click here to reveal e-mail address> wrote in message
news:ch8525$iqj$01$Click here to reveal e-mail address...
[Original message clipped]

Reply to this message...
 
    
Lord2702
Fri. Sep. 03, 2004 12:10 PM PT

I want to throw DBConcurrencyException, But I can not get this exception on
client side, hence I derive it from ApplicationException, and ISerializable,
and IDisposable. a Lot of work, But still surprised, evenif
DBConcurrencyException is marked as serializable, and ISerializable, but we
can not throw it. I suppose it is a BUG. But for me, I HAVE to find some way
to throw this exception.

Good Luck!

"msnews.microsoft.com" <Click here to reveal e-mail address> wrote in message
news:%23%Click here to reveal e-mail address...
[Original message clipped]

Reply to this message...
 
 
System.ApplicationException
System.ComponentModel.WarningException
System.Data.DBConcurrencyException
System.Exception
System.IDisposable
System.Runtime.Serialization.ISerializable




Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
 
 Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us - Terms of Use - Privacy Policy - www.dotnet247.com