Remoting parameters with config file
how can we specify remoting parameters with the help config files?
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Prasant JinagaRank #2,383 · 594 reputationPosted Sep 28, 2011, 1:49 AM EDT
Both remoting server and remoting client parameters can be provided through config
files.Below is a sample of server config file which provides all remoting parameter values
which we where providing through code.
type="Server.ClsServer, Server"
objectUri="RemoteObject" />
Later this config file can be loaded using the following code.
RemotingConfiguration.Configure(AppDomain.CurrentDomain.SetupInformation.ApplicationBase
& "Server.config")
Same way we also have client.config file for loading the client remoting parameters.
url = "tcp://localhost:9000/Server/RemoteObject"/>
client remoting can then load the configuration file by using :-
Dim IobjCommon As CommonInterFace.Icommon
Dim StrData As String
Dim objServiceEntries As WellKnownClientTypeEntry()
RemotingConfiguration.Configure(AppDomain.CurrentDomain.SetupInformation.ApplicationBase
& "Client.config")
objServiceEntries =
RemotingConfiguration.GetRegisteredWellKnownClientTypes()
IobjCommon = Activator.GetObject(GetType(Icommon),
objServiceEntries(0).ObjectUrl.ToString())
StrData = IobjCommon.GetValue()
Console.WriteLine(" Serve side Data is " & StrData)
Console.ReadLine()
For more Info Refer the below link.
http://www.dotnetspider.com/forum/102213-How-can-you-specify-remoting-parameters-using-Config-files.aspx
Thanks,
Prasant
Lalit MRank #1,186 · 1.5K reputationPosted Sep 28, 2011, 1:56 AM EDT
Code sample here
----------------------
type="Server.ClsServer, Server"
objectUri="RemoteObject" />
Read more
if help kindly check my answer in check box
Thanks Advance ..