RangeExpression.DataField 屬性
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
取得或設定用於比較的欄位。
public:
property System::String ^ DataField { System::String ^ get(); void set(System::String ^ value); };
public string DataField { get; set; }
member this.DataField : string with get, set
Public Property DataField As String
屬性值
比較時要用的欄位。
範例
以下範例說明如何在 AdventureWorks 資料庫的產品表中搜尋列出價格欄位,尋找標價在 和 FromTextBox 文字框中指定的ToTextBox範圍內的產品。
此程式碼範例是《 Walkthrough:使用宣告式語法過濾網頁資料》中提供較大範例的一部分。
<asp:RangeExpression DataField="ListPrice"
MinType="Inclusive" MaxType="Exclusive">
<asp:ControlParameter ControlID="FromTextBox" />
<asp:ControlParameter ControlID="ToTextBox" />
</asp:RangeExpression>
備註
範圍表達式會搜尋指定範圍的資料欄位。