English 中文(简体)
有可能从银灯系统消失。 Windows.Controls。 页: 1
原标题:Is it possible to descend from Silverlight s System.Windows.Controls.Page?

我想创造银星导航框架系列的后代,因此,我可以在我的所有网页上执行共同导航法,但我可以说明如何这样做。 当我创建后代阶级时,我如何参考我的XAML档案?

他们目前拥有“缩略语:页数”标签,因此我如何用“米页”取代标签? 我是否有必要补充我的后代?

例:

目前,我有:

<navigation:Page x:Class="Views.About" 
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:navigation="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Navigation"
    mc:Ignorable="d" d:DesignWidth="640" d:DesignHeight="480"
    Title="About" 
    Style="{StaticResource PageStyle}">
...
</navigation:Page>

相反,我要(召集一个“MyOwnPage”类:系统、Windows.Controls.Page)

<MyOwnPage ...>
...
</MyOwnPage>
最佳回答

我现在谈谈这个问题。 采用上述例子,你需要在开幕式上顺便提一下:

xmlns:views="clr-namespace:Views"

之后,宣布基本要素为

<views:MyOwnPage ...>
...
</views:MyOwnPage>
问题回答

暂无回答




相关问题
Template Classes in C++ ... a required skill set?

I m new to C++ and am wondering how much time I should invest in learning how to implement template classes. Are they widely used in industry, or is this something I should move through quickly?

JSON with classes?

Is there a standardized way to store classes in JSON, and then converting them back into classes again from a string? For example, I might have an array of objects of type Questions. I d like to ...

Object-Oriented Perl constructor syntax and named parameters

I m a little confused about what is going on in Perl constructors. I found these two examples perldoc perlbot. package Foo; #In Perl, the constructor is just a subroutine called new. sub new { #I ...

Passing another class amongst instances

I was wondering what is the best practice re. passing (another class) amongst two instances of the same class (lets call this Primary ). So, essentially in the constructor for the first, i can ...

Where can I find object-oriented Perl tutorials? [closed]

A Google search yields a number of results - but which ones are the best? The Perl site appears to contain two - perlboot and perltoot. I m reading these now, but what else is out there? Note: I ve ...

热门标签