مشاركة عبر


Configuration.Properties الخاصية

يحصل على مجموعة من الجميع الخصائص التي تتعلق إلى Configurationالكائن.

مساحة الاسم:  EnvDTE
التجميع:  EnvDTE (في EnvDTE.dll)

بناء الجملة

'إقرار
ReadOnly Property Properties As Properties
    Get
Properties Properties { get; }
property Properties^ Properties {
    Properties^ get ();
}
abstract Properties : Properties
function get Properties () : Properties

قيمة الخاصية

النوع: EnvDTE.Properties
Propertiesمجموعة.

ملاحظات

يتم عرض بعض الخصائص كخصائص auإلىmation تشغيل Solutionالكائن أو الكائنات تحصل تشغيل إلى من خلال الحل، مثل SolutionBuildكائن لإنشاء تبعيات.

أمثلة

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; 
        OutputGroups outPGs;
        Properties props;
        if (dte.Solution.Projects.Count > 0)
        {
            prj = dte.Solution.Projects.Item(1);
            config = prj.ConfigurationManager.ActiveConfiguration;
            // Return a collection of OutputGroup objects that contain
            // the names of files that are outputs for the project.
            outPGs = config.OutputGroups;
            MessageBox.Show(outPGs.Count.ToString());
            // Returns the project for the config.
            MessageBox.Show(((Project)config.Owner).Name);
            // Returning the platform name for the Configuration.
            MessageBox.Show(config.PlatformName);
            // Returning all properties for Configuration object.
            props = config.Properties;
            string p = "";
            foreach (Property prop in props)
            {
                p = p + prop.Name + "\n";
            }
            MessageBox.Show(p);
        }
    }
    catch(Exception ex)
    {
        MessageBox.Show(ex.Message);
    }
}

أمن NET Framework.

راجع أيضًَا

المرجع

Configuration واجهة

Configuration الأعضاء

EnvDTE مساحة الاسم