查看C#数据库中的上一条和下一条记录 [英] View previous and next records in C# database
问题描述
我对c#有点新鲜。我正在开发一个Windows窗体应用程序项目,在这个项目中我开发了一个包含数据库的程序。在表单上,有两个按钮用于上一个记录,另一个用于下一个记录时点击。
还有一个文本框将显示单击下一个或上一个按钮时的记录。有人可以帮我解决这个问题吗?
数据库:
表名:员工
栏目名称:名字,姓氏,性别,工资
谢谢大家。
Hi,
I am some how new to c#. I am developing a windows form application project, in this project i have developed a program that contains a database. on the form, there are 2 buttons one for the previous record and the other for for the next record when clicked.
There is also a textbox that will be displaying the records when the next or previous button is clicked. Can some one please help me on how I would go about on coding this?
Database:
Table name : Employees
Columns name: firstname, lastname, gender, salary
Thank you guys.
推荐答案
请参阅为初学者使用ADO.NET [ ^ ],它有一个例子。
See Using ADO.NET for beginners[^], it has an example of that.
这篇关于查看C#数据库中的上一条和下一条记录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!