WindowConfiguration.Apply Yöntem
Önceden kaydedilmiş yapılandırma penceresi adlı çağırır.
Ad alanı: EnvDTE
Derleme: EnvDTE (EnvDTE.dll içinde)
Sözdizimi
'Bildirim
Sub Apply ( _
FromCustomViews As Boolean _
)
void Apply(
bool FromCustomViews
)
void Apply(
[InAttribute] bool FromCustomViews
)
abstract Apply :
FromCustomViews:bool -> unit
function Apply(
FromCustomViews : boolean
)
Parametreler
FromCustomViews
Tür: BooleanBu ise true, özel pencere yapılandırma Kalıcılık adlandırılmış görünümünde arama hedeftir.Bu ise false, sonra yüklü, önceden tanımlanmış kalıcı pencere yapılandırmalarının aranır.Varsayılan, true değeridir.
Notlar
Geçerli pencere düzeninizi Visual Studio ortamında adlandırılmış penceresini yapılandırma kaydedebilirsiniz.Kullanmak Item yöntemi, WindowConfigurations istenen yapılandırmayı gidin ve kullanmak üzere koleksiyonu Apply yapılandırmasını geri çağırma yöntemi.
Örnekler
Sub ApplyExample(dte as DTE)
' Set references to all necessary objects.
Dim colWinConfig As WindowConfigurations
Dim objWinConfig As WindowConfiguration
colWinConfig = dte.WindowConfigurations
objWinConfig = colWinConfig.Item(2)
' List the current window configuration, then set it to another
' one.
MsgBox("Current active window configuration: " & _
colWinConfig.ActiveConfigurationName)
objWinConfig.Apply()
MsgBox("Current active window configuration: " & _
colWinConfig.ActiveConfigurationName)
End Sub
void ApplyExample(_DTE dte)
{
// Set references to all necessary objects.
WindowConfigurations colWinConfig;
WindowConfiguration objWinConfig;
colWinConfig = dte.WindowConfigurations;
objWinConfig = colWinConfig.Item(2);
// List the current window configuration, then set it to another
// one.
MessageBox.Show("Current active window configuration: " +
colWinConfig.ActiveConfigurationName);
objWinConfig.Apply(false);
MessageBox.Show("Current active window configuration: " +
colWinConfig.ActiveConfigurationName);
}
.NET Framework Güvenliği
- Anında arayanlar için tam güven. Bu üye kısmen güvenilen kodla kullanılamaz. Daha fazla bilgi için bkz. Kısmen Güvenilen Koddan Kitaplıkları Kullanma.