本文整理汇总了C#中WebsitePanel.Providers.Web.WebVirtualDirectory.GetValue方法的典型用法代码示例。如果您正苦于以下问题:C# WebVirtualDirectory.GetValue方法的具体用法?C# WebVirtualDirectory.GetValue怎么用?C# WebVirtualDirectory.GetValue使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类WebsitePanel.Providers.Web.WebVirtualDirectory
的用法示例。
在下文中一共展示了WebVirtualDirectory.GetValue方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ToggleWmSvcControls
private void ToggleWmSvcControls(WebVirtualDirectory item)
{
if (!item.GetValue<bool>(WebVirtualDirectory.WmSvcAvailable))
{
pnlWmcSvcManagement.Visible = false;
pnlNotInstalled.Visible = true;
//
return;
}
//
pnlWmcSvcManagement.Visible = true;
pnlNotInstalled.Visible = false;
//
string wmSvcAccountName = item.GetValue<string>(WebVirtualDirectory.WmSvcAccountName);
bool wmcSvcSiteEnabled = item.GetValue<bool>(WebVirtualDirectory.WmSvcSiteEnabled);
btnWmSvcSiteEnable.Visible = true;
txtWmSvcAccountName.Visible = true;
//
txtWmSvcAccountPassword.Text = txtWmSvcAccountPassword.Attributes["value"] = String.Empty;
//
txtWmSvcAccountPasswordC.Text = txtWmSvcAccountPasswordC.Attributes["value"] = String.Empty;
// Disable edit mode if WmSvc account name is set
if (wmcSvcSiteEnabled)
{
btnWmSvcSiteEnable.Visible = false;
txtWmSvcAccountName.Visible = false;
//
txtWmSvcAccountPassword.Text = PasswordControl.EMPTY_PASSWORD;
txtWmSvcAccountPassword.Attributes["value"] = PasswordControl.EMPTY_PASSWORD;
//
txtWmSvcAccountPasswordC.Text = PasswordControl.EMPTY_PASSWORD;
txtWmSvcAccountPasswordC.Attributes["value"] = PasswordControl.EMPTY_PASSWORD;
}
//
litWmSvcAccountName.Visible = wmcSvcSiteEnabled;
btnWmSvcSiteDisable.Visible = wmcSvcSiteEnabled;
btnWmSvcChangePassw.Visible = wmcSvcSiteEnabled;
pnlWmSvcSiteDisabled.Visible = !wmcSvcSiteEnabled;
pnlWmSvcSiteEnabled.Visible = wmcSvcSiteEnabled;
//
txtWmSvcAccountName.Text = wmSvcAccountName;
litWmSvcAccountName.Text = wmSvcAccountName;
}
示例2: ToggleWmSvcConnectionHint
private void ToggleWmSvcConnectionHint(WebVirtualDirectory item)
{
bool wmcSvcSiteEnabled = item.GetValue<bool>(WebSite.WmSvcSiteEnabled);
//
if (wmcSvcSiteEnabled)
{
//
string wmSvcServicePort = item.GetValue<String>(WebSite.WmSvcServicePort);
string wmSvcServiceUrl = item.GetValue<String>(WebSite.WmSvcServiceUrl);
//
if (!String.IsNullOrEmpty(wmSvcServiceUrl))
{
if (!String.IsNullOrEmpty(wmSvcServicePort)
&& !String.Equals(wmSvcServicePort, WebSite.WmSvcDefaultPort))
lclWmSvcConnectionHint.Text = String.Format(
lclWmSvcConnectionHint.Text, String.Format("{0}:{1}", wmSvcServiceUrl, wmSvcServicePort), item.Name);
else
lclWmSvcConnectionHint.Text = String.Format(
lclWmSvcConnectionHint.Text, wmSvcServiceUrl, item.Name);
}
else
lclWmSvcConnectionHint.Visible = false;
}
}
示例3: AutoSuggestWmSvcAccontName
private void AutoSuggestWmSvcAccontName(WebVirtualDirectory item)
{
bool wmSvcItemEnabled = item.GetValue<bool>(WebVirtualDirectory.WmSvcSiteEnabled);
//
if (!wmSvcItemEnabled)
{
string autoSuggestedPart = item.Name;
//
if (autoSuggestedPart.Length > 14)
{
autoSuggestedPart = autoSuggestedPart.Substring(0, 14);
//
while (!String.IsNullOrEmpty(autoSuggestedPart) &&
!Char.IsLetterOrDigit(autoSuggestedPart[autoSuggestedPart.Length - 1]))
{
autoSuggestedPart = autoSuggestedPart.Substring(0, autoSuggestedPart.Length - 1);
}
}
//
txtWmSvcAccountName.Text = autoSuggestedPart + "_admin";
}
}