Click here to Skip to main content
15,793,609 members
Please Sign up or sign in to vote.
2.00/5 (1 vote)
See more:
In my application there is one class library project and one website.
I create a resource file in class library and modifier of it is public.

I need to use this resource in website layer but i giv error.

<asp:Label ID="Label2" runat="server" Text="<%$ Resources:resourceName, ErrorEmptyName %>"></asp:Label>

The resource object with key 'ErrorEmptyName ' was not found.	

but in code page i access this key:
Label1.Text = resourceName.ErrorEmptyName;
and no error.

my resource file for me is a file with resx extention.

What is wrong?how do it?

Thank you in advance.
Updated 6-Dec-15 8:06am
DotNetSteve 6-Dec-15 14:24pm    
Did you try including the namespace? You can either have like an include on the top or in the line of code. NameSpace.Resources
NewWebDesigner 7-Dec-15 2:33am    
yes i did it but error occure.
Do i need to create an expression builder?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900