嗨,我有一个派生自另一个班级的班级.像这样 :
public class Customer
{
public string Date{ get; set; }
public string InstallationNo{ get; set; }
public string SerialNo { get; set; }
}
Run Code Online (Sandbox Code Playgroud)
然后我创建了一个名为Customer_U的类,该类派生自Customer
public class Customer_U:Customer
{
public string Bill{ get; set; }
}
Run Code Online (Sandbox Code Playgroud)
我有一个简单的问题.我有很多时间谷歌,但没有答案.我的列表中填充了以下数据:
List<Customer_U> customer= new List<Customer_U>() 我使用此列表创建一个Excel.在excel colum顺序是这样的:
比尔---日期--- InstalltionNo --- SerialNo.
我想要这个订单.我希望"比尔"成员成为最后一栏.如何在从另一个类派生的类中创建成员的顺序
我在Windows上有3个CheckBoxes.我想启用Button当使用绑定检查任何此CheckBox时.我知道这样的提示:
<Button IsEnabled={Binding ElementName=CheckBox1,Path=IsChecked} />
Run Code Online (Sandbox Code Playgroud)
但是我希望按钮绑定到其他2个CheckBox.
这该怎么做?
我已经使用模型-视图-委托范例实现了一个简单的 QML 应用程序。在我的应用程序中,我使用highlight属性来强调我的ListView. 选择工作正常,但是当我单击远处的项目时,突出显示移动得很慢。
考虑以下示例:
import QtQuick 2.5
ApplicationWindow {
width: 500
height: 400
title: qsTr("List test")
visible: true
ListView {
id: view
anchors.fill: parent
model: 20
delegate: Rectangle {
border.color: "steelblue"
color: Qt.lighter(border.color)
width: ListView.view.width
height: 20
Text { anchors.centerIn: parent; z: 2; text: index + 1 }
MouseArea {
anchors.fill: parent
onClicked: view.currentIndex = index
}
}
highlight: Rectangle {
border.color: "yellow"
border.width: 3
color: "transparent"
height: 20
width: ListView.view.width
z: Infinity
}
} …Run Code Online (Sandbox Code Playgroud)