Questions tagged [app-globalresources]

42 questions
37
votes
3 answers

How to use app_GlobalResource or app_LocalResource?

How to use them in a ASP.NET Web Application project? Any difference? many thanks
12
votes
2 answers

AppHarbor: The directory '/App_GlobalResources/' is not allowed because the application is precompiled

I trying to deploy my ASP.NET WebForms application to AppHarbor. After a succesful deploy I get The directory '/App_GlobalResources/' is not allowed because the application is precompiled I disabled the Precompilation in the app settings but it did…
Igor Kulman
  • 16,211
  • 10
  • 57
  • 118
9
votes
3 answers

How do you Moq a .resx that lives in App_GlobalResource?

I'm writing unit tests for a controller in an MVC3 web project, but my tests throw exceptions when they try and access a resource like this: return Index(Resources.Strings.MyStringResource); The resource is a .resx file titled Strings. I'm using…
8
votes
4 answers

How to get a string from .resx file to a .js file

I want to show an alert message in two different language. I am using asp.net App_GlobalResources. Can I use it inside my script.js file?
Manu A N
  • 131
  • 1
  • 1
  • 5
7
votes
2 answers

Localization in ASP.NET MVC 4 using App_GlobalResources

I am trying to accomplish two things: Localize the “built-in” error messages for “FieldMustBeDate” and "FieldMustBeNumeric". Localize some of the other error messages you would encounter, for example, "PropertyValueRequired". By using…
6
votes
2 answers

Default ASP.NET Themes

Is it possible to create a default theme for an ASP.NET Website? For example, If I had a theme called "Default", and ive selected a theme called "NewTheme" and I referenced a file which doesn't exist in the "NewTheme" but does exist in the "Default"…
Curtis
  • 101,612
  • 66
  • 270
  • 352
3
votes
2 answers

App_GlobalResources Globalization

I'm having some problems with globalization. I inherited a very old project in ASP.NET 2.0. It has several globalization files for multiple languages. However, when I build the application for deployment, it runs fine in our test environment. But…
Sean
  • 2,496
  • 7
  • 32
  • 60
3
votes
1 answer

App_GlobalResources doesn't work in my web application

I created two resx files and add them to App_GlobalResources folder under my application. here are the values and here my label So I changed the language settings in Internet Explorer and it's not working. I only can see english version. Am I…
3
votes
2 answers

Nightmare with Localization under Global Resources

I have two Resources files under App_GlobalResources MyApp.resx MyApp.sv.resx for those who don't know: All languages will fallback to MyApp.resx except the Swedish UICulture will use the MyApp.sv.resx and I have a simple page that shows 3…
balexandre
  • 73,608
  • 45
  • 233
  • 342
3
votes
2 answers

Can we use Resource Expressions in javascript and other parts except Literal?

The Literal control works all the time But if I want to use this as a parameter in an image, like
balexandre
  • 73,608
  • 45
  • 233
  • 342
2
votes
0 answers

Not getting resource file from DefaultModelBinder.ResourceClassKey

In my MVC3 project, in Global.Application_Start(), I have System.Web.Mvc.DefaultModelBinder.ResourceClassKey = "DefaultModelBinder"; I also have 2 resource files in App_GlobalResources: DefaultModelBinder.resx DefaultModelBinder.fr.resx Why isn't…
getit
  • 623
  • 2
  • 8
  • 30
2
votes
3 answers

MVC App_GlobalResources, use local and publish

I have a problem with GlobalResources I create App_GlobalResources folder Add User.resx Add Name = "FirstName", Value = "First name" Default I can't use this resources in my MVC project. I tried: App_GlobalResources.User.FirstName - did not…
18666
  • 125
  • 1
  • 18
2
votes
1 answer

Can I use a resource (resx) file as an "Embedded Resource" *as well as* as "Content"?

I have a resx file in the App_GlobalResources folder of my ASP.NET web application. Its build property must be set to "Content", so that the file is automatically included during publishing and I can use <%$ Resources: ... %> expressions. Its build…
Heinzi
  • 167,459
  • 57
  • 363
  • 519
2
votes
3 answers

Why am I getting App_GlobalResources assembly generated? (Error = CS0433)

I'm working on a ASP.NET MVC2 project, for which I have configured the localisation as follows ... I have a separate Resources assembly, containing all my resx files. The settings for each resx file are... Build Action = Embedded…
Antony Scott
  • 21,690
  • 12
  • 62
  • 94
2
votes
0 answers

App_GlobalResources from resx file in my class library

How to transfer in runtime my cystom resrouce file in my class library to App_GlobalResources folder in my mvc web application?
Luciano Castro
  • 421
  • 4
  • 13
1
2 3