DevExpress GridView显示FK值
我在我的 Winform 项目中使用 DevExpress,在我的表单中有一些外键列,如国家、州、城市,它们是“int”数据类型。
我想显示这些 FK 键的值,即。 (印度、中国、尼泊尔等..)数据来自表,所以它是动态的,DevExpress GridView 有点不同,我无法找到一种方法来做到这一点,有什么建议吗?
详细一点的答案会更有用;)
提前谢谢您。
I am using DevExpress in my Winform project, and in my form there are a few ForeignKey columns, like country, state, city, which are 'int' datatype.
I want to display the value of these FK keys ie. (India, China, Nepal, etc..) & the data comes from tables, so it is dynamic, the DevExpress GridView is a bit different, and I am not able to find a way to do that, any suggestions??
A bit detailed answer will be more useful ;)
Thank you in advance.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
请使用此帖子中演示的方法。
PS 今后,我建议您使用 Devexpress 支持中心 获得官方和有保证的帮助DevExpress 产品的使用。请注意,即使在评估期(30 天)内,全面支持也是免费的。
Please use the approach demonstrated in this thread.
P.S. In the future, I suggest you use the Devexpress Support Center to get official and guaranteed assistance on the use of DevExpress products. Note that FULL SUPPORT IS FREE even during the evaluation period (30 days).
我不知道你如何连接到数据库。我建议使用 Linq Query 从数据库获取数据。因为,它既简单又容易理解。首先,将所有要显示的内容连接起来。
完成了。我希望它对你有帮助
I don't know how do you connect to your databese.I suggest Linq Query for getting data from database. Because,it is both easy and understandable. Firstly, you make join all table what you want to show.
it'is done. I hope it is helpful for you