I have an enter button in an ASP.NET form, but I want the text to be displayed from a server side resource file.
The following syntax fails, and I cannot enclose it in a literal, because the input tag cannot contain any other tags:
<input id="btnX" type="button" disabled="disabled" value='<%$Resources:res,Button.Text%>' />
Any possible solutions?
Thanks:)
What about <% = function%>?
I think the answer to the apocalypse should work:
<%= GetLocalResourceObject("Button.Text") %>
or
<%= GetGlobalResourceObject("res", "Button.Text") %>
It will work if you add runat="server" to the input tag.
runat="server"