开发者

Any way to get the file path to the source file of an embedded resource at runtime?

开发者 https://www.devze.com 2023-03-20 13:08 出处:网络
I am working on a VirtualPathProvider which will let me load embedded resources (ER) (such as .js or .css files) from a referenced assembly. I would like to be able to change the .js files and .css fi

I am working on a VirtualPathProvider which will let me load embedded resources (ER) (such as .js or .css files) from a referenced assembly. I would like to be able to change the .js files and .css files at runtime and have the changes reflected without having to refresh the whole page. I can do this if I have the path to the resource file as I can use that as the source instead of the ER.

Is there any way to extract the source code location of an assemblies csproj or an embedded resource at runtim开发者_Python百科e, perhaps from the .pdb file, and if so, how would I do it in c#? Thanks!

0

精彩评论

暂无评论...
验证码 换一张
取 消