Asp Forum
Home
|
Login
|
Register
|
Search
Forums
>
microsoft.public.dotnet.framework.remoting
Is it possible to pass web controls?
Robin Prosch via .NET 247
9/7/2004 2:59:00 AM
Hi, I have a bunch of subroutines that expect parameters of type Textbox and HTMLTableCell (i.e. Sub
uf_Test(ByVal loTextbox as Textbox). The problem is that these objects are not inherently serializable,
so whenever I call my remoting object, an excpetion gets raised.
Is there a workaround that does not require me to rewrite the said functions to remove these
parameters? Or maybe I can set System.Web.UI.Webcontrols as <Serializable()>?
Thanks.
-----------------------
Posted by a user from .NET 247 (
http://www.dotn...
)
<Id>1vfZoi1mH0KlclWBDQTipg==</Id>
1 Answer
Ken Kolda
9/7/2004 9:00:00 PM
0
No -- if the class is neither serializable or derives from
MarshalByRefObject, you cannot pass it across a remoting layer. Besides, if
the remoted component is your business layer, you wouldn't want to pass UI
elements to it anyway -- that ties your business layer to a UI
implementation.
As for marking WebControl as Serializable, you can't do that. A control
object is most definitely not serializable and trying to force it to be
would be futile.
Ken
"TJ Manigo via .NET 247" <anonymous@dotnet247.com> wrote in message
news:e0kxRaIlEHA.1356@TK2MSFTNGP09.phx.gbl...
> Hi, I have a bunch of subroutines that expect parameters of type Textbox
and HTMLTableCell (i.e. Sub
>
> uf_Test(ByVal loTextbox as Textbox). The problem is that these objects are
not inherently serializable,
>
> so whenever I call my remoting object, an excpetion gets raised.
>
> Is there a workaround that does not require me to rewrite the said
functions to remove these
>
> parameters? Or maybe I can set System.Web.UI.Webcontrols as
<Serializable()>?
>
> Thanks.
>
> -----------------------
> Posted by a user from .NET 247 (
http://www.dotn...
)
>
> <Id>1vfZoi1mH0KlclWBDQTipg==</Id>
Servizio di avviso nuovi messaggi
Ricevi direttamente nella tua mail i nuovi messaggi per
Is it possible to pass web controls?
Inserendo la tua e-mail nella casella sotto, riceverai un avviso tramite posta elettronica ogni volta che il motore di ricerca troverà un nuovo messaggio per te
Il servizio è completamente GRATUITO!
x
Login to ForumsZone
Login with Google
Login with E-Mail & Password