public static Object CreateInstance(string type) { string theServerLocation = ((NameValueCollection)ConfigurationManager.GetSection("appSettings"))["ServerLocation"]; IBusinessServerFactory theFactory = (IBusinessServerFactory)Activator.GetObject(Type.GetType("Application.Interface.IBusinessServerFactory, Application.Interface"), theServerLocation); return(theFactory.CreateInstance(type)); }
public static Object CreateInstance(string type) { string theServerLocation = ConfigurationManager.AppSettings.Get("ServerLocation"); IBusinessServerFactory theFactory = (IBusinessServerFactory)Activator.GetObject(Type.GetType("Application.Interface.IBusinessServerFactory, Application.Interface"), theServerLocation); return(theFactory.CreateInstance(type)); }