Пример #1
0
        private void SetVirtualDirProperty(String propertyName, object propertyValue)
        {
            DirectoryEntry virDir = IISWMIHelper.GetIIsWebVirtualDir(SiteId);

            virDir.Properties[propertyName].Value = propertyValue;
            virDir.CommitChanges();
        }
Пример #2
0
        public override void SetASPDotNetVersion(AspDotNetVersion version)
        {
            DirectoryEntry virDir = IISWMIHelper.GetIIsWebVirtualDir(SiteId);

            ScriptMapper.SetASPNetVersion(virDir, version);
            virDir.CommitChanges();
        }
Пример #3
0
        private T GetVirtualDirPropertyDef <T>(String propertyName, T DefaultValue)
        {
            PropertyValueCollection pc = IISWMIHelper.GetIIsWebVirtualDir(SiteId).Properties["propertyName"];

            return((pc != null) ? (T)Convert.ChangeType(pc.Value, typeof(T)) : DefaultValue);
        }