Color.ToString Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates a string representation of the color by using the sRGB
channels.
Overloads
ToString() |
Creates a string representation of the color using the |
ToString(IFormatProvider) |
Creates a string representation of the color by using the |
ToString()
Creates a string representation of the color using the sRGB
channels.
public:
override System::String ^ ToString();
public override string ToString ();
override this.ToString : unit -> string
Public Overrides Function ToString () As String
Returns
The string representation of the color. The default implementation represents the Byte values in hex form, prefixes with the #
character, and starts with the alpha channel. For example, the ToString() value for AliceBlue is #FFF0F8FF
.
Applies to
ToString(IFormatProvider)
Creates a string representation of the color by using the sRGB
channels and the specified format provider.
public:
System::String ^ ToString(IFormatProvider ^ provider);
public string ToString (IFormatProvider provider);
override this.ToString : IFormatProvider -> string
Public Function ToString (provider As IFormatProvider) As String
Parameters
- provider
- IFormatProvider
Culture-specific formatting information.
Returns
The string representation of the color.
Applies to
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應