Obtient le nom de la société associée à l'application.
Espace de noms : System.Windows.Forms
Assembly : System.Windows.Forms (dans system.windows.forms.dll)
Visual Basic (Déclaration)
Public Shared ReadOnly Property CompanyName As String
Visual Basic (Utilisation)
Dim value As String
value = Application.CompanyName
public static string CompanyName { get; }
public:
static property String^ CompanyName {
String^ get ();
}
/** @property */
public static String get_CompanyName ()
public static function get CompanyName () : String
Valeur de la propriété
Nom de la société.
L'exemple de code suivant permet d'obtenir cette propriété et d'afficher sa valeur dans une zone de texte. L'exemple requiert que textBox1 ait été placé dans un formulaire.
Private Sub PrintCompanyName()
textBox1.Text = "The company name is: " & _
Application.CompanyName
End Sub
private void PrintCompanyName() {
textBox1.Text = "The company name is: " + Application.CompanyName;
}
private:
void PrintCompanyName()
{
textBox1->Text = String::Format( "The company name is: {0}",
Application::CompanyName );
}
private void PrintCompanyName()
{
textBox1.set_Text("The company name is: "
+ Application.get_CompanyName());
} //PrintCompanyName
Windows 98, Windows 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile pour Pocket PC, Windows Mobile pour Smartphone, Windows Server 2003, Windows XP Édition Media Center, Windows XP Professionnel Édition x64, Windows XP SP2, Windows XP Starter Edition
Le .NET Framework ne prend pas en charge toutes les versions de chaque plate-forme. Pour obtenir la liste des versions prises en charge, consultez Configuration requise.
.NET Framework
Prise en charge dans : 2.0, 1.1, 1.0