How to get the comment from a .resx file entry

前端 未结 2 2020
轮回少年
轮回少年 2020-12-02 01:53

Strings in resource files have a name, a value and a comment
The ResXResourceReader class gives me access to the name and the value.
Is there a way to r

相关标签:
2条回答
  • 2020-12-02 02:09

    You should be able to get Comment via ResXDataNode class: http://msdn.microsoft.com/en-us/library/system.resources.resxdatanode.aspx

    You will need to set UseResXDataNodes flag on the reader: http://msdn.microsoft.com/en-us/library/system.resources.resxresourcereader.useresxdatanodes.aspx

    0 讨论(0)
  • 2020-12-02 02:18

    This way seems to work ONLY for .RESX file on disk. If you usethe embedded version, comments seems to be removed.

    0 讨论(0)
提交回复
热议问题