Configuration.IsDeployable الخاصية
يحصل على ما إذا كان مشروع أو المشاريع العنصر يمكن نشر التكوين.
مساحة الاسم: EnvDTE
التجميع: EnvDTE (في EnvDTE.dll)
بناء الجملة
'إقرار
ReadOnly Property IsDeployable As Boolean
Get
bool IsDeployable { get; }
property bool IsDeployable {
bool get ();
}
abstract IsDeployable : bool
function get IsDeployable () : boolean
قيمة الخاصية
النوع: System.Boolean
قيمة منطقية تشير إلى trueإذا كان المشروع أو مشروع العنصر يمكن نشرة، falseإذا عدم.
ملاحظات
للإشارة إلى ما إذا كان يجب أن يتم نشر مشروع أو العنصر، قم بتحديد في SolutionContextكـ h أي التكوين كـ سياق ونشر لتكوين محدد للحل.
أمثلة
public void CodeExample(DTE2 dte, AddIn addin)
{ // Make sure you have a solution loaded into Visual Studio
// before running the following example.
try
{
Project prj;
Configuration config;
if (dte.Solution.Projects.Count > 0)
{
prj = dte.Solution.Projects.Item(1);
config = prj.ConfigurationManager.ActiveConfiguration;
// Determine and show whether the active configuration can be deployed.
MessageBox.Show(config.IsDeployable.ToString());
}
}
catch(Exception ex)
{
MessageBox.Show(ex.Message);
}
}
أمن NET Framework.
- الثقة الكاملة للمتصل الفوري. يتعذر استخدام هذا العضو بواسطة التعليمات البرمجية الموثوق بها جزئيًا. لمزيد من المعلومات، راجع باستخدام مكتبات من تعليمات برمجية موثوق بها جزئي.
راجع أيضًَا
المرجع
موارد أخرى
كيفية: الترجمة وإعادة تشغيل أمثلة التعليمات البرمجية لطراز كائن التنفيذ التلقائي