I have a string resource I can access in my code behind like so:
My.Resources.SomeStringResource
But if I try to access it in the .aspx like this:
<a href="http://someurl.com"><%=My.Resources.SomeStringResource %></a>
It does not compile. It seems My.Computer
, My.Log
, My.Request
and some others are available but not My.Resources
.
Is what I am trying to do possible?
Change the resource access modifier to "Public" in the *.RESX file:
and then access in the code-front like so:
<%= WebApplication1.My.Resources.Resource1.String2%>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With