2

is it possible to use resource files (.resx) in ASP.NET for a HTML controls ?

2
  • How do you mean? Can you post an example of what you would like to do? Commented Aug 11, 2010 at 7:43
  • for ASP controls I assign meta:resourcekey="CompanyNameTb", but is it possible to do the same with a HTML tag, e.g. <a></a> ? Commented Aug 11, 2010 at 7:47

1 Answer 1

3

You neeed to add runat="server" to the control.

<input type="button" value="Press Me" runat="server" 
   meta:resourcekey="PressMeButtonResources"/> 

Alternatively, you could retrieve resource values programmatically. Here is a an MSDN Article on how to do that. Then you could generate content on the Server side and apply it to your page.

Sign up to request clarification or add additional context in comments.

1 Comment

is it possible without adding runat="server" to page?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.