biztalk - Unable to add behaviorExtension in machine.config via c# -
my biztalk application requires me add custom behaviorextension machine.config file. install application via msi, via biztalk deployment framework (btdf), done programmatically well.
now cannot seem find way either list installed behaviors not edit them.
i have following code, after i'm stuck.
// machine.config file. configuration machineconfig = configurationmanager.openmachineconfiguration(); // machine.config file path. configurationfilemap configfile = new configurationfilemap(machineconfig.filepath); // map application configuration file machine // configuration file. configuration config = configurationmanager.openmappedmachineconfiguration(configfile); configurationsectiongroup svcmodel = config.sectiongroups.get("system.servicemodel"); configurationsection extensions = svcmodel.sections.get("extensions");
can give me pointers on how approach this?
you there. extensions
variable of type system.servicemodel.configuration.extensionssection
, has property behaviorextensions containing looking for. so:
var extensions = (system.servicemodel.configuration.extensionssection) svcmodel.sections.get("extensions"); var behaviors = extensions.behaviorextensions;
Comments
Post a Comment