WebPartZoneBase.CreateWebPartChrome 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.
Enables derived zones to substitute a custom WebPartChrome object to change the appearance of WebPart controls in a zone.
protected:
virtual System::Web::UI::WebControls::WebParts::WebPartChrome ^ CreateWebPartChrome();
protected virtual System.Web.UI.WebControls.WebParts.WebPartChrome CreateWebPartChrome ();
abstract member CreateWebPartChrome : unit -> System.Web.UI.WebControls.WebParts.WebPartChrome
override this.CreateWebPartChrome : unit -> System.Web.UI.WebControls.WebParts.WebPartChrome
Protected Overridable Function CreateWebPartChrome () As WebPartChrome
Returns
A WebPartChrome that determines how WebPart controls in a zone are rendered.
Remarks
Web Parts chrome refers to the peripheral user interface (UI) elements that frame each WebPart control in a zone. The chrome for a WebPart control includes its border, its title bar, and the icons, title text, and verbs menu that appear within the title bar. The appearance of the chrome is set at the zone level, and applies to all WebPart controls in a zone.
Important
The WebPartChrome object affects the entire rendering of the WebPart controls, not merely their chrome elements.
To use the CreateWebPartChrome method, you must create a custom WebPartChrome object to define the appearance of the chrome for Web Parts controls in a zone. You must also create a custom zone that inherits from the WebPartZoneBase class and overrides the CreateWebPartChrome method to be able to substitute your custom chrome object and apply it to the controls in the zone.
Applies to
See also
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應