This commit is contained in:
NaBian committed 2020-02-15 19:39:53 +08:00
1 parent d9b94f83fe
commit 7f0330856d
20 files changed
+1159 -52

No files matched your search

@@ -0,0 +1,25 @@
using System;
using System.IO;
using System.Windows;
public class DemoHelper
{
public static void Main()
{
}
public static string GetCode(string demoName)
{
var uri = new Uri($"/HandyControlDemoCode;component/{demoName}", UriKind.Relative);
var resourceStream = Application.GetResourceStream(uri);
if (resourceStream != null)
{
using var reader = new StreamReader(resourceStream.Stream);
var code = reader.ReadToEnd();
return code;
}
return "";
}
}