Home All Groups Group Topic Archive Search About

RESOURCE FILE PROBLEM

Author
1 Apr 2006 1:37 PM
Savas Ates
I created App_GlobalResources directory and I put  my Resource file which is
named
WebResources.resx

It includes one record
name         value
Button1    isbuluyorum

and other fields are empty.

In my Resource.aspx file i add a control  like this

  <asp:Button id="Button1" style="Z-INDEX: 101; LEFT: 204px; POSITION:
absolute; TOP: 150px" runat="server"
Text="<% $ Resources: WebResources,Button1%>"
Width="184px" Height="36px">    </asp:Button>

When I run my application it is supposed to get a value for button1 from
resx file . Therefore It does nothing . No error no warning.
On my button's it is written  like that <% $ Resources:
WebResources,Button1%>

Why it doesnt change my button1's text property ? I want to built a
international web application  so it is a basic application to do more in
the future for me ? How can i find out more about Resource Files . Is it the
best way using Resource Files To built multilanguage web-applications ?

Author
1 Apr 2006 5:13 PM
Nicholas Paldino [.NET/C# MVP]
Savas,

    I don't know if this makes a difference, but try not putting the space
between the % and the $, like so:

<asp:Button id="Button1" style="Z-INDEX: 101; LEFT: 204px; POSITION:
     absolute; TOP: 150px" runat="server"
    Text="<%$ Resources: WebResources,Button1%>"
    Width="184px" Height="36px">    </asp:Button>

    Hope this helps.


--
          - Nicholas Paldino [.NET/C# MVP]
          - mvp@spam.guard.caspershouse.com

Show quoteHide quote
"Savas Ates" <in da club> wrote in message
news:%238HviFZVGHA.5288@TK2MSFTNGP14.phx.gbl...
>I created App_GlobalResources directory and I put  my Resource file which
>is named
> WebResources.resx
>
> It includes one record
> name         value
> Button1    isbuluyorum
>
> and other fields are empty.
>
> In my Resource.aspx file i add a control  like this
>
>  <asp:Button id="Button1" style="Z-INDEX: 101; LEFT: 204px; POSITION:
> absolute; TOP: 150px" runat="server"
> Text="<% $ Resources: WebResources,Button1%>"
> Width="184px" Height="36px">    </asp:Button>
>
> When I run my application it is supposed to get a value for button1 from
> resx file . Therefore It does nothing . No error no warning.
> On my button's it is written  like that <% $ Resources:
> WebResources,Button1%>
>
> Why it doesnt change my button1's text property ? I want to built a
> international web application  so it is a basic application to do more in
> the future for me ? How can i find out more about Resource Files . Is it
> the best way using Resource Files To built multilanguage web-applications
> ?
>
>
>