Idioma

ColorBuilder.BuildColor(IComponent, Control, String) Método

Definição

Inicia um editor de cor para construir um valor de propriedade de cor em HTML.

public:
 static System::String ^ BuildColor(System::ComponentModel::IComponent ^ component, System::Windows::Forms::Control ^ owner, System::String ^ initialColor);
public static string BuildColor(System.ComponentModel.IComponent component, System.Windows.Forms.Control owner, string initialColor);
static member BuildColor : System.ComponentModel.IComponent * System.Windows.Forms.Control * string -> string
Public Shared Function BuildColor (component As IComponent, owner As Control, initialColor As String) As String

Parâmetros

component
IComponent

O IComponent site de quem deve ser usado para aceder a serviços em tempo de design.

owner
Control

Eles Control costumavam ser os responsáveis pela janela do seletor.

initialColor
String

A cor inicial deve ser mostrada na janela do seletor, num formato de cor HTML válido.

Devoluções

O valor de cor, representado como uma cadeia de caracteres num formato de cor HTML, ou null se o serviço de construção não pudesse ser recuperado.

Exemplos

// Create a parent control.
System::Windows::Forms::Control^ c = gcnew System::Windows::Forms::Control;
c->CreateControl();

// Launch the Color Builder using the specified control
// parent and an initial HTML format (S"RRGGBB") color String*.
System::Web::UI::Design::ColorBuilder::BuildColor( this->Component, c, "405599" );
// Create a parent control.
System.Windows.Forms.Control c = new System.Windows.Forms.Control();            
c.CreateControl();            

// Launch the Color Builder using the specified control 
// parent and an initial HTML format ("RRGGBB") color string.
System.Web.UI.Design.ColorBuilder.BuildColor(this.Component, c, "405599");
' Create a parent control.
Dim c As New System.Windows.Forms.Control()
c.CreateControl()

' Launch the Color Builder using the specified control 
' parent and an initial HTML format ("RRGGBB") color string.
System.Web.UI.Design.ColorBuilder.BuildColor(Me.Component, c, "405599")

Observações

A cadeia devolvida, se diferente de null, indica uma cor num formato de cor HTML válido. Formatos válidos incluem cores nomeadas e códigos de cor em formato RGB (#RRGGBB).

Aplica-se a