#3 .net4.7之后资源文件引用总结

Open
opened 1 year ago by lyq · 0 comments
天问 commented 1 year ago
  • 引用项目文件夹中的图片:

    
            using (Stream iconStream = System.Windows.Application
                .GetResourceStream(new Uri(
                    $"pack://application:,,,/{Assembly.GetEntryAssembly().GetName().Name};component/Group.ico"))
                .Stream)
    
  • ms-appx协议引用:

    "ms-appx:///License Texts/LicenseSerilogExceptions.txt";
    
* 引用项目文件夹中的图片: ``` using (Stream iconStream = System.Windows.Application .GetResourceStream(new Uri( $"pack://application:,,,/{Assembly.GetEntryAssembly().GetName().Name};component/Group.ico")) .Stream) ``` * ms-appx协议引用: ``` "ms-appx:///License Texts/LicenseSerilogExceptions.txt"; ```
Sign in to join this conversation.
No Label
No Milestone
No assignee
1 Participants
Loading...
Cancel
Save
There is no content yet.