I calling a WCF Service using reflections . Where I'm creating a Proxy by using ChannelFactory ,binding and endpoint address.
Let us think that My ServiceContract Name is ISeravice1.
I'm creating a Proxy and calling a specific method in this way:
using (ChannelFactory
{
object oProxy = cf.CreateChannel();
Type oType = oProxy.GetType();
MethodInfo oMeth = oType.GetMethod(method);
oMeth.Invoke(oProxy, args);
}
In the above code I need to pass
If I have many Service Contracts then I need to specify all , so I need to remove hardcoding of name of Service Contract.
Regards,
Ramana
Suthish NairPosted May 24, 2011, 7:00 AM