ASP.NET說,下面的ImageButton服務器標記的格式不正確:的ImageButton隨着鼠標事件處理考慮不規範
<asp:TableCell VerticalAlign="Top">
<asp:ImageButton runat="server" ID="imgAdd" src="Images/add_plus_1.gif"
onmouseout="this.src='Images/add_plus_1.gif'"
onmouseover="this.src='Images/add_plus_2.gif'"
onmousedown"this.src='Images/add_plus_3.gif'"
CauseValidation="false" style="cursor: pointer"
OnClientClick="Javascript:SL_AddBuilding()" />
</asp:TableCell>
我認爲所有的鼠標事件的屬性是合法的,所以我不知道它在抱怨什麼。
雖然它的工作原理,您應該添加onmouseout,onmouseover,onmousedown通過圖像按鈕的屬性。 – ScottE 2011-01-20 16:10:41