Re: remoting options
- From: peter <apvx95@xxxxxxxxxxxxx>
- Date: Tue, 28 Jun 2005 19:17:37 +0100
Sorry to reply to my own post, but I've thought about it and I think I can see a bit where you're coming from;
peter wrote:
Do you have the following lines (or their VB equivalent) somewhere in your code (hopefully in Application_start()):
string path = Server.MapPath("config_file_name"); RemotingConfiguration.Configure(path);
As I've said, I don't use IIS, so I'm speaking a bit without the book here. Still, that's never stopped me before :)
The problem as I see it is that you've got IIS acting as both server and client. I don't even know if this is possible.
I also don't know if you can use a configuration file on the client side for a remote object hosted in IIS: although I don't see why not. If you were to do this, that config file would *not* be web.config. Putting client-side remoting configuration details in web.config does not work (or so I'm told). The client side config file would look something like this:
<configuration> <system.runtime.remoting> <application> <client> <wellknown type="fully.qualified.type.name, locationOfTheType" url="http://localhost/objectURI.rem" /> </client> </application> </system.runtime.remoting> </configuration>
If you have a config file like this and are then using the two lines I put in my previous post (above), then you're configuring remoting on the client side through a config file.
If you are not using a config file, then you need some lines like this in your code:
HttpClientChannel channel = new HttpClientChannel(); ChannelServices.RegisterChannel(channel);
myObj = (myObj)Activator.GetObject(typeof(myObj), @"http://localhost/path/to/objectURI.rem");
(You'll need the VB equivalent, of course, but it's very similar.)
You'll also need a reference to your proxy|interface|abstract base class in your client project references (*not* to the object itself, although it would probably work in this case).
If none of the above makes sense, my advice is to try to create a simple console application client with just enough code in it to prove that it's getting a constructive response from the remote object.
If you don't have lines in your client like:
RemotingConfiguration.Configure(path);
or (alternatively)
myObj = (myObj)Activator.GetObject(typeof(myObj), @"http://......");
Then I can't see how you're making a remote call. Without knowing the full story, I would suspect in this case that you're actually making a local call to a dll referenced in your client code.
HTH
Peter .
- References:
- remoting options
- From: param
- RE: remoting options
- From: [MSFT]
- Re: remoting options
- From: param
- Re: remoting options
- From: richlm
- Re: remoting options
- From: param
- Re: remoting options
- From: peter
- Re: remoting options
- From: param
- Re: remoting options
- From: peter
- Re: remoting options
- From: param
- Re: remoting options
- From: peter
- Re: remoting options
- From: param
- Re: remoting options
- From: peter
- Re: remoting options
- From: param
- Re: remoting options
- From: peter
- Re: remoting options
- From: param
- Re: remoting options
- From: peter
- remoting options
- Prev by Date: Re: remoting options
- Next by Date: Re: remoting options
- Previous by thread: Re: remoting options
- Next by thread: Re: remoting options
- Index(es):
Relevant Pages
|
Loading