PanelStyle.BackImageUrl プロパティ
アセンブリ: System.Web (system.web.dll 内)

Dim instance As PanelStyle Dim value As String value = instance.BackImageUrl instance.BackImageUrl = value
/** @property */ public String get_BackImageUrl () /** @property */ public void set_BackImageUrl (String value)
パネル コントロールの背景イメージの URL。既定値は空の文字列 ("") です。

BackImageUrl プロパティは、パネル コントロールの背景イメージの URL を指定します。このプロパティが正常に機能するためには、イメージ ファイルが指定した場所に存在する必要があります。指定したイメージ ファイルにアクセスできない場合、パネル コントロールの背景イメージは表示されません。

Panel1 と Panel2 の 2 つのパネル コントロールに同じ背景イメージを適用するコード例を次に示します。この例を正常に動作させるには、独自のイメージを提供する必要があります。このコード例は、PanelStyle クラスのトピックで取り上げているコード例の一部分です。
Partial Class PanelStylevb_aspx Inherits Page Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs) Dim panelState As StateBag = New StateBag() Dim myPanelStyle As PanelStyle = New PanelStyle(panelState) ' Set the properties of the PanelStyle class. myPanelStyle.HorizontalAlign = HorizontalAlign.Center myPanelStyle.ScrollBars = ScrollBars.Both myPanelStyle.Wrap = False myPanelStyle.Direction = ContentDirection.LeftToRight myPanelStyle.BackImageUrl = "~\images\picture.jpg" ' Use the ApplyStyle method of the Panel control to apply ' the settings from the myPanelStyle object. Panel1.ApplyStyle(myPanelStyle) Panel2.ApplyStyle(myPanelStyle) End Sub End Class
public partial class PanelStylecs_aspx : Page { void Page_Load(object sender, EventArgs e) { StateBag panelState = new StateBag(); PanelStyle myPanelStyle = new PanelStyle(panelState); // Set the properties of the PanelStyle class. myPanelStyle.HorizontalAlign = HorizontalAlign.Center; myPanelStyle.ScrollBars = ScrollBars.Both; myPanelStyle.Wrap = false; myPanelStyle.Direction = ContentDirection.LeftToRight; myPanelStyle.BackImageUrl = @"~\images\picture.jpg"; // Use the ApplyStyle method of the Panel control to apply // the settings from the myPanelStyle object. Panel1.ApplyStyle(myPanelStyle); Panel2.ApplyStyle(myPanelStyle); } }

Windows 98, Windows 2000 SP4, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


Weblioに収録されているすべての辞書からPanelStyle.BackImageUrl プロパティを検索する場合は、下記のリンクをクリックしてください。

- PanelStyle.BackImageUrl プロパティのページへのリンク