MenuClick

作者: psmyfish | 来源:发表于2019-05-23 11:20 被阅读2次

MenuClick

private void MenuClick(object sender, RoutedEventArgs e)
        {
            Button ben = (Button)e.OriginalSource;
            Type type = this.GetType();
            Assembly assembly = type.Assembly;
            Page page = (Page)assembly.CreateInstance(type.Namespace + "." + ben.Content);
            this.ContentControlMainPage.Content = new Frame() { Content = page };
        }

相关文章

网友评论

    本文标题:MenuClick

    本文链接:https://www.haomeiwen.com/subject/fxrvzqtx.html