Strong named resources in F #

Following the instructions in this SO post , I have successfully added the resource file and can request the resources that I have included, but I have to manually use it ResourceManagerto get the embedded resources - for example

let someText = ResourceManager("strings", System.Reflection.Assembly.GetCallingAssembly()).GetObject("SomeText")

In VB.NET and C #, these resources are strongly named. Therefore, if I have a FILE file named "SomeText.txt", I can call it in code using

var someText = MyDefaultNamespace.Properties.Resources.SomeText;

Is there a way for F # resources to be strongly named, for example, they are in C # and VB.NET, in F #? Maybe text template t4?

+4
source share
1 answer

, , , # VB.NET , F # .

+1

Source: https://habr.com/ru/post/1666646/


All Articles